class_openxrextensionwrapperextension.rst 22 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388
  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/OpenXRExtensionWrapperExtension.xml.
  6. .. _class_OpenXRExtensionWrapperExtension:
  7. OpenXRExtensionWrapperExtension
  8. ===============================
  9. **Inherits:** :ref:`Object<class_Object>`
  10. Allows clients to implement OpenXR extensions with GDExtension.
  11. .. rst-class:: classref-introduction-group
  12. Description
  13. -----------
  14. **OpenXRExtensionWrapperExtension** allows clients to implement OpenXR extensions with GDExtension. The extension should be registered with :ref:`register_extension_wrapper<class_OpenXRExtensionWrapperExtension_method_register_extension_wrapper>`.
  15. .. rst-class:: classref-reftable-group
  16. Methods
  17. -------
  18. .. table::
  19. :widths: auto
  20. +-----------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
  21. | :ref:`Dictionary<class_Dictionary>` | :ref:`_get_requested_extensions<class_OpenXRExtensionWrapperExtension_private_method__get_requested_extensions>` **(** **)** |virtual| |
  22. +-----------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
  23. | void | :ref:`_on_before_instance_created<class_OpenXRExtensionWrapperExtension_private_method__on_before_instance_created>` **(** **)** |virtual| |
  24. +-----------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
  25. | :ref:`bool<class_bool>` | :ref:`_on_event_polled<class_OpenXRExtensionWrapperExtension_private_method__on_event_polled>` **(** const void* event **)** |virtual| |
  26. +-----------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
  27. | void | :ref:`_on_instance_created<class_OpenXRExtensionWrapperExtension_private_method__on_instance_created>` **(** :ref:`int<class_int>` instance **)** |virtual| |
  28. +-----------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
  29. | void | :ref:`_on_instance_destroyed<class_OpenXRExtensionWrapperExtension_private_method__on_instance_destroyed>` **(** **)** |virtual| |
  30. +-----------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
  31. | void | :ref:`_on_pre_render<class_OpenXRExtensionWrapperExtension_private_method__on_pre_render>` **(** **)** |virtual| |
  32. +-----------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
  33. | void | :ref:`_on_process<class_OpenXRExtensionWrapperExtension_private_method__on_process>` **(** **)** |virtual| |
  34. +-----------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
  35. | void | :ref:`_on_register_metadata<class_OpenXRExtensionWrapperExtension_private_method__on_register_metadata>` **(** **)** |virtual| |
  36. +-----------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
  37. | void | :ref:`_on_session_created<class_OpenXRExtensionWrapperExtension_private_method__on_session_created>` **(** :ref:`int<class_int>` session **)** |virtual| |
  38. +-----------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
  39. | void | :ref:`_on_session_destroyed<class_OpenXRExtensionWrapperExtension_private_method__on_session_destroyed>` **(** **)** |virtual| |
  40. +-----------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
  41. | void | :ref:`_on_state_exiting<class_OpenXRExtensionWrapperExtension_private_method__on_state_exiting>` **(** **)** |virtual| |
  42. +-----------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
  43. | void | :ref:`_on_state_focused<class_OpenXRExtensionWrapperExtension_private_method__on_state_focused>` **(** **)** |virtual| |
  44. +-----------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
  45. | void | :ref:`_on_state_idle<class_OpenXRExtensionWrapperExtension_private_method__on_state_idle>` **(** **)** |virtual| |
  46. +-----------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
  47. | void | :ref:`_on_state_loss_pending<class_OpenXRExtensionWrapperExtension_private_method__on_state_loss_pending>` **(** **)** |virtual| |
  48. +-----------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
  49. | void | :ref:`_on_state_ready<class_OpenXRExtensionWrapperExtension_private_method__on_state_ready>` **(** **)** |virtual| |
  50. +-----------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
  51. | void | :ref:`_on_state_stopping<class_OpenXRExtensionWrapperExtension_private_method__on_state_stopping>` **(** **)** |virtual| |
  52. +-----------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
  53. | void | :ref:`_on_state_synchronized<class_OpenXRExtensionWrapperExtension_private_method__on_state_synchronized>` **(** **)** |virtual| |
  54. +-----------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
  55. | void | :ref:`_on_state_visible<class_OpenXRExtensionWrapperExtension_private_method__on_state_visible>` **(** **)** |virtual| |
  56. +-----------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
  57. | :ref:`int<class_int>` | :ref:`_set_instance_create_info_and_get_next_pointer<class_OpenXRExtensionWrapperExtension_private_method__set_instance_create_info_and_get_next_pointer>` **(** void* next_pointer **)** |virtual| |
  58. +-----------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
  59. | :ref:`int<class_int>` | :ref:`_set_session_create_and_get_next_pointer<class_OpenXRExtensionWrapperExtension_private_method__set_session_create_and_get_next_pointer>` **(** void* next_pointer **)** |virtual| |
  60. +-----------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
  61. | :ref:`int<class_int>` | :ref:`_set_swapchain_create_info_and_get_next_pointer<class_OpenXRExtensionWrapperExtension_private_method__set_swapchain_create_info_and_get_next_pointer>` **(** void* next_pointer **)** |virtual| |
  62. +-----------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
  63. | :ref:`int<class_int>` | :ref:`_set_system_properties_and_get_next_pointer<class_OpenXRExtensionWrapperExtension_private_method__set_system_properties_and_get_next_pointer>` **(** void* next_pointer **)** |virtual| |
  64. +-----------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
  65. | :ref:`OpenXRAPIExtension<class_OpenXRAPIExtension>` | :ref:`get_openxr_api<class_OpenXRExtensionWrapperExtension_method_get_openxr_api>` **(** **)** |
  66. +-----------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
  67. | void | :ref:`register_extension_wrapper<class_OpenXRExtensionWrapperExtension_method_register_extension_wrapper>` **(** **)** |
  68. +-----------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
  69. .. rst-class:: classref-section-separator
  70. ----
  71. .. rst-class:: classref-descriptions-group
  72. Method Descriptions
  73. -------------------
  74. .. _class_OpenXRExtensionWrapperExtension_private_method__get_requested_extensions:
  75. .. rst-class:: classref-method
  76. :ref:`Dictionary<class_Dictionary>` **_get_requested_extensions** **(** **)** |virtual|
  77. Returns a :ref:`Dictionary<class_Dictionary>` of OpenXR extensions related to this extension. The :ref:`Dictionary<class_Dictionary>` should contain the name of the extension, mapped to a ``bool *`` cast to an integer:
  78. - If the ``bool *`` is a ``nullptr`` this extension is mandatory.
  79. - If the ``bool *`` points to a boolean, the boolean will be updated to ``true`` if the extension is enabled.
  80. .. rst-class:: classref-item-separator
  81. ----
  82. .. _class_OpenXRExtensionWrapperExtension_private_method__on_before_instance_created:
  83. .. rst-class:: classref-method
  84. void **_on_before_instance_created** **(** **)** |virtual|
  85. Called before the OpenXR instance is created.
  86. .. rst-class:: classref-item-separator
  87. ----
  88. .. _class_OpenXRExtensionWrapperExtension_private_method__on_event_polled:
  89. .. rst-class:: classref-method
  90. :ref:`bool<class_bool>` **_on_event_polled** **(** const void* event **)** |virtual|
  91. Called when there is an OpenXR event to process. When implementing, return ``true`` if the event was handled, return ``false`` otherwise.
  92. .. rst-class:: classref-item-separator
  93. ----
  94. .. _class_OpenXRExtensionWrapperExtension_private_method__on_instance_created:
  95. .. rst-class:: classref-method
  96. void **_on_instance_created** **(** :ref:`int<class_int>` instance **)** |virtual|
  97. Called right after the OpenXR instance is created.
  98. .. rst-class:: classref-item-separator
  99. ----
  100. .. _class_OpenXRExtensionWrapperExtension_private_method__on_instance_destroyed:
  101. .. rst-class:: classref-method
  102. void **_on_instance_destroyed** **(** **)** |virtual|
  103. Called right before the OpenXR instance is destroyed.
  104. .. rst-class:: classref-item-separator
  105. ----
  106. .. _class_OpenXRExtensionWrapperExtension_private_method__on_pre_render:
  107. .. rst-class:: classref-method
  108. void **_on_pre_render** **(** **)** |virtual|
  109. Called right before the XR viewports begin their rendering step.
  110. .. rst-class:: classref-item-separator
  111. ----
  112. .. _class_OpenXRExtensionWrapperExtension_private_method__on_process:
  113. .. rst-class:: classref-method
  114. void **_on_process** **(** **)** |virtual|
  115. Called as part of the OpenXR process handling. This happens right before general and physics processing steps of the main loop. During this step controller data is queried and made available to game logic.
  116. .. rst-class:: classref-item-separator
  117. ----
  118. .. _class_OpenXRExtensionWrapperExtension_private_method__on_register_metadata:
  119. .. rst-class:: classref-method
  120. void **_on_register_metadata** **(** **)** |virtual|
  121. Allows extensions to register additional controller metadata. This function is called even when the OpenXR API is not constructed as the metadata needs to be available to the editor.
  122. Extensions should also provide metadata regardless of whether they are supported on the host system. The controller data is used to setup action maps for users who may have access to the relevant hardware.
  123. .. rst-class:: classref-item-separator
  124. ----
  125. .. _class_OpenXRExtensionWrapperExtension_private_method__on_session_created:
  126. .. rst-class:: classref-method
  127. void **_on_session_created** **(** :ref:`int<class_int>` session **)** |virtual|
  128. Called right after the OpenXR session is created.
  129. .. rst-class:: classref-item-separator
  130. ----
  131. .. _class_OpenXRExtensionWrapperExtension_private_method__on_session_destroyed:
  132. .. rst-class:: classref-method
  133. void **_on_session_destroyed** **(** **)** |virtual|
  134. Called right before the OpenXR session is destroyed.
  135. .. rst-class:: classref-item-separator
  136. ----
  137. .. _class_OpenXRExtensionWrapperExtension_private_method__on_state_exiting:
  138. .. rst-class:: classref-method
  139. void **_on_state_exiting** **(** **)** |virtual|
  140. Called when the OpenXR session state is changed to exiting.
  141. .. rst-class:: classref-item-separator
  142. ----
  143. .. _class_OpenXRExtensionWrapperExtension_private_method__on_state_focused:
  144. .. rst-class:: classref-method
  145. void **_on_state_focused** **(** **)** |virtual|
  146. Called when the OpenXR session state is changed to focused. This state is the active state when the game runs.
  147. .. rst-class:: classref-item-separator
  148. ----
  149. .. _class_OpenXRExtensionWrapperExtension_private_method__on_state_idle:
  150. .. rst-class:: classref-method
  151. void **_on_state_idle** **(** **)** |virtual|
  152. Called when the OpenXR session state is changed to idle.
  153. .. rst-class:: classref-item-separator
  154. ----
  155. .. _class_OpenXRExtensionWrapperExtension_private_method__on_state_loss_pending:
  156. .. rst-class:: classref-method
  157. void **_on_state_loss_pending** **(** **)** |virtual|
  158. Called when the OpenXR session state is changed to loss pending.
  159. .. rst-class:: classref-item-separator
  160. ----
  161. .. _class_OpenXRExtensionWrapperExtension_private_method__on_state_ready:
  162. .. rst-class:: classref-method
  163. void **_on_state_ready** **(** **)** |virtual|
  164. Called when the OpenXR session state is changed to ready. This means OpenXR is ready to set up the session.
  165. .. rst-class:: classref-item-separator
  166. ----
  167. .. _class_OpenXRExtensionWrapperExtension_private_method__on_state_stopping:
  168. .. rst-class:: classref-method
  169. void **_on_state_stopping** **(** **)** |virtual|
  170. Called when the OpenXR session state is changed to stopping.
  171. .. rst-class:: classref-item-separator
  172. ----
  173. .. _class_OpenXRExtensionWrapperExtension_private_method__on_state_synchronized:
  174. .. rst-class:: classref-method
  175. void **_on_state_synchronized** **(** **)** |virtual|
  176. Called when the OpenXR session state is changed to synchronized. OpenXR also returns to this state when the application loses focus.
  177. .. rst-class:: classref-item-separator
  178. ----
  179. .. _class_OpenXRExtensionWrapperExtension_private_method__on_state_visible:
  180. .. rst-class:: classref-method
  181. void **_on_state_visible** **(** **)** |virtual|
  182. Called when the OpenXR session state is changed to visible. This means OpenXR is now ready to receive frames.
  183. .. rst-class:: classref-item-separator
  184. ----
  185. .. _class_OpenXRExtensionWrapperExtension_private_method__set_instance_create_info_and_get_next_pointer:
  186. .. rst-class:: classref-method
  187. :ref:`int<class_int>` **_set_instance_create_info_and_get_next_pointer** **(** void* next_pointer **)** |virtual|
  188. Adds additional data structures when the OpenXR instance is created.
  189. .. rst-class:: classref-item-separator
  190. ----
  191. .. _class_OpenXRExtensionWrapperExtension_private_method__set_session_create_and_get_next_pointer:
  192. .. rst-class:: classref-method
  193. :ref:`int<class_int>` **_set_session_create_and_get_next_pointer** **(** void* next_pointer **)** |virtual|
  194. Adds additional data structures when the OpenXR session is created.
  195. .. rst-class:: classref-item-separator
  196. ----
  197. .. _class_OpenXRExtensionWrapperExtension_private_method__set_swapchain_create_info_and_get_next_pointer:
  198. .. rst-class:: classref-method
  199. :ref:`int<class_int>` **_set_swapchain_create_info_and_get_next_pointer** **(** void* next_pointer **)** |virtual|
  200. Adds additional data structures when creating OpenXR swapchains.
  201. .. rst-class:: classref-item-separator
  202. ----
  203. .. _class_OpenXRExtensionWrapperExtension_private_method__set_system_properties_and_get_next_pointer:
  204. .. rst-class:: classref-method
  205. :ref:`int<class_int>` **_set_system_properties_and_get_next_pointer** **(** void* next_pointer **)** |virtual|
  206. Adds additional data structures when interogating OpenXR system abilities.
  207. .. rst-class:: classref-item-separator
  208. ----
  209. .. _class_OpenXRExtensionWrapperExtension_method_get_openxr_api:
  210. .. rst-class:: classref-method
  211. :ref:`OpenXRAPIExtension<class_OpenXRAPIExtension>` **get_openxr_api** **(** **)**
  212. Returns the created :ref:`OpenXRAPIExtension<class_OpenXRAPIExtension>`, which can be used to access the OpenXR API.
  213. .. rst-class:: classref-item-separator
  214. ----
  215. .. _class_OpenXRExtensionWrapperExtension_method_register_extension_wrapper:
  216. .. rst-class:: classref-method
  217. void **register_extension_wrapper** **(** **)**
  218. Registers the extension. This should happen at core module initialization level.
  219. .. |virtual| replace:: :abbr:`virtual (This method should typically be overridden by the user to have any effect.)`
  220. .. |const| replace:: :abbr:`const (This method has no side effects. It doesn't modify any of the instance's member variables.)`
  221. .. |vararg| replace:: :abbr:`vararg (This method accepts any number of arguments after the ones described here.)`
  222. .. |constructor| replace:: :abbr:`constructor (This method is used to construct a type.)`
  223. .. |static| replace:: :abbr:`static (This method doesn't need an instance to be called, so it can be called directly using the class name.)`
  224. .. |operator| replace:: :abbr:`operator (This method describes a valid operator to use with this type as left-hand operand.)`
  225. .. |bitfield| replace:: :abbr:`BitField (This value is an integer composed as a bitmask of the following flags.)`