ffmpeg to extract a video one frame per second?

7.6k views Asked by At

Currently I am using command line to extract pictures from video.

ffmpeg -i ../m.mp4 -f image2 m.mp4-%04d.bmp

This results too many frames.

I would like to extract pictures from a video, one frame per second of video. Preferably with multithreading.

1

There are 1 answers

0
llogan On

Use -r 1 as an output option:

ffmpeg -i input.mp4 -r 1 %04d.bmp

Results in 0001.bmp, 0002.bmp, 0003.bmp, etc.

The BMP encoder currently has no threading capabilities as shown by ffmpeg -h encoder=bmp.