VrSpatialInputState class

Renderer-independent, borrowed-event-safe navigation and pointer state.

Normalized axes are +X right, +Y forward/up. Hosts integrate these values once per render frame, not once per network packet. The host supplies its actual screen-right basis, accounting for left/right-handed renderers. Remote state expires on silence; gamepads send edges and stay held until release. Call reset on route suspension, disconnect and disposal.

Constructors

VrSpatialInputState({double remoteTimeoutSeconds = 0.5})

Properties

hashCode → int
The hash code for this object.
no setterinherited
lookX ↔ double
getter/setter pair
lookY ↔ double
getter/setter pair
moveX ↔ double
getter/setter pair
moveY ↔ double
getter/setter pair
pointerActive → bool
no setter
remoteTimeoutSeconds → double
final
runtimeType → Type
A representation of the runtime type of the object.
no setterinherited

Methods

handleEvent(VrInputEvent event) → void
Copies only scalar/vector values; never retains a pooled event or map.
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
reset() → void
toString() → String
A string representation of this object.
inherited
update(double dt) → void
writeMovement(Vector3 out, {required Vector3 forward, required Vector3 screenRight, required double dt, double speed = 3.0}) → void
Writes an XZ-plane displacement, with no diagonal/pitch speed boost.
writeRay(Ray out, {required Vector3 origin, required Vector3 forward, required Vector3 screenRight, required Vector3 up}) → void
Writes the active controller ray, falling back to head gaze on release. A touch pad uses a head-relative frontal hemisphere; IMU/driver poses supply a world-space direction. The origin is a 3DoF estimate, not 6DoF.

Operators

operator ==(Object other) → bool
The equality operator.
inherited