class_openxripbinding.rst 7.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189
  1. :github_url: hide
  2. .. DO NOT EDIT THIS FILE!!!
  3. .. Generated automatically from Godot engine sources.
  4. .. Generator: https://github.com/godotengine/godot/tree/master/doc/tools/make_rst.py.
  5. .. XML source: https://github.com/godotengine/godot/tree/master/modules/openxr/doc_classes/OpenXRIPBinding.xml.
  6. .. _class_OpenXRIPBinding:
  7. OpenXRIPBinding
  8. ===============
  9. **Inherits:** :ref:`Resource<class_Resource>` **<** :ref:`RefCounted<class_RefCounted>` **<** :ref:`Object<class_Object>`
  10. Defines a binding between an :ref:`OpenXRAction<class_OpenXRAction>` and an XR input or output.
  11. .. rst-class:: classref-introduction-group
  12. Description
  13. -----------
  14. This binding resource binds an :ref:`OpenXRAction<class_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.
  15. .. rst-class:: classref-reftable-group
  16. Properties
  17. ----------
  18. .. table::
  19. :widths: auto
  20. +---------------------------------------------------+------------------------------------------------------------------+--------+
  21. | :ref:`OpenXRAction<class_OpenXRAction>` | :ref:`action<class_OpenXRIPBinding_property_action>` | |
  22. +---------------------------------------------------+------------------------------------------------------------------+--------+
  23. | :ref:`String<class_String>` | :ref:`binding_path<class_OpenXRIPBinding_property_binding_path>` | ``""`` |
  24. +---------------------------------------------------+------------------------------------------------------------------+--------+
  25. | :ref:`PackedStringArray<class_PackedStringArray>` | :ref:`paths<class_OpenXRIPBinding_property_paths>` | |
  26. +---------------------------------------------------+------------------------------------------------------------------+--------+
  27. .. rst-class:: classref-reftable-group
  28. Methods
  29. -------
  30. .. table::
  31. :widths: auto
  32. +-------------------------+----------------------------------------------------------------------------------------------------------+
  33. | |void| | :ref:`add_path<class_OpenXRIPBinding_method_add_path>`\ (\ path\: :ref:`String<class_String>`\ ) |
  34. +-------------------------+----------------------------------------------------------------------------------------------------------+
  35. | :ref:`int<class_int>` | :ref:`get_path_count<class_OpenXRIPBinding_method_get_path_count>`\ (\ ) |const| |
  36. +-------------------------+----------------------------------------------------------------------------------------------------------+
  37. | :ref:`bool<class_bool>` | :ref:`has_path<class_OpenXRIPBinding_method_has_path>`\ (\ path\: :ref:`String<class_String>`\ ) |const| |
  38. +-------------------------+----------------------------------------------------------------------------------------------------------+
  39. | |void| | :ref:`remove_path<class_OpenXRIPBinding_method_remove_path>`\ (\ path\: :ref:`String<class_String>`\ ) |
  40. +-------------------------+----------------------------------------------------------------------------------------------------------+
  41. .. rst-class:: classref-section-separator
  42. ----
  43. .. rst-class:: classref-descriptions-group
  44. Property Descriptions
  45. ---------------------
  46. .. _class_OpenXRIPBinding_property_action:
  47. .. rst-class:: classref-property
  48. :ref:`OpenXRAction<class_OpenXRAction>` **action** :ref:`🔗<class_OpenXRIPBinding_property_action>`
  49. .. rst-class:: classref-property-setget
  50. - |void| **set_action**\ (\ value\: :ref:`OpenXRAction<class_OpenXRAction>`\ )
  51. - :ref:`OpenXRAction<class_OpenXRAction>` **get_action**\ (\ )
  52. :ref:`OpenXRAction<class_OpenXRAction>` that is bound to :ref:`binding_path<class_OpenXRIPBinding_property_binding_path>`.
  53. .. rst-class:: classref-item-separator
  54. ----
  55. .. _class_OpenXRIPBinding_property_binding_path:
  56. .. rst-class:: classref-property
  57. :ref:`String<class_String>` **binding_path** = ``""`` :ref:`🔗<class_OpenXRIPBinding_property_binding_path>`
  58. .. rst-class:: classref-property-setget
  59. - |void| **set_binding_path**\ (\ value\: :ref:`String<class_String>`\ )
  60. - :ref:`String<class_String>` **get_binding_path**\ (\ )
  61. Binding path that defines the input or output bound to :ref:`action<class_OpenXRIPBinding_property_action>`.
  62. \ **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.
  63. .. rst-class:: classref-item-separator
  64. ----
  65. .. _class_OpenXRIPBinding_property_paths:
  66. .. rst-class:: classref-property
  67. :ref:`PackedStringArray<class_PackedStringArray>` **paths** :ref:`🔗<class_OpenXRIPBinding_property_paths>`
  68. .. rst-class:: classref-property-setget
  69. - |void| **set_paths**\ (\ value\: :ref:`PackedStringArray<class_PackedStringArray>`\ )
  70. - :ref:`PackedStringArray<class_PackedStringArray>` **get_paths**\ (\ )
  71. **Deprecated:** Use :ref:`binding_path<class_OpenXRIPBinding_property_binding_path>` instead.
  72. Paths that define the inputs or outputs bound on the device.
  73. **Note:** The returned array is *copied* and any changes to it will not update the original property value. See :ref:`PackedStringArray<class_PackedStringArray>` for more details.
  74. .. rst-class:: classref-section-separator
  75. ----
  76. .. rst-class:: classref-descriptions-group
  77. Method Descriptions
  78. -------------------
  79. .. _class_OpenXRIPBinding_method_add_path:
  80. .. rst-class:: classref-method
  81. |void| **add_path**\ (\ path\: :ref:`String<class_String>`\ ) :ref:`🔗<class_OpenXRIPBinding_method_add_path>`
  82. **Deprecated:** Binding is for a single path.
  83. Add an input/output path to this binding.
  84. .. rst-class:: classref-item-separator
  85. ----
  86. .. _class_OpenXRIPBinding_method_get_path_count:
  87. .. rst-class:: classref-method
  88. :ref:`int<class_int>` **get_path_count**\ (\ ) |const| :ref:`🔗<class_OpenXRIPBinding_method_get_path_count>`
  89. **Deprecated:** Binding is for a single path.
  90. Get the number of input/output paths in this binding.
  91. .. rst-class:: classref-item-separator
  92. ----
  93. .. _class_OpenXRIPBinding_method_has_path:
  94. .. rst-class:: classref-method
  95. :ref:`bool<class_bool>` **has_path**\ (\ path\: :ref:`String<class_String>`\ ) |const| :ref:`🔗<class_OpenXRIPBinding_method_has_path>`
  96. **Deprecated:** Binding is for a single path.
  97. Returns ``true`` if this input/output path is part of this binding.
  98. .. rst-class:: classref-item-separator
  99. ----
  100. .. _class_OpenXRIPBinding_method_remove_path:
  101. .. rst-class:: classref-method
  102. |void| **remove_path**\ (\ path\: :ref:`String<class_String>`\ ) :ref:`🔗<class_OpenXRIPBinding_method_remove_path>`
  103. **Deprecated:** Binding is for a single path.
  104. Removes this input/output path from this binding.
  105. .. |virtual| replace:: :abbr:`virtual (This method should typically be overridden by the user to have any effect.)`
  106. .. |const| replace:: :abbr:`const (This method has no side effects. It doesn't modify any of the instance's member variables.)`
  107. .. |vararg| replace:: :abbr:`vararg (This method accepts any number of arguments after the ones described here.)`
  108. .. |constructor| replace:: :abbr:`constructor (This method is used to construct a type.)`
  109. .. |static| replace:: :abbr:`static (This method doesn't need an instance to be called, so it can be called directly using the class name.)`
  110. .. |operator| replace:: :abbr:`operator (This method describes a valid operator to use with this type as left-hand operand.)`
  111. .. |bitfield| replace:: :abbr:`BitField (This value is an integer composed as a bitmask of the following flags.)`
  112. .. |void| replace:: :abbr:`void (No return value.)`