How to limit the number of frames ffprobe interprets?
Asked Answered
K

1

12

I have this command

ffprobe -show_frames -select_streams v  -print_format json -i c:\test.mpg

However, it prints off all the frame info. Is there anyway I can limit ffprobe to just look at the first 10 frames? Thanks

B

Klarrisa answered 27/1, 2016 at 17:21 Comment(0)
K
14

-read_intervals will do the trick. e.g. %+2 is to read first 2 sec, %+#2 to read 2 frames.

For example: -read_intervals "%+2"

Klarrisa answered 27/1, 2016 at 17:53 Comment(1)
misleading option name, not quite explained in ffprobe -h, but it actually does work to only read the first x seconds from the input file.Ulick

© 2022 - 2024 — McMap. All rights reserved.