久久久久久久av_日韩在线中文_看一级毛片视频_日本精品二区_成人深夜福利视频_武道仙尊动漫在线观看

<tfoot id='XTuxK'></tfoot>

    <bdo id='XTuxK'></bdo><ul id='XTuxK'></ul>

<small id='XTuxK'></small><noframes id='XTuxK'>

      <i id='XTuxK'><tr id='XTuxK'><dt id='XTuxK'><q id='XTuxK'><span id='XTuxK'><b id='XTuxK'><form id='XTuxK'><ins id='XTuxK'></ins><ul id='XTuxK'></ul><sub id='XTuxK'></sub></form><legend id='XTuxK'></legend><bdo id='XTuxK'><pre id='XTuxK'><center id='XTuxK'></center></pre></bdo></b><th id='XTuxK'></th></span></q></dt></tr></i><div class="qwawimqqmiuu" id='XTuxK'><tfoot id='XTuxK'></tfoot><dl id='XTuxK'><fieldset id='XTuxK'></fieldset></dl></div>
    1. <legend id='XTuxK'><style id='XTuxK'><dir id='XTuxK'><q id='XTuxK'></q></dir></style></legend>

      1. 在php中使用ffmpeg為視頻添加水印

        Adding watermark to a video by using ffmpeg in php(在php中使用ffmpeg為視頻添加水印)
          <tbody id='fEsgy'></tbody>
        <legend id='fEsgy'><style id='fEsgy'><dir id='fEsgy'><q id='fEsgy'></q></dir></style></legend>

        <small id='fEsgy'></small><noframes id='fEsgy'>

            • <bdo id='fEsgy'></bdo><ul id='fEsgy'></ul>

              • <i id='fEsgy'><tr id='fEsgy'><dt id='fEsgy'><q id='fEsgy'><span id='fEsgy'><b id='fEsgy'><form id='fEsgy'><ins id='fEsgy'></ins><ul id='fEsgy'></ul><sub id='fEsgy'></sub></form><legend id='fEsgy'></legend><bdo id='fEsgy'><pre id='fEsgy'><center id='fEsgy'></center></pre></bdo></b><th id='fEsgy'></th></span></q></dt></tr></i><div class="qwawimqqmiuu" id='fEsgy'><tfoot id='fEsgy'></tfoot><dl id='fEsgy'><fieldset id='fEsgy'></fieldset></dl></div>
                <tfoot id='fEsgy'></tfoot>
                  本文介紹了在php中使用ffmpeg為視頻添加水印的處理方法,對(duì)大家解決問(wèn)題具有一定的參考價(jià)值,需要的朋友們下面隨著小編來(lái)一起學(xué)習(xí)吧!

                  問(wèn)題描述

                  我創(chuàng)建了一個(gè)包含一組圖像和 mp3 的視頻.但我想為該視頻添加水印文本.我正在使用以下代碼添加文本.

                  I created a video with group of images and mp3. But i want to add a watermark text to that video .i am using the below code to add the text.

                  exec('/usr/local/bin/ffmpeg -y -i output.mov -acodec libmp3lame -vcodec msmpeg4 
                  -b:a 192k -b:v 1000k -ar 44100 
                  -vf "drawtext=text=string1 string2 string3 string4 string5 string6 string7 :expansion=normal:fontfile=/usr/bin/DejaVuSerif-BoldItalic-webfont.ttf: y=0:x=h-(2*lh)-n: fontcolor=white: fontsize=40: box=1: boxcolor=0x00000000@1" 
                  -an IMG_0696.avi');
                  

                  這個(gè)問(wèn)題是視頻文件以零大小創(chuàng)建.任何人都可以幫助我.或者建議我任何其他命令來(lái)向視頻添加水印文本.提前謝謝你...

                  The issue with this is that the video file is creating with zero size. Can any one help me please. Or else Suggest me any other command to add watermark text to video. Thank you in advance...

                  推薦答案

                  我正在使用 php-ffmpeg [Below : Composer Json]:

                  I am using php-ffmpeg [Below : Composer Json]:

                  {
                      "require": {
                          "php-ffmpeg/php-ffmpeg": "^0.6.1"
                      }
                  }
                  

                  并且使用這個(gè) php-ffmpeg 庫(kù),您可以使用以下代碼添加水印:

                  and Using this php-ffmpeg library you can add watermark's using the following codes:

                  <?php
                  
                  function processVideo($videoSource,$reqExtension, $watermark = "")
                  {
                      $ffmpeg = FFMpegFFMpeg::create();
                  
                      $video = $ffmpeg->open($videoSource);
                  
                      $format = new FFMpegFormatVideoX264('libmp3lame', 'libx264');
                  
                      if (!empty($watermark))
                      {
                          $video  ->filters()
                                  ->watermark($watermark, array(
                                      'position' => 'relative',
                                      'top' => 25,
                                      'right' => 50,
                                  ));
                      }
                  
                      $format
                      -> setKiloBitrate(1000)
                      -> setAudioChannels(2)
                      -> setAudioKiloBitrate(256);
                  
                      $randomFileName = rand().".$reqExtension";
                      $saveLocation = getcwd(). '/video/'.$randomFileName;
                      $video->save($format, $saveLocation);
                  
                      if (file_exists($saveLocation))
                          return "http://localhost/test/video/$randomFileName";
                      else
                          return "http://localhost/test/thumb/404.png";
                  
                  }
                  
                  echo $videoLocation =  processVideo("sample.mp4","mp4","favicon.png");
                  
                  ?>
                  

                  [請(qǐng)根據(jù)需要更新位置.]

                  [Please, update the location according to your need.]

                  這篇關(guān)于在php中使用ffmpeg為視頻添加水印的文章就介紹到這了,希望我們推薦的答案對(duì)大家有所幫助,也希望大家多多支持html5模板網(wǎng)!

                  【網(wǎng)站聲明】本站部分內(nèi)容來(lái)源于互聯(lián)網(wǎng),旨在幫助大家更快的解決問(wèn)題,如果有圖片或者內(nèi)容侵犯了您的權(quán)益,請(qǐng)聯(lián)系我們刪除處理,感謝您的支持!

                  相關(guān)文檔推薦

                  MySQLi prepared statement amp; foreach loop(MySQLi準(zhǔn)備好的語(yǔ)句amp;foreach 循環(huán))
                  Is mysqli_insert_id() gets record from whole server or from same user?(mysqli_insert_id() 是從整個(gè)服務(wù)器還是從同一用戶獲取記錄?)
                  PHP MySQLi doesn#39;t recognize login info(PHP MySQLi 無(wú)法識(shí)別登錄信息)
                  mysqli_select_db() expects exactly 2 parameters(mysqli_select_db() 需要 2 個(gè)參數(shù))
                  Php mysql pdo query: fill up variable with query result(Php mysql pdo 查詢:用查詢結(jié)果填充變量)
                  MySQLI 28000/1045 Access denied for user #39;root#39;@#39;localhost#39;(MySQLI 28000/1045 用戶“root@“l(fā)ocalhost的訪問(wèn)被拒絕)
                  <legend id='YnBDH'><style id='YnBDH'><dir id='YnBDH'><q id='YnBDH'></q></dir></style></legend>
                  <i id='YnBDH'><tr id='YnBDH'><dt id='YnBDH'><q id='YnBDH'><span id='YnBDH'><b id='YnBDH'><form id='YnBDH'><ins id='YnBDH'></ins><ul id='YnBDH'></ul><sub id='YnBDH'></sub></form><legend id='YnBDH'></legend><bdo id='YnBDH'><pre id='YnBDH'><center id='YnBDH'></center></pre></bdo></b><th id='YnBDH'></th></span></q></dt></tr></i><div class="qwawimqqmiuu" id='YnBDH'><tfoot id='YnBDH'></tfoot><dl id='YnBDH'><fieldset id='YnBDH'></fieldset></dl></div>

                1. <small id='YnBDH'></small><noframes id='YnBDH'>

                  <tfoot id='YnBDH'></tfoot>
                  • <bdo id='YnBDH'></bdo><ul id='YnBDH'></ul>

                              <tbody id='YnBDH'></tbody>

                            主站蜘蛛池模板: 久久69精品久久久久久久电影好 | 日日日色 | 91亚洲精品国偷拍自产在线观看 | 18性欧美 | 国产精品免费一区二区三区四区 | 99re在线视频观看 | 在线一区视频 | 中文字幕第十五页 | 亚洲国产一区二区三区 | 国产精品久久久久久久久久尿 | 国产综合网址 | 久久天天躁狠狠躁夜夜躁2014 | 久久一二 | 欧美a在线 | 日韩中文字幕一区二区 | 亚洲欧美国产精品一区二区 | 亚洲精品www久久久 www.蜜桃av | 日本激情视频中文字幕 | 国产精品99久久久久久久久久久久 | 久久国产成人午夜av影院武则天 | 日韩在线91 | 日本一本在线 | 欧美午夜一区 | 久久久噜噜噜久久中文字幕色伊伊 | 久久曰视频 | 国产高清在线精品一区二区三区 | www.成人在线视频 | 久热精品在线播放 | 天天天操天天天干 | 国产成人精品a视频 | 女同videos另类 | 亚洲欧美成人 | 日韩成人精品一区二区三区 | 视频国产一区 | 成年网站在线观看 | 久久精品视频免费看 | 日韩欧美在线免费观看视频 | 北条麻妃av一区二区三区 | 久久久久国产一区二区三区 | 亚洲成人精品久久久 | 免费在线看黄 |