Search code examples
ffmpegbitbitratemediainfo

Get bits per each second FFmpeg/Mediainfo


Is there any way to get how many bits per second are in any video?

ej:

ffmpeg/mediainfo -commands input.mkv

Result:

sec 1 - 500bits
sec 2 - 600bits
sec 3 - 300bits

Thanks!


Solution

  • You can output frame information such as the packet size and time with ffprobe:

    ffprobe -show_entries frame=pkt_size,pkt_pts_time <input>

    You can then aggregate them as you like. For eg. the plotframes ffmpeg tool uses this information to generate a video frame size by type plot.

    enter image description here