Skip to main content

XRHeadsetTracker

class · sealed · Singleton<XRHeadsetTracker> Unity component singleton
namespace AR51.Unity.SDK.Tracker;

public sealed class XRHeadsetTracker : Singleton<XRHeadsetTracker>

Inherits: MonoBehaviour (Unity)Singleton<XRHeadsetTracker>. Access via XRHeadsetTracker.Instance.

note

Unity SDK units are meters (Unity world space). Positions, rotations, and scales below follow that convention.

A Unity component that streams each registered XR device's camera-to-anchor transform and feeds it into ObjectTransformConsumer as an ObjectTransform of type "XR" — one per device, keyed by device id. It operates automatically through its Unity lifecycle and per-frame Update; there is nothing to call. Optionally, it can log each frame's pose to a per-device file.

Properties

PropertyTypeDefaultDescription
Export
ExportToFileboolfalsewhen true, appends each frame's pose to a per-device text file
FilePathstring⚠️ needs confirmation: expected to be a directory path — the filename is generated per device/session, not the file itself

Methods

This component exposes no public methods beyond inherited Unity/Singleton<> behavior. Its operation is automatic (lifecycle plus per-frame Update); you do not call into it. The internal Tracker class and all transform-streaming logic are internal and not documented here.

See also

  • ObjectTransformConsumer — receives the "XR" transforms this tracker emits and spawns/updates GameObjects from them
  • ObjectTransform — the per-frame pose value (id, type, position, rotation, scale) streamed for each device
  • Class index — all Unity SDK types
Was this page helpful?