-
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
API to request audio output device selection #86
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.
I like this direction! Mostly nits and questions.
My main question is how to map temporary permissions?
Firefox has avoided session-based permissions thus far, doing one-offs or persistent permission only. But this API inherently needs a different kind of temporary permission I think, one that probably expires at the end of the page? Is that what Safari does?
index.html
Outdated
has the value <code>NotAllowedError</code> and abort these steps.</p></li> | ||
<li><p>Let <var>deviceInfo</var> be a new <code>MediaDeviceInfo</code> object to represent the selected audio output device.</p></li> | ||
<li><p>Update <var>deviceInfo</var> as done by the | ||
<code>enumeratedevices</code> algorithm steps 2.5.4 and 2.5.5.</p></li> |
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.
Step numbers may change. I think in mediacapture-main we should break out steps 2.5.3-2.5.5 into a new create a MediaDeviceInfo algorithm, and call that here. That way, all the storage stuff around deviceId
and groupId
can live there.
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.
Agreed, I did this draft as a first step before modifying other specs. There is also the need to add a bunch of references for promises/permission
In my mind, Firefox would add When the box is But is non-persistent permission important for speakers? There's no snooping risk. Having the option to persist these things seems necessary to enable future multi-speaker use cases. It also seems odd if a site can remember I use my bluetooth headset as a mic, but not as a speaker. Which brings me to... Does this API needs to accept constraints? Specifically, the Otherwise, a site cannot remember the user's choice from last time without permission. So far, we've been able to distinguish memory from permission. |
I think we should discuss the persistency in a follow-up discussion.
|
a84c327
to
69daca4
Compare
At end of call, I think we decided editors can integrate once follow-up issue has been filed for adding hooks. |
This change seems to propose disallowing a web application from getting an output device list and presenting it to the user, in favor of a browser-specific UI for doing this. Is this correct? Such a change would break a lot of use cases. The browser doesn't know the context of what the application is trying to do. For example, it's common in my applications to use multiple audio outputs simultaneously. As part of saved config, I know what devices should be used for what, and when, because the user previously configured them in my application. If instead on every page load I have to request the user multiple times to select a device, this would be very damaging to the user experience. |
This is correct.
This is a scenario that makes sense and we plan to work on that, with the same constraint as getUserMedia: we should not allow passive monitoring of output devices by a web page. |
@bradisbell I filed #99 |
PR for #83