Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix Level and BitDepth in AV1 Codec String #918

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

saisrirammortha
Copy link

#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
image

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

image

@saisrirammortha
Copy link
Author

@barbibulle Please check this when you find time.

@saisrirammortha
Copy link
Author

saisrirammortha commented Jan 11, 2024

We can avoid adding additional details in the Codec String as those values are default. This is mentioned in the spec

image

https://aomediacodec.github.io/av1-isobmff/#codecsparam

What do you suggest?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant