-
Notifications
You must be signed in to change notification settings - Fork 25
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
Add deviceId option to selectAudioOutput() #104
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM overall, some comments below.
</li> | ||
<li><p>If <var>device</var> is available, resolve | ||
<var>p</var> with either <var>deviceId</var> or a freshly | ||
rotated device id for <var>device</var>, and abort the |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is probably implementation dependent, but can you clarify when we would reuse the deviceId and when we would use a rotated device Id? In Safari implementation, we would probably either reuse the deviceId or prompt.
A few additional edge cases:
- If we call twice selectAudioOutput with the same old deviceId, and we end up in this 'reuse deviceId' case, I would expect the implementation to always return the same deviceId (either the old one if rotation did not happen, or the same new one), except if rotation happened in between. The term 'freshly' might be a bit ambiguous.
- If the deviceId is already exposed as part of enumerateDevices, I would expect all implementations of selectAudioOutput to just return the provided deviceId.
Fixes #99 (as a proposal)
Preview | Diff