UniqProject / BDInfo

BDInfo from http://www.cinemasquid.com/blu-ray/tools/bdinfo
GNU Lesser General Public License v2.1
233 stars 58 forks source link

NAL unit parsing is incorrect #16

Open pete-farlow opened 5 years ago

pete-farlow commented 5 years ago

The BDInfo source code does not account for emulation prevention bytes at all, it seems you're not aware of those. Therefore the results are pretty random. With AVC the tool often gets lucky, because the respective nal units don't require emulation prevention all that much, but with HEVC it's totally hit and miss.

I saw a few workarounds in the code that sort of work around this bug, which can only work under certain conditions.

Anyway - after I fixed the code to include emulation prevention awareness and removed these workarounds, output was 100% reliable.

Please search the AVC and/or HEVC specs for "emulation prevention" - it's the same scheme in both cases.

UniqProject commented 3 years ago

Busy testing the changes.