Skip to content

Tracking the headset position and gaze

The SDK automatically tracks headset position and forward direction (gaze proxy) while a session is active.

Important: this is not eye tracking. visionOS app APIs do not expose eye-tracking rays. The SDK uses HMD forward direction as the gaze signal.

Orientation sensors

By default, the SDK records:

  • position
  • pitch
  • FPS
  • battery level

Yaw tracking is supported in v1.0.1, but is disabled by default.

Roll is not currently recorded as a separate built-in sensor.

AR tracking access (v1.0.1)

The SDK uses ARSessionManager internally and also exposes it for app-side integration.

ARSessionManager centralizes one shared ARKit world-tracking session for the SDK. This avoids duplicate tracking sessions and provides a single transform source for gaze/position-dependent systems.

The most useful public access points are:

  • isTrackingActive
  • worldTrackingState
  • getTransform() for the latest device world transform (simd_float4x4)
  • queryDeviceTransform(atTimestamp:)
  • getPosition() for a convenience [Double] position
  • addDelegate(_:) / removeDelegate(_:) for position/transform callbacks

In most integrations, you do not need to start or manage AR tracking manually since the SDK handles this during session lifecycle. These helpers are primarily for synchronization, debugging, and advanced app features that need timestamp-based device transforms.

Example:

if ARSessionManager.shared.isTrackingActive,
   let transform = ARSessionManager.shared.getTransform() {
    // Use current device world transform
}

intercom If you have a question or any feedback about our documentation please use the Intercom button (purple circle) in the lower right corner of any web page or join our Discord.