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
#632 broke ability for site to say "give me first device" even in Firefox #649
Comments
Removal of deviceId was done by design and was agreed at TPAC IIRC. Usually websites want to reuse the same device as previously, in that case {video: {deviceId: {exact}} should work. It is not clear to me why websites would like to/should be able to opt-out of the selector, especially if the selector is well made. If we really want to support that use case, we could add a new constraint or add a specific 'default' deviceId so that {video: deviceId: {exact: 'default'}} would give what you want. |
I like that idea. It would need to be standardized though, since sites may rely on it even without ever seeing it from enumerateDevices(). |
Since this is the current model in all browsers except Firefox, it presumably has other advocates? 😉 Today, it lets sites that feel strongly about consistent user experience across browsers force a "default first, choose later" experience across all browsers, even Firefox. Is that not valuable? Sites already have the power to pick for their users on re-visits (among choices they've made in the past) so I don't see an immediate problem with sites having the ability to force the system default on initial visit. Since the getUserMedia API today already has this expressiveness (at least it had before #632), I see no reason to remove it. But primarily, this is sugar on #644. |
I'm going to close this since I opened it and I've seen no interest in suppressing the device picker in Firefox. |
With #632 enumerateDevices() filters out all but the first camera and first microphone.
But it also filters out the deviceId which I think is a mistake. This will break someone doing this:
I think this is a legitimate use case where the site explicitly wants to choose the first device (which is guaranteed to be the system default) for the user. This is the only way to avoid a selector in Firefox, and my plans in #644 (comment) rely on this.
A default deviceId could easily be provided, without leaking any information, and would avoid breaking the above code.
cc @youennf
The text was updated successfully, but these errors were encountered: