109
votes

How do I generate a movie using ffmpeg using a single image (image1.png) for a duration of 15 seconds with a specific resolution so when I play the video, the image will appear on screen for 15 seconds.

1
Googled a lot, but only found questions related to making a video from set of images. +1 to this question!RealZombs

1 Answers

153
votes
ffmpeg -loop 1 -i image.png -c:v libx264 -t 15 -pix_fmt yuv420p -vf scale=320:240 out.mp4
  • The -t 15 makes it 15 seconds long.
  • The -vf scale=320:240 sets the width/height.

Make sure to use the latest ffmpeg version e.g. http://johnvansickle.com/ffmpeg/