#1737 Update AV1 reference implementation (libaom)

Closed
opened 2 months ago by Moonchild · 10 comments

There are some audio issues with the version of libaom we have now -- most notably lack of audio. It looks like the bitstream format has changed after our initial implementation, so we need to pull at least a few updates (and preferably to the 1.0 implementation) of libaom.

Aside from that we probably want to update it further to 1.0 from Bug 1445683 (Firefox 63) but that’s more involved and might not be necessary right away.

ALTERNATIVELY: we can import libaom 1.0 straight away and write our own build system plumbing around it.

There are some audio issues with the version of libaom we have now -- most notably lack of audio. It looks like the bitstream format has changed after our initial implementation, so we need to pull at least a few updates (and preferably to the 1.0 implementation) of libaom. 1. [x] Disable AV1 by default. Enabling was premature. 2. [x] Investigate if import of [Bug 1314147](https://bugzilla.mozilla.org/show_bug.cgi?id=1314147) was complete. We seem to be missing a few config files? @trav90 you did this import IIRC, did you put files in different places? 3. [x] ~~Port [Bug 1369950](https://bugzilla.mozilla.org/show_bug.cgi?id=1369950) (55)~~ 4. [x] ~~Port [Bug 1380118](https://bugzilla.mozilla.org/show_bug.cgi?id=1380118) (55)~~ 5. [x] ~~Port [Bug 1413734](https://bugzilla.mozilla.org/show_bug.cgi?id=1413734) (58)~~ 6. [x] Update to upstream and use script/editing to fix the build config and mozbuild files. 7. [x] Test result 8. [ ] ~~Re-enable AV1 by default.~~ Aside from that we probably want to update it further to 1.0 from [Bug 1445683](https://bugzilla.mozilla.org/show_bug.cgi?id=1445683) (Firefox 63) but that's more involved and might not be necessary right away. ALTERNATIVELY: we can import libaom 1.0 straight away and write our own build system plumbing around it.
Moonchild added the
C: Media
label 2 months ago
Moonchild added the
Enhancement
label 2 months ago
Moonchild added the
Web Compatibility
label 2 months ago
trav90 commented 2 months ago
Collaborator

If my memory serves the import of bug 1314147 was complete, but the initial import included some extraneous config files that didn’t end up being needed and were cleaned up later.

If my memory serves the import of bug 1314147 was complete, but the initial import included some extraneous config files that didn't end up being needed and were cleaned up later.
trav90 commented 2 months ago
Collaborator

I believe applicable patches from 1369950 have also already been ported.

I believe applicable patches from 1369950 have also already been ported.
Moonchild commented 2 months ago
Owner

the initial import included some extraneous config files that didn’t end up being needed and were cleaned up later.

That threw me off when looking at trying to apply the diff as it couldn’t find the files to patch.

> the initial import included some extraneous config files that didn’t end up being needed and were cleaned up later. That threw me off when looking at trying to apply the diff as it couldn't find the files to patch.
Moonchild commented 1 month ago
Owner

OK I’m officially confused about the state of this now.
Checking what we have it seems to be a 1.0 version and the whole cmake parser thing is already in place.
Our source is not the same as what is in Firefox 63, but I can’t tell if what we have is older or newer than what’s there.

OK I'm officially confused about the state of this now. Checking what we have it seems to be a 1.0 version and the whole cmake parser thing is already in place. Our source is not the same as what is in Firefox 63, but I can't tell if what we have is older or newer than what's there.
trav90 commented 1 month ago
Collaborator

I’ll look into this and see if I can sort out what version we have. I’ll also look at updating it to something newer as time permits.

I'll look into this and see if I can sort out what version we have. I'll also look at updating it to something newer as time permits.
trav90 self-assigned this 1 month ago
Moonchild commented 1 month ago
Owner

I’ve been puzzling on this and I think I got the updates in place. Will just have to test. Since we’re currently at 2.0.2 upstream that’s what I aimed for.

I've been puzzling on this and I think I got the updates in place. Will just have to test. Since we're currently at 2.0.2 upstream that's what I aimed for.
trav90 was unassigned by Moonchild 1 month ago
Moonchild self-assigned this 1 month ago
Moonchild commented 1 month ago
Owner

Well, shoot. I updated libaom successfully but it didn’t solve the sound issue on 9gag etc.

Well, shoot. I updated libaom successfully but it didn't solve the sound issue on 9gag etc.
Moonchild commented 1 month ago
Owner

I’m reassigning this to you for when you have time, Travis. There’s something still wrong but I have no clue what and don’t know our media glue and/or demuxer code at all.

~~I'm reassigning this to you for when you have time, Travis. There's something still wrong but I have no clue what and don't know our media glue and/or demuxer code at all.~~
Moonchild commented 1 month ago
Owner

OK so a few frustrating hours later it just seems like the audio issue on 9gag is an isolated thing that might not be related at all to the aom lib, but be something separate 9who knows might be crap encoding on their end that trips up the demuxer).
Discussed with Tobin, including the very mixed signals from the interwebs where part says AV1 is too immature and another part says it’s gonna be required, and there’s a serious lack of test opportunities in the wild so I give up.
@trav90 You could have a look if you have time but I think this issue as-is with the lib update should be considered done. i’ll spin off a follow-up to make it easier for users to select different codecs at their own leisure (or peril) from preferences, borrowing some Borealis code.

OK so a few frustrating hours later it just seems like the audio issue on 9gag is an isolated thing that might not be related at all to the aom lib, but be something separate 9who knows might be crap encoding on their end that trips up the demuxer). Discussed with Tobin, including the very mixed signals from the interwebs where part says AV1 is too immature and another part says it's gonna be required, and there's a serious lack of test opportunities in the wild so I give up. @trav90 You could have a look if you have time but I think this issue as-is with the lib update should be considered done. i'll spin off a follow-up to make it easier for users to select different codecs at their own leisure (or peril) from preferences, borrowing some Borealis code.
Moonchild removed their assignment 1 month ago
Moonchild self-assigned this 1 month ago
Moonchild added the
Done
label 1 month ago
Moonchild closed this issue 1 month ago
trav90 commented 1 month ago
Collaborator

Sounds good.

Sounds good.
Sign in to join this conversation.
No Milestone
No Assignees
2 Participants
Notifications
Due Date

No due date set.

Dependencies

This issue currently doesn't have any dependencies.

Loading…
There is no content yet.