How to get the information of bit-rate from YouTub

2019-01-02 16:32发布

I was using YouTube videos for my test and I was wondering how can I get the information of bit-rate of the played video?

I used 2 methods to know the information about the bit-rate but didn't get any information.

1. Right-click on a video and choose "Stats for nerds".
2. ffmpeg -i input_video -f ffmetadata metadata.txt

I don't know if by doing the right click on the video and then properties, then details would give me the correct way of showing the bit-rate.

Any suggestions?

1条回答
还给你的自由
2楼-- · 2019-01-02 17:03

Most YouTube video use adaptive bit rate (ABR) format streaming which means that there is not just a single bit rate.

For ABR multiple bit rate versions of the video are created and each one is broken down into equal length (by time) chunks - e.g. 10 second chunks.

The client player is then able to select the next chunk from the most appropriate bit rate stream for the current network conditions - if the network gets busy it can drop down to a lower bit rate for the next chunk and visa versa if the network is good.

So there is not really the concept of a single bit rate for the whole video, but different bit rates for each chunk that is downloaded (although in practice if you have a good connection it should work up to the top bit rate and stay there).

As you say, you can see a visualisation of this on YouTube by right clicking and looking at the 'stats for nerds' option - see example below:

enter image description here

You can also see the available bit rates resolutions, and force the player to select a single one by clicking on the 'wheel' in the bottom right hand corner.

查看更多
登录 后发表回答