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

Prevent the wpt-runner from crashing by avoiding some panics #403

Merged
merged 3 commits into from
Dec 2, 2023

Conversation

orottier
Copy link
Owner

These are needed to make the wpt runner in the node bindings project work

@@ -573,7 +573,8 @@ impl AudioRenderQuantum {
.zip(center.iter())
.for_each(|(r, c)| *r += sqrt05 * c);
}

_ => (),
Copy link
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think I will stick to the firefox implementation for upmixing/downmixing: https://searchfox.org/mozilla-central/source/dom/media/AudioChannelFormat.h
This means, ignore any channel count > 6, but do provide all implementations of N -> M channels with N, M in [1, 6]

and resort to discrete mixing for channel counts > 6.
Mixing is now panic free.
@orottier orottier marked this pull request as ready for review December 2, 2023 16:16
@orottier orottier changed the title Prevent the wpt-runner from crashing (only that, no true fixes here) Prevent the wpt-runner from crashing by avoiding some panics Dec 2, 2023
@orottier orottier requested a review from b-ma December 2, 2023 16:17
@b-ma
Copy link
Collaborator

b-ma commented Dec 2, 2023

Looks noce to me! The strategy for up/down mix is sensible indeed

@orottier orottier merged commit f43ce60 into main Dec 2, 2023
3 checks passed
@orottier orottier deleted the feature/prevent-wpt-crashes branch December 2, 2023 18:14
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.

2 participants