summaryrefslogtreecommitdiff
path: root/doc/classes
diff options
context:
space:
mode:
Diffstat (limited to 'doc/classes')
-rw-r--r--doc/classes/XRInterfaceExtension.xml50
-rw-r--r--doc/classes/XRServer.xml18
2 files changed, 47 insertions, 21 deletions
diff --git a/doc/classes/XRInterfaceExtension.xml b/doc/classes/XRInterfaceExtension.xml
index d2bb6aa59a..cd09f83335 100644
--- a/doc/classes/XRInterfaceExtension.xml
+++ b/doc/classes/XRInterfaceExtension.xml
@@ -9,46 +9,52 @@
<tutorials>
</tutorials>
<methods>
- <method name="_commit_views" qualifiers="virtual">
+ <method name="_end_frame" qualifiers="virtual">
<return type="void" />
- <argument index="0" name="render_target" type="RID" />
- <argument index="1" name="screen_rect" type="Rect2" />
<description>
+ Called if interface is active and queues have been submitted.
</description>
</method>
<method name="_get_anchor_detection_is_enabled" qualifiers="virtual const">
<return type="bool" />
<description>
+ Return [code]true[/code] if anchor detection is enabled for this interface.
</description>
</method>
<method name="_get_camera_feed_id" qualifiers="virtual const">
<return type="int" />
<description>
+ Returns the camera feed id for the [CameraFeed] registered with the [CameraServer] that should be presented as the background on an AR capable device (if applicable).
</description>
</method>
<method name="_get_camera_transform" qualifiers="virtual">
<return type="Transform3D" />
<description>
+ Returns the [Transform3D] that positions the [XRCamera3D] in the world.
</description>
</method>
<method name="_get_capabilities" qualifiers="virtual const">
<return type="int" />
<description>
+ Returns the capabilities of this interface.
</description>
</method>
<method name="_get_name" qualifiers="virtual const">
<return type="StringName" />
<description>
+ Returns the name of this interface.
</description>
</method>
<method name="_get_play_area" qualifiers="virtual const">
<return type="PackedVector3Array" />
<description>
+ Returns an [PackedVector3Array] that denotes the play areas boundaries (if applicable).
</description>
</method>
<method name="_get_play_area_mode" qualifiers="virtual const">
<return type="int" />
<description>
+ Returns the [enum XRInterface.PlayAreaMode] that sets up our play area.
</description>
</method>
<method name="_get_projection_for_view" qualifiers="virtual">
@@ -58,27 +64,32 @@
<argument index="2" name="z_near" type="float" />
<argument index="3" name="z_far" type="float" />
<description>
+ Returns the projection matrix for the given view as a [PackedFloat64Array].
</description>
</method>
<method name="_get_render_target_size" qualifiers="virtual">
<return type="Vector2" />
<description>
+ Returns the size of our render target for this interface, this overrides the size of the [Viewport] marked as the xr viewport.
</description>
</method>
<method name="_get_suggested_pose_names" qualifiers="virtual const">
<return type="PackedStringArray" />
<argument index="0" name="tracker_name" type="StringName" />
<description>
+ Returns a [PackedStringArray] with pose names configured by this interface. Note that user configuration can override this list.
</description>
</method>
<method name="_get_suggested_tracker_names" qualifiers="virtual const">
<return type="PackedStringArray" />
<description>
+ Returns a [PackedStringArray] with tracker names configured by this interface. Note that user configuration can override this list.
</description>
</method>
<method name="_get_tracking_status" qualifiers="virtual const">
<return type="int" />
<description>
+ Returns a [enum XRInterface.TrackingStatus] specifying the current status of our tracking.
</description>
</method>
<method name="_get_transform_for_view" qualifiers="virtual">
@@ -86,50 +97,80 @@
<argument index="0" name="view" type="int" />
<argument index="1" name="cam_transform" type="Transform3D" />
<description>
+ Returns a [Transform3D] for a given view.
</description>
</method>
<method name="_get_view_count" qualifiers="virtual">
<return type="int" />
<description>
+ Returns the number of views this interface requires, 1 for mono, 2 for stereoscopic.
</description>
</method>
<method name="_initialize" qualifiers="virtual">
<return type="bool" />
<description>
+ Initializes the interface, returns [code]true[/code] on success.
</description>
</method>
<method name="_is_initialized" qualifiers="virtual const">
<return type="bool" />
<description>
+ Returns [code]true[/code] if this interface has been initialised.
</description>
</method>
<method name="_notification" qualifiers="virtual">
<return type="void" />
<argument index="0" name="what" type="int" />
<description>
+ Informs the interface of an applicable system notification.
+ </description>
+ </method>
+ <method name="_post_draw_viewport" qualifiers="virtual">
+ <return type="void" />
+ <argument index="0" name="render_target" type="RID" />
+ <argument index="1" name="screen_rect" type="Rect2" />
+ <description>
+ Called after the XR [Viewport] draw logic has completed.
+ </description>
+ </method>
+ <method name="_pre_draw_viewport" qualifiers="virtual">
+ <return type="bool" />
+ <argument index="0" name="render_target" type="RID" />
+ <description>
+ Called if this is our primary [XRInterfaceExtension] before we start processing a [Viewport] for every active XR [Viewport], returns [code]true[/code] if that viewport should be rendered. An XR interface may return [code]false[/code] if the user has taken off their headset and we can pause rendering.
+ </description>
+ </method>
+ <method name="_pre_render" qualifiers="virtual">
+ <return type="void" />
+ <description>
+ Called if this [XRInterfaceExtension] is active before rendering starts, most XR interfaces will sync tracking at this point in time.
</description>
</method>
<method name="_process" qualifiers="virtual">
<return type="void" />
<description>
+ Called if this [XRInterfaceExtension] is active before our physics and game process is called. most XR interfaces will update its [XRPositionalTracker]s at this point in time.
</description>
</method>
<method name="_set_anchor_detection_is_enabled" qualifiers="virtual">
<return type="void" />
<argument index="0" name="enabled" type="bool" />
<description>
+ Enables anchor detection on this interface if supported.
</description>
</method>
<method name="_set_play_area_mode" qualifiers="virtual const">
<return type="bool" />
<argument index="0" name="mode" type="int" />
<description>
+ Set the play area mode for this interface.
</description>
</method>
<method name="_supports_play_area_mode" qualifiers="virtual const">
<return type="bool" />
<argument index="0" name="mode" type="int" enum="XRInterface.PlayAreaMode" />
<description>
+ Returns [code]true[/code] if this interface supports this play area mode.
</description>
</method>
<method name="_trigger_haptic_pulse" qualifiers="virtual">
@@ -141,11 +182,13 @@
<argument index="4" name="duration_sec" type="float" />
<argument index="5" name="delay_sec" type="float" />
<description>
+ Triggers a haptic pulse to be emitted on the specified tracker.
</description>
</method>
<method name="_uninitialize" qualifiers="virtual">
<return type="void" />
<description>
+ Uninitialize the interface.
</description>
</method>
<method name="add_blit">
@@ -169,6 +212,7 @@
<return type="RID" />
<argument index="0" name="render_target" type="RID" />
<description>
+ Returns a valid [RID] for a texture to which we should render the current frame if supported by the interface.
</description>
</method>
</methods>
diff --git a/doc/classes/XRServer.xml b/doc/classes/XRServer.xml
index 3a7fdea8d0..335ca4c35f 100644
--- a/doc/classes/XRServer.xml
+++ b/doc/classes/XRServer.xml
@@ -69,24 +69,6 @@
Returns a list of available interfaces the ID and name of each interface.
</description>
</method>
- <method name="get_last_commit_usec">
- <return type="int" />
- <description>
- Returns the absolute timestamp (in μs) of the last [XRServer] commit of the AR/VR eyes to [RenderingServer]. The value comes from an internal call to [method Time.get_ticks_usec].
- </description>
- </method>
- <method name="get_last_frame_usec">
- <return type="int" />
- <description>
- Returns the duration (in μs) of the last frame. This is computed as the difference between [method get_last_commit_usec] and [method get_last_process_usec] when committing.
- </description>
- </method>
- <method name="get_last_process_usec">
- <return type="int" />
- <description>
- Returns the absolute timestamp (in μs) of the last [XRServer] process callback. The value comes from an internal call to [method Time.get_ticks_usec].
- </description>
- </method>
<method name="get_reference_frame" qualifiers="const">
<return type="Transform3D" />
<description>