webxr
webxr copied to clipboard
Allow for mid-session feature requests
It would be nice if content could add features to the XRSession in the middle of the session. For example, a complex app may not require hand-tracking by default (and may not wish to appear creepy by asking for it up front), but might have a "hand tracking mode" that can be enabled in the settings.
The Permissions Request API exists, but is not implemented, and with https://github.com/immersive-web/webxr/pull/1189 , it will not be sufficient for granting permissions to a given session. We should add a requestAdditionalFeatures()
API to XRSession that does the same required/optional stuff as requestSession()
that can update the session's set of granted features mid-session
It would be nice if content could add features to the XRSession in the middle of the session. For example, a complex app may not require hand-tracking by default (and may not wish to appear creepy by asking for it up front), but might have a "hand tracking mode" that can be enabled in the settings.
Are you thinking that these settings are accessed from VR? It seems more likely that this would be controlled from the 2D page.
The Permissions Request API exists, but is not implemented, and with #1189 , it will not be sufficient for granting permissions to a given session. We should add a
requestAdditionalFeatures()
API to XRSession that does the same required/optional stuff asrequestSession()
that can update the session's set of granted features mid-session
I haven't heard anyone ask for this feature. Maybe we can keep this open but log it as a future enhancement?
Yes, my intent is not for this to be a CR blocker
Are you thinking that these settings are accessed from VR? It seems more likely that this would be controlled from the 2D page.
Yes, but imagine something like 8thwall's authoring tools where you are authoring stuff in a long running VR session.
Not sure if this is right place, but here I go. I can see how this can be expanded to the other features that requires permission, for instance, microphone permission. We have a vr app where user might use microphone, but it's not required at the start. So when the user wants to use a microphone we kick them out of the session, then they answer the prompt and have to re-enter it again. Fortunately enough we can know that we already had a user permission without asking for it each time, but this experience is far from ideal.
We also tried not exiting the session, but it lead us to weird bugs with the session
If the platform could present user a prompt inside an immersive session (say with a visiblity-blurred mode) this would be much better