ARVRPositionalTracker

Inherits: Object

Category: Core

Brief Description

A tracked object

Properties

floatrumble

Methods

TrackerHandget_hand ( ) const
intget_joy_id ( ) const
Stringget_name ( ) const
Basisget_orientation ( ) const
Vector3get_position ( ) const
boolget_tracks_orientation ( ) const
boolget_tracks_position ( ) const
Transformget_transform ( bool adjust_by_reference_frame ) const
TrackerTypeget_type ( ) const

Enumerations

enum TrackerHand:

  • TRACKER_HAND_UNKNOWN = 0 — The hand this tracker is held in is unknown or not applicable.
  • TRACKER_LEFT_HAND = 1 — This tracker is the left hand controller.
  • TRACKER_RIGHT_HAND = 2 — This tracker is the right hand controller.

Description

An instance of this object represents a device that is tracked such as a controller or anchor point. HMDs aren’t represented here as they are fully handled internally.

As controllers are turned on and the AR/VR interface detects them instances of this object are automatically added to this list of active tracking objects accessible through the ARVRServer

The ARVRController and ARVRAnchor both consume objects of this type and should be the objects you use in game. The positional trackers are just the under the hood objects that make this all work and are mostly exposed so GDNative based interfaces can interact with them.

Property Descriptions

Setterset_rumble(value)
Getterget_rumble()

The degree to which the tracker rumbles. Ranges from 0.0 to 1.0 with precision .01.

Method Descriptions

Returns the hand holding this tracker, if known. See TRACKER_* constants.


  • int get_joy_id ( ) const

If this is a controller that is being tracked the controller will also be represented by a joystick entry with this id.


Returns the controller or anchor point’s name if available.


  • Basis get_orientation ( ) const

Returns the controller’s orientation matrix.


Returns the world-space controller position.


  • bool get_tracks_orientation ( ) const

Returns true if this device tracks orientation.


  • bool get_tracks_position ( ) const

Returns true if this device tracks position.


  • Transform get_transform ( bool adjust_by_reference_frame ) const

Returns the transform combining this device’s orientation and position.


Returns the tracker’s type.