Fix Level and BitDepth in AV1 Codec String
https://github.com/axiomatic-systems/Bento4/issues/917
The logic of generating codec string for AV1 had a bug. It is giving same Codec String for all the generated manifests. Bitdepth is added as a constant value
For Bitdepth
From AV1 Spec (https://aomediacodec.github.io/av1-spec/av1-spec.pdf), Section 5.5.2. Color config syntax
We can derive this statements for Bitdepth
If high_bitdepth is 0, then the value for bitdepth is 08. If high_bitdepth is 1 and twelve_bit is 0, then the value for bitdepth is 10. If high_bitdepth is 1 and twelve_bit is 1, then the value for bitdepth is 12.
For Level From AV1 Spec (https://aomediacodec.github.io/av1-spec/av1-spec.pdf), Section Annex A: Profiles and levels, A.3. Levels Seq Level Index value can be stored for the Level. We need not right shift Seq Level Index by 4 bits This 2 digit Seq Level Index can be converted to the X.Y format level format, where X = 2 + (seq_level_index >> 2) and Y = seq_level_index & 3
@barbibulle Please check this when you find time.
We can avoid adding additional details in the Codec String as those values are default. This is mentioned in the spec
https://aomediacodec.github.io/av1-isobmff/#codecsparam
What do you suggest?
Thanks for the fix. Sorry it took so long to merge it.