Closed
Bug 1355648
Opened 7 years ago
Closed 7 years ago
Add hasOrientation, hasPosition to the Gamepad extension for tracked controllers
Categories
(Core :: WebVR, enhancement)
Core
WebVR
Tracking
()
RESOLVED
FIXED
mozilla55
Tracking | Status | |
---|---|---|
firefox55 | --- | fixed |
People
(Reporter: dmarcos, Assigned: daoshengmu)
References
()
Details
(Keywords: dev-doc-complete)
Attachments
(3 files)
This way we can discriminate tracked gamepads consistently since the pose is not always available. It will make the API also consistent with VRDisplay API: https://w3c.github.io/webvr/spec/1.1/#interface-vrdisplaycapabilities
Assignee | ||
Updated•7 years ago
|
Assignee | ||
Comment 1•7 years ago
|
||
Summarize our discussion: We will want hasOrientation() and hasPosition() to be true if the sensors for orientation and position are present, even if the device can't get it's tracking position Should be a three-state logic effectively: State A - We can't measure our position and will never give you a position State B - We can measure our position, but don't know our position right now State C - We can measure our position, and this is the position hasPosition() should return true for B and C, but false for A "pose" should never be null, but the position values can be null for A and B. Same thing for orientation..
Assignee | ||
Updated•7 years ago
|
Assignee: nobody → dmu
Assignee | ||
Comment 2•7 years ago
|
||
As the spec [1] mentioned, "MUST be null if the gamepad is incapable of providing positional data. When not null, MUST be a three-element array." [1] https://w3c.github.io/gamepad/extensions.html#gamepadpose-interface
Comment hidden (mozreview-request) |
Comment hidden (mozreview-request) |
Comment 5•7 years ago
|
||
mozreview-review |
Comment on attachment 8860341 [details] Bug 1355648 - Part 1: Check VR controllers if losing tracking; https://reviewboard.mozilla.org/r/132380/#review135438 LGTM, Thanks!
Attachment #8860341 -
Flags: review?(kgilbert) → review+
Comment 6•7 years ago
|
||
mozreview-review |
Comment on attachment 8860342 [details] Bug 1355648 - Part 2: Handle GampadPose losing tracking situation; https://reviewboard.mozilla.org/r/132382/#review135440 LGTM
Attachment #8860342 -
Flags: review?(kgilbert) → review+
Comment hidden (mozreview-request) |
Comment 8•7 years ago
|
||
mozreview-review |
Comment on attachment 8860342 [details] Bug 1355648 - Part 2: Handle GampadPose losing tracking situation; https://reviewboard.mozilla.org/r/132382/#review136364
Attachment #8860342 -
Flags: review?(kyle) → review+
Pushed by dmu@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/f07c7d6ddb8d Part 1: Check VR controllers if losing tracking; r=kip https://hg.mozilla.org/integration/autoland/rev/1a675abcc1f0 Part 2: Handle GampadPose losing tracking situation; r=kip,qdot
Comment 10•7 years ago
|
||
Backed out in https://hg.mozilla.org/integration/autoland/rev/00ef02146b91 for https://treeherder.mozilla.org/logviewer.html#?job_id=94357043&repo=autoland
Comment hidden (mozreview-request) |
Comment hidden (mozreview-request) |
Comment hidden (mozreview-request) |
Assignee | ||
Comment 14•7 years ago
|
||
In Attachment #8861769 [details], fixing GamepadPose test for GamepadServiceTest and VRServiceTest.
Assignee | ||
Comment 15•7 years ago
|
||
Try looks good, https://treeherder.mozilla.org/#/jobs?repo=try&revision=548c24650186da0ec5c95e19d587de1921fde296
Comment 16•7 years ago
|
||
mozreview-review |
Comment on attachment 8861769 [details] Bug 1355648 - Part 3: Set position and orientation IsValid properties for GamepadPose tests; https://reviewboard.mozilla.org/r/133772/#review137062 LGTM, Thanks!
Attachment #8861769 -
Flags: review?(kgilbert) → review+
Comment 17•7 years ago
|
||
Pushed by dmu@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/d9eb118a1ac8 Part 1: Check VR controllers if losing tracking; r=kip https://hg.mozilla.org/integration/autoland/rev/574ebf5abbfa Part 2: Handle GampadPose losing tracking situation; r=kip,qdot https://hg.mozilla.org/integration/autoland/rev/efa1d4ebbc3d Part 3: Set position and orientation IsValid properties for GamepadPose tests; r=kip
Comment 18•7 years ago
|
||
bugherder |
https://hg.mozilla.org/mozilla-central/rev/d9eb118a1ac8 https://hg.mozilla.org/mozilla-central/rev/574ebf5abbfa https://hg.mozilla.org/mozilla-central/rev/efa1d4ebbc3d
Status: NEW → RESOLVED
Closed: 7 years ago
status-firefox55:
--- → fixed
Resolution: --- → FIXED
Target Milestone: --- → mozilla55
Updated•7 years ago
|
Keywords: dev-doc-needed
Comment 19•7 years ago
|
||
I don't think I need to add anything to the reference docs to cover this - I already documented VRDisplayCapabilities https://developer.mozilla.org/en-US/docs/Web/API/VRDisplayCapabilities And I was planning on adding a separate tutorial on how to handle VR controllers in a web app. Let me know if you think anything else is needed. Thanks!
Keywords: dev-doc-needed → dev-doc-complete
You need to log in
before you can comment on or make changes to this bug.
Description
•