Forum Discussion

Hakobio.Ouat's avatar
Hakobio.Ouat
Explorer
1 month ago

Spatial Anchors won't stay after Recenter +Workaround

I have a minimally reproductible project but it cannot be uploaded here.
Unity 6000.3.9 and Quest3 v2.1.1034, SDK v84

We have a scene 0 that loads scene 1 in which the CameraRig lives.

With that setup, after launching the APK I place some anchors, then holding the Meta button (Recenter) the anchors move away. After that first recenter everything works normally and any new anchor does stay in place.
This doesn't not happen if scene 0 is not included and thus we launch directly to the CameraRig scene.

Workarounds:
- Removing scene 0 (but that's our bootstrapper we can't remove it, but this fix might work for you)
- Adding a CameraRig (OVRManager) on scene 0 (so far it seems to work)

If any developer from Meta is available, i do have a project that can reproduce he bug.
Thanks in advance.

1 Reply

  • Degly's avatar
    Degly
    Start Partner

    This matches a known initialization/order issue with tracking origin + anchors. I have seen it specially on LBE applications.

    What’s happening:

    • First scene loads without an active XR rig / OVRManager
    • Anchors are created before tracking origin is fully stabilized
    • First recenter redefines origin, so existing anchors appear to shift
    • Sometimes even the initial origin is not in line with the headset origin so it needs recalibration

    Your workaround is correct:

    • Ensure OVRManager / XR rig exists in the first loaded scene
    • Recalibrate the headset before anything!

    Recommended pattern:

    • Use a bootstrap scene that already contains OVRManager/XR Origin. AKA BootScene
    • Or delay anchor creation until after tracking is fully initialized (e.g., a few frames or after first pose update)

    Anchors created before XR is initialized will drift on first recenter, but if you initialize XR in scene 0 or delay anchor creation it will work correctly.

→ Find helpful resources to begin your development journey in Getting Started

→ Get the latest information about HorizonOS development in News & Announcements.

→ Access Start program mentor videos and share knowledge, tutorials, and videos in Community Resources.

→ Get support or provide help in Questions & Discussions.

→ Show off your work in What I’m Building to get feedback and find playtesters.

→ Looking for documentation?  Developer Docs

→ Looking for account support?  Support Center

→ Looking for the previous forum?  Forum Archive

→ Looking to join the Start program? Apply here.

 

Recent Discussions