Add deviceId option to selectAudioOutput()#104
Merged
Conversation
alvestrand
reviewed
Aug 13, 2020
alvestrand
reviewed
Aug 13, 2020
youennf
approved these changes
Aug 20, 2020
youennf
left a comment
Collaborator
There was a problem hiding this comment.
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 |
Collaborator
There was a problem hiding this comment.
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.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fixes #99 (as a proposal)
Preview | Diff