class_openxrinteractionprofilemetadata.rst 8.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108
  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/4.2/doc/tools/make_rst.py.
  5. .. XML source: https://github.com/godotengine/godot/tree/4.2/modules/openxr/doc_classes/OpenXRInteractionProfileMetadata.xml.
  6. .. _class_OpenXRInteractionProfileMetadata:
  7. OpenXRInteractionProfileMetadata
  8. ================================
  9. **Inherits:** :ref:`Object<class_Object>`
  10. Meta class registering supported devices in OpenXR.
  11. .. rst-class:: classref-introduction-group
  12. Description
  13. -----------
  14. This class allows OpenXR core and extensions to register metadata relating to supported interaction devices such as controllers, trackers, haptic devices, etc. It is primarily used by the action map editor and to sanitize any action map by removing extension-dependent entries when applicable.
  15. .. rst-class:: classref-reftable-group
  16. Methods
  17. -------
  18. .. table::
  19. :widths: auto
  20. +------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
  21. | void | :ref:`register_interaction_profile<class_OpenXRInteractionProfileMetadata_method_register_interaction_profile>` **(** :ref:`String<class_String>` display_name, :ref:`String<class_String>` openxr_path, :ref:`String<class_String>` openxr_extension_name **)** |
  22. +------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
  23. | void | :ref:`register_io_path<class_OpenXRInteractionProfileMetadata_method_register_io_path>` **(** :ref:`String<class_String>` interaction_profile, :ref:`String<class_String>` display_name, :ref:`String<class_String>` toplevel_path, :ref:`String<class_String>` openxr_path, :ref:`String<class_String>` openxr_extension_name, :ref:`ActionType<enum_OpenXRAction_ActionType>` action_type **)** |
  24. +------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
  25. | void | :ref:`register_profile_rename<class_OpenXRInteractionProfileMetadata_method_register_profile_rename>` **(** :ref:`String<class_String>` old_name, :ref:`String<class_String>` new_name **)** |
  26. +------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
  27. | void | :ref:`register_top_level_path<class_OpenXRInteractionProfileMetadata_method_register_top_level_path>` **(** :ref:`String<class_String>` display_name, :ref:`String<class_String>` openxr_path, :ref:`String<class_String>` openxr_extension_name **)** |
  28. +------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
  29. .. rst-class:: classref-section-separator
  30. ----
  31. .. rst-class:: classref-descriptions-group
  32. Method Descriptions
  33. -------------------
  34. .. _class_OpenXRInteractionProfileMetadata_method_register_interaction_profile:
  35. .. rst-class:: classref-method
  36. void **register_interaction_profile** **(** :ref:`String<class_String>` display_name, :ref:`String<class_String>` openxr_path, :ref:`String<class_String>` openxr_extension_name **)**
  37. Registers an interaction profile using its OpenXR designation (e.g. ``/interaction_profiles/khr/simple_controller`` is the profile for OpenXR's simple controller profile).
  38. \ ``display_name`` is the description shown to the user. ``openxr_path`` is the interaction profile path being registered. ``openxr_extension_name`` optionally restricts this profile to the given extension being enabled/available. If the extension is not available, the profile and all related entries used in an action map are filtered out.
  39. .. rst-class:: classref-item-separator
  40. ----
  41. .. _class_OpenXRInteractionProfileMetadata_method_register_io_path:
  42. .. rst-class:: classref-method
  43. void **register_io_path** **(** :ref:`String<class_String>` interaction_profile, :ref:`String<class_String>` display_name, :ref:`String<class_String>` toplevel_path, :ref:`String<class_String>` openxr_path, :ref:`String<class_String>` openxr_extension_name, :ref:`ActionType<enum_OpenXRAction_ActionType>` action_type **)**
  44. Registers an input/output path for the given ``interaction_profile``. The profile should previously have been registered using :ref:`register_interaction_profile<class_OpenXRInteractionProfileMetadata_method_register_interaction_profile>`. ``display_name`` is the description shown to the user. ``toplevel_path`` specifies the bind path this input/output can be bound to (e.g. ``/user/hand/left`` or ``/user/hand/right``). ``openxr_path`` is the action input/output being registered (e.g. ``/user/hand/left/input/aim/pose``). ``openxr_extension_name`` restricts this input/output to an enabled/available extension, this doesn't need to repeat the extension on the profile but relates to overlapping extension (e.g. ``XR_EXT_palm_pose`` that introduces ``…/input/palm_ext/pose`` input paths). ``action_type`` defines the type of input or output provided by OpenXR.
  45. .. rst-class:: classref-item-separator
  46. ----
  47. .. _class_OpenXRInteractionProfileMetadata_method_register_profile_rename:
  48. .. rst-class:: classref-method
  49. void **register_profile_rename** **(** :ref:`String<class_String>` old_name, :ref:`String<class_String>` new_name **)**
  50. Allows for renaming old interaction profile paths to new paths to maintain backwards compatibility with older action maps.
  51. .. rst-class:: classref-item-separator
  52. ----
  53. .. _class_OpenXRInteractionProfileMetadata_method_register_top_level_path:
  54. .. rst-class:: classref-method
  55. void **register_top_level_path** **(** :ref:`String<class_String>` display_name, :ref:`String<class_String>` openxr_path, :ref:`String<class_String>` openxr_extension_name **)**
  56. Registers a top level path to which profiles can be bound. For instance ``/user/hand/left`` refers to the bind point for the player's left hand. Extensions can register additional top level paths, for instance a haptic vest extension might register ``/user/body/vest``.
  57. \ ``display_name`` is the name shown to the user. ``openxr_path`` is the top level path being registered. ``openxr_extension_name`` is optional and ensures the top level path is only used if the specified extension is available/enabled.
  58. When a top level path ends up being bound by OpenXR, a :ref:`XRPositionalTracker<class_XRPositionalTracker>` is instantiated to manage the state of the device.
  59. .. |virtual| replace:: :abbr:`virtual (This method should typically be overridden by the user to have any effect.)`
  60. .. |const| replace:: :abbr:`const (This method has no side effects. It doesn't modify any of the instance's member variables.)`
  61. .. |vararg| replace:: :abbr:`vararg (This method accepts any number of arguments after the ones described here.)`
  62. .. |constructor| replace:: :abbr:`constructor (This method is used to construct a type.)`
  63. .. |static| replace:: :abbr:`static (This method doesn't need an instance to be called, so it can be called directly using the class name.)`
  64. .. |operator| replace:: :abbr:`operator (This method describes a valid operator to use with this type as left-hand operand.)`
  65. .. |bitfield| replace:: :abbr:`BitField (This value is an integer composed as a bitmask of the following flags.)`