Open Bug 1659809 Opened 4 years ago Updated 2 years ago

Follow-up: consolidate enabled/disabled and mute/unmute logic in MediaStreamTracks.

Categories

(Core :: WebRTC: Audio/Video, enhancement, P3)

All
Android
enhancement

Tracking

()

People

(Reporter: jib, Assigned: jib)

References

Details

From https://phabricator.services.mozilla.com/D84222#inline-495173:

This is too naive. Imagine a user hammering the mute/unmute button 50 times. You now have to wait for 50 I/O operations (25 to start the camera, 25 to stop the camera) before getting a live video again.

SetEnabledFor solves this so it would be great if we could re-use what's necessary there in here too. See mOperationInProgress and friends: https://searchfox.org/mozilla-central/rev/3434a9df60373a997263107e6f124fb164ddebf2/dom/media/MediaManager.cpp#225-228

This was not needed for bug 1564451 and thus deferred, but should might still be an issue with in bug 1643027 since there'd be a global user-facing toggle button.

Also address https://phabricator.services.mozilla.com/D86072#inline-493494:

I'd prefer avoiding injecting the initial state here, but rather set it the same way as when we mute an already active device. To keep the struct as dumb as possible.

Probably not a S2
Reminder, S2 means: (Serious) Major functionality/product severely impaired or a high impact issue and a satisfactory workaround does not exist

And it seems that it is in the backlog now

Severity: S2 → S3
Priority: P2 → P3
You need to log in before you can comment on or make changes to this bug.