I'm using ffmpeg to do two things - add a transparent watermark to the whole video, and also add a title intro image. I'm using the following command to add the watermark:

ffmpeg -i original.mp4 -i watermark.png -filter_complex "overlay=W-w-45:H-h-35" watermarked.mp4

And this command to add the intro:

ffmpeg -itsoffset 2 -i watermarked.mp4 -r 25 -loop 1 -i intro.png -filter_complex "[1:v] fade=out:50:10:alpha=1 [intro]; [0:v][intro] overlay=shortest=1 [v]" -map "[v]" -map 0:a output.mp4

I'm concerned that by processing the video twice, I'm losing quality. Is there a way to add the watermark and the intro with just one ffmpeg command / just one pass on the video?

(I understand the first ffmpeg command above, but I'm a bit lost with the second one - I managed to get it working based on code I saw somewhere)

1 Answer 1


Can't test the below now, but it should be

ffmpeg -itsoffset 2 -i original.mp4 -i watermark.png -loop 1 -t 2.5 -i intro.png -filter_complex "[2:v] fade=out:50:10:alpha=1 [intro]; [0][1]overlay=W-w-45:H-h-35[main];[main][intro] overlay=eof_action=pass [v]" -map "[v]" -map 0:a output.mp4
  • Where does the watermark image come into that? Commented Sep 17, 2018 at 12:10
  • Corrected inputs
    – Gyan
    Commented Sep 17, 2018 at 12:58

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.