Skip to content
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

Define enumeration behavior when a gamepad is emulated with WebXR input devices. #110

Open
kearwood opened this issue Sep 20, 2019 · 0 comments

Comments

@kearwood
Copy link
Collaborator

There is a need to specify enumeration behaviour when a gamepad is exposed as both an XR input source with WebXR and as a traditional gamepad.

The WebXR specification requires that the XR input devices, which often have positional and orientation tracking features, are not enumerated by the gamepad api, but are still represented as gamepad objects.

When using a 2d browser within a VR or AR headset, a user may wish to use their controllers as a regular gamepad for web content that is not using WebXR. For example, they may wish to play a 2d WebGL game on a virtual monitor while using buttons on their tracked controllers to provide inputs that look like a gamepad to the content that is written against the Gamepad API. Often in such cases, two tracked controllers for XR may be combined into a single gamepad object, with the controls distributed between the two hands and mapping to a standard layout (eg, Left+Right Oculus touch controller buttons mapping to a single XBox one controller).

If a UA is to allow the gamepad api to enumerate such an emulated gamepad, the gamepad may disappear from the Gamepad API once a WebXR session is started, with a different set of controllers then appearing through the WebXR based enumeration.

Perhaps it would be beneficial to standardize this behavior consistently across UA's.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant