User Tools

Site Tools


ffprobe:frame:count_number_of_frames

This is an old revision of the document!


ffprobe - Frame - Count number of frames

ffprobe -v error -select_streams v:0 -count_packets -show_entries stream=nb_read_packets -of csv=p=0 input.mp4

NOTE:

  • -v error - This hides “info” output (version info, etc) which makes parsing easier (but makes it harder if you ask for help since it hides important info).
  • -count_frames - Counts the number of packets per stream and report it in the corresponding stream section.
  • -select_streams v:0 - Select only the first video stream.
  • -show_entries stream=nb_read_packets - Show only the entry for nb_read_frames.
  • -of csv=p=0 - sets the output formatting.
    • In this case it hides the descriptions and only shows the value.
ffprobe/frame/count_number_of_frames.1748337388.txt.gz · Last modified: 2025/05/27 09:16 by peter

Donate Powered by PHP Valid HTML5 Valid CSS Driven by DokuWiki