[FFmpeg-user] Adding Watermark to Video

Kieran O Leary kieran.o.leary at gmail.com
Mon Oct 10 00:31:48 EEST 2016


Hi,

replies below:

On Sunday, 9 October 2016, Al-Haseeb Jafar <alhaseebjafar at gmail.com> wrote:

> I'm completely unfamiliar with ffmpeg (I just know its name).
> On my video site phpvibe CMS is using the following ffmpeg command.
> CMD 1:
> {ffmpeg-cmd} -i {input} -vcodec libx264 -s {ffmpeg-vsize} -threads 4
> -movflags faststart {output}.mp4
> I want to add a functionality to this code of adding watermark to the top
> right corner, padding 10 pixels right and top, while converting the video.
> I found this command for this purpose.
> CMD 2:
> {ffmpeg-cmd} -i {input} -i watermark.png -filter_complex
> "overlay=main_w-overlay_w-10:10" {output}.mp4
> Can you help me properly adding CMD 2 into CMD 1, plz?
>

I haven't tested this but it should work..
 {ffmpeg-cmd} -i {input} -i
/wherever/watermark/is/located/watermark.png  -vcodec libx264 -s
{ffmpeg-vsize} -threads 4
-movflags faststart -filter_complex
"overlay=main_w-overlay_w-10:10" {output}.mp4
>
> And where should be watermark.png? I mean in which directory?


If you don't specify a path, ffmpeg will assume that's it's your current
working directory. You can specify the full path, so instead of
watermark.png, something like /home/user/Downloads/watermark.png, or
wherever your watermark is located.



> I'm ready to pay for this.



There should be no need for this as you should be able to get support here,
but if you wish to donate to the development of ffmpeg
https://www.ffmpeg.org/donations.html

-Kieran


More information about the ffmpeg-user mailing list