[FFmpeg-user] Best way to get a average bit rate per stream?

William Caulfield william.caulfield at contentbridge.tv
Tue Sep 3 20:14:50 EEST 2019


On Tue, Sep 3, 2019 at 9:38 AM August Johansson <augustperson25 at gmail.com>
wrote:

> Hi,
> I would like to store the average bit rate of every stream in my database.
> I tested using ffprobe -print_format json -show_streams but this
> information does not seem to be there. What would be the best way to return
> this information?
> Thanks
> _______________________________________________


A bit off topic, but I would use mediainfo for this:

mediainfo --Inform="General;%OverallBitRate%" file.ext

That would get you the overall bitrate in bps, eg:  10236425

mediainfo --Inform="General;%OverallBitRate/String%" file.ext

That would get you the overall bitrate in a more Human readable form, eg:
10.2 Mb/s





> --
>

*William Caulfield *| *ContentBridge Systems*


More information about the ffmpeg-user mailing list