[FFmpeg-user] lbavfilter. watermark. time interval.

Mark Himsley mark at mdsh.com
Mon Dec 12 20:17:00 CET 2011


On 12/12/11 15:49, Mark Himsley wrote:
> On 12/12/11 14:29, demimurych wrote:
>
>>> Sorry,I forgot to mention an important detail: while you probably
>>> supposed that I want to use a video sequence as watermark, my
>>> watermark is a static PNG image.I really hope it can work this
>>> way.Best regards,Max
>
> Ah - yes, I agree. Fading a still image over time doesn't appear to
> work. As it happens, I need this feature too.

The best work-around I have so far for the fade a single frame issue is 
to make the watermark image FFmpeg's main input, loop input, and swap 
around the sources in the overlay filter:

Something like this:

ffmpeg -threads 4 -loop_input -i "watermark.png" -vf 
"movie=test_clips.mov,scale=0:0:interl=1,format=yuv420p[bg];[in]scale=0:0:interl=1,format=yuva420p,fade=in:25:25:alpha=1,fade=out:250:25:alpha=1[fg];[bg][fg]overlay=0:0,scale=0:0:interl=1[out]" 
-vcodec dvvideo -aspect 16:9 -top 0 -an -vframes 300 -y "out.mov"

You don't get the sound, so you'd have to do that separately.
You'd have to set the -vframes or it tries to go on for ever, and fails 
when the movie source ends.

What would be nice is a loop_input feature on the movie video filter 
source... That would solve your (and my) problem.

Hope this helps (probably not...)

-- 
Mark


More information about the ffmpeg-user mailing list