Pinkie
Pinkie

Reputation: 10256

ffmpeg overlay size

I have the following ffmpeg command which puts an overlay image over the video. After ffmpeg encoding is done the overlay image appears too big, bigger then it's actual size. How do i control width and height dimensions for the overlay image.

ffmpeg -i 1.wmv -s 640x360 -f mp4 -b 800k -acodec libfaac -ab 64k -vf "movie=0:png:dollar.png [wm];[in][wm] overlay=0:0:1 [out]" out.mp4

Upvotes: 8

Views: 5087

Answers (2)

Aakash
Aakash

Reputation: 1900

Try this worked for me : ffmpeg -i basevideo.xxx -vf "movie=overlayvid.xxx [in]; [in] scale=width:height [scale]; [in][scale] overlay=x:y [out]" output.xxx

Upvotes: 3

Alexey Nakonechny
Alexey Nakonechny

Reputation: 116

Try appending filter settings with scale=width:height clause like this:

ffmpeg -i 1.wmv -s 640x360 -f mp4 -b 800k -acodec libfaac -ab 64k -vf "movie=0:png:dollar.png, scale=120:120 [wm];[in][wm] overlay=0:0:1 [out]" out.mp4

Upvotes: 6

Related Questions