videoffmpegvideo-encodingnuke

Convert a video file to an image sequence of equal length?


How using FFMPEG do I convert a video file to a sequence of images that is equal in duration/frames to the original video file?

I'm trying to import video into the non comercial version of Nuke on Linux which refuses to accept h.264 and doesn't have handy a list of accepted codecs that I can find...but plays nice with images sequences...but I can't get the sound to line up with the image sequence.

I tried getting a look at the framerate with:

ffprobe -v 0 -of compact=p=0 -select_streams 0 -show_entries stream=r_frame_rate Forest.mp4 

which returns:

r_frame_rate=30/1

and then I run

ffmpeg -i Forest.mp4 -r 30/1 forest/jpegs%06d.jpg

Solution

  • Assuming your video is constant frame rate (avg_frame_rate should be same as r_frame_rate),

    use

    ffmpeg -i Forest.mp4 -vsync 0 forest/jpegs%06d.jpg