12th January 2011, 02:08
|
#1
| Link
|
Registered User
Join Date: May 2010
Posts: 120
|
H.264 Level compliance help
Quote:
Calculate the number of reference frames as follows:
Round up width and height (purely for this calculation, not the encode) to the nearest mod 16 value
Reference frames = MaxDPB * 1024 / 1.5 / ( mod16_width * mod16_height )
Round down the result
Select MaxDPB, --vbv-maxrate and --vbv-bufsize options from the table below depending on which level you wish to encode to:
Level MaxDPB vbv-maxrate vbv-bufsize
3.0 3,037.5 10,000 10,000
3.1 6,750 14,000 14,000
3.2 7,680 20,000 20,000
4.0 12,288 20,000 25,000
4.1 12,288 50,000 62,500
4.2 13,056 50,000 62,500
5.0 41,400 135,000 135,000
5.1 69,120 240,000 240,000
MaxDPB = Maximum Decoded Picture Buffer size. Although the table shows maximum values for --vbv-bufsize, this typically should be set to a maximum of 14000, it depends on the device you're encoding for.
Example:
In the video used as an example in this guide the cropped resolution is 708x564. Rounding width and height up to mod 16 gives us 720x576.
Therefore, the number of reference frames for a
level 3.0 compliant encode is 3037.5 * 1024 / 1.5 / (720*576) = 5
level 3.1 compliant encode is 6750 * 1024 / 1.5 / (720*576) = 11
Settings for a 3.1 level encode of our example video: --level 3.1 --ref 11 --vbv-maxrate 14000 --vbv-bufsize 14000
Note: Mod 16 width and height are only used in the reference frame calculation, the actual encode is NOT required to be mod 16 for level compliance. However, some devices and graphics card acceleration may require mod 16 resolution. It is your choice if you wish to encode to a mod 16 resolution. If you do then there must NOT be any black borders in the encode, you may need to over crop to obtain mod 16.
|
Is there anyone who can explain to me how I reckon the table out.
I think that "/" is dividing and "*" is times, but i am not sure.
Last edited by DVDBob; 12th January 2011 at 02:15.
|
|
|