Skip to content

tracked-controls-webxr does not update entity position when referenceSpaceType is bounded-floor #5803

@v5ma

Description

@v5ma

When <a-scene webxr="referenceSpaceType: bounded-floor"> is used, entities with laser-controls, oculus-touch-controls, or any component depending on tracked-controls-webxr remain stuck at world position (0, 0, 0). The controller models render at the scene origin and never move, even though the raw WebXR input source poses report correct positions.

Hand tracking via hand-tracking-controls is also affected (entity object3D.getWorldPosition() returns 0,0,0), though the third-party handy-controls library (handy-work) tracks correctly under the same bounded-floor session.

Switching to referenceSpaceType: local-floor restores normal laser-controls tracking behavior.

Expected behavior

tracked-controls-webxr should update entity position/rotation from frame.getPose(inputSource.gripSpace, referenceSpace) regardless of whether the active reference space is local-floor or bounded-floor. Both are floor-level reference spaces with the same coordinate conventions (y=0 at floor).

Actual behavior

  • laser-controls entities stay at (0, 0, 0) for the entire session
  • Raw XR API calls (frame.getPose(src.gripSpace, refSpace)) return correct positions
  • Camera tracking works correctly (head position updates)
  • handy-controls (third-party, uses targetRaySpace/gripSpace directly) tracks correctly
  • Suggests tracked-controls-webxr either fails to match input sources or fails to apply poses when bounded-floor is the reference space type

Steps to reproduce

<a-scene webxr="requiredFeatures: bounded-floor, hand-tracking;
                referenceSpaceType: bounded-floor"
         renderer="stencil: true">

  <a-entity id="rig">
    <a-entity camera look-controls position="0 1.6 0"></a-entity>
    <a-entity laser-controls="hand: left"></a-entity>
    <a-entity laser-controls="hand: right"></a-entity>
  </a-entity>
</a-scene>
  1. Open on Meta Quest 3 (or any device supporting bounded-floor)
  2. Enter VR
  3. Observe controller models stuck at floor center (0, 0, 0)
  4. Change referenceSpaceType to local-floor and they track correctly

Telemetry evidence

Logged every 2 seconds during a VR session:

RAW-L ctrl raw=(0.88, 1.11, -0.77)    <-- correct XR API position
ENT-L leftController world=(0.00, 0.00, 0.00)  <-- entity never updates

RAW-R ctrl raw=(0.62, 1.10, -0.74)
ENT-R rightController world=(0.00, 0.00, 0.00)

The RAW values come from frame.getPose(src.gripSpace, renderer.xr.getReferenceSpace()) and are correct. The ENT values come from el.object3D.getWorldPosition() on the laser-controls entity and never change from origin.

Environment

  • A-Frame version: 1.7.1
  • Device: Meta Quest 3
  • Browser: Meta Quest Browser (Chromium-based)
  • OS: Quest OS v74+

Workaround

Use handy-controls from the handy-work library, which reads gripSpace and targetRaySpace poses directly rather than going through tracked-controls-webxr. This tracks correctly with bounded-floor.

Alternatively, keep referenceSpaceType: local-floor and request bounded-floor separately only to read boundsGeometry without calling renderer.xr.setReferenceSpace().

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions