Table of Contents

Class OpenXRIPBinding

Defines a binding between an OpenXRAction and an XR input or output.

Inheritance
OpenXRIPBinding

Remarks

This binding resource binds an OpenXRAction to an input or output. As most controllers have left hand and right versions that are handled by the same interaction profile we can specify multiple bindings. For instance an action "Fire" could be bound to both "/user/hand/left/input/trigger" and "/user/hand/right/input/trigger". This would require two binding entries.

Properties

action

OpenXRAction that is bound to binding_path.

var action : OpenXRAction

Property Value

OpenXRAction

Remarks

binding_modifiers

Binding modifiers for this binding.

var binding_modifiers : Array = []

Property Value

Array

Remarks

  • void set_binding_modifiers(Array value)
  • Array get_binding_modifiers

binding_path

Binding path that defines the input or output bound to action.

Note: Binding paths are suggestions, an XR runtime may choose to bind the action to a different input or output emulating this input or output.

var binding_path : String = ""

Property Value

String

Remarks

  • void set_binding_path(String value)
  • String get_binding_path

paths

Paths that define the inputs or outputs bound on the device.

var paths : PackedStringArray

Property Value

PackedStringArray

Remarks

Methods

add_path(String)

Add an input/output path to this binding.

void add_path(String path)

Parameters

path String

get_binding_modifier(int)

Qualifiers: const

Get the OpenXRBindingModifier at this index.

OpenXRActionBindingModifier get_binding_modifier(int index)

Parameters

index int

get_binding_modifier_count

Qualifiers: const

Get the number of binding modifiers for this binding.

int get_binding_modifier_count

get_path_count

Qualifiers: const

Get the number of input/output paths in this binding.

int get_path_count

has_path(String)

Qualifiers: const

Returns true if this input/output path is part of this binding.

bool has_path(String path)

Parameters

path String

remove_path(String)

Removes this input/output path from this binding.

void remove_path(String path)

Parameters

path String