FFmpeg libavfilter watermark?

2019-09-10 09:15发布

问题:

Since the vhook subsystem has been removed from the latest version of FFMPEG, how can I add a watermark to a video?

the following software is installed on my server:

FFmpeg version SVN-r0.5.1-4:0.5.1-1ubuntu1 with libavfilter 0.4.0

for example: --> but this code does not work.

exec('ffmpeg -i 01.mpg  -vfilters "movie=0:png:watermark.png [logo]; [in][logo] overlay=10:main_h-overlay_h-10 [out]" -f  flv 03.flv');

Thanks,

回答1:

I don't think -vfilters is recognized: use -vf instead. movie doesn't take a list of undefined colon delimited arguments (http://ffmpeg.org/ffmpeg.html#toc-movie)

Try :

ffmpeg -i 01.mpg -vf "movie=watermark.png [logo]; [in][logo] overlay=10:main_h-overlay_h-10 [out]" -f flv 03.flv


标签: php ffmpeg