1

I have a list of frames index, for example: [1,5,6,7,100,106,1100].

How I extract a video / audio from source video that only includes the above frames using ffmpeg?

DustinPham
  • 91
  • 1
  • 6

1 Answers1

0

Using FFmpeg 's select filter. Note, frame numbers are zero-based.

ffmpeg -i inputFile.mkv -vf select='eq(n\,1)+eq(n\,5)+eq(n\,6)+eq(n\,7)+eq(n\,100)+eq(n\,106)+eq(n\,1100)' -vsync 0 -vframes 7 frames%d.jpg
SuRGeoNix
  • 482
  • 1
  • 3
  • 10