Open Bug 1725336 Opened 3 years ago Updated 1 year ago

Error in AudioContext.createMediaStreamSource when AudioContext is constructed with a custom sample rate

Categories

(Core :: Web Audio, defect, P3)

Firefox 90
defect

Tracking

()

UNCONFIRMED

People

(Reporter: tasnimrock2k6, Unassigned)

References

(Depends on 1 open bug)

Details

User Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/92.0.4515.131 Safari/537.36

Steps to reproduce:

Example code in https://jsfiddle.net/mx9gonuv/8/

The AudioContext is actually initialized with sampleRate of 16000 and then, the mic input is given to when connecting to the audio node via createMediaStreamSource.

Actual results:

If you "run" the linked jsfiddle snippet, the following console message is recieved:

"Error: NotSupportedError: AudioContext.createMediaStreamSource: Connecting AudioNodes from AudioContexts with different sample-rate is currently not supported."

Expected results:

The above error should have not happened. Even the error message is confusing. It's still the same audio-context but just audio nodes that have different sample-rate.

Note that this bug was not seen in chrome.

The Bugbug bot thinks this bug should belong to the 'Core::Web Audio' component, and is moving the bug to that component. Please revert this change in case you think the bot is wrong.

Component: Untriaged → Web Audio
Product: Firefox → Core
Severity: -- → S3
Priority: -- → P3

Hi Karl,
I think this bug feels more like a duplicate of https://bugzilla.mozilla.org/show_bug.cgi?id=1674892 . That seems to be dependent on https://bugzilla.mozilla.org/show_bug.cgi?id=1238038 . Any idea / estimates when that's gonna be fixed? And would that just fix this bug or will it require extra work?

Bug 1238038 is being reviewed at the moment, I expect and landing, and thus an availability in Nightly in the next few days / weeks.

Thanks for the update.

Now that bug 1238038 is fixed, wanted to ask how far we are from fixing this bug?

Yes, probably a duplicate of bug 1674892, but I'll leave it open as there is a separate test case.

Depends on: 1674892
You need to log in before you can comment on or make changes to this bug.