Media (Intel® Video Processing Library, Intel Media SDK)
Access community support with transcoding, decoding, and encoding in applications using media tools like Intel® oneAPI Video Processing Library and Intel® Media SDK
Announcements
The Intel Media SDK project is no longer active. For continued support and access to new features, Intel Media SDK users are encouraged to read the transition guide on upgrading from Intel® Media SDK to Intel® Video Processing Library (VPL), and to move to VPL as soon as possible.
For more information, see the VPL website.

Problem meeting Profile/Level constraints on vbv_size

monaco__joe
Beginner
1,361 Views

For MPEG2 encode, the streams generated by MSDK do not appear to obey main profile/main level constraints on vbvsize.

Table 8-14 in ISO_IEC_13818-2 limits vbv buffer size to 112*16384 = 1835008 bits for main profile/main level.

In the attached code, I setup the encoder for main profile/main level and parse the coded output to determine what value the encoder specifies.  I see the results below.  The software version specifies a size of 134*16384 bits and the hardware version specifies136*16384.

 Using SW version 1.8
3 buffers suggested
Starting frame encode
Frame 000 of type I is   7640 bytes
Sequence Header Code
Extension Start Code
Sequence Extension
Main Profile
Main Level
vbvsz = 134 

Using HW version 1.7
6 buffers suggested
Starting frame encode
Frame 000 of type I is   5627 bytes
Sequence Header Code
Extension Start Code
Sequence Extension
Main Profile
Main Level
vbvsz = 136

This leads me to a couple of questions:

  • Is there anything I can do in my configuration to influence the VBV size used by msdk?
  • Does the msdk encoder actually exploit the expanded buffer size?  I can easily change the vbv size specified in the stream so that it obeys profile/level constraints.  This will make analyzers happy but if the encoder actually uses the full 134*16384/136*16384 buffer size downstream devices are likely to have problems with the msdk generated stream.

Below are the stats on my test system:

Graphics Devices:
        Name                                         Version             State
        Intel(R) HD Graphics 4600                    10.18.10.3345       Active
        VNC Mirror Driver                            1.8.0.0             08
        NVIDIA GeForce GTX 650                       9.18.13.1407        08

System info:
        CPU:    Intel(R) Core(TM) i7-4770 CPU @ 3.40GHz
        OS:     Microsoft Windows Embedded Standard
        Arch:   64-bit

 

0 Kudos
6 Replies
monaco__joe
Beginner
1,361 Views

With more investigation, it seems the vbv size is directly proportional to output bit rate.  For software version 1.7 I see the following relationship:


OutRate            VBVSize
1500 kb/s          67
3000 kb/s          134
6000 kb/s          267
15000 kb/s         667

 

So, for a MPML stream at maximum rate of 15 Mb/s, the encoder stream specifies a vbv size more than 5 times larger than allowed by that profile and level.  In order to match the VBV size constraints, the output rate has to be <= 2500 kb/s.

Am I missing something here?  I assume this is relationship is going to be true for all profiles and levels?

 

0 Kudos
Anthony_P_Intel
Employee
1,361 Views

Hi,

I haven't had a chance to look at this in detail yet, but the MSDK implementation can change (increase) the profile/level and provide warning the it needed to adjust parameters.  If it is not modifying the profile/level and adjusting the size, it should not be producing values beyond the spec.  I'll investigate.  Thanks for the detailed information.

0 Kudos
monaco__joe
Beginner
1,361 Views

 

Are there any updates available on this issue?

0 Kudos
Anthony_P_Intel
Employee
1,361 Views

Hi,

This question has been escalated, and I will follow up today.  Thank you for checking on status.

0 Kudos
Satish_Pandey
Beginner
1,361 Views

Hi Tony,

Getting same issue for VBV buffer size generate by encoder in elementary stream.

We are getting: For 5Mbps video , VBVsize= 227.

We need to limit VBV buffer size to 112.

I am using Media SDK 2015 R6.

Please do needful.

Thanks

Praveen K.

 

0 Kudos
Anthony_P_Intel
Employee
1,361 Views

HI Praveen,

I apologize, as I had thought this tread was updated long ago.

The issue was fixed in newer Intel(r) HD Graphics drivers. I see your original report mentioned driver version 3345 and my (old) notes mentioned fix should be in any driver newer than 3368.

The very latest drivers (4414) for Intel(r) HD Graphics 4600 are available here:

https://downloadcenter.intel.com/download/25978/Intel-Graphics-Driver-for-Windows-7-8-1-15-36-?product=81496

Please let us know if you still see the issue.

-Tony

0 Kudos
Reply