Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
OpenXR Commands
xrAcquireSwapchainImage(3)
Name
xrAcquireSwapchainImage - Acquire a swapchain image
C Specification
The xrAcquireSwapchainImage function is defined as:
// Provided by XR_VERSION_1_0
XrResult xrAcquireSwapchainImage(
XrSwapchain swapchain,
const XrSwapchainImageAcquireInfo* acquireInfo,
uint32_t* index);
Parameters
Description
Acquires the image corresponding to the index
position in the array
returned by xrEnumerateSwapchainImages.
The runtime must return XR_ERROR_CALL_ORDER_INVALID
if the next
available index has already been acquired and not yet released with
xrReleaseSwapchainImage.
If the swapchain
was created with the
XR_SWAPCHAIN_CREATE_STATIC_IMAGE_BIT
set in
XrSwapchainCreateInfo::createFlags
, this function must not have
been previously called for this swapchain.
The runtime must return XR_ERROR_CALL_ORDER_INVALID
if a
swapchain
created with the XR_SWAPCHAIN_CREATE_STATIC_IMAGE_BIT
set in XrSwapchainCreateInfo::createFlags
and this function has
been successfully called previously for this swapchain.
See Also
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrApplyFoveationHTC(3)
Name
xrApplyFoveationHTC - Apply foveation config to system.
C Specification
The xrApplyFoveationHTC function is defined as:
// Provided by XR_HTC_foveation
XrResult xrApplyFoveationHTC(
XrSession session,
const XrFoveationApplyInfoHTC* applyInfo);
Parameters
Description
The foveation configuration will be applied after this call, and the state will persist until the next call to xrApplyFoveationHTC or the end of this XrSession, whichever comes first. You should not call xrApplyFoveationHTC during rendering to target image layer XrSwapchainSubImage in render loop.
See Also
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrApplyHapticFeedback(3)
Name
xrApplyHapticFeedback - Apply haptic feedback
C Specification
The xrApplyHapticFeedback function is defined as:
// Provided by XR_VERSION_1_0
XrResult xrApplyHapticFeedback(
XrSession session,
const XrHapticActionInfo* hapticActionInfo,
const XrHapticBaseHeader* hapticFeedback);
Parameters
Description
Triggers a haptic event through the specified action of type
XR_ACTION_TYPE_VIBRATION_OUTPUT
.
The runtime should deliver this request to the appropriate device, but
exactly which device, if any, this event is sent to is up to the runtime to
decide.
If an appropriate device is unavailable the runtime may ignore this request
for haptic feedback.
If session
is not focused, the runtime must return
XR_SESSION_NOT_FOCUSED
, and not trigger a haptic event.
If another haptic event from this session is currently happening on the device bound to this action, the runtime must interrupt that other event and replace it with the new one.
See Also
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrAttachSessionActionSets(3)
Name
xrAttachSessionActionSets - Attaches action sets to a given session
C Specification
The xrAttachSessionActionSets function is defined as:
// Provided by XR_VERSION_1_0
XrResult xrAttachSessionActionSets(
XrSession session,
const XrSessionActionSetsAttachInfo* attachInfo);
Parameters
Description
xrAttachSessionActionSets attaches the XrActionSet handles in
attachInfo.actionSets
to the session
.
Action sets must be attached in order to be synchronized with
xrSyncActions.
When an action set is attached to a session, that action set becomes immutable. See xrCreateAction and xrSuggestInteractionProfileBindings for details.
After action sets are attached to a session, if any unattached actions are
passed to functions for the same session, then for those functions the
runtime must return XR_ERROR_ACTIONSET_NOT_ATTACHED
.
The runtime must return XR_ERROR_ACTIONSETS_ALREADY_ATTACHED
if
xrAttachSessionActionSets is called more than once for a given
session
.
See Also
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrBeginFrame(3)
Name
xrBeginFrame - Marks a frame
C Specification
The xrBeginFrame function is defined as:
// Provided by XR_VERSION_1_0
XrResult xrBeginFrame(
XrSession session,
const XrFrameBeginInfo* frameBeginInfo);
Parameters
Description
xrBeginFrame is called prior to the start of frame rendering.
The application should still call xrBeginFrame but omit rendering
work for the frame if XrFrameState::shouldRender
is
XR_FALSE
.
Runtimes must not perform frame synchronization or throttling through the xrBeginFrame function and should instead do so through xrWaitFrame.
The runtime must return the error code XR_ERROR_CALL_ORDER_INVALID
if
there was no corresponding successful call to xrWaitFrame.
The runtime must return the success code XR_FRAME_DISCARDED
if a
prior xrBeginFrame has been called without an intervening call to
xrEndFrame.
The runtime must return XR_ERROR_SESSION_NOT_RUNNING
if the
session
is not running.
See Also
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrBeginSession(3)
Name
xrBeginSession - Begins an XrSession
C Specification
The xrBeginSession function is defined as:
// Provided by XR_VERSION_1_0
XrResult xrBeginSession(
XrSession session,
const XrSessionBeginInfo* beginInfo);
Parameters
Description
When the application receives XrEventDataSessionStateChanged event
with the XR_SESSION_STATE_READY
state, the application should then
call xrBeginSession to start rendering frames for display to the user.
After this function successfully returns, the session is considered to be running. The application should then start its frame loop consisting of some sequence of xrWaitFrame/xrBeginFrame/xrEndFrame calls.
If the session is already running when the application
calls xrBeginSession, the runtime must return error
XR_ERROR_SESSION_RUNNING
.
If the session is not running when the application
calls xrBeginSession, but the session is not yet in the
XR_SESSION_STATE_READY
state, the runtime must return error
XR_ERROR_SESSION_NOT_READY
.
Note that a runtime may decide not to show the user any given frame from a
session at any time, for example if the user has switched to a different
application’s running session.
The application should check whether xrWaitFrame returns an
XrFrameState with shouldRender
set to true before rendering a
given frame to determine whether that frame will be visible to the user.
Runtime session frame state must start in a reset state when a session transitions to running so that no state is carried over from when the same session was previously running.
If primaryViewConfigurationType
in beginInfo
is not supported by
the XrSystemId
used to create the session
, the runtime must
return XR_ERROR_VIEW_CONFIGURATION_TYPE_UNSUPPORTED
.
See Also
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrClearSpatialAnchorStoreMSFT(3)
Name
xrClearSpatialAnchorStoreMSFT - Clear all spatial anchors from the spatial anchor store
C Specification
The application can use the xrClearSpatialAnchorStoreMSFT function to remove all spatial anchors from the spatial anchor store for this application. The function only removes the record of the spatial anchors in the store but does not affect any XrSpatialAnchorMSFT handles previously loaded in the current session.
// Provided by XR_MSFT_spatial_anchor_persistence
XrResult xrClearSpatialAnchorStoreMSFT(
XrSpatialAnchorStoreConnectionMSFT spatialAnchorStore);
Parameters
Description
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrComputeNewSceneMSFT(3)
Name
xrComputeNewSceneMSFT - Compute new scene
C Specification
The xrComputeNewSceneMSFT function begins the compute of a new scene and the runtime must return quickly without waiting for the compute to complete. The application should use xrGetSceneComputeStateMSFT to inspect the compute status.
The application can control the compute features by passing a list of
XrSceneComputeFeatureMSFT via
XrNewSceneComputeInfoMSFT::requestedFeatures
.
-
If
XR_SCENE_COMPUTE_FEATURE_PLANE_MSFT
is passed, butXR_SCENE_COMPUTE_FEATURE_PLANE_MESH_MSFT
is not passed, then:-
The application may be able to read
XR_SCENE_COMPONENT_TYPE_PLANE_MSFT
andXR_SCENE_COMPONENT_TYPE_OBJECT_MSFT
scene components from the resulting XrSceneMSFT handle. -
XrScenePlaneMSFT::
meshBufferId
must be zero to indicate that the plane scene component does not have a mesh buffer available to read.
-
-
If
XR_SCENE_COMPUTE_FEATURE_PLANE_MSFT
andXR_SCENE_COMPUTE_FEATURE_PLANE_MESH_MSFT
are passed, then:-
the application may be able to read
XR_SCENE_COMPONENT_TYPE_PLANE_MSFT
andXR_SCENE_COMPONENT_TYPE_OBJECT_MSFT
scene components from the resulting XrSceneMSFT handle -
XrScenePlaneMSFT::
meshBufferId
may contain a non-zero mesh buffer identifier to indicate that the plane scene component has a mesh buffer available to read.
-
-
If
XR_SCENE_COMPUTE_FEATURE_VISUAL_MESH_MSFT
is passed then:-
the application may be able to read
XR_SCENE_COMPONENT_TYPE_VISUAL_MESH_MSFT
andXR_SCENE_COMPONENT_TYPE_OBJECT_MSFT
scene components from the resulting XrSceneMSFT handle.
-
-
If
XR_SCENE_COMPUTE_FEATURE_COLLIDER_MESH_MSFT
is passed then:-
the application may be able to read
XR_SCENE_COMPONENT_TYPE_COLLIDER_MESH_MSFT
andXR_SCENE_COMPONENT_TYPE_OBJECT_MSFT
scene components from the resulting XrSceneMSFT handle.
-
// Provided by XR_MSFT_scene_understanding
XrResult xrComputeNewSceneMSFT(
XrSceneObserverMSFT sceneObserver,
const XrNewSceneComputeInfoMSFT* computeInfo);
Parameters
Description
The runtime must return
XR_ERROR_SCENE_COMPUTE_FEATURE_INCOMPATIBLE_MSFT
if incompatible
features were passed or no compatible features were passed.
The runtime must return
XR_ERROR_SCENE_COMPUTE_FEATURE_INCOMPATIBLE_MSFT
if
XR_SCENE_COMPUTE_FEATURE_PLANE_MESH_MSFT
was passed but
XR_SCENE_COMPUTE_FEATURE_PLANE_MSFT
was not passed.
The runtime must return XR_ERROR_COMPUTE_NEW_SCENE_NOT_COMPLETED_MSFT
if xrComputeNewSceneMSFT is called while the scene computation is in
progress.
An application that wishes to use
XR_SCENE_COMPUTE_CONSISTENCY_OCCLUSION_OPTIMIZED_MSFT
must create an
XrSceneObserverMSFT handle that passes neither
XR_SCENE_COMPUTE_CONSISTENCY_SNAPSHOT_COMPLETE_MSFT
nor
XR_SCENE_COMPUTE_CONSISTENCY_SNAPSHOT_INCOMPLETE_FAST_MSFT
to
xrComputeNewSceneMSFT for the lifetime of that
XrSceneObserverMSFT handle.
This allows the runtime to return occlusion mesh at a different cadence than
non-occlusion mesh or planes.
-
The runtime must return
XR_ERROR_SCENE_COMPUTE_CONSISTENCY_MISMATCH_MSFT
if:-
XR_SCENE_COMPUTE_CONSISTENCY_OCCLUSION_OPTIMIZED_MSFT
is passed to xrComputeNewSceneMSFT and -
a previous call to xrComputeNewSceneMSFT did not pass
XR_SCENE_COMPUTE_CONSISTENCY_OCCLUSION_OPTIMIZED_MSFT
for the same XrSceneObserverMSFT handle.
-
-
The runtime must return
XR_ERROR_SCENE_COMPUTE_CONSISTENCY_MISMATCH_MSFT
if:-
XR_SCENE_COMPUTE_CONSISTENCY_OCCLUSION_OPTIMIZED_MSFT
is not passed to xrComputeNewSceneMSFT and -
a previous call to xrComputeNewSceneMSFT did pass
XR_SCENE_COMPUTE_CONSISTENCY_OCCLUSION_OPTIMIZED_MSFT
for the same XrSceneObserverMSFT handle.
-
-
The runtime must return
XR_ERROR_SCENE_COMPUTE_FEATURE_INCOMPATIBLE_MSFT
if:-
XR_SCENE_COMPUTE_CONSISTENCY_OCCLUSION_OPTIMIZED_MSFT
is passed to xrComputeNewSceneMSFT and -
neither
XR_SCENE_COMPUTE_FEATURE_VISUAL_MESH_MSFT
norXR_SCENE_COMPUTE_FEATURE_COLLIDER_MESH_MSFT
are also passed.
-
-
The runtime must return
XR_ERROR_SCENE_COMPUTE_FEATURE_INCOMPATIBLE_MSFT
if:-
XR_SCENE_COMPUTE_CONSISTENCY_OCCLUSION_OPTIMIZED_MSFT
is passed to xrComputeNewSceneMSFT and -
at least one of
XR_SCENE_COMPUTE_FEATURE_SERIALIZE_SCENE_MSFT
,XR_SCENE_COMPUTE_FEATURE_PLANE_MSFT
,XR_SCENE_COMPUTE_FEATURE_PLANE_MESH_MSFT
, orXR_SCENE_COMPUTE_FEATURE_SERIALIZE_SCENE_MSFT
are also passed.
-
See Also
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrConvertTimeToTimespecTimeKHR(3)
Name
xrConvertTimeToTimespecTimeKHR - Convert XrTime to timespec monotonic time
C Specification
To convert from XrTime
to timespec monotonic time, call:
// Provided by XR_KHR_convert_timespec_time
XrResult xrConvertTimeToTimespecTimeKHR(
XrInstance instance,
XrTime time,
struct timespec* timespecTime);
Parameters
Description
The xrConvertTimeToTimespecTimeKHR function converts an
XrTime
to time as if generated by clock_gettime
.
If the output timespecTime
cannot represent the input time
, the
runtime must return XR_ERROR_TIME_INVALID
.
See Also
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrConvertTimeToWin32PerformanceCounterKHR(3)
Name
xrConvertTimeToWin32PerformanceCounterKHR - Convert XrTime to Win32 QueryPerformanceCounter
time
C Specification
To convert from XrTime
to a Windows performance counter time stamp,
call:
// Provided by XR_KHR_win32_convert_performance_counter_time
XrResult xrConvertTimeToWin32PerformanceCounterKHR(
XrInstance instance,
XrTime time,
LARGE_INTEGER* performanceCounter);
Parameters
Description
The xrConvertTimeToWin32PerformanceCounterKHR function converts an
XrTime
to time as if generated by the QueryPerformanceCounter
Windows function.
If the output performanceCounter
cannot represent the input
time
, the runtime must return XR_ERROR_TIME_INVALID
.
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrConvertTimespecTimeToTimeKHR(3)
Name
xrConvertTimespecTimeToTimeKHR - Convert timespec monotonic time to XrTime
C Specification
To convert from timespec monotonic time to XrTime
, call:
// Provided by XR_KHR_convert_timespec_time
XrResult xrConvertTimespecTimeToTimeKHR(
XrInstance instance,
const struct timespec* timespecTime,
XrTime* time);
Parameters
Description
The xrConvertTimespecTimeToTimeKHR function converts a time obtained
by the clock_gettime
function to the equivalent XrTime
.
If the output time
cannot represent the input timespecTime
, the
runtime must return XR_ERROR_TIME_INVALID
.
See Also
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrConvertWin32PerformanceCounterToTimeKHR(3)
Name
xrConvertWin32PerformanceCounterToTimeKHR - Convert Win32 QueryPerformanceCounter
time to XrTime
C Specification
To convert from a Windows performance counter time stamp to XrTime
,
call:
// Provided by XR_KHR_win32_convert_performance_counter_time
XrResult xrConvertWin32PerformanceCounterToTimeKHR(
XrInstance instance,
const LARGE_INTEGER* performanceCounter,
XrTime* time);
Parameters
Description
The xrConvertWin32PerformanceCounterToTimeKHR function converts a time
stamp obtained by the QueryPerformanceCounter
Windows function to the
equivalent XrTime
.
If the output time
cannot represent the input
performanceCounter
, the runtime must return
XR_ERROR_TIME_INVALID
.
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrCreateAction(3)
Name
xrCreateAction - Creates an XrAction
C Specification
The xrCreateAction function is defined as:
// Provided by XR_VERSION_1_0
XrResult xrCreateAction(
XrActionSet actionSet,
const XrActionCreateInfo* createInfo,
XrAction* action);
Parameters
Description
xrCreateAction creates an action and returns its handle.
If actionSet
has been included in a call to
xrAttachSessionActionSets, the implementation must return
XR_ERROR_ACTIONSETS_ALREADY_ATTACHED
.
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrCreateActionSet(3)
Name
xrCreateActionSet - Creates an XrActionSet
C Specification
The xrCreateActionSet function is defined as:
// Provided by XR_VERSION_1_0
XrResult xrCreateActionSet(
XrInstance instance,
const XrActionSetCreateInfo* createInfo,
XrActionSet* actionSet);
Parameters
Description
The xrCreateActionSet function creates an action set and returns a handle to the created action set.
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrCreateActionSpace(3)
Name
xrCreateActionSpace - Creates a space based on a pose action
C Specification
The xrCreateActionSpace function is defined as:
// Provided by XR_VERSION_1_0
XrResult xrCreateActionSpace(
XrSession session,
const XrActionSpaceCreateInfo* createInfo,
XrSpace* space);
Parameters
Description
Creates an XrSpace handle based on a chosen pose action. Application can provide an XrPosef to define the position and orientation of the new space’s origin within the natural reference frame of the action space.
Multiple XrSpace handles may exist simultaneously, up to some limit imposed by the runtime. The XrSpace handle must be eventually freed via the xrDestroySpace function or by destroying the parent XrAction handle.
The runtime must return XR_ERROR_ACTION_TYPE_MISMATCH
if the action
provided in action
is not of type XR_ACTION_TYPE_POSE_INPUT
.
See Also
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrCreateDebugUtilsMessengerEXT(3)
Name
xrCreateDebugUtilsMessengerEXT - Creates a debug messenger
C Specification
// Provided by XR_EXT_debug_utils
XrResult xrCreateDebugUtilsMessengerEXT(
XrInstance instance,
const XrDebugUtilsMessengerCreateInfoEXT* createInfo,
XrDebugUtilsMessengerEXT* messenger);
Parameters
Description
The application must ensure that xrCreateDebugUtilsMessengerEXT is
not executed in parallel with any OpenXR function that is also called with
instance
or child of instance
.
When an event of interest occurs a debug messenger calls its
createInfo
->userCallback
with a debug message from the producer
of the event.
Additionally, the debug messenger must filter out any debug messages that
the application’s callback is not interested in based on
XrDebugUtilsMessengerCreateInfoEXT flags, as described below.
See Also
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrCreateFacialTrackerHTC(3)
Name
xrCreateFacialTrackerHTC - Create an facial tracker handle.
C Specification
The xrCreateFacialTrackerHTC function is defined as
// Provided by XR_HTC_facial_tracking
XrResult xrCreateFacialTrackerHTC(
XrSession session,
const XrFacialTrackerCreateInfoHTC* createInfo,
XrFacialTrackerHTC* facialTracker);
Parameters
Description
An application can create an XrFacialTrackerHTC handle using xrCreateFacialTrackerHTC.
If the system does not support eye tracking or lip tracking, runtime must
return XR_ERROR_FEATURE_UNSUPPORTED
from
xrCreateFacialTrackerHTC according to the corresponding case.
In this case, the runtime must return XR_FALSE
for
supportEyeFacialTracking
or supportLipFacialTracking
in
XrSystemFacialTrackingPropertiesHTC when the function
xrGetSystemProperties is called, so that the application may avoid
creating a facial tracker.
See Also
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrCreateFoveationProfileFB(3)
Name
xrCreateFoveationProfileFB - Create a foveation profile
C Specification
The xrCreateFoveationProfileFB function is defined as:
// Provided by XR_FB_foveation
XrResult xrCreateFoveationProfileFB(
XrSession session,
const XrFoveationProfileCreateInfoFB* createInfo,
XrFoveationProfileFB* profile);
Parameters
Description
Creates an XrFoveationProfileFB handle. The returned foveation profile handle may be subsequently used in API calls.
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrCreateGeometryInstanceFB(3)
Name
xrCreateGeometryInstanceFB - Create a triangle mesh
C Specification
The xrCreateGeometryInstanceFB function is defined as:
// Provided by XR_FB_passthrough
XrResult xrCreateGeometryInstanceFB(
XrSession session,
const XrGeometryInstanceCreateInfoFB* createInfo,
XrGeometryInstanceFB* outGeometryInstance);
Parameters
Description
Creates an XrGeometryInstanceFB handle. Geometry instance functionality requires https://www.khronos.org/registry/OpenXR/specs/1.0/html/xrspec.html#XR_FB_triangle_mesh extension to be enabled. An XrGeometryInstanceFB connects a layer, a mesh, and a transformation, with the semantics that a specific mesh will be instantiated in a specific layer with a specific transformation. A mesh can be instantiated multiple times, in the same or in different layers.
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrCreateHandMeshSpaceMSFT(3)
Name
xrCreateHandMeshSpaceMSFT - Create a space for hand mesh tracking
C Specification
The application creates a hand mesh space using function xrCreateHandMeshSpaceMSFT. The position and normal of hand mesh vertices will be represented in this space.
// Provided by XR_MSFT_hand_tracking_mesh
XrResult xrCreateHandMeshSpaceMSFT(
XrHandTrackerEXT handTracker,
const XrHandMeshSpaceCreateInfoMSFT* createInfo,
XrSpace* space);
Parameters
Description
A hand mesh space location is specified by runtime preference to effectively represent hand mesh vertices without unnecessary transformations. For example, an optical hand tracking system can define the hand mesh space origin at the depth camera’s optical center.
An application should create separate hand mesh space handles for each hand to retrieve the corresponding hand mesh data. The runtime may use the lifetime of this hand mesh space handle to manage the underlying device resources. Therefore, the application should destroy the hand mesh handle after it is finished using the hand mesh.
The hand mesh space can be related to other spaces in the session, such as
view reference space, or grip action space from the
/interaction_profiles/khr/simple_controller interaction profile.
The hand mesh space may be not locatable when the hand is outside of the
tracking range, or if focus is removed from the application.
In these cases, the runtime must not set the
XR_SPACE_LOCATION_POSITION_VALID_BIT
and
XR_SPACE_LOCATION_ORIENTATION_VALID_BIT
bits on calls to
xrLocateSpace with the hand mesh space, and the application should
avoid using the returned poses or query for hand mesh data.
If the underlying XrHandTrackerEXT is destroyed, the runtime must
continue to support xrLocateSpace using the hand mesh space, and it
must return space location with XR_SPACE_LOCATION_POSITION_VALID_BIT
and XR_SPACE_LOCATION_ORIENTATION_VALID_BIT
unset.
The application may create a mesh space for the reference hand by setting
handPoseType
to XR_HAND_POSE_TYPE_REFERENCE_OPEN_PALM_MSFT
.
Hand mesh spaces for the reference hand must only be locatable in reference
to mesh spaces or joint spaces of the reference hand.
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrCreateHandTrackerEXT(3)
Name
xrCreateHandTrackerEXT - Create a hand joints handle.
C Specification
An application can create an XrHandTrackerEXT handle using xrCreateHandTrackerEXT function.
// Provided by XR_EXT_hand_tracking
XrResult xrCreateHandTrackerEXT(
XrSession session,
const XrHandTrackerCreateInfoEXT* createInfo,
XrHandTrackerEXT* handTracker);
Parameters
Description
If the system does not support hand tracking, runtime must return
XR_ERROR_FEATURE_UNSUPPORTED
from xrCreateHandTrackerEXT.
In this case, the runtime must return XR_FALSE
for
supportsHandTracking
in XrSystemHandTrackingPropertiesEXT when
the function xrGetSystemProperties is called, so that the application
can avoid creating a hand tracker.
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrCreateInstance(3)
Name
xrCreateInstance - Creates an OpenXR Instance
C Specification
The xrCreateInstance function is defined as:
// Provided by XR_VERSION_1_0
XrResult xrCreateInstance(
const XrInstanceCreateInfo* createInfo,
XrInstance* instance);
Parameters
Description
xrCreateInstance creates the XrInstance, then enables and
initializes global API layers and extensions requested by the application.
If an extension is provided by an API layer, both the API layer and
extension must be specified at xrCreateInstance time.
If a specified API layer cannot be found, no XrInstance will be
created and the function will return XR_ERROR_API_LAYER_NOT_PRESENT
.
Likewise, if a specified extension cannot be found, the call must return
XR_ERROR_EXTENSION_NOT_PRESENT
and no XrInstance will be
created.
Additionally, some runtimes may limit the number of concurrent instances
that may be in use.
If the application attempts to create more instances than a runtime can
simultaneously support, xrCreateInstance may return
XR_ERROR_LIMIT_REACHED
.
If the XrApplicationInfo::applicationName
is the empty string
the runtime must return XR_ERROR_NAME_INVALID
.
If the XrInstanceCreateInfo structure contains a platform-specific
extension for a platform other than the target platform,
XR_ERROR_INITIALIZATION_FAILED
may be returned.
If a mandatory platform-specific extension is defined for the target
platform but no matching extension struct is provided in
XrInstanceCreateInfo the runtime must return
XR_ERROR_INITIALIZATION_FAILED
.
See Also
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrCreateKeyboardSpaceFB(3)
Name
xrCreateKeyboardSpaceFB - Create a foveation profile
C Specification
The xrCreateKeyboardSpaceFB function is defined as:
// Provided by XR_FB_keyboard_tracking
XrResult xrCreateKeyboardSpaceFB(
XrSession session,
const XrKeyboardSpaceCreateInfoFB* createInfo,
XrSpace* keyboardSpace);
Parameters
Description
The xrCreateKeyboardSpaceFB function returns an XrSpace that can be used to locate a physical keyboard in space. The origin of the created XrSpace is located in the center of the bounding box in the x and z axes, and at the top of the y axis (meaning the keyboard is located entirely in negative y).
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrCreateMarkerSpaceVARJO(3)
Name
xrCreateMarkerSpaceVARJO - Creates marker space
C Specification
The xrCreateMarkerSpaceVARJO function is defined as:
// Provided by XR_VARJO_marker_tracking
XrResult xrCreateMarkerSpaceVARJO(
XrSession session,
const XrMarkerSpaceCreateInfoVARJO* createInfo,
XrSpace* space);
Parameters
Description
The xrCreateMarkerSpaceVARJO function creates marker XrSpace for
pose relative to the marker specified in XrMarkerSpaceCreateInfoVARJO.
The runtime must return XR_ERROR_MARKER_ID_INVALID_VARJO
if the
supplied markerId
is invalid.
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrCreatePassthroughFB(3)
Name
xrCreatePassthroughFB - Create a passthrough feature
C Specification
The xrCreatePassthroughFB function is defined as:
// Provided by XR_FB_passthrough
XrResult xrCreatePassthroughFB(
XrSession session,
const XrPassthroughCreateInfoFB* createInfo,
XrPassthroughFB* outPassthrough);
Parameters
Description
Creates an XrPassthroughFB handle. The returned passthrough handle may be subsequently used in API calls.
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrCreatePassthroughHTC(3)
Name
xrCreatePassthroughHTC - Create a passthrough handle.
C Specification
The xrCreatePassthroughHTC function is defined as:
// Provided by XR_HTC_passthrough
XrResult xrCreatePassthroughHTC(
XrSession session,
const XrPassthroughCreateInfoHTC* createInfo,
XrPassthroughHTC* passthrough);
Parameters
Description
Creates an XrPassthroughHTC handle.
If the function successfully returned, the output passthrough
must be
a valid handle.
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrCreatePassthroughLayerFB(3)
Name
xrCreatePassthroughLayerFB - Create a passthrough layer
C Specification
The xrCreatePassthroughLayerFB function is defined as:
// Provided by XR_FB_passthrough
XrResult xrCreatePassthroughLayerFB(
XrSession session,
const XrPassthroughLayerCreateInfoFB* createInfo,
XrPassthroughLayerFB* outLayer);
Parameters
Description
Creates an XrPassthroughLayerFB handle. The returned layer handle may be subsequently used in API calls. Layer objects may be used to specify rendering properties of the layer, such as styles, and compositing rules.
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrCreateReferenceSpace(3)
Name
xrCreateReferenceSpace - Creates a reference space
C Specification
The xrCreateReferenceSpace function is defined as:
// Provided by XR_VERSION_1_0
XrResult xrCreateReferenceSpace(
XrSession session,
const XrReferenceSpaceCreateInfo* createInfo,
XrSpace* space);
Parameters
Description
Creates an XrSpace handle based on a chosen reference space. Application can provide an XrPosef to define the position and orientation of the new space’s origin within the natural reference frame of the reference space.
Multiple XrSpace handles may exist simultaneously, up to some limit imposed by the runtime. The XrSpace handle must be eventually freed via the xrDestroySpace function.
The runtime must return XR_ERROR_REFERENCE_SPACE_UNSUPPORTED
if the
given reference space type is not supported by this session
.
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrCreateSceneMSFT(3)
Name
xrCreateSceneMSFT - Create a scene handle
C Specification
The xrCreateSceneMSFT functions creates an XrSceneMSFT handle.
It can only be called after xrGetSceneComputeStateMSFT returns
XR_SCENE_COMPUTE_STATE_COMPLETED_MSFT
to indicate that the
asynchronous operation has completed.
The XrSceneMSFT handle manages the collection of scene components that
represents the detected objects found during the query.
After an XrSceneMSFT handle is created, the handle and associated data must remain valid until destroyed, even after xrCreateSceneMSFT is called again to create the next scene. The runtime must keep alive any component data and mesh buffers relating to this historical scene until its handle is destroyed.
// Provided by XR_MSFT_scene_understanding
XrResult xrCreateSceneMSFT(
XrSceneObserverMSFT sceneObserver,
const XrSceneCreateInfoMSFT* createInfo,
XrSceneMSFT* scene);
Parameters
Description
Calling xrCreateSceneMSFT when xrGetSceneComputeStateMSFT
returns XR_SCENE_COMPUTE_STATE_NONE_MSFT
or
XR_SCENE_COMPUTE_STATE_UPDATING_MSFT
must return the error
XR_ERROR_COMPUTE_NEW_SCENE_NOT_COMPLETED_MSFT
.
See Also
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrCreateSceneObserverMSFT(3)
Name
xrCreateSceneObserverMSFT - Create a scene observer handle
C Specification
An XrSceneObserverMSFT handle is created using xrCreateSceneObserverMSFT.
// Provided by XR_MSFT_scene_understanding
XrResult xrCreateSceneObserverMSFT(
XrSession session,
const XrSceneObserverCreateInfoMSFT* createInfo,
XrSceneObserverMSFT* sceneObserver);
Parameters
Description
See Also
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrCreateSession(3)
Name
xrCreateSession - Creates an XrSession
C Specification
The xrCreateSession function is defined as:
// Provided by XR_VERSION_1_0
XrResult xrCreateSession(
XrInstance instance,
const XrSessionCreateInfo* createInfo,
XrSession* session);
Parameters
Description
Creates a session using the provided createInfo
and returns a handle
to that session.
This session is created in the XR_SESSION_STATE_IDLE
state, and a
corresponding XrEventDataSessionStateChanged event to the
XR_SESSION_STATE_IDLE
state must be generated as the first such event
for the new session.
The runtime must return XR_ERROR_GRAPHICS_REQUIREMENTS_CALL_MISSING
(XR_ERROR_VALIDATION_FAILURE
may be returned due to legacy behavior)
on calls to xrCreateSession if a function named like
xrGet*GraphicsRequirements
has not been called for the same
instance
and XrSessionCreateInfo::systemId
.
(See graphics binding extensions for details.)
See Also
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrCreateSpatialAnchorFB(3)
Name
xrCreateSpatialAnchorFB - Creates a new spatial anchor
C Specification
The xrCreateSpatialAnchorFB function is defined as:
// Provided by XR_FB_spatial_entity
XrResult xrCreateSpatialAnchorFB(
XrSession session,
const XrSpatialAnchorCreateInfoFB* info,
XrAsyncRequestIdFB* requestId);
Parameters
Description
Creates a Spatial Anchor using the specified tracking origin and pose
relative to the specified tracking origin.
The anchor will be locatable at the time of creation, and the 6 DOF pose
relative to the tracking origin can be queried using the
xrLocateSpace method.
This operation is asynchronous and the runtime must post an
XrEventDataSpatialAnchorCreateCompleteFB event when the operation
completes successfully or encounters an error.
The requestId
can be used to later refer to the request, such as
identifying which request has completed when an
XrEventDataSpatialAnchorCreateCompleteFB is posted to the event queue.
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrCreateSpatialAnchorFromPerceptionAnchorMSFT(3)
Name
xrCreateSpatialAnchorFromPerceptionAnchorMSFT - Create an XrSpatialAnchorMSFT from a Windows SpatialAnchor pointer
C Specification
The xrCreateSpatialAnchorFromPerceptionAnchorMSFT function creates a
XrSpatialAnchorMSFT handle from an IUnknown
pointer to
Windows.Perception.Spatial.SpatialAnchor.
// Provided by XR_MSFT_perception_anchor_interop
XrResult xrCreateSpatialAnchorFromPerceptionAnchorMSFT(
XrSession session,
IUnknown* perceptionAnchor,
XrSpatialAnchorMSFT* anchor);
Parameters
Description
The input perceptionAnchor
must support successful QueryInterface
to
Windows.Perception.Spatial.SpatialAnchor
, otherwise the runtime must return XR_ERROR_VALIDATION_FAILURE
.
If the function successfully returned, the output anchor
must be a
valid handle.
This also increments the refcount of the perceptionAnchor
object.
When application is done with the anchor
handle, it can be destroyed
using xrDestroySpatialAnchorMSFT function.
This also decrements the refcount of underlying windows perception anchor
object.
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrCreateSpatialAnchorFromPersistedNameMSFT(3)
Name
xrCreateSpatialAnchorFromPersistedNameMSFT - Create a spatial anchor from the spatial anchor store by name
C Specification
The application can use the
xrCreateSpatialAnchorFromPersistedNameMSFT function to create a
XrSpatialAnchorMSFT from the spatial anchor store.
If the spatialAnchorName
provided does not correspond to a currently
stored anchor (i.e. the list of spatial anchor names returned from
xrEnumeratePersistedSpatialAnchorNamesMSFT), the function must return
XR_ERROR_SPATIAL_ANCHOR_NAME_NOT_FOUND_MSFT
.
// Provided by XR_MSFT_spatial_anchor_persistence
XrResult xrCreateSpatialAnchorFromPersistedNameMSFT(
XrSession session,
const XrSpatialAnchorFromPersistedAnchorCreateInfoMSFT* spatialAnchorCreateInfo,
XrSpatialAnchorMSFT* spatialAnchor);
Parameters
Description
See Also
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrCreateSpatialAnchorMSFT(3)
Name
xrCreateSpatialAnchorMSFT - Creates a spatial anchor
C Specification
The xrCreateSpatialAnchorMSFT function is defined as:
// Provided by XR_MSFT_spatial_anchor
XrResult xrCreateSpatialAnchorMSFT(
XrSession session,
const XrSpatialAnchorCreateInfoMSFT* createInfo,
XrSpatialAnchorMSFT* anchor);
Parameters
Description
Creates an XrSpatialAnchorMSFT handle representing a spatial anchor
that will track a fixed location in the physical world over time.
That real-world location is specified by the position and orientation of the
specified pose
within space
at time
.
If space
cannot be located relative to the environment at the moment
of the call to xrCreateSpatialAnchorMSFT, the runtime must return
XR_ERROR_CREATE_SPATIAL_ANCHOR_FAILED_MSFT
.
After the anchor is created, the runtime should then adjust its position
and orientation over time relative to other spaces so as to maintain maximum
alignment to its original real-world location, even if that changes the
anchor’s relationship to the original space
used to initialize it.
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrCreateSpatialAnchorSpaceMSFT(3)
Name
xrCreateSpatialAnchorSpaceMSFT - Creates a space from a spatial anchor
C Specification
The xrCreateSpatialAnchorSpaceMSFT function is defined as:
// Provided by XR_MSFT_spatial_anchor
XrResult xrCreateSpatialAnchorSpaceMSFT(
XrSession session,
const XrSpatialAnchorSpaceCreateInfoMSFT* createInfo,
XrSpace* space);
Parameters
Description
Creates an XrSpace handle based on a spatial anchor. Application can provide an XrPosef to define the position and orientation of the new space’s origin relative to the anchor’s natural origin.
Multiple XrSpace handles may exist for a given XrSpatialAnchorMSFT simultaneously, up to some limit imposed by the runtime. The XrSpace handle must be eventually freed via the xrDestroySpace function or by destroying the parent XrSpatialAnchorMSFT handle.
See Also
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrCreateSpatialAnchorStoreConnectionMSFT(3)
Name
xrCreateSpatialAnchorStoreConnectionMSFT - Create a handle to track a connection to the spatial anchor store
C Specification
The application can use the xrCreateSpatialAnchorStoreConnectionMSFT function to create an handle to the spatial anchor store. The application can use this handle to interact with the spatial anchor store in order to persist anchors across application sessions.
The xrCreateSpatialAnchorStoreConnectionMSFT function may be a slow operation and therefore should be invoked from a non-timing critical thread.
// Provided by XR_MSFT_spatial_anchor_persistence
XrResult xrCreateSpatialAnchorStoreConnectionMSFT(
XrSession session,
XrSpatialAnchorStoreConnectionMSFT* spatialAnchorStore);
Parameters
Description
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrCreateSpatialGraphNodeSpaceMSFT(3)
Name
xrCreateSpatialGraphNodeSpaceMSFT - Create an XrSpace from a spatial graph node.
C Specification
The xrCreateSpatialGraphNodeSpaceMSFT function creates an XrSpace handle for a given spatial graph node type and ID.
// Provided by XR_MSFT_spatial_graph_bridge
XrResult xrCreateSpatialGraphNodeSpaceMSFT(
XrSession session,
const XrSpatialGraphNodeSpaceCreateInfoMSFT* createInfo,
XrSpace* space);
Parameters
Description
See Also
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrCreateSwapchain(3)
Name
xrCreateSwapchain - Creates an XrSwapchain
C Specification
The xrCreateSwapchain function is defined as:
// Provided by XR_VERSION_1_0
XrResult xrCreateSwapchain(
XrSession session,
const XrSwapchainCreateInfo* createInfo,
XrSwapchain* swapchain);
Parameters
Description
Creates an XrSwapchain handle.
The returned swapchain handle may be subsequently used in API calls.
Multiple XrSwapchain handles may exist simultaneously, up to some
limit imposed by the runtime.
The XrSwapchain handle must be eventually freed via the
xrDestroySwapchain function.
The runtime must return XR_ERROR_SWAPCHAIN_FORMAT_UNSUPPORTED
if the
image format specified in the XrSwapchainCreateInfo is unsupported.
The runtime must return XR_ERROR_FEATURE_UNSUPPORTED
if any bit of
the create flags specified in the XrSwapchainCreateInfo is
unsupported.
See Also
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrCreateSwapchainAndroidSurfaceKHR(3)
Name
xrCreateSwapchainAndroidSurfaceKHR - Creates a swapchain and an Android Surface
C Specification
To create an XrSwapchain object and an Android Surface object call:
// Provided by XR_KHR_android_surface_swapchain
XrResult xrCreateSwapchainAndroidSurfaceKHR(
XrSession session,
const XrSwapchainCreateInfo* info,
XrSwapchain* swapchain,
jobject* surface);
Parameters
Description
xrCreateSwapchainAndroidSurfaceKHR creates an XrSwapchain object
returned in swapchain
and an Android Surface jobject
returned in
surface
.
The jobject
must be valid to be passed back to Java code using JNI and
must be valid to be used with ordinary Android APIs for submitting images
to Surfaces.
The returned XrSwapchain must be valid to be referenced in
XrSwapchainSubImage structures to show content on the screen.
The width and height passed in XrSwapchainCreateInfo may not be
persistent throughout the life cycle of the created swapchain, since on
Android, the size of the images is controlled by the producer and possibly
changes at any time.
The only function that is allowed to be called on the XrSwapchain returned from this function is xrDestroySwapchain. For example, calling any of the functions xrEnumerateSwapchainImages, xrAcquireSwapchainImage, xrWaitSwapchainImage or xrReleaseSwapchainImage is invalid.
When the application receives the XrEventDataSessionStateChanged event
with the XR_SESSION_STATE_STOPPING
state, it must ensure that no
threads are writing to any of the Android surfaces created with this
extension before calling xrEndSession.
The effect of writing frames to the Surface when the session is in states
other than XR_SESSION_STATE_VISIBLE
or XR_SESSION_STATE_FOCUSED
is undefined.
xrCreateSwapchainAndroidSurfaceKHR must return the same set of error
codes as xrCreateSwapchain under the same circumstances, plus
XR_ERROR_FUNCTION_UNSUPPORTED
in case the function is not supported.
See Also
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrCreateTriangleMeshFB(3)
Name
xrCreateTriangleMeshFB - Create a triangle mesh
C Specification
The xrCreateTriangleMeshFB function is defined as:
// Provided by XR_FB_triangle_mesh
XrResult xrCreateTriangleMeshFB(
XrSession session,
const XrTriangleMeshCreateInfoFB* createInfo,
XrTriangleMeshFB* outTriangleMesh);
Parameters
Description
This creates an XrTriangleMeshFB handle. The returned triangle mesh handle may be subsequently used in API calls.
When the mesh is mutable (the XR_TRIANGLE_MESH_MUTABLE_BIT_FB
bit is
set in createInfo
→flags
), the created triangle mesh starts in
the https://www.khronos.org/registry/OpenXR/specs/1.0/html/xrspec.html#fb_triangle_mesh_state_undefined_topology state.
Immutable meshes have no state machine; they may be considered to be in state https://www.khronos.org/registry/OpenXR/specs/1.0/html/xrspec.html#fb_triangle_mesh_state_ready with no valid edges leaving that state.
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrCreateVulkanDeviceKHR(3)
Name
xrCreateVulkanDeviceKHR - Create an OpenXR compatible VkDevice
C Specification
// Provided by XR_KHR_vulkan_enable2
XrResult xrCreateVulkanDeviceKHR(
XrInstance instance,
const XrVulkanDeviceCreateInfoKHR* createInfo,
VkDevice* vulkanDevice,
VkResult* vulkanResult);
Parameters
Description
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrCreateVulkanInstanceKHR(3)
Name
xrCreateVulkanInstanceKHR - Create an OpenXR compatible VkInstance
C Specification
// Provided by XR_KHR_vulkan_enable2
XrResult xrCreateVulkanInstanceKHR(
XrInstance instance,
const XrVulkanInstanceCreateInfoKHR* createInfo,
VkInstance* vulkanInstance,
VkResult* vulkanResult);
Parameters
Description
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrDeserializeSceneMSFT(3)
Name
xrDeserializeSceneMSFT - Deserialize scene
C Specification
The xrDeserializeSceneMSFT function is defined as:
// Provided by XR_MSFT_scene_understanding_serialization
XrResult xrDeserializeSceneMSFT(
XrSceneObserverMSFT sceneObserver,
const XrSceneDeserializeInfoMSFT* deserializeInfo);
Parameters
Description
The xrDeserializeSceneMSFT function begins deserializing a list of serialized scene fragments. The runtime must return quickly without waiting for the deserialization to complete. The application should use xrGetSceneComputeStateMSFT to inspect the completeness of the deserialization.
The runtime must return XR_ERROR_COMPUTE_NEW_SCENE_NOT_COMPLETED_MSFT
if xrDeserializeSceneMSFT is called while the scene computation is in
progress.
The xrGetSceneComputeStateMSFT function must return
XR_SCENE_COMPUTE_STATE_UPDATING_MSFT
while the deserialization is in
progress, and XR_SCENE_COMPUTE_STATE_COMPLETED_MSFT
when the
deserialization has completed successfully.
If the runtime fails to deserialize the binary stream,
xrGetSceneComputeStateMSFT must return
XR_SCENE_COMPUTE_STATE_COMPLETED_WITH_ERROR_MSFT
to indicate that the
deserialization has completed but an error occurred.
When xrGetSceneComputeStateMSFT returns
XR_SCENE_COMPUTE_STATE_COMPLETED_MSFT
, the application may call
xrCreateSceneMSFT to create the XrSceneMSFT handle.
If xrCreateSceneMSFT is called while xrGetSceneComputeStateMSFT
returns XR_SCENE_COMPUTE_STATE_COMPLETED_WITH_ERROR_MSFT
, a valid
XrSceneMSFT handle must be returned, but that handle must contain
zero scene components.
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrDestroyAction(3)
Name
xrDestroyAction - Destroys an XrAction
C Specification
The xrDestroyAction function is defined as:
// Provided by XR_VERSION_1_0
XrResult xrDestroyAction(
XrAction action);
Parameters
Description
Action handles can be destroyed by calling xrDestroyAction. Handles for actions that are part of an action set are automatically destroyed when the action set’s handle is destroyed.
The implementation must not destroy the underlying resources for an action when xrDestroyAction is called. Those resources are still used to make action spaces locatable and when processing action priority in xrSyncActions. Destroying the action handle removes the application’s access to these resources, but has no other change on actions.
Resources for all actions in an instance must be freed when the instance containing those actions sets is destroyed.
See Also
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrDestroyActionSet(3)
Name
xrDestroyActionSet - Destroys an XrActionSet
C Specification
The xrDestroyActionSet function is defined as:
// Provided by XR_VERSION_1_0
XrResult xrDestroyActionSet(
XrActionSet actionSet);
Parameters
Description
Action set handles can be destroyed by calling xrDestroyActionSet. When an action set handle is destroyed, all handles of actions in that action set are also destroyed.
The implementation must not free underlying resources for the action set while there are other valid handles that refer to those resources. The implementation may release resources for an action set when all of the action spaces for actions in that action set have been destroyed. See Action Spaces Lifetime for details.
Resources for all action sets in an instance must be freed when the instance containing those actions sets is destroyed.
See Also
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrDestroyDebugUtilsMessengerEXT(3)
Name
xrDestroyDebugUtilsMessengerEXT - Destroys a debug messenger
C Specification
// Provided by XR_EXT_debug_utils
XrResult xrDestroyDebugUtilsMessengerEXT(
XrDebugUtilsMessengerEXT messenger);
Parameters
Description
The application must ensure that xrDestroyDebugUtilsMessengerEXT is
not executed in parallel with any OpenXR function that is also called with
the instance
or child of instance
that it was created with.
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrDestroyFacialTrackerHTC(3)
Name
xrDestroyFacialTrackerHTC - Destroy a facial tracker handle
C Specification
The xrDestroyFacialTrackerHTC function is defined as:
// Provided by XR_HTC_facial_tracking
XrResult xrDestroyFacialTrackerHTC(
XrFacialTrackerHTC facialTracker);
Parameters
Description
xrDestroyFacialTrackerHTC releases the facialTracker
and the
underlying resources when finished with facial tracking experiences.
See Also
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrDestroyFoveationProfileFB(3)
Name
xrDestroyFoveationProfileFB - Destroy a foveation profile
C Specification
The xrDestroyFoveationProfileFB function is defined as:
// Provided by XR_FB_foveation
XrResult xrDestroyFoveationProfileFB(
XrFoveationProfileFB profile);
Parameters
Description
XrFoveationProfileFB handles are destroyed using xrDestroyFoveationProfileFB. A XrFoveationProfileFB may be safely destroyed after being applied to a swapchain state using xrUpdateSwapchainFB without affecting the foveation parameters of the swapchain. The application is responsible for ensuring that it has no calls using profile in progress when the foveation profile is destroyed.
See Also
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrDestroyGeometryInstanceFB(3)
Name
xrDestroyGeometryInstanceFB - Destroy a geometry instance
C Specification
The xrDestroyGeometryInstanceFB function is defined as:
// Provided by XR_FB_passthrough
XrResult xrDestroyGeometryInstanceFB(
XrGeometryInstanceFB instance);
Parameters
Description
Destroys an XrGeometryInstanceFB handle. Destroying an XrGeometryInstanceFB does not destroy a mesh and does not free mesh resources. Destroying a layer invalidates all geometry instances attached to it. Destroying a mesh invalidates all its instances.
See Also
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrDestroyHandTrackerEXT(3)
Name
xrDestroyHandTrackerEXT - Destroy a hand joints handle
C Specification
xrDestroyHandTrackerEXT function releases the handTracker
and
the underlying resources when finished with hand tracking experiences.
// Provided by XR_EXT_hand_tracking
XrResult xrDestroyHandTrackerEXT(
XrHandTrackerEXT handTracker);
Parameters
Description
See Also
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrDestroyInstance(3)
Name
xrDestroyInstance - Destroy an instance of OpenXR
C Specification
The xrDestroyInstance function is defined as:
// Provided by XR_VERSION_1_0
XrResult xrDestroyInstance(
XrInstance instance);
Parameters
The xrDestroyInstance function is used to destroy an XrInstance.
Description
XrInstance handles are destroyed using xrDestroyInstance. When an XrInstance is destroyed, all handles that are children of that XrInstance are also destroyed.
See Also
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrDestroyPassthroughFB(3)
Name
xrDestroyPassthroughFB - Destroy a passthrough feature
C Specification
The xrDestroyPassthroughFB function is defined as:
// Provided by XR_FB_passthrough
XrResult xrDestroyPassthroughFB(
XrPassthroughFB passthrough);
Parameters
Description
Destroys an XrPassthroughFB handle.
See Also
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrDestroyPassthroughHTC(3)
Name
xrDestroyPassthroughHTC - Destroy a passthrough handle
C Specification
The xrDestroyPassthroughHTC function is defined as:
// Provided by XR_HTC_passthrough
XrResult xrDestroyPassthroughHTC(
XrPassthroughHTC passthrough);
Parameters
Description
The xrDestroyPassthroughHTC function releases the passthrough and the underlying resources.
See Also
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrDestroyPassthroughLayerFB(3)
Name
xrDestroyPassthroughLayerFB - Destroy a passthrough layer
C Specification
The xrDestroyPassthroughLayerFB function is defined as:
// Provided by XR_FB_passthrough
XrResult xrDestroyPassthroughLayerFB(
XrPassthroughLayerFB layer);
Parameters
Description
Destroys an XrPassthroughLayerFB handle.
See Also
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrDestroySceneMSFT(3)
Name
xrDestroySceneMSFT - Destroy a scene handle
C Specification
The xrDestroySceneMSFT function releases the scene
and the
underlying resources.
// Provided by XR_MSFT_scene_understanding
XrResult xrDestroySceneMSFT(
XrSceneMSFT scene);
Parameters
Description
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrDestroySceneObserverMSFT(3)
Name
xrDestroySceneObserverMSFT - Destroy a scene observer handle
C Specification
The xrDestroySceneObserverMSFT function releases the
sceneObserver
and the underlying resources.
// Provided by XR_MSFT_scene_understanding
XrResult xrDestroySceneObserverMSFT(
XrSceneObserverMSFT sceneObserver);
Parameters
Description
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrDestroySession(3)
Name
xrDestroySession - Destroys an XrSession
C Specification
The xrDestroySession function is defined as.
// Provided by XR_VERSION_1_0
XrResult xrDestroySession(
XrSession session);
Parameters
Description
XrSession handles are destroyed using xrDestroySession. When an XrSession is destroyed, all handles that are children of that XrSession are also destroyed.
The application is responsible for ensuring that it has no calls using
session
in progress when the session is destroyed.
xrDestroySession can be called when the session is in any session state.
See Also
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrDestroySpace(3)
Name
xrDestroySpace - Creates a space based on a pose action
C Specification
The xrDestroySpace function is defined as:
// Provided by XR_VERSION_1_0
XrResult xrDestroySpace(
XrSpace space);
Parameters
Description
XrSpace handles are destroyed using xrDestroySpace. The runtime may still use this space if there are active dependencies (e.g, compositions in progress).
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrDestroySpatialAnchorMSFT(3)
Name
xrDestroySpatialAnchorMSFT - Destroys a spatial anchor
C Specification
The xrDestroySpatialAnchorMSFT function is defined as:
// Provided by XR_MSFT_spatial_anchor
XrResult xrDestroySpatialAnchorMSFT(
XrSpatialAnchorMSFT anchor);
Parameters
Description
XrSpatialAnchorMSFT handles are destroyed using xrDestroySpatialAnchorMSFT. By destroying an anchor, the runtime can stop spending resources used to maintain tracking for that anchor’s origin.
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrDestroySpatialAnchorStoreConnectionMSFT(3)
Name
xrDestroySpatialAnchorStoreConnectionMSFT - Destroys the anchor store handle
C Specification
The application can use the xrDestroySpatialAnchorStoreConnectionMSFT function to destroy an anchor store connection.
// Provided by XR_MSFT_spatial_anchor_persistence
XrResult xrDestroySpatialAnchorStoreConnectionMSFT(
XrSpatialAnchorStoreConnectionMSFT spatialAnchorStore);
Parameters
Description
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrDestroySpatialGraphNodeBindingMSFT(3)
Name
xrDestroySpatialGraphNodeBindingMSFT - Destroy a spatial graph node handle
C Specification
The xrDestroySpatialGraphNodeBindingMSFT function releases the
nodeBinding
and the underlying resources.
// Provided by XR_MSFT_spatial_graph_bridge
XrResult xrDestroySpatialGraphNodeBindingMSFT(
XrSpatialGraphNodeBindingMSFT nodeBinding);
Parameters
Description
See Also
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrDestroySwapchain(3)
Name
xrDestroySwapchain - Destroys an XrSwapchain
C Specification
The xrDestroySwapchain function is defined as:
// Provided by XR_VERSION_1_0
XrResult xrDestroySwapchain(
XrSwapchain swapchain);
Parameters
Description
All submitted graphics API commands that refer to swapchain
must have
completed execution.
Runtimes may continue to utilize swapchain images after
xrDestroySwapchain is called.
See Also
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrDestroyTriangleMeshFB(3)
Name
xrDestroyTriangleMeshFB - Destroy a triangle mesh
C Specification
The xrDestroyTriangleMeshFB function is defined as:
// Provided by XR_FB_triangle_mesh
XrResult xrDestroyTriangleMeshFB(
XrTriangleMeshFB mesh);
Parameters
Description
XrTriangleMeshFB handles and their associated data are destroyed by xrDestroyTriangleMeshFB. The mesh buffers retrieved by xrTriangleMeshGetVertexBufferFB and xrTriangleMeshGetIndexBufferFB must not be accessed anymore after their parent mesh object has been destroyed.
See Also
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrEndFrame(3)
Name
xrEndFrame - Marks a frame
C Specification
The xrEndFrame function is defined as:
// Provided by XR_VERSION_1_0
XrResult xrEndFrame(
XrSession session,
const XrFrameEndInfo* frameEndInfo);
Parameters
Description
xrEndFrame may return immediately to the application.
XrFrameEndInfo::displayTime
should be computed using values
returned by xrWaitFrame.
The runtime should be robust against variations in the timing of calls to
xrWaitFrame, since a pipelined system may call xrWaitFrame on a
separate thread from xrBeginFrame and xrEndFrame without any
synchronization guarantees.
Note
An accurate predicted display time is very important to avoid black pull-in by reprojection and to reduce motion judder in case the runtime does not implement a translational reprojection. Reprojection should never display images before the display refresh period they were predicted for, even if they are completed early, because this will cause motion judder just the same. In other words, the better the predicted display time, the less latency experienced by the user. |
Every call to xrEndFrame must be preceded by a successful call to
xrBeginFrame.
Failure to do so must result in XR_ERROR_CALL_ORDER_INVALID
being
returned by xrEndFrame.
XrFrameEndInfo may reference swapchains into which the application
has rendered for this frame.
From each XrSwapchain only one image index is implicitly referenced
per frame, the one corresponding to the last call to
xrReleaseSwapchainImage.
However, a specific swapchain (and by extension a specific swapchain image
index) may be referenced in XrFrameEndInfo multiple times.
This can be used for example to render a side by side image into a single
swapchain image and referencing it twice with differing image rectangles in
different layers.
If no layers are provided then the display must be cleared.
XR_ERROR_LAYER_INVALID
must be returned if an unknown, unsupported
layer type, or NULL
pointer is passed as one of the
XrFrameEndInfo::layers.
XR_ERROR_LAYER_INVALID
must be returned if a layer references a
swapchain that has no released swapchain image.
XR_ERROR_LAYER_LIMIT_EXCEEDED
must be returned if
XrFrameEndInfo::layerCount exceeds
XrSystemGraphicsProperties::maxLayerCount or if the runtime is unable
to composite the specified layers due to resource constraints.
XR_ERROR_SWAPCHAIN_RECT_INVALID
must be returned if
XrFrameEndInfo::layers contains a composition layer which references
pixels outside of the associated swapchain image or if negatively sized.
XR_ERROR_ENVIRONMENT_BLEND_MODE_UNSUPPORTED
must be returned if
XrFrameEndInfo::environmentBlendMode is not supported.
XR_ERROR_SESSION_NOT_RUNNING
must be returned if the session
is not running.
Note
Applications should discard frames for which xrEndFrame returns a recoverable error over attempting to resubmit the frame with different frame parameters to provide a more consistent experience across different runtime implementations. |
See Also
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrEndSession(3)
Name
xrEndSession - Ends an XrSession
C Specification
The xrEndSession function is defined as:
// Provided by XR_VERSION_1_0
XrResult xrEndSession(
XrSession session);
Parameters
Description
When the application receives XrEventDataSessionStateChanged event
with the XR_SESSION_STATE_STOPPING
state, the application should stop
its frame loop and then call xrEndSession to end the
running session.
This function signals to the runtime that the application will no longer
call xrWaitFrame, xrBeginFrame or xrEndFrame from any
thread allowing the runtime to safely transition the session to
XR_SESSION_STATE_IDLE
.
The application must also avoid reading input state or sending haptic
output after calling xrEndSession.
If the session is not running when the application
calls xrEndSession, the runtime must return error
XR_ERROR_SESSION_NOT_RUNNING
.
If the session is still running when the application
calls xrEndSession, but the session is not yet in the
XR_SESSION_STATE_STOPPING
state, the runtime must return error
XR_ERROR_SESSION_NOT_STOPPING
.
If the application wishes to exit a running session, the application can
call xrRequestExitSession so that the session transitions from
XR_SESSION_STATE_IDLE
to XR_SESSION_STATE_EXITING
.
See Also
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrEnumerateApiLayerProperties(3)
Name
xrEnumerateApiLayerProperties - Returns up to requested number of global layer properties
C Specification
To determine what set of API layers are available, OpenXR provides the xrEnumerateApiLayerProperties function:
// Provided by XR_VERSION_1_0
XrResult xrEnumerateApiLayerProperties(
uint32_t propertyCapacityInput,
uint32_t* propertyCountOutput,
XrApiLayerProperties* properties);
Parameters
Description
The list of available layers may change at any time due to actions outside
of the OpenXR runtime, so two calls to xrEnumerateApiLayerProperties
with the same parameters may return different results, or retrieve
different propertyCountOutput
values or properties
contents.
Once an instance has been created, the layers enabled for that instance will continue to be enabled and valid for the lifetime of that instance, even if some of them become unavailable for future instances.
See Also
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrEnumerateBoundSourcesForAction(3)
Name
xrEnumerateBoundSourcesForAction - Queries the bound input sources for an action
C Specification
The xrEnumerateBoundSourcesForAction function is defined as:
// Provided by XR_VERSION_1_0
XrResult xrEnumerateBoundSourcesForAction(
XrSession session,
const XrBoundSourcesForActionEnumerateInfo* enumerateInfo,
uint32_t sourceCapacityInput,
uint32_t* sourceCountOutput,
XrPath* sources);
Parameters
Description
If an action is unbound, xrEnumerateBoundSourcesForAction must assign
0
to the value pointed-to by sourceCountOutput
and not modify the
array.
xrEnumerateBoundSourcesForAction must return
XR_ERROR_ACTIONSET_NOT_ATTACHED
if passed an action in an action set
never attached to the session with xrAttachSessionActionSets.
As bindings for actions do not change between calls to xrSyncActions,
xrEnumerateBoundSourcesForAction must enumerate the same set of bound
sources, or absence of bound sources, for a given query (defined by the
enumerateInfo
parameter) between any two calls to xrSyncActions.
Note
The |
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrEnumerateColorSpacesFB(3)
Name
xrEnumerateColorSpacesFB - Enumerates color spaces
C Specification
The xrEnumerateColorSpacesFB function is defined as:
// Provided by XR_FB_color_space
XrResult xrEnumerateColorSpacesFB(
XrSession session,
uint32_t colorSpaceCapacityInput,
uint32_t* colorSpaceCountOutput,
XrColorSpaceFB* colorSpaces);
Parameters
Description
xrEnumerateColorSpacesFB enumerates the color spaces supported by the current session. Runtimes must always return identical buffer contents from this enumeration for the lifetime of the session.
See Also
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrEnumerateDisplayRefreshRatesFB(3)
Name
xrEnumerateDisplayRefreshRatesFB - Enumerates display refresh rates
C Specification
The xrEnumerateDisplayRefreshRatesFB function is defined as:
// Provided by XR_FB_display_refresh_rate
XrResult xrEnumerateDisplayRefreshRatesFB(
XrSession session,
uint32_t displayRefreshRateCapacityInput,
uint32_t* displayRefreshRateCountOutput,
float* displayRefreshRates);
Parameters
Description
xrEnumerateDisplayRefreshRatesFB enumerates the display refresh rates supported by the current session. Display refresh rates must be in order from lowest to highest supported display refresh rates. Runtimes must always return identical buffer contents from this enumeration for the lifetime of the session.
See Also
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrEnumerateEnvironmentBlendModes(3)
Name
xrEnumerateEnvironmentBlendModes - Lists environment blend modes
C Specification
The xrEnumerateEnvironmentBlendModes function is defined as:
// Provided by XR_VERSION_1_0
XrResult xrEnumerateEnvironmentBlendModes(
XrInstance instance,
XrSystemId systemId,
XrViewConfigurationType viewConfigurationType,
uint32_t environmentBlendModeCapacityInput,
uint32_t* environmentBlendModeCountOutput,
XrEnvironmentBlendMode* environmentBlendModes);
Parameters
Description
Enumerates the set of environment blend modes that this runtime supports for a given view configuration of the system. Environment blend modes should be in order from highest to lowest runtime preference.
Runtimes must always return identical buffer contents from this enumeration
for the given systemId
and viewConfigurationType
for the
lifetime of the instance.
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrEnumerateInstanceExtensionProperties(3)
Name
xrEnumerateInstanceExtensionProperties - Returns properties of available instance extensions
C Specification
The application can determine the available instance extensions by calling xrEnumerateInstanceExtensionProperties:
// Provided by XR_VERSION_1_0
XrResult xrEnumerateInstanceExtensionProperties(
const char* layerName,
uint32_t propertyCapacityInput,
uint32_t* propertyCountOutput,
XrExtensionProperties* properties);
Parameters
Description
Because the list of available layers may change externally between calls to
xrEnumerateInstanceExtensionProperties, two calls may retrieve
different results if a layerName
is available in one call but not in
another.
The extensions supported by a layer may also change between two calls, e.g.
if the layer implementation is replaced by a different version between those
calls.
See Also
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrEnumeratePerformanceMetricsCounterPathsMETA(3)
Name
xrEnumeratePerformanceMetricsCounterPathsMETA - Enumerate all performance metrics counter paths that supported by the runtime
C Specification
The xrEnumeratePerformanceMetricsCounterPathsMETA function enumerates all performance metrics counter paths that supported by the runtime, it is defined as:
// Provided by XR_META_performance_metrics
XrResult xrEnumeratePerformanceMetricsCounterPathsMETA(
XrInstance instance,
uint32_t counterPathCapacityInput,
uint32_t* counterPathCountOutput,
XrPath* counterPaths);
Parameters
Description
See Also
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrEnumeratePersistedSpatialAnchorNamesMSFT(3)
Name
xrEnumeratePersistedSpatialAnchorNamesMSFT - Enumerate the names of currently persisted spatial anchors in the spatial anchor store
C Specification
The application can use the
xrEnumeratePersistedSpatialAnchorNamesMSFT function to enumerate the
names of all spatial anchors currently persisted in the spatial anchor store
for this application.
This function follows the two-call idiom for
filling the spatialAnchorNames
.
// Provided by XR_MSFT_spatial_anchor_persistence
XrResult xrEnumeratePersistedSpatialAnchorNamesMSFT(
XrSpatialAnchorStoreConnectionMSFT spatialAnchorStore,
uint32_t spatialAnchorNamesCapacityInput,
uint32_t* spatialAnchorNamesCountOutput,
XrSpatialAnchorPersistenceNameMSFT* persistedAnchorNames);
Parameters
Description
See Also
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrEnumerateReferenceSpaces(3)
Name
xrEnumerateReferenceSpaces - Enumerate available reference spaces
C Specification
The xrEnumerateReferenceSpaces function is defined as:
// Provided by XR_VERSION_1_0
XrResult xrEnumerateReferenceSpaces(
XrSession session,
uint32_t spaceCapacityInput,
uint32_t* spaceCountOutput,
XrReferenceSpaceType* spaces);
Parameters
Description
Enumerates the set of reference space types that this runtime supports for a given session. Runtimes must always return identical buffer contents from this enumeration for the lifetime of the session.
If a session enumerates support for a given reference space type, calls to xrCreateReferenceSpace must succeed for that session, with any transient unavailability of poses expressed later during calls to xrLocateSpace.
See Also
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrEnumerateRenderModelPathsFB(3)
Name
xrEnumerateRenderModelPathsFB - Enumerate supported render model paths
C Specification
The xrEnumerateRenderModelPathsFB function is defined as:
// Provided by XR_FB_render_model
XrResult xrEnumerateRenderModelPathsFB(
XrSession session,
uint32_t pathCapacityInput,
uint32_t* pathCountOutput,
XrRenderModelPathInfoFB* paths);
Parameters
Description
The application must call xrEnumerateRenderModelPathsFB to enumerate the valid render model paths that are supported by the runtime before calling xrGetRenderModelPropertiesFB. The paths returned may be used later in xrGetRenderModelPropertiesFB.
See Also
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrEnumerateReprojectionModesMSFT(3)
Name
xrEnumerateReprojectionModesMSFT - Queries the supported reprojection modes.
C Specification
First, the application uses xrEnumerateReprojectionModesMSFT to inspect what reprojection mode the view configuration supports.
The xrEnumerateReprojectionModesMSFT function returns the supported reprojection modes of the view configuration.
// Provided by XR_MSFT_composition_layer_reprojection
XrResult xrEnumerateReprojectionModesMSFT(
XrInstance instance,
XrSystemId systemId,
XrViewConfigurationType viewConfigurationType,
uint32_t modeCapacityInput,
uint32_t* modeCountOutput,
XrReprojectionModeMSFT* modes);
Parameters
Description
A system may support different sets of reprojection modes for different view configuration types.
See Also
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrEnumerateSceneComputeFeaturesMSFT(3)
Name
xrEnumerateSceneComputeFeaturesMSFT - Enumerates scene compute features
C Specification
The xrEnumerateSceneComputeFeaturesMSFT function enumerates the supported scene compute features of the given system.
This function follows the two-call idiom for
filling the features
array.
// Provided by XR_MSFT_scene_understanding
XrResult xrEnumerateSceneComputeFeaturesMSFT(
XrInstance instance,
XrSystemId systemId,
uint32_t featureCapacityInput,
uint32_t* featureCountOutput,
XrSceneComputeFeatureMSFT* features);
Parameters
Description
See Also
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrEnumerateSpaceSupportedComponentsFB(3)
Name
xrEnumerateSpaceSupportedComponentsFB - Enumerates supported components for a given spatial entity
C Specification
The xrEnumerateSpaceSupportedComponentsFB function is defined as:
// Provided by XR_FB_spatial_entity
XrResult xrEnumerateSpaceSupportedComponentsFB(
XrSpace space,
uint32_t componentTypeCapacityInput,
uint32_t* componentTypeCountOutput,
XrSpaceComponentTypeFB* componentTypes);
Parameters
Description
Lists any component types that an entity supports. The list of component types available for an entity depends on which extensions are enabled. Component types must not be enumerated unless the corresponding extension that defines them is also enabled.
See Also
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrEnumerateSwapchainFormats(3)
Name
xrEnumerateSwapchainFormats - Enumerates swapchain formats
C Specification
The xrEnumerateSwapchainFormats function is defined as:
// Provided by XR_VERSION_1_0
XrResult xrEnumerateSwapchainFormats(
XrSession session,
uint32_t formatCapacityInput,
uint32_t* formatCountOutput,
int64_t* formats);
Parameters
Description
xrEnumerateSwapchainFormats enumerates the texture formats supported
by the current session.
The type of formats returned are dependent on the graphics API specified in
xrCreateSession.
For example, if a DirectX graphics API was specified, then the enumerated
formats correspond to the DXGI formats, such as
DXGI_FORMAT_R8G8B8A8_UNORM_SRGB
.
Texture formats should be in order from highest to lowest runtime
preference.
The application should use the highest preference format that it supports
for optimal performance and quality.
With an OpenGL-based graphics API, the texture formats correspond to OpenGL internal formats.
With a Direct3D-based graphics API, xrEnumerateSwapchainFormats never
returns typeless formats (e.g. DXGI_FORMAT_R8G8B8A8_TYPELESS
).
Only concrete formats are returned, and only concrete formats may be
specified by applications for swapchain creation.
Runtimes must always return identical buffer contents from this enumeration for the lifetime of the session.
See Also
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrEnumerateSwapchainImages(3)
Name
xrEnumerateSwapchainImages - Gets images from an XrSwapchain
C Specification
The xrEnumerateSwapchainImages function is defined as:
// Provided by XR_VERSION_1_0
XrResult xrEnumerateSwapchainImages(
XrSwapchain swapchain,
uint32_t imageCapacityInput,
uint32_t* imageCountOutput,
XrSwapchainImageBaseHeader* images);
Parameters
Description
Fills an array of graphics API-specific XrSwapchainImage
structures.
The resources must be constant and valid for the lifetime of the
XrSwapchain.
Runtimes must always return identical buffer contents from this enumeration for the lifetime of the swapchain.
Note: images
is a pointer to an array of structures of graphics
API-specific type, not an array of structure pointers.
The pointer submitted as images
will be treated as an array of the
expected graphics API-specific type based on the graphics API used at
session creation time.
If the type
member of any array element accessed in this way does not
match the expected value, the runtime must return
XR_ERROR_VALIDATION_FAILURE
.
Note
Under a typical memory model, a runtime must treat the supplied pointer as
an opaque blob beginning with XrSwapchainImageBaseHeader, until after
it has verified the |
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrEnumerateViewConfigurationViews(3)
Name
xrEnumerateViewConfigurationViews - Gets view configuration views
C Specification
The xrEnumerateViewConfigurationViews function is defined as:
// Provided by XR_VERSION_1_0
XrResult xrEnumerateViewConfigurationViews(
XrInstance instance,
XrSystemId systemId,
XrViewConfigurationType viewConfigurationType,
uint32_t viewCapacityInput,
uint32_t* viewCountOutput,
XrViewConfigurationView* views);
Parameters
Description
Each XrViewConfigurationType defines the number of views associated
with it.
Applications can query more details of each view element using
xrEnumerateViewConfigurationViews.
If the supplied viewConfigurationType
is not supported by this
XrInstance and XrSystemId
, the runtime must return
XR_ERROR_VIEW_CONFIGURATION_TYPE_UNSUPPORTED
.
Runtimes must always return identical buffer contents from this enumeration
for the given systemId
and viewConfigurationType
for the
lifetime of the instance.
See Also
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrEnumerateViewConfigurations(3)
Name
xrEnumerateViewConfigurations - Enumerates supported view configurations
C Specification
The xrEnumerateViewConfigurations function is defined as:
// Provided by XR_VERSION_1_0
XrResult xrEnumerateViewConfigurations(
XrInstance instance,
XrSystemId systemId,
uint32_t viewConfigurationTypeCapacityInput,
uint32_t* viewConfigurationTypeCountOutput,
XrViewConfigurationType* viewConfigurationTypes);
Parameters
Description
xrEnumerateViewConfigurations enumerates the view configuration types
supported by the XrSystemId
.
The supported set for that system must not change during the lifetime of
its XrInstance.
The returned list of primary view configurations should be in order from
what the runtime considered highest to lowest user preference.
Thus the first enumerated view configuration type should be the one the
runtime prefers the application to use if possible.
Runtimes must always return identical buffer contents from this enumeration
for the given systemId
and for the lifetime of the instance.
See Also
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrEnumerateViveTrackerPathsHTCX(3)
Name
xrEnumerateViveTrackerPathsHTCX - Enumerates all connected VIVE trackers
C Specification
The xrEnumerateViveTrackerPathsHTCX function is defined as:
// Provided by XR_HTCX_vive_tracker_interaction
XrResult xrEnumerateViveTrackerPathsHTCX(
XrInstance instance,
uint32_t pathCapacityInput,
uint32_t* pathCountOutput,
XrViveTrackerPathsHTCX* paths);
Parameters
Description
xrEnumerateViveTrackerPathsHTCX enumerates all connected VIVE trackers to retrieve their paths under current instance.
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrEraseSpaceFB(3)
Name
xrEraseSpaceFB - Erases a spatial entity from persistent storage
C Specification
The xrEraseSpaceFB function is defined as:
// Provided by XR_FB_spatial_entity_storage
XrResult xrEraseSpaceFB(
XrSession session,
const XrSpaceEraseInfoFB* info,
XrAsyncRequestIdFB* requestId);
Parameters
Description
The xrEraseSpaceFB function erases a spatial entity from storage at
the specified location.
The XrSpace remains valid in the current session until the application
destroys it or the session ends.
The runtime must return XR_ERROR_VALIDATION_FAILURE
if
XrSpaceEraseInfoFB::space
is XR_NULL_HANDLE or otherwise
invalid.
The runtime must return XR_ERROR_VALIDATION_FAILURE
if
XrSpaceEraseInfoFB::location
is invalid.
This operation is asynchronous and the runtime must post an
XrEventDataSpaceEraseCompleteFB event when the operation completes
successfully or encounters an error.
See Also
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrGeometryInstanceSetTransformFB(3)
Name
xrGeometryInstanceSetTransformFB - Create a triangle mesh
C Specification
The xrGeometryInstanceSetTransformFB function is defined as:
// Provided by XR_FB_passthrough
XrResult xrGeometryInstanceSetTransformFB(
XrGeometryInstanceFB instance,
const XrGeometryInstanceTransformFB* transformation);
Parameters
Description
Sets an XrGeometryInstanceTransformFB transform on an XrGeometryInstanceFB geometry instance.
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrGetActionStateBoolean(3)
Name
xrGetActionStateBoolean - Gets boolean action state
C Specification
xrGetActionStateBoolean retrieves the current state of a boolean action. It is defined as:
// Provided by XR_VERSION_1_0
XrResult xrGetActionStateBoolean(
XrSession session,
const XrActionStateGetInfo* getInfo,
XrActionStateBoolean* state);
Parameters
Description
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrGetActionStateFloat(3)
Name
xrGetActionStateFloat - Gets a floating point action state
C Specification
xrGetActionStateFloat retrieves the current state of a floating-point action. It is defined as:
// Provided by XR_VERSION_1_0
XrResult xrGetActionStateFloat(
XrSession session,
const XrActionStateGetInfo* getInfo,
XrActionStateFloat* state);
Parameters
Description
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrGetActionStatePose(3)
Name
xrGetActionStatePose - Gets metadata from a pose action
C Specification
The xrGetActionStatePose function is defined as:
// Provided by XR_VERSION_1_0
XrResult xrGetActionStatePose(
XrSession session,
const XrActionStateGetInfo* getInfo,
XrActionStatePose* state);
Parameters
Description
xrGetActionStatePose returns information about the binding and active state for the specified action. To determine the pose of this action at a historical or predicted time, the application can create an action space using xrCreateActionSpace. Then, after each sync, the application can locate the pose of this action space within a base space using xrLocateSpace.
See Also
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrGetActionStateVector2f(3)
Name
xrGetActionStateVector2f - Gets 2D float vector action state
C Specification
xrGetActionStateVector2f retrieves the current state of a two-dimensional vector action. It is defined as:
// Provided by XR_VERSION_1_0
XrResult xrGetActionStateVector2f(
XrSession session,
const XrActionStateGetInfo* getInfo,
XrActionStateVector2f* state);
Parameters
Description
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrGetAudioInputDeviceGuidOculus(3)
Name
xrGetAudioInputDeviceGuidOculus - Query the GUID for the active audio input device
C Specification
// Provided by XR_OCULUS_audio_device_guid
XrResult xrGetAudioInputDeviceGuidOculus(
XrInstance instance,
wchar_t buffer[XR_MAX_AUDIO_DEVICE_STR_SIZE_OCULUS]);
Parameters
Description
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrGetAudioOutputDeviceGuidOculus(3)
Name
xrGetAudioOutputDeviceGuidOculus - Query the GUID for the active audio output device
C Specification
// Provided by XR_OCULUS_audio_device_guid
XrResult xrGetAudioOutputDeviceGuidOculus(
XrInstance instance,
wchar_t buffer[XR_MAX_AUDIO_DEVICE_STR_SIZE_OCULUS]);
Parameters
Description
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrGetControllerModelKeyMSFT(3)
Name
xrGetControllerModelKeyMSFT - Retrieve the model key for the controller
C Specification
xrGetControllerModelKeyMSFT retrieves the
XrControllerModelKeyMSFT
for a controller.
This model key may later be used to retrieve the model data.
The xrGetControllerModelKeyMSFT function is defined as:
// Provided by XR_MSFT_controller_model
XrResult xrGetControllerModelKeyMSFT(
XrSession session,
XrPath topLevelUserPath,
XrControllerModelKeyStateMSFT* controllerModelKeyState);
Parameters
Description
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrGetControllerModelPropertiesMSFT(3)
Name
xrGetControllerModelPropertiesMSFT - Get controller model properties
C Specification
The xrGetControllerModelPropertiesMSFT function returns the controller
model properties for a given modelKey
.
// Provided by XR_MSFT_controller_model
XrResult xrGetControllerModelPropertiesMSFT(
XrSession session,
XrControllerModelKeyMSFT modelKey,
XrControllerModelPropertiesMSFT* properties);
Parameters
Description
The runtime must return the same data in
XrControllerModelPropertiesMSFT for a valid modelKey
.
Therefore, the application can cache the returned
XrControllerModelPropertiesMSFT using modelKey
and reuse the
data for each frame.
If the input modelKey
is invalid, i.e. it is
XR_NULL_CONTROLLER_MODEL_KEY_MSFT or not a key returned from
XrControllerModelKeyStateMSFT, the runtime must return
XR_ERROR_CONTROLLER_MODEL_KEY_INVALID_MSFT
.
See Also
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrGetControllerModelStateMSFT(3)
Name
xrGetControllerModelStateMSFT - Get controller model state
C Specification
The xrGetControllerModelStateMSFT function returns the current state of the controller model representing user’s interaction to the controller, such as pressing a button or pulling a trigger.
// Provided by XR_MSFT_controller_model
XrResult xrGetControllerModelStateMSFT(
XrSession session,
XrControllerModelKeyMSFT modelKey,
XrControllerModelStateMSFT* state);
Parameters
Description
The runtime may return different state for a model key after each call to xrSyncActions, which represents the latest state of the user interactions.
If the input modelKey
is invalid, i.e. it is
XR_NULL_CONTROLLER_MODEL_KEY_MSFT or not a key returned from
XrControllerModelKeyStateMSFT, the runtime must return
XR_ERROR_CONTROLLER_MODEL_KEY_INVALID_MSFT
.
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrGetCurrentInteractionProfile(3)
Name
xrGetCurrentInteractionProfile - Gets the current interaction profile for a top level user paths
C Specification
The xrGetCurrentInteractionProfile function is defined as:
// Provided by XR_VERSION_1_0
XrResult xrGetCurrentInteractionProfile(
XrSession session,
XrPath topLevelUserPath,
XrInteractionProfileState* interactionProfile);
Parameters
Description
xrGetCurrentInteractionProfile asks the runtime for the active interaction profiles for a top level user path.
The runtime must return only interaction profiles for which the application has provided bindings with xrSuggestInteractionProfileBindings or XR_NULL_PATH. The runtime may return interaction profiles that do not represent physically present hardware, for example if the runtime is using a known interaction profile to bind to hardware that the application is not aware of. The runtime may return the last-known interaction profile in the event that no controllers are active.
If xrAttachSessionActionSets has not yet been called for the
session
, the runtime must return
XR_ERROR_ACTIONSET_NOT_ATTACHED
.
If topLevelUserPath
is not one of the device input subpaths described
in section /user paths, the runtime must return
XR_ERROR_PATH_UNSUPPORTED
.
See Also
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrGetD3D11GraphicsRequirementsKHR(3)
Name
xrGetD3D11GraphicsRequirementsKHR - Retrieve the D3D11 feature level and graphics device requirements for an instance and system
C Specification
To retrieve the D3D11 feature level and graphics device for an instance and system, call:
// Provided by XR_KHR_D3D11_enable
XrResult xrGetD3D11GraphicsRequirementsKHR(
XrInstance instance,
XrSystemId systemId,
XrGraphicsRequirementsD3D11KHR* graphicsRequirements);
Parameters
Description
The xrGetD3D11GraphicsRequirementsKHR function identifies to the
application what graphics device (Windows LUID) needs to be used and the
minimum feature level to use.
The runtime must return XR_ERROR_GRAPHICS_REQUIREMENTS_CALL_MISSING
(XR_ERROR_VALIDATION_FAILURE
may be returned due to legacy behavior)
on calls to xrCreateSession if xrGetD3D11GraphicsRequirementsKHR
has not been called for the same instance
and systemId
.
The LUID and feature level that xrGetD3D11GraphicsRequirementsKHR
returns must be used to create the ID3D11Device
that the application
passes to xrCreateSession in the XrGraphicsBindingD3D11KHR.
See Also
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrGetD3D12GraphicsRequirementsKHR(3)
Name
xrGetD3D12GraphicsRequirementsKHR - Retrieve the D3D12 feature level and graphics device requirements for an instance and system
C Specification
To retrieve the D3D12 feature level and graphics device for an instance and system, call:
// Provided by XR_KHR_D3D12_enable
XrResult xrGetD3D12GraphicsRequirementsKHR(
XrInstance instance,
XrSystemId systemId,
XrGraphicsRequirementsD3D12KHR* graphicsRequirements);
Parameters
Description
The xrGetD3D12GraphicsRequirementsKHR function identifies to the
application what graphics device (Windows LUID) needs to be used and the
minimum feature level to use.
The runtime must return XR_ERROR_GRAPHICS_REQUIREMENTS_CALL_MISSING
(XR_ERROR_VALIDATION_FAILURE
may be returned due to legacy behavior)
on calls to xrCreateSession if xrGetD3D12GraphicsRequirementsKHR
has not been called for the same instance
and systemId
.
The LUID and feature level that xrGetD3D12GraphicsRequirementsKHR
returns must be used to create the ID3D12Device
that the application
passes to xrCreateSession in the XrGraphicsBindingD3D12KHR.
See Also
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrGetDisplayRefreshRateFB(3)
Name
xrGetDisplayRefreshRateFB - Get the current display refresh rate
C Specification
The xrGetDisplayRefreshRateFB function is defined as:
// Provided by XR_FB_display_refresh_rate
XrResult xrGetDisplayRefreshRateFB(
XrSession session,
float* displayRefreshRate);
Parameters
Description
xrGetDisplayRefreshRateFB retrieves the current display refresh rate.
See Also
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrGetFacialExpressionsHTC(3)
Name
xrGetFacialExpressionsHTC - Retrieve facial expressions
C Specification
The xrGetFacialExpressionsHTC function is defined as:
// Provided by XR_HTC_facial_tracking
XrResult xrGetFacialExpressionsHTC(
XrFacialTrackerHTC facialTracker,
XrFacialExpressionsHTC* facialExpressions);
Parameters
Description
xrGetFacialExpressionsHTC retrieves an array of values of blend shapes for a facial expression on a given time.
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrGetHandMeshFB(3)
Name
xrGetHandMeshFB - Create a foveation profile
C Specification
The xrGetHandMeshFB function is defined as:
// Provided by XR_FB_hand_tracking_mesh
XrResult xrGetHandMeshFB(
XrHandTrackerEXT handTracker,
XrHandTrackingMeshFB* mesh);
Parameters
Description
The xrGetHandMeshFB function populates an XrHandTrackingMeshFB structure with enough information to render a skinned mesh driven by the hand joints. As discussed in the specification for that structure, the data enumerated by this call is constant during the lifetime of an XrInstance.
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrGetInputSourceLocalizedName(3)
Name
xrGetInputSourceLocalizedName - Gets a localized source name
C Specification
The xrGetInputSourceLocalizedName function is defined as:
// Provided by XR_VERSION_1_0
XrResult xrGetInputSourceLocalizedName(
XrSession session,
const XrInputSourceLocalizedNameGetInfo* getInfo,
uint32_t bufferCapacityInput,
uint32_t* bufferCountOutput,
char* buffer);
Parameters
Description
xrGetInputSourceLocalizedName returns a string for the bound source in the current system locale.
If xrAttachSessionActionSets has not yet been called for the session,
the runtime must return XR_ERROR_ACTIONSET_NOT_ATTACHED
.
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrGetInstanceProcAddr(3)
Name
xrGetInstanceProcAddr - Gets a function pointer for an OpenXR function
C Specification
Function pointers for all OpenXR functions can be obtained with the function xrGetInstanceProcAddr.
// Provided by XR_VERSION_1_0
XrResult xrGetInstanceProcAddr(
XrInstance instance,
const char* name,
PFN_xrVoidFunction* function);
Parameters
Description
xrGetInstanceProcAddr itself is obtained in a platform- and loader- specific manner. Typically, the loader library will export this function as a function symbol, so applications can link against the loader library, or load it dynamically and look up the symbol using platform-specific APIs. Loaders must export function symbols for all core OpenXR functions. Because of this, applications that use only the core OpenXR functions have no need to use xrGetInstanceProcAddr.
Because an application can call xrGetInstanceProcAddr before creating
an instance, xrGetInstanceProcAddr returns a valid function pointer
when the instance
parameter is XR_NULL_HANDLE and the name
parameter is one of the following strings:
xrGetInstanceProcAddr must return XR_ERROR_HANDLE_INVALID
if
name
is not one of the above strings and instance
is
XR_NULL_HANDLE.
xrGetInstanceProcAddr may return XR_ERROR_HANDLE_INVALID
if
name
is not one of the above strings and instance
is invalid but
not XR_NULL_HANDLE.
xrGetInstanceProcAddr must return XR_ERROR_FUNCTION_UNSUPPORTED
if instance
is a valid instance and the string specified in name
is not the name of an OpenXR core or enabled extension function.
If name
is the name of an extension function, then the result returned
by xrGetInstanceProcAddr will depend upon how the instance
was
created.
If instance
was created with the related extension’s name appearing in
the XrInstanceCreateInfo::enabledExtensionNames
array, then
xrGetInstanceProcAddr returns a valid function pointer.
If the related extension’s name did not appear in the
XrInstanceCreateInfo::enabledExtensionNames
array during the
creation of instance
, then xrGetInstanceProcAddr returns
XR_ERROR_FUNCTION_UNSUPPORTED
.
Because of this, function pointers returned by xrGetInstanceProcAddr
using one XrInstance may not be valid when used with objects related
to a different XrInstance.
The returned function pointer is of type PFN_xrVoidFunction, and must be cast to the type of the function being queried.
The table below defines the various use cases for xrGetInstanceProcAddr and return value (“fp” is “function pointer”) for each case.
instance parameter |
name parameter |
return value |
---|---|---|
* |
|
undefined |
invalid instance |
* |
undefined |
|
fp |
|
|
fp |
|
|
fp |
|
|
* (any |
|
instance |
core OpenXR function |
fp1 |
instance |
enabled extension function for |
fp1 |
instance |
* (any |
|
- 1
-
The returned function pointer must only be called with a handle (the first parameter) that is
instance
or a child ofinstance
.
See Also
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrGetInstanceProperties(3)
Name
xrGetInstanceProperties - Gets information about the instance
C Specification
The xrGetInstanceProperties function provides information about the instance and the associated runtime.
// Provided by XR_VERSION_1_0
XrResult xrGetInstanceProperties(
XrInstance instance,
XrInstanceProperties* instanceProperties);
Parameters
Description
The instanceProperties
parameter must be filled out by the runtime in
response to this call, with information as defined in
XrInstanceProperties.
See Also
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrGetMarkerSizeVARJO(3)
Name
xrGetMarkerSizeVARJO - Gets physical size of marker
C Specification
The xrGetMarkerSizeVARJO function is defined as:
// Provided by XR_VARJO_marker_tracking
XrResult xrGetMarkerSizeVARJO(
XrSession session,
uint64_t markerId,
XrExtent2Df* size);
Parameters
Description
The xrGetMarkerSizeVARJO function retrieves the height and width of an
active marker.
The runtime must return XR_ERROR_MARKER_NOT_TRACKED_VARJO
if marker
tracking functionality is disabled or the marker with given markerId
is inactive.
The runtime must return XR_ERROR_MARKER_ID_INVALID_VARJO
if the
supplied markerId
is invalid.
See Also
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrGetOpenGLESGraphicsRequirementsKHR(3)
Name
xrGetOpenGLESGraphicsRequirementsKHR - Retrieve the OpenGL ES version requirements for an instance and system
C Specification
To query OpenGL ES API version requirements for an instance and system, call:
// Provided by XR_KHR_opengl_es_enable
XrResult xrGetOpenGLESGraphicsRequirementsKHR(
XrInstance instance,
XrSystemId systemId,
XrGraphicsRequirementsOpenGLESKHR* graphicsRequirements);
Parameters
Description
The xrGetOpenGLESGraphicsRequirementsKHR function identifies to the
application the minimum OpenGL ES version requirement and the highest known
tested OpenGL ES version.
The runtime must return XR_ERROR_GRAPHICS_REQUIREMENTS_CALL_MISSING
(XR_ERROR_VALIDATION_FAILURE
may be returned due to legacy behavior)
on calls to xrCreateSession if
xrGetOpenGLESGraphicsRequirementsKHR has not been called for the same
instance
and systemId
.
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrGetOpenGLGraphicsRequirementsKHR(3)
Name
xrGetOpenGLGraphicsRequirementsKHR - Retrieve the OpenGL version requirements for an instance and system
C Specification
To query OpenGL API version requirements for an instance and system, call:
// Provided by XR_KHR_opengl_enable
XrResult xrGetOpenGLGraphicsRequirementsKHR(
XrInstance instance,
XrSystemId systemId,
XrGraphicsRequirementsOpenGLKHR* graphicsRequirements);
Parameters
Description
The xrGetOpenGLGraphicsRequirementsKHR function identifies to the
application the minimum OpenGL version requirement and the highest known
tested OpenGL version.
The runtime must return XR_ERROR_GRAPHICS_REQUIREMENTS_CALL_MISSING
(XR_ERROR_VALIDATION_FAILURE
may be returned due to legacy behavior)
on calls to xrCreateSession if
xrGetOpenGLGraphicsRequirementsKHR has not been called for the same
instance
and systemId
.
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrGetPerformanceMetricsStateMETA(3)
Name
xrGetPerformanceMetricsStateMETA - Get current state of performance metrics
C Specification
The xrGetPerformanceMetricsStateMETA function is defined as:
// Provided by XR_META_performance_metrics
XrResult xrGetPerformanceMetricsStateMETA(
XrSession session,
XrPerformanceMetricsStateMETA* state);
Parameters
Description
The xrGetPerformanceMetricsStateMETA function gets the current state of the performance metrics system.
See Also
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrGetReferenceSpaceBoundsRect(3)
Name
xrGetReferenceSpaceBoundsRect - Gets the bounds rectangle of a reference space
C Specification
XR systems may have limited real world spatial ranges in which users can freely move around while remaining tracked. Applications may wish to query these boundaries and alter application behavior or content placement to ensure the user can complete the experience while remaining within the boundary. Applications can query this information using xrGetReferenceSpaceBoundsRect.
When called, xrGetReferenceSpaceBoundsRect should return the extents
of a rectangle that is clear of obstacles down to the floor, allowing where
the user can freely move while remaining tracked, if available for that
reference space.
The returned extent represents the dimensions of an axis-aligned bounding
box where the XrExtent2Df::width
and
XrExtent2Df::height
fields correspond to the X and Z axes of the
provided space, with the extents centered at the origin of the space.
Not all systems or spaces may support boundaries.
If a runtime is unable to provide bounds for a given space,
XR_SPACE_BOUNDS_UNAVAILABLE
will be returned and all fields of
bounds
will be set to 0.
The returned extents are expressed relative to the natural origin of the provided XrReferenceSpaceType and must not incorporate any origin offsets specified by the application during calls to xrCreateReferenceSpace.
The runtime must return XR_ERROR_REFERENCE_SPACE_UNSUPPORTED
if the
XrReferenceSpaceType passed in createInfo
is not supported by
this session
.
When a runtime will begin operating with updated space bounds, the runtime must queue a corresponding XrEventDataReferenceSpaceChangePending event.
// Provided by XR_VERSION_1_0
XrResult xrGetReferenceSpaceBoundsRect(
XrSession session,
XrReferenceSpaceType referenceSpaceType,
XrExtent2Df* bounds);
Parameters
Description
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrGetRenderModelPropertiesFB(3)
Name
xrGetRenderModelPropertiesFB - Get information for a render model
C Specification
The xrGetRenderModelPropertiesFB function is defined as:
// Provided by XR_FB_render_model
XrResult xrGetRenderModelPropertiesFB(
XrSession session,
XrPath path,
XrRenderModelPropertiesFB* properties);
Parameters
Description
xrGetRenderModelPropertiesFB is used for getting information for a render model using a path retrieved from xrEnumerateRenderModelPathsFB. The information returned will be for the connected device that corresponds to the path given. For example, using /model_fb/controller/left will return information for the left controller that is currently connected and will change if a different device that also represents a left controller is connected.
The runtime must return XR_ERROR_CALL_ORDER_INVALID
if
xrGetRenderModelPropertiesFB is called with render model paths before
calling xrEnumerateRenderModelPathsFB.
The runtime must return XR_ERROR_PATH_INVALID
if a path not given by
xrEnumerateRenderModelPathsFB is used.
If xrGetRenderModelPropertiesFB returns a success code of
XR_RENDER_MODEL_UNAVAILABLE_FB
and has a modelKey
of
XR_NULL_RENDER_MODEL_KEY_FB, this indicates that the model for the
device is unavailable.
The application may keep calling xrGetRenderModelPropertiesFB because
the model may become available later when a device is connected.
See Also
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrGetSceneComponentsMSFT(3)
Name
xrGetSceneComponentsMSFT - Get scene components from a scene
C Specification
Scene components are read from an XrSceneMSFT using
xrGetSceneComponentsMSFT and passing one
XrSceneComponentTypeMSFT.
This function follows the two-call idiom for
filling multiple buffers in a struct.
Different scene component types may have additional properties that can be
read by chaining additional structures to XrSceneComponentsMSFT.
Those additional structures must have an array size that is at least as
large as XrSceneComponentsMSFT::componentCapacityInput, otherwise the
runtime must return XR_ERROR_SIZE_INSUFFICIENT
.
-
If
XR_SCENE_COMPONENT_TYPE_OBJECT_MSFT
is passed to xrGetSceneComponentsMSFT, then XrSceneObjectsMSFT may be included in the XrSceneComponentsMSFT::next
chain. -
If
XR_SCENE_COMPONENT_TYPE_PLANE_MSFT
is passed to xrGetSceneComponentsMSFT, then XrScenePlanesMSFT may be included in the XrSceneComponentsMSFT::next
chain. -
If
XR_SCENE_COMPONENT_TYPE_VISUAL_MESH_MSFT
orXR_SCENE_COMPONENT_TYPE_COLLIDER_MESH_MSFT
are passed to xrGetSceneComponentsMSFT, then XrSceneMeshesMSFT may be included in the XrSceneComponentsMSFT::next
chain.
// Provided by XR_MSFT_scene_understanding
XrResult xrGetSceneComponentsMSFT(
XrSceneMSFT scene,
const XrSceneComponentsGetInfoMSFT* getInfo,
XrSceneComponentsMSFT* components);
Parameters
Description
See Also
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrGetSceneComputeStateMSFT(3)
Name
xrGetSceneComputeStateMSFT - Get the scene compute state
C Specification
An application can inspect the completion of the compute by polling xrGetSceneComputeStateMSFT. This function should typically be called once per frame per XrSceneObserverMSFT.
// Provided by XR_MSFT_scene_understanding
XrResult xrGetSceneComputeStateMSFT(
XrSceneObserverMSFT sceneObserver,
XrSceneComputeStateMSFT* state);
Parameters
Description
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrGetSceneMeshBuffersMSFT(3)
Name
xrGetSceneMeshBuffersMSFT - Get scene mesh buffers
C Specification
The xrGetSceneMeshBuffersMSFT function retrieves the scene mesh vertex buffer and index buffer for the given scene mesh buffer identifier.
Note
Applications may use the scene mesh buffer identifier as a key to cache the vertices and indices of a mesh for reuse within an XrSceneMSFT or across multiple XrSceneMSFT for the same XrSession. Applications can avoid unnecessarily calling xrGetSceneMeshBuffersMSFT
for a scene component if XrSceneComponentMSFT:: |
This function follows the two-call idiom for filling multiple buffers in a struct.
The xrGetSceneMeshBuffersMSFT function is defined as:
// Provided by XR_MSFT_scene_understanding
XrResult xrGetSceneMeshBuffersMSFT(
XrSceneMSFT scene,
const XrSceneMeshBuffersGetInfoMSFT* getInfo,
XrSceneMeshBuffersMSFT* buffers);
Parameters
Description
Applications can request the vertex buffer of the mesh by including
XrSceneMeshVertexBufferMSFT in the
XrSceneMeshBuffersMSFT::next
chain.
Runtimes must support requesting a 32-bit index buffer and may support
requesting a 16-bit index buffer.
Applications can request a 32-bit index buffer by including
XrSceneMeshIndicesUint32MSFT in the
XrSceneMeshBuffersMSFT::next
chain.
Applications can request a 16-bit index buffer by including
XrSceneMeshIndicesUint16MSFT in the
XrSceneMeshBuffersMSFT::next
chain.
If the runtime for the given scene mesh buffer does not support requesting a
16-bit index buffer then XR_ERROR_VALIDATION_FAILURE
must be
returned.
The runtime must support reading a 16-bit index buffer for the given scene
mesh buffer if XrScenePlaneMSFT:supportsIndicesUint16 or
XrSceneMeshMSFT:supportsIndicesUint16 are XR_TRUE
for the scene
component that contained that scene mesh buffer identifier.
The runtime must return XR_ERROR_SCENE_MESH_BUFFER_ID_INVALID_MSFT
if
none of the scene components in the given XrSceneMSFT contain
XrSceneMeshBuffersGetInfoMSFT::meshBufferId
.
The runtime must return XR_ERROR_SCENE_MESH_BUFFER_ID_INVALID_MSFT
if
XrSceneMeshBuffersGetInfoMSFT::meshBufferId
is zero.
The runtime must return XR_ERROR_VALIDATION_FAILURE
if both
XrSceneMeshIndicesUint32MSFT and XrSceneMeshIndicesUint16MSFT
are included in the XrSceneMeshBuffersMSFT::next
chain.
The runtime must return XR_ERROR_VALIDATION_FAILURE
if the
XrSceneMeshBuffersMSFT::next
does not contain at least one of
XrSceneMeshVertexBufferMSFT, XrSceneMeshIndicesUint32MSFT or
XrSceneMeshIndicesUint16MSFT.
The runtime must return the same vertices and indices for a given scene mesh buffer identifier and XrSession. A runtime may return zero vertices and indices if the underlying mesh data is no longer available.
See Also
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrGetSerializedSceneFragmentDataMSFT(3)
Name
xrGetSerializedSceneFragmentDataMSFT - Get serialized scene fragment data
C Specification
The application can call the xrGetSerializedSceneFragmentDataMSFT function to read the binary data of a serialized scene fragment from the XrSceneMSFT handle. This function follows the two-call idiom for filling the buffer.
The xrGetSerializedSceneFragmentDataMSFT function is defined as:
// Provided by XR_MSFT_scene_understanding_serialization
XrResult xrGetSerializedSceneFragmentDataMSFT(
XrSceneMSFT scene,
const XrSerializedSceneFragmentDataGetInfoMSFT* getInfo,
uint32_t countInput,
uint32_t* readOutput,
uint8_t* buffer);
Parameters
Description
The runtime must return XR_ERROR_SCENE_COMPONENT_ID_INVALID_MSFT
if
the given scene fragment XrUuidMSFT was not found.
See Also
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrGetSpaceBoundary2DFB(3)
Name
xrGetSpaceBoundary2DFB - Gets the 2D boundary for a spatial entity
C Specification
The xrGetSpaceBoundary2DFB function is defined as:
// Provided by XR_FB_scene
XrResult xrGetSpaceBoundary2DFB(
XrSession session,
XrSpace space,
XrBoundary2DFB* boundary2DOutput);
Parameters
Description
Gets the 2D boundary, specified by vertices, for a spatial entity with the
XR_SPACE_COMPONENT_TYPE_BOUNDED_2D_FB
component type enabled.
See Also
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrGetSpaceBoundingBox2DFB(3)
Name
xrGetSpaceBoundingBox2DFB - Gets the 2D bounding box for a spatial entity
C Specification
The xrGetSpaceBoundingBox2DFB function is defined as:
// Provided by XR_FB_scene
XrResult xrGetSpaceBoundingBox2DFB(
XrSession session,
XrSpace space,
XrRect2Df* boundingBox2DOutput);
Parameters
Description
Gets the 2D bounding box for a spatial entity with the
XR_SPACE_COMPONENT_TYPE_BOUNDED_2D_FB
component type enabled.
See Also
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrGetSpaceBoundingBox3DFB(3)
Name
xrGetSpaceBoundingBox3DFB - Gets the 3D bounding box for a spatial entity
C Specification
The xrGetSpaceBoundingBox3DFB function is defined as:
// Provided by XR_FB_scene
XrResult xrGetSpaceBoundingBox3DFB(
XrSession session,
XrSpace space,
XrRect3DfFB* boundingBox3DOutput);
Parameters
Description
Gets the 3D bounding box for a spatial entity with the
XR_SPACE_COMPONENT_TYPE_BOUNDED_3D_FB
component type enabled.
See Also
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrGetSpaceComponentStatusFB(3)
Name
xrGetSpaceComponentStatusFB - Provides the current state of a component
C Specification
The xrGetSpaceComponentStatusFB function is defined as:
// Provided by XR_FB_spatial_entity
XrResult xrGetSpaceComponentStatusFB(
XrSpace space,
XrSpaceComponentTypeFB componentType,
XrSpaceComponentStatusFB* status);
Parameters
Description
Gets the current status of the specified component for the specified entity.
This function must return XR_ERROR_SPACE_COMPONENT_NOT_SUPPORTED_FB
if the XrSpace does not support the specified component type.
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrGetSpaceContainerFB(3)
Name
xrGetSpaceContainerFB - Gets a XrSpaceContainerFB which lists contained spaces
C Specification
The xrGetSpaceContainerFB function is defined as:
// Provided by XR_FB_spatial_entity_container
XrResult xrGetSpaceContainerFB(
XrSession session,
XrSpace space,
XrSpaceContainerFB* spaceContainerOutput);
Parameters
Description
The xrGetSpaceContainerFB function is used by an application to perform the two calls required to obtain information about which spatial entities are contained by a specified spatial entity.
The XR_SPACE_COMPONENT_TYPE_SPACE_CONTAINER_FB
component type must be
enabled, otherwise this function will return
XR_ERROR_SPACE_COMPONENT_NOT_ENABLED_FB
.
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrGetSpaceRoomLayoutFB(3)
Name
xrGetSpaceRoomLayoutFB - Gets the room layout for a spatial entity
C Specification
The xrGetSpaceRoomLayoutFB function is defined as:
// Provided by XR_FB_scene
XrResult xrGetSpaceRoomLayoutFB(
XrSession session,
XrSpace space,
XrRoomLayoutFB* roomLayoutOutput);
Parameters
Description
Gets the room layout, specified by UUIDs for each surface, for a spatial
entity with the XR_SPACE_COMPONENT_TYPE_ROOM_LAYOUT_FB
component type
enabled.
See Also
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrGetSpaceSemanticLabelsFB(3)
Name
xrGetSpaceSemanticLabelsFB - Gets the semantic labels for a spatial entity
C Specification
The xrGetSpaceSemanticLabelsFB function is defined as:
// Provided by XR_FB_scene
XrResult xrGetSpaceSemanticLabelsFB(
XrSession session,
XrSpace space,
XrSemanticLabelsFB* semanticLabelsOutput);
Parameters
Description
Gets the semantic labels for a spatial entity with the
XR_SPACE_COMPONENT_TYPE_SEMANTIC_LABELS_FB
component type enabled.
See Also
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrGetSpaceUuidFB(3)
Name
xrGetSpaceUuidFB - Gets an entity
C Specification
The xrGetSpaceUuidFB function is defined as:
// Provided by XR_FB_spatial_entity
XrResult xrGetSpaceUuidFB(
XrSpace space,
XrUuidEXT* uuid);
Parameters
Description
Gets the UUID for a spatial entity.
If this space was previously created as a spatial anchor, uuid
must
be equal to the XrEventDataSpatialAnchorCreateCompleteFB::uuid
in the event corresponding to the creation of that space.
Subsequent calls to xrGetSpaceUuidFB using the same XrSpace
must return the same XrUuidEXT.
See Also
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrGetSpatialGraphNodeBindingPropertiesMSFT(3)
Name
xrGetSpatialGraphNodeBindingPropertiesMSFT - Destroy a spatial graph node handle
C Specification
The xrGetSpatialGraphNodeBindingPropertiesMSFT function retrieves the spatial graph node GUID and the pose in the node space from an XrSpatialGraphNodeBindingMSFT handle.
// Provided by XR_MSFT_spatial_graph_bridge
XrResult xrGetSpatialGraphNodeBindingPropertiesMSFT(
XrSpatialGraphNodeBindingMSFT nodeBinding,
const XrSpatialGraphNodeBindingPropertiesGetInfoMSFT* getInfo,
XrSpatialGraphNodeBindingPropertiesMSFT* properties);
Parameters
Description
See Also
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrGetSwapchainStateFB(3)
Name
xrGetSwapchainStateFB - Query state for the corresponding swapchain
C Specification
The xrGetSwapchainStateFB function is defined as:
// Provided by XR_FB_swapchain_update_state
XrResult xrGetSwapchainStateFB(
XrSwapchain swapchain,
XrSwapchainStateBaseHeaderFB* state);
Parameters
Description
xrGetSwapchainStateFB provides support for an application to query specific mutable state associated with an XrSwapchain.
See Also
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrGetSystem(3)
Name
xrGetSystem - Gets a system identifier
C Specification
The xrGetSystem function is defined as:
// Provided by XR_VERSION_1_0
XrResult xrGetSystem(
XrInstance instance,
const XrSystemGetInfo* getInfo,
XrSystemId* systemId);
Parameters
Description
To get an XrSystemId
, an application specifies its desired
form factor to xrGetSystem and gets the
runtime’s XrSystemId
associated with that configuration.
If the form factor is supported but temporarily unavailable,
xrGetSystem must return XR_ERROR_FORM_FACTOR_UNAVAILABLE
.
A runtime may return XR_SUCCESS
on a subsequent call for a form
factor it previously returned XR_ERROR_FORM_FACTOR_UNAVAILABLE
.
For example, connecting or warming up hardware might cause an unavailable
form factor to become available.
See Also
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrGetSystemProperties(3)
Name
xrGetSystemProperties - Gets the properties of a particular system
C Specification
The xrGetSystemProperties function is defined as:
// Provided by XR_VERSION_1_0
XrResult xrGetSystemProperties(
XrInstance instance,
XrSystemId systemId,
XrSystemProperties* properties);
Parameters
Description
An application can call xrGetSystemProperties to retrieve information about the system such as vendor ID, system name, and graphics and tracking properties.
See Also
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrGetViewConfigurationProperties(3)
Name
xrGetViewConfigurationProperties - Gets information for a view configuration
C Specification
The xrGetViewConfigurationProperties function is defined as:
// Provided by XR_VERSION_1_0
XrResult xrGetViewConfigurationProperties(
XrInstance instance,
XrSystemId systemId,
XrViewConfigurationType viewConfigurationType,
XrViewConfigurationProperties* configurationProperties);
Parameters
Description
xrGetViewConfigurationProperties queries properties of an individual
view configuration.
Applications must use one of the supported view configuration types
returned by xrEnumerateViewConfigurations.
If viewConfigurationType
is not supported by this XrInstance the
runtime must return XR_ERROR_VIEW_CONFIGURATION_TYPE_UNSUPPORTED
.
See Also
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrGetVisibilityMaskKHR(3)
Name
xrGetVisibilityMaskKHR - Gets visibility mask
C Specification
The xrGetVisibilityMaskKHR function is defined as:
// Provided by XR_KHR_visibility_mask
XrResult xrGetVisibilityMaskKHR(
XrSession session,
XrViewConfigurationType viewConfigurationType,
uint32_t viewIndex,
XrVisibilityMaskTypeKHR visibilityMaskType,
XrVisibilityMaskKHR* visibilityMask);
Parameters
Description
xrGetVisibilityMaskKHR retrieves the view mask for a given view.
This function follows the two-call idiom for
filling multiple buffers in a struct.
Specifically, if either vertexCapacityInput
or
indexCapacityInput
is 0
, the runtime must respond as if both fields
were set to 0
, returning the vertex count and index count through
vertexCountOutput
or indexCountOutput
respectively.
If a view mask for the specified view isn’t available, the returned vertex
and index counts must be 0
.
See Also
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrGetVulkanDeviceExtensionsKHR(3)
Name
xrGetVulkanDeviceExtensionsKHR - Get list of required Vulkan device extensions for an OpenXR instance and system
C Specification
// Provided by XR_KHR_vulkan_enable
XrResult xrGetVulkanDeviceExtensionsKHR(
XrInstance instance,
XrSystemId systemId,
uint32_t bufferCapacityInput,
uint32_t* bufferCountOutput,
char* buffer);
Parameters
Description
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrGetVulkanGraphicsDevice2KHR(3)
Name
xrGetVulkanGraphicsDevice2KHR - Retrieve the Vulkan physical device associated with an OpenXR instance and system
C Specification
// Provided by XR_KHR_vulkan_enable2
XrResult xrGetVulkanGraphicsDevice2KHR(
XrInstance instance,
const XrVulkanGraphicsDeviceGetInfoKHR* getInfo,
VkPhysicalDevice* vulkanPhysicalDevice);
Parameters
Description
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrGetVulkanGraphicsDeviceKHR(3)
Name
xrGetVulkanGraphicsDeviceKHR - Retrieve the Vulkan physical device associated with an OpenXR instance and system
C Specification
To identify what graphics device needs to be used for an instance and system, call:
// Provided by XR_KHR_vulkan_enable
XrResult xrGetVulkanGraphicsDeviceKHR(
XrInstance instance,
XrSystemId systemId,
VkInstance vkInstance,
VkPhysicalDevice* vkPhysicalDevice);
Parameters
Description
xrGetVulkanGraphicsDeviceKHR function identifies to the application
what graphics device (Vulkan VkPhysicalDevice
) needs to be used.
xrGetVulkanGraphicsDeviceKHR must be called prior to calling
xrCreateSession, and the VkPhysicalDevice
that
xrGetVulkanGraphicsDeviceKHR returns should be passed to
xrCreateSession in the XrGraphicsBindingVulkanKHR.
See Also
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrGetVulkanGraphicsRequirementsKHR(3)
Name
xrGetVulkanGraphicsRequirementsKHR - Retrieve the Vulkan version requirements for an instance and system
C Specification
To query Vulkan API version requirements, call:
// Provided by XR_KHR_vulkan_enable
XrResult xrGetVulkanGraphicsRequirementsKHR(
XrInstance instance,
XrSystemId systemId,
XrGraphicsRequirementsVulkanKHR* graphicsRequirements);
Parameters
Description
The xrGetVulkanGraphicsRequirementsKHR function identifies to the
application the minimum Vulkan version requirement and the highest known
tested Vulkan version.
The runtime must return XR_ERROR_GRAPHICS_REQUIREMENTS_CALL_MISSING
(XR_ERROR_VALIDATION_FAILURE
may be returned due to legacy behavior)
on calls to xrCreateSession if
xrGetVulkanGraphicsRequirementsKHR has not been called for the same
instance
and systemId
.
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrGetVulkanInstanceExtensionsKHR(3)
Name
xrGetVulkanInstanceExtensionsKHR - Get list of required Vulkan instance extensions for an OpenXR instance and system
C Specification
// Provided by XR_KHR_vulkan_enable
XrResult xrGetVulkanInstanceExtensionsKHR(
XrInstance instance,
XrSystemId systemId,
uint32_t bufferCapacityInput,
uint32_t* bufferCountOutput,
char* buffer);
Parameters
Description
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrInitializeLoaderKHR(3)
Name
xrInitializeLoaderKHR - Initializes loader
C Specification
To initialize an OpenXR loader with platform or implementation-specific parameters, call:
// Provided by XR_KHR_loader_init
XrResult xrInitializeLoaderKHR(
const XrLoaderInitInfoBaseHeaderKHR* loaderInitInfo);
Parameters
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrLoadControllerModelMSFT(3)
Name
xrLoadControllerModelMSFT - Load controller render model
C Specification
The xrLoadControllerModelMSFT function loads the controller model as a byte buffer containing a binary form of glTF (a.k.a GLB file format) for the controller. The binary glTF data must conform to glTF 2.0 format defined at https://github.com/KhronosGroup/glTF/tree/master/specification/2.0.
// Provided by XR_MSFT_controller_model
XrResult xrLoadControllerModelMSFT(
XrSession session,
XrControllerModelKeyMSFT modelKey,
uint32_t bufferCapacityInput,
uint32_t* bufferCountOutput,
uint8_t* buffer);
Parameters
Description
The xrLoadControllerModelMSFT function may be a slow operation and therefore should be invoked from a non-timing critical thread.
If the input modelKey
is invalid, i.e. it is
XR_NULL_CONTROLLER_MODEL_KEY_MSFT or not a key returned from
XrControllerModelKeyStateMSFT, the runtime must return
XR_ERROR_CONTROLLER_MODEL_KEY_INVALID_MSFT
.
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrLoadRenderModelFB(3)
Name
xrLoadRenderModelFB - Load binary data for a render model
C Specification
The xrLoadRenderModelFB function is defined as:
// Provided by XR_FB_render_model
XrResult xrLoadRenderModelFB(
XrSession session,
const XrRenderModelLoadInfoFB* info,
XrRenderModelBufferFB* buffer);
Parameters
Description
xrLoadRenderModelFB is used to load the GLTF model data using a valid
modelKey
.
xrLoadRenderModelFB loads the model as a byte buffer containing the
GLTF in the binary format (GLB).
The GLB data must conform to the glTF 2.0 format defined at
https://github.com/KhronosGroup/glTF/tree/master/specification/2.0.
The GLB may contain texture data in a format that requires the use of the
KHR_texture_basisu
GLTF extension defined at
https://github.com/KhronosGroup/glTF/tree/master/extensions/2.0/Khronos/KHR_texture_basisu.
Therefore, the application should ensure it can handle this extension.
If the device for the requested model is disconnected or does not match the
modelKey
provided, xrLoadRenderModelFB must return
XR_RENDER_MODEL_UNAVAILABLE_FB
as well as a bufferCountOutput
value of 0 indicating that the model was not available.
The xrLoadRenderModelFB function may be slow, therefore applications should call it from a non-time sensitive thread.
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrLocateHandJointsEXT(3)
Name
xrLocateHandJointsEXT - Locate hand joint locations
C Specification
The xrLocateHandJointsEXT function locates an array of hand joints to a base space at given time.
// Provided by XR_EXT_hand_tracking
XrResult xrLocateHandJointsEXT(
XrHandTrackerEXT handTracker,
const XrHandJointsLocateInfoEXT* locateInfo,
XrHandJointLocationsEXT* locations);
Parameters
Description
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrLocateSceneComponentsMSFT(3)
Name
xrLocateSceneComponentsMSFT - Locate scene components
C Specification
The xrLocateSceneComponentsMSFT function locates an array of scene components to a base space at a given time.
// Provided by XR_MSFT_scene_understanding
XrResult xrLocateSceneComponentsMSFT(
XrSceneMSFT scene,
const XrSceneComponentsLocateInfoMSFT* locateInfo,
XrSceneComponentLocationsMSFT* locations);
Parameters
Description
The runtime must return XR_ERROR_SIZE_INSUFFICIENT
if
XrSceneComponentLocationsMSFT::locationCount
is less than
XrSceneComponentsLocateInfoMSFT::componentIdCount
.
Note
Similar to xrLocateSpace, apps should call xrLocateSceneComponentsMSFT each frame because the location returned by xrLocateSceneComponentsMSFT in later frames may change over time as the target space or the scene components may refine their locations. |
See Also
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrLocateSpace(3)
Name
xrLocateSpace - Locates a space with reference to another space
C Specification
xrLocateSpace provides the physical location of a space in a base space at a specified time, if currently known by the runtime.
// Provided by XR_VERSION_1_0
XrResult xrLocateSpace(
XrSpace space,
XrSpace baseSpace,
XrTime time,
XrSpaceLocation* location);
Parameters
Description
For a time
in the past, the runtime should locate the spaces based on
the runtime’s most accurate current understanding of how the world was at
that historical time.
For a time
in the future, the runtime should locate the spaces based
on the runtime’s most up-to-date prediction of how the world will be at that
future time.
The minimum valid range of values for time
are described in
https://www.khronos.org/registry/OpenXR/specs/1.0/html/xrspec.html#prediction-time-limits.
For values of time
outside this range, xrLocateSpace may return
a location with no position and XR_SPACE_LOCATION_POSITION_VALID_BIT
unset.
Some devices improve their understanding of the world as the device is used.
The location returned by xrLocateSpace for a given space
,
baseSpace
and time
may change over time, even for spaces that
track static objects, as one or both spaces adjust their origins.
During tracking loss of space
relative to baseSpace
, runtimes
should continue to provide inferred or last-known position
and
orientation
values.
These inferred poses can, for example, be based on neck model updates,
inertial dead reckoning, or a last-known position, so long as it is still
reasonable for the application to use that pose.
While a runtime is providing position data, it must continue to set
XR_SPACE_LOCATION_POSITION_VALID_BIT
but it can clear
XR_SPACE_LOCATION_POSITION_TRACKED_BIT
to indicate that the position
is inferred or last-known in this way.
If the runtime has not yet observed even a last-known pose for how to locate
space
in baseSpace
(e.g. one space is an action space bound to a
motion controller that has not yet been detected, or the two spaces are in
disconnected fragments of the runtime’s tracked volume), the runtime should
return a location with no position and
XR_SPACE_LOCATION_POSITION_VALID_BIT
unset.
The runtime must return a location with both
XR_SPACE_LOCATION_POSITION_VALID_BIT
and
XR_SPACE_LOCATION_POSITION_TRACKED_BIT
set when locating space
and baseSpace
if both spaces were created relative to the same entity
(e.g. two action spaces for the same action), even if the entity is
currently untracked.
The location in this case is the difference in the two spaces'
application-specified transforms relative to that common entity.
During tracking loss, the runtime should return a location with
XR_SPACE_LOCATION_POSITION_VALID_BIT
and
XR_SPACE_LOCATION_ORIENTATION_VALID_BIT
set and
XR_SPACE_LOCATION_POSITION_TRACKED_BIT
and
XR_SPACE_LOCATION_ORIENTATION_TRACKED_BIT
unset for spaces tracking
two static entities in the world when their relative pose is known to the
runtime.
This enables applications to continue to make use of the runtime’s latest
knowledge of the world.
If an XrSpaceVelocity structure is chained to the next
pointer
of XrSpaceLocation and the velocity is observed or can be calculated
by the runtime, the runtime must fill in the linear velocity of the origin
of space within the reference frame of baseSpace
and set the
XR_SPACE_VELOCITY_LINEAR_VALID_BIT
.
Similarly, if an XrSpaceVelocity structure is chained to the
next
pointer of XrSpaceLocation and the angular velocity is
observed or can be calculated by the runtime, the runtime must fill in the
angular velocity of the origin of space within the reference frame of
baseSpace
and set the XR_SPACE_VELOCITY_ANGULAR_VALID_BIT
.
The following example code shows how an application can get both the location and velocity of a space within a base space using the xrLocateSpace function by chaining an XrSpaceVelocity to the next pointer of XrSpaceLocation and calling xrLocateSpace.
XrSpace space; // previously initialized
XrSpace baseSpace; // previously initialized
XrTime time; // previously initialized
XrSpaceVelocity velocity {XR_TYPE_SPACE_VELOCITY};
XrSpaceLocation location {XR_TYPE_SPACE_LOCATION, &velocity};
xrLocateSpace(space, baseSpace, time, &location);
See Also
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrLocateViews(3)
Name
xrLocateViews - Gets view and projection info
C Specification
The xrLocateViews function is defined as:
// Provided by XR_VERSION_1_0
XrResult xrLocateViews(
XrSession session,
const XrViewLocateInfo* viewLocateInfo,
XrViewState* viewState,
uint32_t viewCapacityInput,
uint32_t* viewCountOutput,
XrView* views);
Parameters
Description
The xrLocateViews function returns the view and projection info for a particular display time. This time is typically the target display time for a given frame. Repeatedly calling xrLocateViews with the same time may not necessarily return the same result. Instead the prediction gets increasingly accurate as the function is called closer to the given time for which a prediction is made. This allows an application to get the predicted views as late as possible in its pipeline to get the least amount of latency and prediction error.
xrLocateViews returns an array of XrView elements, one for each view of the specified view configuration type, along with an XrViewState containing additional state data shared across all views. The eye each view corresponds to is statically defined in XrViewConfigurationType in case the application wants to apply eye-specific rendering traits. The XrViewState and XrView member data may change on subsequent calls to xrLocateViews, and so applications must not assume it to be constant.
See Also
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrPassthroughLayerPauseFB(3)
Name
xrPassthroughLayerPauseFB - Pause a passthrough layer
C Specification
The xrPassthroughLayerPauseFB function is defined as:
// Provided by XR_FB_passthrough
XrResult xrPassthroughLayerPauseFB(
XrPassthroughLayerFB layer);
Parameters
Description
Pauses an XrPassthroughLayerFB layer. Runtime will not render or composite paused layers.
See Also
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrPassthroughLayerResumeFB(3)
Name
xrPassthroughLayerResumeFB - Resume a passthrough layer
C Specification
The xrPassthroughLayerResumeFB function is defined as:
// Provided by XR_FB_passthrough
XrResult xrPassthroughLayerResumeFB(
XrPassthroughLayerFB layer);
Parameters
Description
Resumes an XrPassthroughLayerFB layer.
See Also
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrPassthroughLayerSetKeyboardHandsIntensityFB(3)
Name
xrPassthroughLayerSetKeyboardHandsIntensityFB - Renders hands over the keyboard (keyboard hands) with a specific intensity of hands passthrough layer
C Specification
The xrPassthroughLayerSetKeyboardHandsIntensityFB function is defined as:
// Provided by XR_FB_passthrough_keyboard_hands
XrResult xrPassthroughLayerSetKeyboardHandsIntensityFB(
XrPassthroughLayerFB layer,
const XrPassthroughKeyboardHandsIntensityFB* intensity);
Parameters
Description
Sets an XrPassthroughKeyboardHandsIntensityFB intensity on an XrPassthroughLayerFB layer.
See Also
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrPassthroughLayerSetStyleFB(3)
Name
xrPassthroughLayerSetStyleFB - Set style on a passthrough layer
C Specification
The xrPassthroughLayerSetStyleFB function is defined as:
// Provided by XR_FB_passthrough
XrResult xrPassthroughLayerSetStyleFB(
XrPassthroughLayerFB layer,
const XrPassthroughStyleFB* style);
Parameters
Description
Sets an XrPassthroughStyleFB style on an XrPassthroughLayerFB layer.
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrPassthroughPauseFB(3)
Name
xrPassthroughPauseFB - Pause a passthrough feature
C Specification
The xrPassthroughPauseFB function is defined as:
// Provided by XR_FB_passthrough
XrResult xrPassthroughPauseFB(
XrPassthroughFB passthrough);
Parameters
Description
Pauses an XrPassthroughFB feature. When the feature is paused, runtime will stop rendering and compositing all passthrough layers produced on behalf of the application, and may free up some or all the resources used to produce passthrough until xrPassthroughStartFB is called.
See Also
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrPassthroughStartFB(3)
Name
xrPassthroughStartFB - Start a passthrough feature
C Specification
The xrPassthroughStartFB function is defined as:
// Provided by XR_FB_passthrough
XrResult xrPassthroughStartFB(
XrPassthroughFB passthrough);
Parameters
Description
Starts an XrPassthroughFB feature. If the feature is not started, either explicitly with a call to xrPassthroughStartFB, or implicitly at creation using the behavior flags, it is considered paused. When the feature is paused, runtime will stop rendering and compositing all passthrough layers produced on behalf of the application, and may free up some or all the resources used to produce passthrough until xrPassthroughStartFB is called.
See Also
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrPathToString(3)
Name
xrPathToString - Converts a semantic path to a string
C Specification
// Provided by XR_VERSION_1_0
XrResult xrPathToString(
XrInstance instance,
XrPath path,
uint32_t bufferCapacityInput,
uint32_t* bufferCountOutput,
char* buffer);
Parameters
Description
xrPathToString retrieves the path name string associated with an
XrPath
, in the context of a given XrInstance, in the form of
a NULL
terminated string placed into a caller-allocated buffer.
Since the mapping between a well-formed path name string and an
XrPath
is bijective, there will always be exactly one string for
each valid XrPath
value.
This can be useful if the calling application receives an XrPath
value that they had not previously retrieved via xrStringToPath.
During the lifetime of the given XrInstance, the path name string
retrieved by this function for a given valid XrPath
will not
change.
For invalid paths, including XR_NULL_PATH, XR_ERROR_PATH_INVALID
must be returned.
See Also
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrPerfSettingsSetPerformanceLevelEXT(3)
Name
xrPerfSettingsSetPerformanceLevelEXT - xrPerfSettingsSetPerformanceLevelEXT
C Specification
// Provided by XR_EXT_performance_settings
XrResult xrPerfSettingsSetPerformanceLevelEXT(
XrSession session,
XrPerfSettingsDomainEXT domain,
XrPerfSettingsLevelEXT level);
Parameters
Description
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrPersistSpatialAnchorMSFT(3)
Name
xrPersistSpatialAnchorMSFT - Persist the spatial anchor in the spatial anchor store
C Specification
The application can use the xrPersistSpatialAnchorMSFT function to
persist a spatial anchor in the spatial anchor store for this application.
The given spatialAnchorName
will be the string to retrieve the spatial
anchor from the Spatial Anchor store or subsequently remove the record of
this spatial anchor from the store.
This name will uniquely identify the spatial anchor for the current
application.
If there is already a spatial anchor of the same name persisted in the
spatial anchor store, the existing spatial anchor will be replaced and
xrPersistSpatialAnchorMSFT must return XR_SUCCESS
.
// Provided by XR_MSFT_spatial_anchor_persistence
XrResult xrPersistSpatialAnchorMSFT(
XrSpatialAnchorStoreConnectionMSFT spatialAnchorStore,
const XrSpatialAnchorPersistenceInfoMSFT* spatialAnchorPersistenceInfo);
Parameters
Description
See Also
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrPollEvent(3)
Name
xrPollEvent - Polls for events
C Specification
// Provided by XR_VERSION_1_0
XrResult xrPollEvent(
XrInstance instance,
XrEventDataBuffer* eventData);
Parameters
xrPollEvent polls for the next event and returns an event if one is
available.
xrPollEvent returns immediately regardless of whether an event was
available.
The event (if present) is unilaterally removed from the queue if a valid
XrInstance is provided.
On return the eventData
parameter is filled with the event’s data and
the type field is changed to the event’s type.
Runtimes may create valid next chains depending on enabled extensions, but
they must guarantee that any such chains point only to objects which fit
completely within the original XrEventDataBuffer pointed to by
eventData
.
Description
The runtime must discard queued events which contain destroyed or otherwise invalid handles.
Event | Description |
---|---|
event queue has overflowed and some events were lost |
|
application is about to lose the instance |
|
active input form factor for one or more top level user paths has changed |
|
runtime will begin operating with updated space bounds |
|
application has changed lifecycle state |
See Also
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrQueryPerformanceMetricsCounterMETA(3)
Name
xrQueryPerformanceMetricsCounterMETA - Query performance metrics counter
C Specification
The xrQueryPerformanceMetricsCounterMETA function is defined as:
// Provided by XR_META_performance_metrics
XrResult xrQueryPerformanceMetricsCounterMETA(
XrSession session,
XrPath counterPath,
XrPerformanceMetricsCounterMETA* counter);
Parameters
Description
The xrQueryPerformanceMetricsCounterMETA function queries a performance metrics counter.
The application should enable the performance metrics system (by calling
xrSetPerformanceMetricsStateMETA) before querying metrics using
xrQueryPerformanceMetricsCounterMETA.
If the performance metrics system has not been enabled before calling
xrQueryPerformanceMetricsCounterMETA, the runtime must return
XR_ERROR_VALIDATION_FAILURE
.
If counterPath
is not in the list returned by
xrEnumeratePerformanceMetricsCounterPathsMETA, the runtime must return
XR_ERROR_PATH_UNSUPPORTED
.
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrQuerySpacesFB(3)
Name
xrQuerySpacesFB - Queries for spatial entities
C Specification
The xrQuerySpacesFB function is defined as:
// Provided by XR_FB_spatial_entity_query
XrResult xrQuerySpacesFB(
XrSession session,
const XrSpaceQueryInfoBaseHeaderFB* info,
XrAsyncRequestIdFB* requestId);
Parameters
Description
The xrQuerySpacesFB function enables an application to find and
retrieve spatial entities from storage.
Cast an XrSpaceQueryInfoFB pointer to a
XrSpaceQueryInfoBaseHeaderFB pointer to pass as info
.
The application should keep the returned requestId
for the duration
of the request as it is used to refer to the request when calling
xrRetrieveSpaceQueryResultsFB and is used to map completion events to
the request.
This operation is asynchronous and the runtime must post an
XrEventDataSpaceQueryCompleteFB event when the operation completes
successfully or encounters an error.
The runtime must post an XrEventDataSpaceQueryResultsAvailableFB if
before XrEventDataSpaceQueryCompleteFB if any results are found.
Once an XrEventDataSpaceQueryResultsAvailableFB event has been posted,
the application may call xrRetrieveSpaceQueryResultsFB to retrieve
the available results.
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrQuerySystemTrackedKeyboardFB(3)
Name
xrQuerySystemTrackedKeyboardFB - Queries the system keyboard
C Specification
The xrQuerySystemTrackedKeyboardFB function is defined as:
// Provided by XR_FB_keyboard_tracking
XrResult xrQuerySystemTrackedKeyboardFB(
XrSession session,
const XrKeyboardTrackingQueryFB* queryInfo,
XrKeyboardTrackingDescriptionFB* keyboard);
Parameters
Description
The xrQuerySystemTrackedKeyboardFB function populates an XrKeyboardTrackingDescriptionFB structure with enough information to describe a keyboard that the system can locate.
See Also
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrReleaseSwapchainImage(3)
Name
xrReleaseSwapchainImage - Release a swapchain image
C Specification
The xrReleaseSwapchainImage function is defined as:
// Provided by XR_VERSION_1_0
XrResult xrReleaseSwapchainImage(
XrSwapchain swapchain,
const XrSwapchainImageReleaseInfo* releaseInfo);
Parameters
Description
If the swapchain
was created with the
XR_SWAPCHAIN_CREATE_STATIC_IMAGE_BIT
set in
XrSwapchainCreateInfo::createFlags
structure, this function
must not have been previously called for this swapchain.
The runtime must return XR_ERROR_CALL_ORDER_INVALID
if no image has
been waited on by calling xrWaitSwapchainImage.
See Also
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrRequestDisplayRefreshRateFB(3)
Name
xrRequestDisplayRefreshRateFB - Request a display refresh rate
C Specification
The xrRequestDisplayRefreshRateFB function is defined as:
// Provided by XR_FB_display_refresh_rate
XrResult xrRequestDisplayRefreshRateFB(
XrSession session,
float displayRefreshRate);
Parameters
Description
xrRequestDisplayRefreshRateFB provides a mechanism for an application
to request the system to dynamically change the display refresh rate to the
application preferred value.
The runtime must return XR_ERROR_DISPLAY_REFRESH_RATE_UNSUPPORTED_FB
if displayRefreshRate
is not either 0.0f
or one of the values
enumerated by xrEnumerateDisplayRefreshRatesFB.
A display refresh rate of 0.0f
indicates the application has no
preference.
Note that this is only a request and does not guarantee the system will switch to the requested display refresh rate.
See Also
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrRequestExitSession(3)
Name
xrRequestExitSession - Request to exit a running session.
C Specification
When an application wishes to exit a running session,
it can call xrRequestExitSession, requesting that the runtime
transition through the various intermediate session states including
XR_SESSION_STATE_STOPPING
to XR_SESSION_STATE_EXITING
.
On platforms where an application’s lifecycle is managed by the system, session state changes may be implicitly triggered by application lifecycle state changes. On such platforms, using platform-specific methods to alter application lifecycle state may be the preferred method of provoking session state changes. The behavior of xrRequestExitSession is not altered, however explicit session exit may not interact with the platform-specific application lifecycle.
The xrRequestExitSession function is defined as:
// Provided by XR_VERSION_1_0
XrResult xrRequestExitSession(
XrSession session);
Parameters
Description
If session
is not running when
xrRequestExitSession is called, XR_ERROR_SESSION_NOT_RUNNING
must be returned.
See Also
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrResultToString(3)
Name
xrResultToString - Converts an XrResult to a UTF-8 string
C Specification
// Provided by XR_VERSION_1_0
XrResult xrResultToString(
XrInstance instance,
XrResult value,
char buffer[XR_MAX_RESULT_STRING_SIZE]);
Parameters
Description
Returns the text version of the provided XrResult value as a UTF-8 string.
In all cases the returned string must be one of:
See Also
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrRetrieveSpaceQueryResultsFB(3)
Name
xrRetrieveSpaceQueryResultsFB - Copies query results into an output buffer
C Specification
The xrRetrieveSpaceQueryResultsFB function is defined as:
// Provided by XR_FB_spatial_entity_query
XrResult xrRetrieveSpaceQueryResultsFB(
XrSession session,
XrAsyncRequestIdFB requestId,
XrSpaceQueryResultsFB* results);
Parameters
Description
Allows an application to retrieve all available results for a specified
query.
Call this function once to get the number of results found and then once
more to copy the results into a buffer provided by the application.
The number of results will not change between the two calls used to retrieve
results.
This function must only retrieve each query result once.
After the application has used this function to retrieve a query result, the
runtime frees its copy.
The runtime must return XR_ERROR_VALIDATION_FAILURE
if
requestId
refers to a request that is not yet complete, a request for
which results have already been retrieved, or if requestId
does not
refer to a known request.
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrSaveSpaceFB(3)
Name
xrSaveSpaceFB - Saves a spatial entity to persistent storage
C Specification
The xrSaveSpaceFB function is defined as:
// Provided by XR_FB_spatial_entity_storage
XrResult xrSaveSpaceFB(
XrSession session,
const XrSpaceSaveInfoFB* info,
XrAsyncRequestIdFB* requestId);
Parameters
Description
The xrSaveSpaceFB function persists the spatial entity at the
specified location with the specified mode.
The runtime must return XR_ERROR_VALIDATION_FAILURE
if
XrSpaceSaveInfoFB::space
is XR_NULL_HANDLE or otherwise
invalid.
The runtime must return XR_ERROR_VALIDATION_FAILURE
if
XrSpaceSaveInfoFB::location
or
XrSpaceSaveInfoFB::persistenceMode
is invalid.
This operation is asynchronous and the runtime must post an
XrEventDataSpaceSaveCompleteFB event when the operation completes
successfully or encounters an error.
See Also
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrSessionBeginDebugUtilsLabelRegionEXT(3)
Name
xrSessionBeginDebugUtilsLabelRegionEXT - Session begin debug utils label region
C Specification
// Provided by XR_EXT_debug_utils
XrResult xrSessionBeginDebugUtilsLabelRegionEXT(
XrSession session,
const XrDebugUtilsLabelEXT* labelInfo);
Parameters
Description
The xrSessionBeginDebugUtilsLabelRegionEXT function begins a label
region within session
.
See Also
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrSessionEndDebugUtilsLabelRegionEXT(3)
Name
xrSessionEndDebugUtilsLabelRegionEXT - Session end debug utils label region
C Specification
// Provided by XR_EXT_debug_utils
XrResult xrSessionEndDebugUtilsLabelRegionEXT(
XrSession session);
Parameters
Description
This function ends the last label region begun with the
xrSessionBeginDebugUtilsLabelRegionEXT function within the same
session
.
See Also
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrSessionInsertDebugUtilsLabelEXT(3)
Name
xrSessionInsertDebugUtilsLabelEXT - Session insert debug utils label
C Specification
// Provided by XR_EXT_debug_utils
XrResult xrSessionInsertDebugUtilsLabelEXT(
XrSession session,
const XrDebugUtilsLabelEXT* labelInfo);
Parameters
Description
The xrSessionInsertDebugUtilsLabelEXT function inserts an individual
label within session
.
The individual labels are useful for different reasons based on the type of
debugging scenario.
When used with something active like a profiler or debugger, it identifies a
single point of time.
When used with logging, the individual label identifies that a particular
location has been passed at the point the log message is triggered.
Because of this usage, individual labels only exist in a log until the next
call to any of the label functions:
See Also
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrSetAndroidApplicationThreadKHR(3)
Name
xrSetAndroidApplicationThreadKHR - declare threads to be of a certain priority type
C Specification
To declare a thread to be of a certain XrAndroidThreadTypeKHR type call:
// Provided by XR_KHR_android_thread_settings
XrResult xrSetAndroidApplicationThreadKHR(
XrSession session,
XrAndroidThreadTypeKHR threadType,
uint32_t threadId);
Parameters
Description
xrSetAndroidApplicationThreadKHR allows to declare an XR-critical thread and to classify it.
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrSetColorSpaceFB(3)
Name
xrSetColorSpaceFB - Set a color space
C Specification
The xrSetColorSpaceFB function is defined as:
// Provided by XR_FB_color_space
XrResult xrSetColorSpaceFB(
XrSession session,
const XrColorSpaceFB colorspace);
Parameters
Description
xrSetColorSpaceFB provides a mechanism for an application to specify
the color space used in the final rendered frame.
If this function is not called, the session will use the color space deemed
appropriate by the runtime.
Oculus HMDs for both PC and Mobile product lines default to
XR_COLOR_SPACE_RIFT_CV1_FB
.
The runtime must return XR_ERROR_COLOR_SPACE_UNSUPPORTED_FB
if
colorSpace
is not one of the values enumerated by
xrEnumerateColorSpacesFB.
Formal definitions of color spaces contain a number of aspects such as gamma
correction, max luminance and more.
However, xrSetColorSpaceFB will only affect the color gamut of the
output by transforming the color gamut from the source (defined by the
colorSpace
parameter) to the HMD display’s color gamut (defined by the
hardware internally).
This call will not affect gamma correction, leaving that to follow the GPU
texture format standards.
Luminance, tonemapping, and other aspects of the color space will also
remain unaffected.
For more info on color management in Oculus HMDs, please refer to this guide: Color Management in Oculus Headsets
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrSetDebugUtilsObjectNameEXT(3)
Name
xrSetDebugUtilsObjectNameEXT - Sets debug utils object name
C Specification
// Provided by XR_EXT_debug_utils
XrResult xrSetDebugUtilsObjectNameEXT(
XrInstance instance,
const XrDebugUtilsObjectNameInfoEXT* nameInfo);
Parameters
Description
Applications may change the name associated with an object simply by
calling xrSetDebugUtilsObjectNameEXT again with a new string.
If XrDebugUtilsObjectNameInfoEXT::objectName
is an empty string,
then any previously set name is removed.
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrSetDigitalLensControlALMALENCE(3)
Name
xrSetDigitalLensControlALMALENCE - Sets DLVR status
C Specification
The xrSetDigitalLensControlALMALENCE function is defined as:
// Provided by XR_ALMALENCE_digital_lens_control
XrResult xrSetDigitalLensControlALMALENCE(
XrSession session,
const XrDigitalLensControlALMALENCE* digitalLensControl);
Parameters
Description
xrSetDigitalLensControlALMALENCE handles state of Digital Lens API Layer
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrSetEnvironmentDepthEstimationVARJO(3)
Name
xrSetEnvironmentDepthEstimationVARJO - Enable or disable environment depth estimation functionality
C Specification
The xrSetEnvironmentDepthEstimationVARJO function is defined as:
// Provided by XR_VARJO_environment_depth_estimation
XrResult xrSetEnvironmentDepthEstimationVARJO(
XrSession session,
XrBool32 enabled);
Parameters
Description
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrSetInputDeviceActiveEXT(3)
Name
xrSetInputDeviceActiveEXT - Sets the active state of the input device
C Specification
// Provided by XR_EXT_conformance_automation
XrResult xrSetInputDeviceActiveEXT(
XrSession session,
XrPath interactionProfile,
XrPath topLevelPath,
XrBool32 isActive);
Parameters
Description
See Also
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrSetInputDeviceLocationEXT(3)
Name
xrSetInputDeviceLocationEXT - Sets the effective location of a pose input source on the input device
C Specification
// Provided by XR_EXT_conformance_automation
XrResult xrSetInputDeviceLocationEXT(
XrSession session,
XrPath topLevelPath,
XrPath inputSourcePath,
XrSpace space,
XrPosef pose);
Parameters
Description
See Also
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrSetInputDeviceStateBoolEXT(3)
Name
xrSetInputDeviceStateBoolEXT - Sets the state of a boolean input source on the input device
C Specification
// Provided by XR_EXT_conformance_automation
XrResult xrSetInputDeviceStateBoolEXT(
XrSession session,
XrPath topLevelPath,
XrPath inputSourcePath,
XrBool32 state);
Parameters
Description
See Also
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrSetInputDeviceStateFloatEXT(3)
Name
xrSetInputDeviceStateFloatEXT - Sets the state of a float input source on the input device
C Specification
// Provided by XR_EXT_conformance_automation
XrResult xrSetInputDeviceStateFloatEXT(
XrSession session,
XrPath topLevelPath,
XrPath inputSourcePath,
float state);
Parameters
Description
See Also
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrSetInputDeviceStateVector2fEXT(3)
Name
xrSetInputDeviceStateVector2fEXT - Sets the state of a 2D vector input source on the input device
C Specification
// Provided by XR_EXT_conformance_automation
XrResult xrSetInputDeviceStateVector2fEXT(
XrSession session,
XrPath topLevelPath,
XrPath inputSourcePath,
XrVector2f state);
Parameters
Description
See Also
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrSetMarkerTrackingPredictionVARJO(3)
Name
xrSetMarkerTrackingPredictionVARJO - Sets marker tracking with prediction
C Specification
The xrSetMarkerTrackingPredictionVARJO function is defined as:
// Provided by XR_VARJO_marker_tracking
XrResult xrSetMarkerTrackingPredictionVARJO(
XrSession session,
uint64_t markerId,
XrBool32 enabled);
Parameters
Description
The xrSetMarkerTrackingPredictionVARJO function enables or disables
the prediction feature for a specified marker.
By default, markers are created with disabled prediction.
This works well for markers that are supposed to be stationary.
The prediction can be used to improve tracking of movable markers.
The runtime must return XR_ERROR_MARKER_ID_INVALID_VARJO
if the
supplied markerId
is invalid.
See Also
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrSetMarkerTrackingTimeoutVARJO(3)
Name
xrSetMarkerTrackingTimeoutVARJO - Sets marker lifetime duration
C Specification
The xrSetMarkerTrackingTimeoutVARJO function is defined as:
// Provided by XR_VARJO_marker_tracking
XrResult xrSetMarkerTrackingTimeoutVARJO(
XrSession session,
uint64_t markerId,
XrDuration timeout);
Parameters
Description
The xrSetMarkerTrackingTimeoutVARJO function sets a desired lifetime
duration for a specified marker.
The default value is XR_NO_DURATION.
Negative value will be clamped to XR_NO_DURATION.
It defines the time period during which the runtime must keep returning
poses of previously tracked markers.
The tracking may be lost if the marker went outside of the trackable field
of view.
In this case the runtime still will try to predict marker’s pose for the
timeout period.
The runtime must return XR_ERROR_MARKER_ID_INVALID_VARJO
if the
supplied markerId
is invalid.
See Also
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrSetMarkerTrackingVARJO(3)
Name
xrSetMarkerTrackingVARJO - Enables marker tracking
C Specification
The xrSetMarkerTrackingVARJO function is defined as:
// Provided by XR_VARJO_marker_tracking
XrResult xrSetMarkerTrackingVARJO(
XrSession session,
XrBool32 enabled);
Parameters
Description
The xrSetMarkerTrackingVARJO function enables or disables marker tracking functionality. As soon as feature is become disabled all trackable markers become inactive and corresponding events will be generated. An application may call any of the functions in this extension regardless if the marker tracking functionality is enabled or disabled.
See Also
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrSetPerformanceMetricsStateMETA(3)
Name
xrSetPerformanceMetricsStateMETA - Enable/disable performance metrics
C Specification
The xrSetPerformanceMetricsStateMETA function is defined as:
// Provided by XR_META_performance_metrics
XrResult xrSetPerformanceMetricsStateMETA(
XrSession session,
const XrPerformanceMetricsStateMETA* state);
Parameters
Description
The xrSetPerformanceMetricsStateMETA function enables or disables the performance metrics system.
See Also
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2022 The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.
xrSetSpaceComponentStatusFB(3)
Name
xrSetSpaceComponentStatusFB - Enables or disables supported component interfaces for an entity
C Specification
The xrSetSpaceComponentStatusFB function is defined as:
// Provided by XR_FB_spatial_entity
XrResult xrSetSpaceComponentStatusFB(
XrSpace space,
const XrSpaceComponentStatusSetInfoFB* info,
XrAsyncRequestIdFB* requestId);