FFMPEG: how to add watermark to video?
- by DocWiki
My Platform: Ubuntu 10.10 + FFMPEG 0.5.3(I installed ffmpeg from source)
I try to add Watermark to a .MOV video with FFMPEG 0.5.3 imlib2.so (Please note FFMPEG 0.6+ dont support imlib2.so, so I use ffmpeg 0.5.3)
Here is my code:
ffmpeg -sameq -i example.mov -vhook '/usr/local/lib/vhook/imlib2.so -x 0 -y 0 -i /var/www/files/watermark.png' newexample.mov
Here is the output:
FFmpeg version 0.5.3, Copyright (c) 2000-2009 Fabrice Bellard, et al.
configuration: --enable-avfilter --enable-filter=movie --enable-avfilter-lavf
libavutil 49.15. 0 / 49.15. 0
libavcodec 52.20. 1 / 52.20. 1
libavformat 52.31. 0 / 52.31. 0
libavdevice 52. 1. 0 / 52. 1. 0
libavfilter 0. 4. 0 / 0. 4. 0
built on Jul 3 2011 12:05:08, gcc: 4.4.5
Seems stream 1 codec frame rate differs from container frame rate: 59.94 (5994/100) - 29.97 (30000/1001)
Input #0, mov,mp4,m4a,3gp,3g2,mj2, from 'example.mov':
Duration: 00:03:14.06, start: 0.000000, bitrate: 3350 kb/s
Stream #0.0(eng): Audio: aac, 48000 Hz, stereo, s16
Stream #0.1(eng): Video: h264, yuv420p, 1150x647, 29.97 tbr, 29.97 tbn, 59.94 tbc
Output #0, mov, to 'newexample.mov':
Stream #0.0(eng): Video: mpeg4, yuv420p, 1150x647, q=2-31, 200 kb/s, 90k tbn, 29.97 tbc
Stream #0.1(eng): Audio: 0x0000, 48000 Hz, stereo, s16, 64 kb/s
Stream mapping:
Stream #0.1 - #0.0
Stream #0.0 - #0.1
Unsupported codec for output stream #0.1
What could be the possible problem? Is that AAC or H264 that is not supported?
I installed libavcodec-extra-52, linfaac, libfaad and etc. but the error is the same.
Do I have to install following this instruction? HOWTO: Install and use the latest FFmpeg and x264 or there is a simpler solution?