This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

unlimited bandwidth in VBR ?

Guru 20755 points

Hello,

According to previous threads I understand that in H.264 and MPEG-4 codecs using VBR there is no API for controlling maximum bit rate. But it is said that there are API for controlling the max/min quantization factors, which should put limitation on maximum bit rate. Is there a defined formula for calculating maximum bit rate, with the given QP ? If not, then it seems very problematic to use VBR if we don't know beforehand the bandwidth limitation, i.e. if the bit rate can will reach above values which the network support and we dont know about that then VBR is useless.

Best Regards,

Ran

  • Ran,

    Bitrate is always measured in terms of window of time. The max bitrate for an instantaneous time (i.e. bits taken to encode a frame) may be diff than the target/avergae bitrate. But this should not be a problem. All the network system do have some buffering, which takes care of the peaks and trenches what we see during encoding. This buffering is what we say as the VBV buffer of the encoder. So I dont think using VBR is problematic. What you are inferring would only happen in system where encoded data is sent without buffering to the transmitting channel, we dont think such is the case in practical systems.

    regards

    Yashwant

  • Hi Yashwant,

    If I refer to H.264 , it has CVBR and VBR, which as I understand CVBR has API for definign maximum bit rate, and in case the CVBR algorithm requires higher bitrate, it will instead change the quantization factor in order not to get above this maximum bit rate , right ? If I now refer to H.264 VBR, there is no API for controlling  maximum bitrate with VBR, and there is no other information which tell is the maximum bitrate is for example 10% (as an example) above target bit rate.    This might be problematic if I need to consider if VBR is OK for the known bandwidth limitation in our network, because if it is not known before using VBR algo the maximum bitrate, how can we consider if our network bandwith is suffecient for using the VBR algo ?

    Best Regards,

    Ran

  • Ran,

    The use of QP to make sure that the bitrate does not overshoot is equally applicable to VBR also. First, it will be good to visualize CVBR as what is depicted in the picture http://processors.wiki.ti.com/index.php/H.264_DM36x_Ver_2.0_Codec#CVBR_Rate_control. Based on the complexity, the operating bitrate shifts to a higher running bitrate limited by maxbitrate. For VBR, you can visualize the curve as it being flat and remaining at average bitrate. Hence it a given period of time(VBV size), there will be almost no deviation in the target bitrate. It will remain within 5% of set bitrate, amybe in reality, it can perform even better.

    regards

    Yashwant

  • Hi Yashwant,

    I did not completely understand this...

    • I dont fully understand the difference between VBR and CVBR:  Isn't VBR same as CVBR in that bitrate changes with complexity, and that the only difference is that CVBR allows controlling maximum bitrate with the given API ?

    >For VBR, you can visualize the curve as it being flat and remaining at average bitrate

    • Isn't that actually CBR, where bit rate remains on the average bitrate ? As I understand the concept of VBR is that bitrate is changed depending on complexity (just as you described before the CVBR).
    • Is it guarauntee with VBR that the change will be 5% of set bit rate ?

    >The use of QP to make sure that the bitrate does not overshoot is equally applicable to VBR also

    • With VBR, how to make this dependens in QP into limitation numbers, i.e. what is the function that connects maximum bitrate to QP: maximum_bit_rate = func(QP) ? or is it always 5% ?

    Regards,

    Ran

    • I dont fully understand the difference between VBR and CVBR:  Isn't VBR same as CVBR in that bitrate changes with complexity, and that the only difference is that CVBR allows controlling maximum bitrate with the given API

    >> No, CVBR allows the running bitrate to move from targetBitrate to a higher value for a specifed period of time in case complexity increases. The time can be 2 sec to say 5 mnts based on what you set as VBRduration. On the other hand, VBR will always have running bitrate at target bitrate even if the complexity increases.

    • Isn't that actually CBR, where bit rate remains on the average bitrate ? As I understand the concept of VBR is that bitrate is changed depending on complexity (just as you described before the CVBR).

    >> Both VBR and CBR tries to achive targetBitrate. VBR gives more focus to quality as it has typically higher buffer level to operate and does not skip frames. Use case wise, CBR is suited for apllication like VC and VBR for serviallnce.

    • Is it guarauntee with VBR that the change will be 5% of set bit rate ?

    >> Yes, it will work for all practical scenarios. But we need to have min and max QP set to reasonalble values. If you give 2mbps for 1080P white noise sequence with maxQP set at 40, you may see higher deviation for obvious reasons.

    • With VBR, how to make this dependens in QP into limitation numbers, i.e. what is the function that connects maximum bitrate to QP: maximum_bit_rate = func(QP) ? or is it always 5% ?

    >> There is also a parameter called maxPicSize. You can play with this if you want more strict control for VBR.  This parameter decides how mcuh max bits RC can give to encode a picture.

    regards

    Yashwant

  • Hi Yashwant,

    Thank you very much for all clarifications.
    As I now see VBR in H.264 does not change bitrate as complexity increase. Is it also the same with MPEG-4 VBR ?

    Regards,

    Ran