From 314df7c228f52807da776997b8cce37ad7a780e0 Mon Sep 17 00:00:00 2001 From: yl Date: Tue, 3 Aug 2021 22:06:17 -0700 Subject: [PATCH] Update to OpenXR SDK 1.0.18 --- .gitattributes | 2 +- openxr_preview/include/openxr/openxr.h | 181 +- .../include/openxr/openxr_platform.h | 16 + .../include/openxr/openxr_reflection.h | 119 +- openxr_preview/specs/openxr.html | 4403 +++++++++++++---- samples/BasicXrApp/OpenXrProgram.cpp | 42 + .../Scene_EyeGazeInteraction.cpp | 2 +- samples/SampleSceneUwp/Main.cpp | 4 + samples/SampleSceneUwp/Scene_Orbit.cpp | 20 +- samples/SampleSceneWin32/Main.cpp | 13 +- .../Scene_ControllerActions.cpp | 113 +- .../Scene_ControllerModel.cpp | 3 +- .../SampleSceneWin32/Scene_TrackingState.cpp | 4 +- .../SceneUnderstandingUwp/Scene_Placement.cpp | 4 +- samples/ThreeSpacesUwp/Scene_ThreeSpaces.cpp | 2 +- shared/SampleShared/SampleShared_uwp.vcxproj | 5 + .../SampleShared/SampleShared_win32.vcxproj | 5 + .../XrActionContext.h | 42 +- .../XrInstanceContext.h | 25 +- .../XrSessionContext.h | 12 +- .../XrSystemContext.h | 22 +- .../XrViewConfiguration.h | 4 +- shared/XrSceneLib/Context.h | 18 +- shared/XrSceneLib/ProjectionLayer.cpp | 2 +- shared/XrSceneLib/ProjectionLayer.h | 2 +- shared/XrSceneLib/Scene.h | 6 +- shared/XrSceneLib/XrApp.cpp | 60 +- shared/XrSceneLib/XrApp.h | 1 + shared/XrSceneLib/pch.h | 3 + shared/XrUtility/XrExtensionContext.h | 2 +- shared/XrUtility/XrExtensions.h | 2 +- shared/XrUtility/XrSide.h | 8 +- shared/ext/fmt/format.h | 8 +- shared/ext/fmt/os.h | 4 +- 34 files changed, 3979 insertions(+), 1180 deletions(-) rename shared/{XrUtility => SampleShared}/XrActionContext.h (81%) rename shared/{XrUtility => SampleShared}/XrInstanceContext.h (61%) rename shared/{XrUtility => SampleShared}/XrSessionContext.h (93%) rename shared/{XrUtility => SampleShared}/XrSystemContext.h (84%) rename shared/{XrUtility => SampleShared}/XrViewConfiguration.h (98%) diff --git a/.gitattributes b/.gitattributes index 7fc44a2..89b1ddb 100644 --- a/.gitattributes +++ b/.gitattributes @@ -11,4 +11,4 @@ *.cmd text eol=crlf *.sh text eol=lf *.html text eol=lf -*.adoc text eol=lf \ No newline at end of file +*.adoc text eol=lf diff --git a/openxr_preview/include/openxr/openxr.h b/openxr_preview/include/openxr/openxr.h index a9e9aa5..fb1c4a0 100644 --- a/openxr_preview/include/openxr/openxr.h +++ b/openxr_preview/include/openxr/openxr.h @@ -25,7 +25,7 @@ extern "C" { ((((major) & 0xffffULL) << 48) | (((minor) & 0xffffULL) << 32) | ((patch) & 0xffffffffULL)) // OpenXR current version number. -#define XR_CURRENT_API_VERSION XR_MAKE_VERSION(1, 0, 17) +#define XR_CURRENT_API_VERSION XR_MAKE_VERSION(1, 0, 18) #define XR_VERSION_MAJOR(version) (uint16_t)(((uint64_t)(version) >> 48)& 0xffffULL) #define XR_VERSION_MINOR(version) (uint16_t)(((uint64_t)(version) >> 32) & 0xffffULL) @@ -196,11 +196,11 @@ typedef enum XrResult { XR_ERROR_SCENE_COMPUTE_CONSISTENCY_MISMATCH_MSFT = -1000097005, XR_ERROR_DISPLAY_REFRESH_RATE_UNSUPPORTED_FB = -1000101000, XR_ERROR_COLOR_SPACE_UNSUPPORTED_FB = -1000108000, + XR_ERROR_SPATIAL_ANCHOR_NAME_NOT_FOUND_MSFT = -1000142001, + XR_ERROR_SPATIAL_ANCHOR_NAME_INVALID_MSFT = -1000142002, XR_SPATIAL_ANCHOR_EXPORT_DATA_UNAVAILABLE_MSFT = 1000062000, XR_ERROR_SPATIAL_ANCHOR_EXPORT_FAILED_MSFT = -1000062000, XR_ERROR_SPATIAL_ANCHOR_SUFFICIENCY_QUERY_FAILED_MSFT = -1000062001, - XR_ERROR_SPATIAL_ANCHOR_NAME_NOT_FOUND_MSFT = -1000142001, - XR_ERROR_SPATIAL_ANCHOR_NAME_INVALID_MSFT = -1000142002, XR_RESULT_MAX_ENUM = 0x7FFFFFFF } XrResult; @@ -293,6 +293,8 @@ typedef enum XrStructureType { XR_TYPE_COMPOSITION_LAYER_COLOR_SCALE_BIAS_KHR = 1000034000, XR_TYPE_SPATIAL_ANCHOR_CREATE_INFO_MSFT = 1000039000, XR_TYPE_SPATIAL_ANCHOR_SPACE_CREATE_INFO_MSFT = 1000039001, + XR_TYPE_COMPOSITION_LAYER_IMAGE_LAYOUT_FB = 1000040000, + XR_TYPE_COMPOSITION_LAYER_ALPHA_BLEND_FB = 1000041001, XR_TYPE_VIEW_CONFIGURATION_DEPTH_RANGE_EXT = 1000046000, XR_TYPE_GRAPHICS_BINDING_EGL_MNDX = 1000048004, XR_TYPE_SPATIAL_GRAPH_NODE_SPACE_CREATE_INFO_MSFT = 1000049000, @@ -322,6 +324,7 @@ typedef enum XrStructureType { XR_TYPE_COMPOSITION_LAYER_REPROJECTION_INFO_MSFT = 1000066000, XR_TYPE_COMPOSITION_LAYER_REPROJECTION_PLANE_OVERRIDE_MSFT = 1000066001, XR_TYPE_ANDROID_SURFACE_SWAPCHAIN_CREATE_INFO_FB = 1000070000, + XR_TYPE_COMPOSITION_LAYER_SECURE_CONTENT_FB = 1000072000, XR_TYPE_INTERACTION_PROFILE_ANALOG_THRESHOLD_VALVE = 1000079000, XR_TYPE_HAND_JOINTS_MOTION_RANGE_INFO_EXT = 1000080000, XR_TYPE_LOADER_INIT_INFO_ANDROID_KHR = 1000089000, @@ -352,19 +355,23 @@ typedef enum XrStructureType { XR_TYPE_SCENE_DESERIALIZE_INFO_MSFT = 1000098001, XR_TYPE_EVENT_DATA_DISPLAY_REFRESH_RATE_CHANGED_FB = 1000101000, XR_TYPE_SYSTEM_COLOR_SPACE_PROPERTIES_FB = 1000108000, + XR_TYPE_FOVEATION_PROFILE_CREATE_INFO_FB = 1000114000, + XR_TYPE_SWAPCHAIN_CREATE_INFO_FOVEATION_FB = 1000114001, + XR_TYPE_SWAPCHAIN_STATE_FOVEATION_FB = 1000114002, + XR_TYPE_FOVEATION_LEVEL_PROFILE_CREATE_INFO_FB = 1000115000, XR_TYPE_BINDING_MODIFICATIONS_KHR = 1000120000, XR_TYPE_VIEW_LOCATE_FOVEATED_RENDERING_VARJO = 1000121000, XR_TYPE_FOVEATED_VIEW_CONFIGURATION_VIEW_VARJO = 1000121001, XR_TYPE_SYSTEM_FOVEATED_RENDERING_PROPERTIES_VARJO = 1000121002, XR_TYPE_COMPOSITION_LAYER_DEPTH_TEST_VARJO = 1000122000, + XR_TYPE_SPATIAL_ANCHOR_PERSISTENCE_INFO_MSFT = 1000142000, + XR_TYPE_SPATIAL_ANCHOR_FROM_PERSISTED_ANCHOR_CREATE_INFO_MSFT = 1000142001, + XR_TYPE_SWAPCHAIN_IMAGE_FOVEATION_VULKAN_FB = 1000160000, XR_TYPE_SWAPCHAIN_STATE_ANDROID_SURFACE_DIMENSIONS_FB = 1000161000, XR_TYPE_SWAPCHAIN_STATE_SAMPLER_OPENGL_ES_FB = 1000162000, XR_TYPE_SWAPCHAIN_STATE_SAMPLER_VULKAN_FB = 1000163000, XR_TYPE_SPATIAL_ANCHOR_EXPORT_PURPOSE_INFO_MSFT = 1000062000, XR_TYPE_SPATIAL_ANCHOR_EXPORT_SUFFICIENCY_MSFT = 1000062001, - XR_TYPE_SPATIAL_ANCHOR_PERSISTENCE_INFO_MSFT = 1000142000, - XR_TYPE_SPATIAL_ANCHOR_FROM_PERSISTED_ANCHOR_CREATE_INFO_MSFT = 1000142001, - XR_TYPE_SPATIAL_ANCHOR_STORE_CONNECTION_CREATE_INFO_MSFT = 1000142002, XR_TYPE_GRAPHICS_BINDING_VULKAN2_KHR = XR_TYPE_GRAPHICS_BINDING_VULKAN_KHR, XR_TYPE_SWAPCHAIN_IMAGE_VULKAN2_KHR = XR_TYPE_SWAPCHAIN_IMAGE_VULKAN_KHR, XR_TYPE_GRAPHICS_REQUIREMENTS_VULKAN2_KHR = XR_TYPE_GRAPHICS_REQUIREMENTS_VULKAN_KHR, @@ -443,8 +450,9 @@ typedef enum XrObjectType { XR_OBJECT_TYPE_HAND_TRACKER_EXT = 1000051000, XR_OBJECT_TYPE_SCENE_OBSERVER_MSFT = 1000097000, XR_OBJECT_TYPE_SCENE_MSFT = 1000097001, - XR_OBJECT_TYPE_SPATIAL_ANCHOR_NEIGHBORHOOD_DATA_STREAM_MSFT = 1000062000, + XR_OBJECT_TYPE_FOVEATION_PROFILE_FB = 1000114000, XR_OBJECT_TYPE_SPATIAL_ANCHOR_STORE_CONNECTION_MSFT = 1000142000, + XR_OBJECT_TYPE_SPATIAL_ANCHOR_NEIGHBORHOOD_DATA_STREAM_MSFT = 1000062000, XR_OBJECT_TYPE_MAX_ENUM = 0x7FFFFFFF } XrObjectType; typedef XrFlags64 XrInstanceCreateFlags; @@ -486,6 +494,7 @@ static const XrSwapchainUsageFlags XR_SWAPCHAIN_USAGE_TRANSFER_DST_BIT = 0x00000 static const XrSwapchainUsageFlags XR_SWAPCHAIN_USAGE_SAMPLED_BIT = 0x00000020; static const XrSwapchainUsageFlags XR_SWAPCHAIN_USAGE_MUTABLE_FORMAT_BIT = 0x00000040; static const XrSwapchainUsageFlags XR_SWAPCHAIN_USAGE_INPUT_ATTACHMENT_BIT_MND = 0x00000080; +static const XrSwapchainUsageFlags XR_SWAPCHAIN_USAGE_INPUT_ATTACHMENT_BIT_KHR = 0x00000080; // alias of XR_SWAPCHAIN_USAGE_INPUT_ATTACHMENT_BIT_MND typedef XrFlags64 XrCompositionLayerFlags; @@ -1533,6 +1542,11 @@ typedef struct XrBindingModificationsKHR { +#define XR_KHR_swapchain_usage_input_attachment_bit 1 +#define XR_KHR_swapchain_usage_input_attachment_bit_SPEC_VERSION 3 +#define XR_KHR_SWAPCHAIN_USAGE_INPUT_ATTACHMENT_BIT_EXTENSION_NAME "XR_KHR_swapchain_usage_input_attachment_bit" + + #define XR_EXT_performance_settings 1 #define XR_EXT_performance_settings_SPEC_VERSION 3 #define XR_EXT_PERFORMANCE_SETTINGS_EXTENSION_NAME "XR_EXT_performance_settings" @@ -1767,7 +1781,7 @@ typedef struct XrEventDataMainSessionVisibilityChangedEXTX { #define XR_MSFT_spatial_anchor 1 XR_DEFINE_HANDLE(XrSpatialAnchorMSFT) -#define XR_MSFT_spatial_anchor_SPEC_VERSION 1 +#define XR_MSFT_spatial_anchor_SPEC_VERSION 2 #define XR_MSFT_SPATIAL_ANCHOR_EXTENSION_NAME "XR_MSFT_spatial_anchor" typedef struct XrSpatialAnchorCreateInfoMSFT { XrStructureType type; @@ -1806,6 +1820,48 @@ XRAPI_ATTR XrResult XRAPI_CALL xrDestroySpatialAnchorMSFT( #endif /* !XR_NO_PROTOTYPES */ +#define XR_FB_composition_layer_image_layout 1 +#define XR_FB_composition_layer_image_layout_SPEC_VERSION 1 +#define XR_FB_COMPOSITION_LAYER_IMAGE_LAYOUT_EXTENSION_NAME "XR_FB_composition_layer_image_layout" +typedef XrFlags64 XrCompositionLayerImageLayoutFlagsFB; + +// Flag bits for XrCompositionLayerImageLayoutFlagsFB +static const XrCompositionLayerImageLayoutFlagsFB XR_COMPOSITION_LAYER_IMAGE_LAYOUT_VERTICAL_FLIP_BIT_FB = 0x00000001; + +// XrCompositionLayerImageLayoutFB extends XrCompositionLayerBaseHeader +typedef struct XrCompositionLayerImageLayoutFB { + XrStructureType type; + void* XR_MAY_ALIAS next; + XrCompositionLayerImageLayoutFlagsFB flags; +} XrCompositionLayerImageLayoutFB; + + + +#define XR_FB_composition_layer_alpha_blend 1 +#define XR_FB_composition_layer_alpha_blend_SPEC_VERSION 2 +#define XR_FB_COMPOSITION_LAYER_ALPHA_BLEND_EXTENSION_NAME "XR_FB_composition_layer_alpha_blend" + +typedef enum XrBlendFactorFB { + XR_BLEND_FACTOR_ZERO_FB = 0, + XR_BLEND_FACTOR_ONE_FB = 1, + XR_BLEND_FACTOR_SRC_ALPHA_FB = 2, + XR_BLEND_FACTOR_ONE_MINUS_SRC_ALPHA_FB = 3, + XR_BLEND_FACTOR_DST_ALPHA_FB = 4, + XR_BLEND_FACTOR_ONE_MINUS_DST_ALPHA_FB = 5, + XR_BLEND_FACTOR_MAX_ENUM_FB = 0x7FFFFFFF +} XrBlendFactorFB; +// XrCompositionLayerAlphaBlendFB extends XrCompositionLayerBaseHeader +typedef struct XrCompositionLayerAlphaBlendFB { + XrStructureType type; + void* XR_MAY_ALIAS next; + XrBlendFactorFB srcFactorColor; + XrBlendFactorFB dstFactorColor; + XrBlendFactorFB srcFactorAlpha; + XrBlendFactorFB dstFactorAlpha; +} XrCompositionLayerAlphaBlendFB; + + + #define XR_MND_headless 1 #define XR_MND_headless_SPEC_VERSION 2 #define XR_MND_HEADLESS_EXTENSION_NAME "XR_MND_headless" @@ -2391,6 +2447,24 @@ XRAPI_ATTR XrResult XRAPI_CALL xrGetSwapchainStateFB( #endif /* !XR_NO_PROTOTYPES */ +#define XR_FB_composition_layer_secure_content 1 +#define XR_FB_composition_layer_secure_content_SPEC_VERSION 1 +#define XR_FB_COMPOSITION_LAYER_SECURE_CONTENT_EXTENSION_NAME "XR_FB_composition_layer_secure_content" +typedef XrFlags64 XrCompositionLayerSecureContentFlagsFB; + +// Flag bits for XrCompositionLayerSecureContentFlagsFB +static const XrCompositionLayerSecureContentFlagsFB XR_COMPOSITION_LAYER_SECURE_CONTENT_EXCLUDE_LAYER_BIT_FB = 0x00000001; +static const XrCompositionLayerSecureContentFlagsFB XR_COMPOSITION_LAYER_SECURE_CONTENT_REPLACE_LAYER_BIT_FB = 0x00000002; + +// XrCompositionLayerSecureContentFB extends XrCompositionLayerBaseHeader +typedef struct XrCompositionLayerSecureContentFB { + XrStructureType type; + const void* XR_MAY_ALIAS next; + XrCompositionLayerSecureContentFlagsFB flags; +} XrCompositionLayerSecureContentFB; + + + #define XR_VALVE_analog_threshold 1 #define XR_VALVE_analog_threshold_SPEC_VERSION 1 #define XR_VALVE_ANALOG_THRESHOLD_EXTENSION_NAME "XR_VALVE_analog_threshold" @@ -2886,8 +2960,85 @@ XRAPI_ATTR XrResult XRAPI_CALL xrSetColorSpaceFB( #endif /* !XR_NO_PROTOTYPES */ +#define XR_FB_foveation 1 +XR_DEFINE_HANDLE(XrFoveationProfileFB) +#define XR_FB_foveation_SPEC_VERSION 1 +#define XR_FB_FOVEATION_EXTENSION_NAME "XR_FB_foveation" +typedef XrFlags64 XrSwapchainCreateFoveationFlagsFB; + +// Flag bits for XrSwapchainCreateFoveationFlagsFB +static const XrSwapchainCreateFoveationFlagsFB XR_SWAPCHAIN_CREATE_FOVEATION_SCALED_BIN_BIT_FB = 0x00000001; +static const XrSwapchainCreateFoveationFlagsFB XR_SWAPCHAIN_CREATE_FOVEATION_FRAGMENT_DENSITY_MAP_BIT_FB = 0x00000002; + +typedef XrFlags64 XrSwapchainStateFoveationFlagsFB; + +// Flag bits for XrSwapchainStateFoveationFlagsFB + +typedef struct XrFoveationProfileCreateInfoFB { + XrStructureType type; + void* XR_MAY_ALIAS next; +} XrFoveationProfileCreateInfoFB; + +// XrSwapchainCreateInfoFoveationFB extends XrSwapchainCreateInfo +typedef struct XrSwapchainCreateInfoFoveationFB { + XrStructureType type; + void* XR_MAY_ALIAS next; + XrSwapchainCreateFoveationFlagsFB flags; +} XrSwapchainCreateInfoFoveationFB; + +typedef struct XrSwapchainStateFoveationFB { + XrStructureType type; + void* XR_MAY_ALIAS next; + XrSwapchainStateFoveationFlagsFB flags; + XrFoveationProfileFB profile; +} XrSwapchainStateFoveationFB; + +typedef XrResult (XRAPI_PTR *PFN_xrCreateFoveationProfileFB)(XrSession session, const XrFoveationProfileCreateInfoFB* createInfo, XrFoveationProfileFB* profile); +typedef XrResult (XRAPI_PTR *PFN_xrDestroyFoveationProfileFB)(XrFoveationProfileFB profile); + +#ifndef XR_NO_PROTOTYPES +#ifdef XR_EXTENSION_PROTOTYPES +XRAPI_ATTR XrResult XRAPI_CALL xrCreateFoveationProfileFB( + XrSession session, + const XrFoveationProfileCreateInfoFB* createInfo, + XrFoveationProfileFB* profile); + +XRAPI_ATTR XrResult XRAPI_CALL xrDestroyFoveationProfileFB( + XrFoveationProfileFB profile); +#endif /* XR_EXTENSION_PROTOTYPES */ +#endif /* !XR_NO_PROTOTYPES */ + + +#define XR_FB_foveation_configuration 1 +#define XR_FB_foveation_configuration_SPEC_VERSION 1 +#define XR_FB_FOVEATION_CONFIGURATION_EXTENSION_NAME "XR_FB_foveation_configuration" + +typedef enum XrFoveationLevelFB { + XR_FOVEATION_LEVEL_NONE_FB = 0, + XR_FOVEATION_LEVEL_LOW_FB = 1, + XR_FOVEATION_LEVEL_MEDIUM_FB = 2, + XR_FOVEATION_LEVEL_HIGH_FB = 3, + XR_FOVEATION_LEVEL_MAX_ENUM_FB = 0x7FFFFFFF +} XrFoveationLevelFB; + +typedef enum XrFoveationDynamicFB { + XR_FOVEATION_DYNAMIC_DISABLED_FB = 0, + XR_FOVEATION_DYNAMIC_LEVEL_ENABLED_FB = 1, + XR_FOVEATION_DYNAMIC_MAX_ENUM_FB = 0x7FFFFFFF +} XrFoveationDynamicFB; +// XrFoveationLevelProfileCreateInfoFB extends XrFoveationProfileCreateInfoFB +typedef struct XrFoveationLevelProfileCreateInfoFB { + XrStructureType type; + void* XR_MAY_ALIAS next; + XrFoveationLevelFB level; + float verticalOffset; + XrFoveationDynamicFB dynamic; +} XrFoveationLevelProfileCreateInfoFB; + + + #define XR_VARJO_foveated_rendering 1 -#define XR_VARJO_foveated_rendering_SPEC_VERSION 1 +#define XR_VARJO_foveated_rendering_SPEC_VERSION 2 #define XR_VARJO_FOVEATED_RENDERING_EXTENSION_NAME "XR_VARJO_foveated_rendering" // XrViewLocateFoveatedRenderingVARJO extends XrViewLocateInfo typedef struct XrViewLocateFoveatedRenderingVARJO { @@ -2913,7 +3064,7 @@ typedef struct XrSystemFoveatedRenderingPropertiesVARJO { #define XR_VARJO_composition_layer_depth_test 1 -#define XR_VARJO_composition_layer_depth_test_SPEC_VERSION 1 +#define XR_VARJO_composition_layer_depth_test_SPEC_VERSION 2 #define XR_VARJO_COMPOSITION_LAYER_DEPTH_TEST_EXTENSION_NAME "XR_VARJO_composition_layer_depth_test" // XrCompositionLayerDepthTestVARJO extends XrCompositionLayerProjection typedef struct XrCompositionLayerDepthTestVARJO { @@ -2939,13 +3090,11 @@ XRAPI_ATTR XrResult XRAPI_CALL xrSetEnvironmentDepthEstimationVARJO( #endif /* !XR_NO_PROTOTYPES */ -#define XR_MSFT_spatial_anchor_persistence_preview 1 - - XR_DEFINE_HANDLE(XrSpatialAnchorStoreConnectionMSFT) - +#define XR_MSFT_spatial_anchor_persistence 1 +XR_DEFINE_HANDLE(XrSpatialAnchorStoreConnectionMSFT) #define XR_MAX_SPATIAL_ANCHOR_NAME_SIZE_MSFT 256 -#define XR_MSFT_spatial_anchor_persistence_preview_SPEC_VERSION 1 -#define XR_MSFT_SPATIAL_ANCHOR_PERSISTENCE_PREVIEW_EXTENSION_NAME "XR_MSFT_spatial_anchor_persistence_preview" +#define XR_MSFT_spatial_anchor_persistence_SPEC_VERSION 2 +#define XR_MSFT_SPATIAL_ANCHOR_PERSISTENCE_EXTENSION_NAME "XR_MSFT_spatial_anchor_persistence" typedef struct XrSpatialAnchorPersistenceNameMSFT { char name[XR_MAX_SPATIAL_ANCHOR_NAME_SIZE_MSFT]; } XrSpatialAnchorPersistenceNameMSFT; diff --git a/openxr_preview/include/openxr/openxr_platform.h b/openxr_preview/include/openxr/openxr_platform.h index 66f3ff2..dbc49a3 100644 --- a/openxr_preview/include/openxr/openxr_platform.h +++ b/openxr_preview/include/openxr/openxr_platform.h @@ -587,6 +587,22 @@ XRAPI_ATTR XrResult XRAPI_CALL xrGetAudioInputDeviceGuidOculus( #endif /* !XR_NO_PROTOTYPES */ #endif /* XR_USE_PLATFORM_WIN32 */ +#ifdef XR_USE_GRAPHICS_API_VULKAN + +#define XR_FB_foveation_vulkan 1 +#define XR_FB_foveation_vulkan_SPEC_VERSION 1 +#define XR_FB_FOVEATION_VULKAN_EXTENSION_NAME "XR_FB_foveation_vulkan" +// XrSwapchainImageFoveationVulkanFB extends XrSwapchainImageVulkanKHR +typedef struct XrSwapchainImageFoveationVulkanFB { + XrStructureType type; + void* XR_MAY_ALIAS next; + VkImage image; + uint32_t width; + uint32_t height; +} XrSwapchainImageFoveationVulkanFB; + +#endif /* XR_USE_GRAPHICS_API_VULKAN */ + #ifdef XR_USE_PLATFORM_ANDROID #define XR_FB_swapchain_update_state_android_surface 1 diff --git a/openxr_preview/include/openxr/openxr_reflection.h b/openxr_preview/include/openxr/openxr_reflection.h index 1e71337..06bcd4b 100644 --- a/openxr_preview/include/openxr/openxr_reflection.h +++ b/openxr_preview/include/openxr/openxr_reflection.h @@ -100,11 +100,11 @@ XR_ENUM_STR(XrResult); _(XR_ERROR_SCENE_COMPUTE_CONSISTENCY_MISMATCH_MSFT, -1000097005) \ _(XR_ERROR_DISPLAY_REFRESH_RATE_UNSUPPORTED_FB, -1000101000) \ _(XR_ERROR_COLOR_SPACE_UNSUPPORTED_FB, -1000108000) \ + _(XR_ERROR_SPATIAL_ANCHOR_NAME_NOT_FOUND_MSFT, -1000142001) \ + _(XR_ERROR_SPATIAL_ANCHOR_NAME_INVALID_MSFT, -1000142002) \ _(XR_SPATIAL_ANCHOR_EXPORT_DATA_UNAVAILABLE_MSFT, 1000062000) \ _(XR_ERROR_SPATIAL_ANCHOR_EXPORT_FAILED_MSFT, -1000062000) \ _(XR_ERROR_SPATIAL_ANCHOR_SUFFICIENCY_QUERY_FAILED_MSFT, -1000062001) \ - _(XR_ERROR_SPATIAL_ANCHOR_NAME_NOT_FOUND_MSFT, -1000142001) \ - _(XR_ERROR_SPATIAL_ANCHOR_NAME_INVALID_MSFT, -1000142002) \ _(XR_RESULT_MAX_ENUM, 0x7FFFFFFF) #define XR_LIST_ENUM_XrStructureType(_) \ @@ -196,6 +196,8 @@ XR_ENUM_STR(XrResult); _(XR_TYPE_COMPOSITION_LAYER_COLOR_SCALE_BIAS_KHR, 1000034000) \ _(XR_TYPE_SPATIAL_ANCHOR_CREATE_INFO_MSFT, 1000039000) \ _(XR_TYPE_SPATIAL_ANCHOR_SPACE_CREATE_INFO_MSFT, 1000039001) \ + _(XR_TYPE_COMPOSITION_LAYER_IMAGE_LAYOUT_FB, 1000040000) \ + _(XR_TYPE_COMPOSITION_LAYER_ALPHA_BLEND_FB, 1000041001) \ _(XR_TYPE_VIEW_CONFIGURATION_DEPTH_RANGE_EXT, 1000046000) \ _(XR_TYPE_GRAPHICS_BINDING_EGL_MNDX, 1000048004) \ _(XR_TYPE_SPATIAL_GRAPH_NODE_SPACE_CREATE_INFO_MSFT, 1000049000) \ @@ -225,6 +227,7 @@ XR_ENUM_STR(XrResult); _(XR_TYPE_COMPOSITION_LAYER_REPROJECTION_INFO_MSFT, 1000066000) \ _(XR_TYPE_COMPOSITION_LAYER_REPROJECTION_PLANE_OVERRIDE_MSFT, 1000066001) \ _(XR_TYPE_ANDROID_SURFACE_SWAPCHAIN_CREATE_INFO_FB, 1000070000) \ + _(XR_TYPE_COMPOSITION_LAYER_SECURE_CONTENT_FB, 1000072000) \ _(XR_TYPE_INTERACTION_PROFILE_ANALOG_THRESHOLD_VALVE, 1000079000) \ _(XR_TYPE_HAND_JOINTS_MOTION_RANGE_INFO_EXT, 1000080000) \ _(XR_TYPE_LOADER_INIT_INFO_ANDROID_KHR, 1000089000) \ @@ -255,19 +258,23 @@ XR_ENUM_STR(XrResult); _(XR_TYPE_SCENE_DESERIALIZE_INFO_MSFT, 1000098001) \ _(XR_TYPE_EVENT_DATA_DISPLAY_REFRESH_RATE_CHANGED_FB, 1000101000) \ _(XR_TYPE_SYSTEM_COLOR_SPACE_PROPERTIES_FB, 1000108000) \ + _(XR_TYPE_FOVEATION_PROFILE_CREATE_INFO_FB, 1000114000) \ + _(XR_TYPE_SWAPCHAIN_CREATE_INFO_FOVEATION_FB, 1000114001) \ + _(XR_TYPE_SWAPCHAIN_STATE_FOVEATION_FB, 1000114002) \ + _(XR_TYPE_FOVEATION_LEVEL_PROFILE_CREATE_INFO_FB, 1000115000) \ _(XR_TYPE_BINDING_MODIFICATIONS_KHR, 1000120000) \ _(XR_TYPE_VIEW_LOCATE_FOVEATED_RENDERING_VARJO, 1000121000) \ _(XR_TYPE_FOVEATED_VIEW_CONFIGURATION_VIEW_VARJO, 1000121001) \ _(XR_TYPE_SYSTEM_FOVEATED_RENDERING_PROPERTIES_VARJO, 1000121002) \ _(XR_TYPE_COMPOSITION_LAYER_DEPTH_TEST_VARJO, 1000122000) \ + _(XR_TYPE_SPATIAL_ANCHOR_PERSISTENCE_INFO_MSFT, 1000142000) \ + _(XR_TYPE_SPATIAL_ANCHOR_FROM_PERSISTED_ANCHOR_CREATE_INFO_MSFT, 1000142001) \ + _(XR_TYPE_SWAPCHAIN_IMAGE_FOVEATION_VULKAN_FB, 1000160000) \ _(XR_TYPE_SWAPCHAIN_STATE_ANDROID_SURFACE_DIMENSIONS_FB, 1000161000) \ _(XR_TYPE_SWAPCHAIN_STATE_SAMPLER_OPENGL_ES_FB, 1000162000) \ _(XR_TYPE_SWAPCHAIN_STATE_SAMPLER_VULKAN_FB, 1000163000) \ _(XR_TYPE_SPATIAL_ANCHOR_EXPORT_PURPOSE_INFO_MSFT, 1000062000) \ _(XR_TYPE_SPATIAL_ANCHOR_EXPORT_SUFFICIENCY_MSFT, 1000062001) \ - _(XR_TYPE_SPATIAL_ANCHOR_PERSISTENCE_INFO_MSFT, 1000142000) \ - _(XR_TYPE_SPATIAL_ANCHOR_FROM_PERSISTED_ANCHOR_CREATE_INFO_MSFT, 1000142001) \ - _(XR_TYPE_SPATIAL_ANCHOR_STORE_CONNECTION_CREATE_INFO_MSFT, 1000142002) \ _(XR_STRUCTURE_TYPE_MAX_ENUM, 0x7FFFFFFF) #define XR_LIST_ENUM_XrFormFactor(_) \ @@ -335,8 +342,9 @@ XR_ENUM_STR(XrResult); _(XR_OBJECT_TYPE_HAND_TRACKER_EXT, 1000051000) \ _(XR_OBJECT_TYPE_SCENE_OBSERVER_MSFT, 1000097000) \ _(XR_OBJECT_TYPE_SCENE_MSFT, 1000097001) \ - _(XR_OBJECT_TYPE_SPATIAL_ANCHOR_NEIGHBORHOOD_DATA_STREAM_MSFT, 1000062000) \ + _(XR_OBJECT_TYPE_FOVEATION_PROFILE_FB, 1000114000) \ _(XR_OBJECT_TYPE_SPATIAL_ANCHOR_STORE_CONNECTION_MSFT, 1000142000) \ + _(XR_OBJECT_TYPE_SPATIAL_ANCHOR_NEIGHBORHOOD_DATA_STREAM_MSFT, 1000062000) \ _(XR_OBJECT_TYPE_MAX_ENUM, 0x7FFFFFFF) #define XR_LIST_ENUM_XrAndroidThreadTypeKHR(_) \ @@ -376,6 +384,15 @@ XR_ENUM_STR(XrResult); _(XR_PERF_SETTINGS_NOTIF_LEVEL_IMPAIRED_EXT, 75) \ _(XR_PERF_SETTINGS_NOTIFICATION_LEVEL_MAX_ENUM_EXT, 0x7FFFFFFF) +#define XR_LIST_ENUM_XrBlendFactorFB(_) \ + _(XR_BLEND_FACTOR_ZERO_FB, 0) \ + _(XR_BLEND_FACTOR_ONE_FB, 1) \ + _(XR_BLEND_FACTOR_SRC_ALPHA_FB, 2) \ + _(XR_BLEND_FACTOR_ONE_MINUS_SRC_ALPHA_FB, 3) \ + _(XR_BLEND_FACTOR_DST_ALPHA_FB, 4) \ + _(XR_BLEND_FACTOR_ONE_MINUS_DST_ALPHA_FB, 5) \ + _(XR_BLEND_FACTOR_MAX_ENUM_FB, 0x7FFFFFFF) + #define XR_LIST_ENUM_XrSpatialGraphNodeTypeMSFT(_) \ _(XR_SPATIAL_GRAPH_NODE_TYPE_STATIC_MSFT, 1) \ _(XR_SPATIAL_GRAPH_NODE_TYPE_DYNAMIC_MSFT, 2) \ @@ -505,6 +522,18 @@ XR_ENUM_STR(XrResult); _(XR_COLOR_SPACE_ADOBE_RGB_FB, 7) \ _(XR_COLOR_SPACE_MAX_ENUM_FB, 0x7FFFFFFF) +#define XR_LIST_ENUM_XrFoveationLevelFB(_) \ + _(XR_FOVEATION_LEVEL_NONE_FB, 0) \ + _(XR_FOVEATION_LEVEL_LOW_FB, 1) \ + _(XR_FOVEATION_LEVEL_MEDIUM_FB, 2) \ + _(XR_FOVEATION_LEVEL_HIGH_FB, 3) \ + _(XR_FOVEATION_LEVEL_MAX_ENUM_FB, 0x7FFFFFFF) + +#define XR_LIST_ENUM_XrFoveationDynamicFB(_) \ + _(XR_FOVEATION_DYNAMIC_DISABLED_FB, 0) \ + _(XR_FOVEATION_DYNAMIC_LEVEL_ENABLED_FB, 1) \ + _(XR_FOVEATION_DYNAMIC_MAX_ENUM_FB, 0x7FFFFFFF) + #define XR_LIST_BITS_XrInstanceCreateFlags(_) #define XR_LIST_BITS_XrSessionCreateFlags(_) @@ -532,6 +561,7 @@ XR_ENUM_STR(XrResult); _(XR_SWAPCHAIN_USAGE_SAMPLED_BIT, 0x00000020) \ _(XR_SWAPCHAIN_USAGE_MUTABLE_FORMAT_BIT, 0x00000040) \ _(XR_SWAPCHAIN_USAGE_INPUT_ATTACHMENT_BIT_MND, 0x00000080) \ + _(XR_SWAPCHAIN_USAGE_INPUT_ATTACHMENT_BIT_KHR, XR_SWAPCHAIN_USAGE_INPUT_ATTACHMENT_BIT_MND) \ #define XR_LIST_BITS_XrCompositionLayerFlags(_) \ _(XR_COMPOSITION_LAYER_CORRECT_CHROMATIC_ABERRATION_BIT, 0x00000001) \ @@ -570,10 +600,23 @@ XR_ENUM_STR(XrResult); #define XR_LIST_BITS_XrOverlayMainSessionFlagsEXTX(_) \ _(XR_OVERLAY_MAIN_SESSION_ENABLED_COMPOSITION_LAYER_INFO_DEPTH_BIT_EXTX, 0x00000001) \ +#define XR_LIST_BITS_XrCompositionLayerImageLayoutFlagsFB(_) \ + _(XR_COMPOSITION_LAYER_IMAGE_LAYOUT_VERTICAL_FLIP_BIT_FB, 0x00000001) \ + #define XR_LIST_BITS_XrAndroidSurfaceSwapchainFlagsFB(_) \ _(XR_ANDROID_SURFACE_SWAPCHAIN_SYNCHRONOUS_BIT_FB, 0x00000001) \ _(XR_ANDROID_SURFACE_SWAPCHAIN_USE_TIMESTAMPS_BIT_FB, 0x00000002) \ +#define XR_LIST_BITS_XrCompositionLayerSecureContentFlagsFB(_) \ + _(XR_COMPOSITION_LAYER_SECURE_CONTENT_EXCLUDE_LAYER_BIT_FB, 0x00000001) \ + _(XR_COMPOSITION_LAYER_SECURE_CONTENT_REPLACE_LAYER_BIT_FB, 0x00000002) \ + +#define XR_LIST_BITS_XrSwapchainCreateFoveationFlagsFB(_) \ + _(XR_SWAPCHAIN_CREATE_FOVEATION_SCALED_BIN_BIT_FB, 0x00000001) \ + _(XR_SWAPCHAIN_CREATE_FOVEATION_FRAGMENT_DENSITY_MAP_BIT_FB, 0x00000002) \ + +#define XR_LIST_BITS_XrSwapchainStateFoveationFlagsFB(_) + #define XR_LIST_STRUCT_XrApiLayerProperties(_) \ _(type) \ _(next) \ @@ -1336,6 +1379,19 @@ XR_ENUM_STR(XrResult); _(anchor) \ _(poseInAnchorSpace) \ +#define XR_LIST_STRUCT_XrCompositionLayerImageLayoutFB(_) \ + _(type) \ + _(next) \ + _(flags) \ + +#define XR_LIST_STRUCT_XrCompositionLayerAlphaBlendFB(_) \ + _(type) \ + _(next) \ + _(srcFactorColor) \ + _(dstFactorColor) \ + _(srcFactorAlpha) \ + _(dstFactorAlpha) \ + #define XR_LIST_STRUCT_XrViewConfigurationDepthRangeEXT(_) \ _(type) \ _(next) \ @@ -1560,6 +1616,11 @@ XR_ENUM_STR(XrResult); _(type) \ _(next) \ +#define XR_LIST_STRUCT_XrCompositionLayerSecureContentFB(_) \ + _(type) \ + _(next) \ + _(flags) \ + #define XR_LIST_STRUCT_XrInteractionProfileAnalogThresholdVALVE(_) \ _(type) \ _(next) \ @@ -1762,6 +1823,28 @@ XR_ENUM_STR(XrResult); _(next) \ _(colorSpace) \ +#define XR_LIST_STRUCT_XrFoveationProfileCreateInfoFB(_) \ + _(type) \ + _(next) \ + +#define XR_LIST_STRUCT_XrSwapchainCreateInfoFoveationFB(_) \ + _(type) \ + _(next) \ + _(flags) \ + +#define XR_LIST_STRUCT_XrSwapchainStateFoveationFB(_) \ + _(type) \ + _(next) \ + _(flags) \ + _(profile) \ + +#define XR_LIST_STRUCT_XrFoveationLevelProfileCreateInfoFB(_) \ + _(type) \ + _(next) \ + _(level) \ + _(verticalOffset) \ + _(dynamic) \ + #define XR_LIST_STRUCT_XrViewLocateFoveatedRenderingVARJO(_) \ _(type) \ _(next) \ @@ -1798,6 +1881,13 @@ XR_ENUM_STR(XrResult); _(spatialAnchorStore) \ _(spatialAnchorPersistenceName) \ +#define XR_LIST_STRUCT_XrSwapchainImageFoveationVulkanFB(_) \ + _(type) \ + _(next) \ + _(image) \ + _(width) \ + _(height) \ + #define XR_LIST_STRUCT_XrSwapchainStateAndroidSurfaceDimensionsFB(_) \ _(type) \ _(next) \ @@ -1905,6 +1995,8 @@ XR_ENUM_STR(XrResult); _(XrEventDataMainSessionVisibilityChangedEXTX, XR_TYPE_EVENT_DATA_MAIN_SESSION_VISIBILITY_CHANGED_EXTX) \ _(XrSpatialAnchorCreateInfoMSFT, XR_TYPE_SPATIAL_ANCHOR_CREATE_INFO_MSFT) \ _(XrSpatialAnchorSpaceCreateInfoMSFT, XR_TYPE_SPATIAL_ANCHOR_SPACE_CREATE_INFO_MSFT) \ + _(XrCompositionLayerImageLayoutFB, XR_TYPE_COMPOSITION_LAYER_IMAGE_LAYOUT_FB) \ + _(XrCompositionLayerAlphaBlendFB, XR_TYPE_COMPOSITION_LAYER_ALPHA_BLEND_FB) \ _(XrViewConfigurationDepthRangeEXT, XR_TYPE_VIEW_CONFIGURATION_DEPTH_RANGE_EXT) \ _(XrSpatialGraphNodeSpaceCreateInfoMSFT, XR_TYPE_SPATIAL_GRAPH_NODE_SPACE_CREATE_INFO_MSFT) \ _(XrSystemHandTrackingPropertiesEXT, XR_TYPE_SYSTEM_HAND_TRACKING_PROPERTIES_EXT) \ @@ -1933,6 +2025,7 @@ XR_ENUM_STR(XrResult); _(XrSpatialAnchorExportSufficiencyMSFT, XR_TYPE_SPATIAL_ANCHOR_EXPORT_SUFFICIENCY_MSFT) \ _(XrCompositionLayerReprojectionInfoMSFT, XR_TYPE_COMPOSITION_LAYER_REPROJECTION_INFO_MSFT) \ _(XrCompositionLayerReprojectionPlaneOverrideMSFT, XR_TYPE_COMPOSITION_LAYER_REPROJECTION_PLANE_OVERRIDE_MSFT) \ + _(XrCompositionLayerSecureContentFB, XR_TYPE_COMPOSITION_LAYER_SECURE_CONTENT_FB) \ _(XrInteractionProfileAnalogThresholdVALVE, XR_TYPE_INTERACTION_PROFILE_ANALOG_THRESHOLD_VALVE) \ _(XrHandJointsMotionRangeInfoEXT, XR_TYPE_HAND_JOINTS_MOTION_RANGE_INFO_EXT) \ _(XrSceneObserverCreateInfoMSFT, XR_TYPE_SCENE_OBSERVER_CREATE_INFO_MSFT) \ @@ -1958,6 +2051,10 @@ XR_ENUM_STR(XrResult); _(XrSceneDeserializeInfoMSFT, XR_TYPE_SCENE_DESERIALIZE_INFO_MSFT) \ _(XrEventDataDisplayRefreshRateChangedFB, XR_TYPE_EVENT_DATA_DISPLAY_REFRESH_RATE_CHANGED_FB) \ _(XrSystemColorSpacePropertiesFB, XR_TYPE_SYSTEM_COLOR_SPACE_PROPERTIES_FB) \ + _(XrFoveationProfileCreateInfoFB, XR_TYPE_FOVEATION_PROFILE_CREATE_INFO_FB) \ + _(XrSwapchainCreateInfoFoveationFB, XR_TYPE_SWAPCHAIN_CREATE_INFO_FOVEATION_FB) \ + _(XrSwapchainStateFoveationFB, XR_TYPE_SWAPCHAIN_STATE_FOVEATION_FB) \ + _(XrFoveationLevelProfileCreateInfoFB, XR_TYPE_FOVEATION_LEVEL_PROFILE_CREATE_INFO_FB) \ _(XrViewLocateFoveatedRenderingVARJO, XR_TYPE_VIEW_LOCATE_FOVEATED_RENDERING_VARJO) \ _(XrFoveatedViewConfigurationViewVARJO, XR_TYPE_FOVEATED_VIEW_CONFIGURATION_VIEW_VARJO) \ _(XrSystemFoveatedRenderingPropertiesVARJO, XR_TYPE_SYSTEM_FOVEATED_RENDERING_PROPERTIES_VARJO) \ @@ -2065,6 +2162,7 @@ XR_ENUM_STR(XrResult); _(XrVulkanInstanceCreateInfoKHR, XR_TYPE_VULKAN_INSTANCE_CREATE_INFO_KHR) \ _(XrVulkanDeviceCreateInfoKHR, XR_TYPE_VULKAN_DEVICE_CREATE_INFO_KHR) \ _(XrVulkanGraphicsDeviceGetInfoKHR, XR_TYPE_VULKAN_GRAPHICS_DEVICE_GET_INFO_KHR) \ + _(XrSwapchainImageFoveationVulkanFB, XR_TYPE_SWAPCHAIN_IMAGE_FOVEATION_VULKAN_FB) \ _(XrSwapchainStateSamplerVulkanFB, XR_TYPE_SWAPCHAIN_STATE_SAMPLER_VULKAN_FB) \ @@ -2145,6 +2243,8 @@ XR_ENUM_STR(XrResult); _(XR_VARJO_quad_views, 38) \ _(XR_MSFT_unbounded_reference_space, 39) \ _(XR_MSFT_spatial_anchor, 40) \ + _(XR_FB_composition_layer_image_layout, 41) \ + _(XR_FB_composition_layer_alpha_blend, 42) \ _(XR_MND_headless, 43) \ _(XR_OCULUS_android_session_state_enable, 45) \ _(XR_EXT_view_configuration_depth_range, 47) \ @@ -2166,6 +2266,7 @@ XR_ENUM_STR(XrResult); _(XR_HUAWEI_controller_interaction, 70) \ _(XR_FB_android_surface_swapchain_create, 71) \ _(XR_FB_swapchain_update_state, 72) \ + _(XR_FB_composition_layer_secure_content, 73) \ _(XR_VALVE_analog_threshold, 80) \ _(XR_EXT_hand_joints_motion_range, 81) \ _(XR_KHR_loader_init, 89) \ @@ -2180,15 +2281,19 @@ XR_ENUM_STR(XrResult); _(XR_FB_display_refresh_rate, 102) \ _(XR_HTC_vive_cosmos_controller_interaction, 103) \ _(XR_FB_color_space, 109) \ + _(XR_FB_foveation, 115) \ + _(XR_FB_foveation_configuration, 116) \ _(XR_KHR_binding_modification, 121) \ _(XR_VARJO_foveated_rendering, 122) \ _(XR_VARJO_composition_layer_depth_test, 123) \ _(XR_VARJO_environment_depth_estimation, 124) \ - _(XR_MSFT_spatial_anchor_persistence_preview, 143) \ + _(XR_MSFT_spatial_anchor_persistence, 143) \ _(XR_OCULUS_audio_device_guid, 160) \ + _(XR_FB_foveation_vulkan, 161) \ _(XR_FB_swapchain_update_state_android_surface, 162) \ _(XR_FB_swapchain_update_state_opengl_es, 163) \ _(XR_FB_swapchain_update_state_vulkan, 164) \ + _(XR_KHR_swapchain_usage_input_attachment_bit, 166) \ #endif diff --git a/openxr_preview/specs/openxr.html b/openxr_preview/specs/openxr.html index 1eb2409..cdaaa46 100644 --- a/openxr_preview/specs/openxr.html +++ b/openxr_preview/specs/openxr.html @@ -446,9 +446,9 @@

The OpenXR Specification

Copyright (c) 2017-2021, The Khronos Group Inc.
-version 1.0.17, -Wed, 09 Jun 2021 01:33:28 +0000 -
from git branch: master commit: 02bdab75bb56b006a92eeb191de0441a79a6ef9c +version 1.0.18, +Wed, 04 Aug 2021 04:44:59 +0000 +
from git branch: commit: 864bd08fafb489e37b495c22f3f90277a647928e
Table of Contents
@@ -536,8 +536,9 @@

The OpenXR Specification

  • 9. Session
  • 10. Rendering @@ -560,7 +561,7 @@

    The OpenXR Specification

  • 11.8. Action Sources
  • -
  • 12. List of Extensions +
  • 12. List of Current Extensions
  • 13. List of Provisional Extensions @@ -637,6 +644,11 @@

    The OpenXR Specification

  • 13.2. XR_MNDX_egl_enable
  • +
  • 14. List of Deprecated Extensions + +
  • Index
  • @@ -1996,11 +2020,11 @@

    2.8. Return Cod XR_ERROR_SCENE_COMPUTE_CONSISTENCY_MISMATCH_MSFT = -1000097005, XR_ERROR_DISPLAY_REFRESH_RATE_UNSUPPORTED_FB = -1000101000, XR_ERROR_COLOR_SPACE_UNSUPPORTED_FB = -1000108000, + XR_ERROR_SPATIAL_ANCHOR_NAME_NOT_FOUND_MSFT = -1000142001, + XR_ERROR_SPATIAL_ANCHOR_NAME_INVALID_MSFT = -1000142002, XR_SPATIAL_ANCHOR_EXPORT_DATA_UNAVAILABLE_MSFT = 1000062000, XR_ERROR_SPATIAL_ANCHOR_EXPORT_FAILED_MSFT = -1000062000, XR_ERROR_SPATIAL_ANCHOR_SUFFICIENCY_QUERY_FAILED_MSFT = -1000062001, - XR_ERROR_SPATIAL_ANCHOR_NAME_NOT_FOUND_MSFT = -1000142001, - XR_ERROR_SPATIAL_ANCHOR_NAME_INVALID_MSFT = -1000142002, XR_RESULT_MAX_ENUM = 0x7FFFFFFF } XrResult; @@ -2343,20 +2367,20 @@

    2.8. Return Cod

    The color space is not supported by the runtime. (Added by the XR_FB_color_space extension)

    -

    XR_ERROR_SPATIAL_ANCHOR_EXPORT_FAILED_MSFT

    -

    Unable to export the spatial anchor (Added by the XR_MSFT_spatial_anchor_export_preview extension)

    +

    XR_ERROR_SPATIAL_ANCHOR_NAME_NOT_FOUND_MSFT

    +

    A spatial anchor was not found associated with the spatial anchor name provided (Added by the XR_MSFT_spatial_anchor_persistence extension)

    -

    XR_ERROR_SPATIAL_ANCHOR_SUFFICIENCY_QUERY_FAILED_MSFT

    -

    Unable to query the export sufficiency of the spatial anchor (Added by the XR_MSFT_spatial_anchor_export_preview extension)

    +

    XR_ERROR_SPATIAL_ANCHOR_NAME_INVALID_MSFT

    +

    The spatial anchor name provided was not valid (Added by the XR_MSFT_spatial_anchor_persistence extension)

    -

    XR_ERROR_SPATIAL_ANCHOR_NAME_NOT_FOUND_MSFT

    -

    A spatial anchor was not found associated with the spatial anchor name provided (Added by the XR_MSFT_spatial_anchor_persistence_preview extension)

    +

    XR_ERROR_SPATIAL_ANCHOR_EXPORT_FAILED_MSFT

    +

    Unable to export the spatial anchor (Added by the XR_MSFT_spatial_anchor_export_preview extension)

    -

    XR_ERROR_SPATIAL_ANCHOR_NAME_INVALID_MSFT

    -

    The spatial anchor name provided was not valid (Added by the XR_MSFT_spatial_anchor_persistence_preview extension)

    +

    XR_ERROR_SPATIAL_ANCHOR_SUFFICIENCY_QUERY_FAILED_MSFT

    +

    Unable to query the export sufficiency of the spatial anchor (Added by the XR_MSFT_spatial_anchor_export_preview extension)

    @@ -2536,8 +2560,9 @@

    2 XR_OBJECT_TYPE_HAND_TRACKER_EXT = 1000051000, XR_OBJECT_TYPE_SCENE_OBSERVER_MSFT = 1000097000, XR_OBJECT_TYPE_SCENE_MSFT = 1000097001, - XR_OBJECT_TYPE_SPATIAL_ANCHOR_NEIGHBORHOOD_DATA_STREAM_MSFT = 1000062000, + XR_OBJECT_TYPE_FOVEATION_PROFILE_FB = 1000114000, XR_OBJECT_TYPE_SPATIAL_ANCHOR_STORE_CONNECTION_MSFT = 1000142000, + XR_OBJECT_TYPE_SPATIAL_ANCHOR_NEIGHBORHOOD_DATA_STREAM_MSFT = 1000062000, XR_OBJECT_TYPE_MAX_ENUM = 0x7FFFFFFF } XrObjectType; @@ -3968,7 +3993,7 @@

    3.

    Before using an OpenXR runtime, an application must initialize it by -creating a XrInstance object. +creating an XrInstance object. The following functions are useful for gathering information about the API layers and extensions installed on the system and creating the instance.

    @@ -7036,6 +7061,12 @@
    <

    Standard pose identifiers for tracked hands or motion controllers as represented by /user/hand/left and /user/hand/right are:

    +
    +
    +grip axes diagram +
    +
    Figure 2. Example grip and aim poses for generic motion controllers
    +
    + + +
    +

    9.1. Session Lifecycle

    +
    +
    +lifecycle +
    +
    Figure 3. Session Life-cycle
    +
    +
    + + + + + +
    + +
    -

    First, the application creates a session by choosing a system -and a graphics API and calling xrCreateSession, which creates a -session in the XR_SESSION_STATE_IDLE state. -The application then sets up an xrPollEvent loop to monitor for -session state changes delivered through the -XrEventDataSessionStateChanged event. -When the runtime determines that the system is ready to start transitioning -to this session’s XR content, it notifies the application that its session -has moved into the XR_SESSION_STATE_READY state. -When the application is ready to proceed and display its XR content, it +

    A typical XR session coordinates the application and the runtime through +session control functions and session state events.

    +
    +
    +
      +
    1. +

      The application creates a session by choosing a system and a +graphics API and passing them into xrCreateSession. +The newly created session is in the XR_SESSION_STATE_IDLE state.

      +
    2. +
    3. +

      The application then monitors for session state changes via +XrEventDataSessionStateChanged events.

      +
    4. +
    5. +

      When the runtime determines that the system is ready to start +transitioning to this session’s XR content, the application receives a +notification of session state change to XR_SESSION_STATE_READY. +Once the application is also ready to proceed and display its XR content, it calls xrBeginSession and starts its frame loop, -which starts its session running. -While the session is running, the application is expected to continuously -run its frame loop by calling xrWaitFrame, xrBeginFrame and -xrEndFrame each frame, to establish synchronization with the runtime. +which begins a running session.

      +
    6. +
    7. +

      While the session is running, the application is expected to continuously +execute its frame loop by calling xrWaitFrame, xrBeginFrame and +xrEndFrame each frame, establishing synchronization with the runtime. Once the runtime is synchronized with the application’s frame loop and ready -to display its frames, the session will move into the -XR_SESSION_STATE_SYNCHRONIZED state. -For frames where xrWaitFrame returns an XrFrameState with -shouldRender set to true, the application should render its -composition layers and submit them to xrEndFrame. -If the application desires to leave a running session, it should call the -xrRequestExitSession function to request that the runtime transition -its session to the XR_SESSION_STATE_STOPPING state as soon as -possible. -Once the application reaches the XR_SESSION_STATE_STOPPING state, it -can call xrEndSession to stop the XR session, after which the session -will transition through XR_SESSION_STATE_IDLE to the -XR_SESSION_STATE_EXITING state.

      -
    -
    -

    On platforms that have applications with lifecycle 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.

    +to display application’s frames, the session moves into the +XR_SESSION_STATE_SYNCHRONIZED state. +In this state, the submitted frames will not be displayed or visible to the +user yet.

    + +
  • +

    When the runtime intends to display frames from the application, it +notifies with XR_SESSION_STATE_VISIBLE state, and +sets XrFrameState::shouldRender to true in +xrWaitFrame. +The application should render XR content and submit the composition layers +to xrEndFrame.

    +
  • +
  • +

    When the runtime determines the application is eligible to receive XR +inputs, e.g. motion controller or hand tracking inputs, it notifies with +XR_SESSION_STATE_FOCUSED state. +The application can expect to receive active action inputs.

    +
  • +
  • +

    When the runtime determines the application has lost XR input focus, it +moves the session state from XR_SESSION_STATE_FOCUSED to XR_SESSION_STATE_VISIBLE state. +The application may need to change its own internal state while input is +unavailable. +Since the session is still visible, the application needs to render and +submit frames at full frame rate, but may wish to change visually to +indicate its input suspended state. +When the runtime returns XR focus back to the application, it moves the +session state back to XR_SESSION_STATE_FOCUSED.

    +
  • +
  • +

    When the runtime needs to end a running session due +to the user closing or switching the application, the runtime will change +the session state through appropriate intermediate ones and finally to +XR_SESSION_STATE_STOPPING. +When the application receives the XR_SESSION_STATE_STOPPING event, it should stop its frame loop and +then call xrEndSession to tell the runtime to stop +the running session.

    +
  • +
  • +

    After xrEndSession, the runtime transitions the session state to +XR_SESSION_STATE_IDLE. +If the XR session is temporarily paused in the background, the runtime will +keep the session state at XR_SESSION_STATE_IDLE and +later transition the session state back to XR_SESSION_STATE_READY when the XR session is resumed. +If the runtime determines that its use of this XR session has concluded, it +will transition the session state from XR_SESSION_STATE_IDLE to XR_SESSION_STATE_EXITING.

    +
  • +
  • +

    When the application receives the XR_SESSION_STATE_EXITING event, it releases the resources related to +the session and calls xrDestroySession.

    +
  • + +
    +

    A session is considered running after a successful @@ -10448,10 +10540,26 @@

    9. Session

    has to spend resources on sub-systems (tracking etc.) that are no longer needed by the application.

    +
    +

    An application must call xrBeginSession when the session is in the +XR_SESSION_STATE_READY state, or +XR_ERROR_SESSION_NOT_READY will be returned; it must call +xrEndSession when the session is in the XR_SESSION_STATE_STOPPING state, otherwise +XR_ERROR_SESSION_NOT_STOPPING will be returned. +This is to allow the runtimes to seamlessly transition from one +application’s session to another.

    +
    +
    +

    The application can call xrDestroySession at any time during the +session life cycle, however, it must stop using the XrSession handle +immediately in all threads and stop using any related resources. +Therefore, it’s typically undesirable to destroy a +running session and instead it’s recommended to wait for +XR_SESSION_STATE_EXITING to destroy a session.

    -

    9.1. Session Lifecycle

    +

    9.2. Session Creation

    To present graphical content on an output device, OpenXR applications need to pick a graphics API which is supported by the runtime. @@ -10807,7 +10915,7 @@

    9.1.

    -

    9.2. Session Control

    +

    9.3. Session Control

    @@ -11125,6 +11233,23 @@

    9.2. Sess
    +

    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:

    @@ -11149,15 +11274,6 @@

    9.2. Sess

    -

    An application can only call xrEndSession when the session is in the -XR_SESSION_STATE_STOPPING state, which allows runtimes to seamlessly -transition from one application’s session to another. -When an application wishes to exit a running session, -the application can call xrRequestExitSession, requesting that the -runtime transition through the various intermediate session states including -XR_SESSION_STATE_STOPPING to XR_SESSION_STATE_EXITING.

    -
    -

    If session is not running when xrRequestExitSession is called, XR_ERROR_SESSION_NOT_RUNNING must be returned.

    @@ -11225,20 +11341,14 @@

    9.2. Sess

    -

    9.3. Session States

    -
    -
    -lifecycle -
    -
    Figure 2. Session Life-cycle
    -
    +

    9.4. Session States

    While events can be expanded upon, there are a minimum set of lifecycle events which can occur which all OpenXR applications must be aware of. These events are detailed below.

    -

    9.3.1. XrEventDataSessionStateChanged

    +

    9.4.1. XrEventDataSessionStateChanged

    -
    + -
    +

    Receiving the XR_SESSION_STATE_READY state indicates that the runtime desires the application to prepare rendering resources, begin its session and synchronize its frame loop with the runtime. @@ -11421,7 +11531,7 @@

    +

    Receiving the XR_SESSION_STATE_SYNCHRONIZED state indicates that the application has synchronized its frame loop with the runtime, but its frames are not visible to the user. @@ -11436,7 +11546,7 @@

    +

    Receiving the XR_SESSION_STATE_VISIBLE state indicates that the application has synchronized its frame loop with the runtime, and the session’s frames will be visible to the user, but the @@ -11455,7 +11565,7 @@

    +

    Receiving the XR_SESSION_STATE_FOCUSED state indicates that the application has synchronized its frame loop with the runtime, the session’s frames will be visible to the user, and the session @@ -11469,7 +11579,7 @@

    + -
    +

    Receiving the XR_SESSION_STATE_EXITING state indicates the runtime wishes the application to terminate its XR experience, typically due to a user request via a runtime user interface. Applications should gracefully end their process when in this state if they do not have a non-XR user experience.

    -
    @@ -12027,7 +12141,7 @@

    type must be XR_TYPE_SWAPCHAIN_CREATE_INFO

  • -

    next must be NULL or a valid pointer to the next structure in a structure chain. See also: XrAndroidSurfaceSwapchainCreateInfoFB, XrSecondaryViewConfigurationSwapchainCreateInfoMSFT

    +

    next must be NULL or a valid pointer to the next structure in a structure chain. See also: XrAndroidSurfaceSwapchainCreateInfoFB, XrSecondaryViewConfigurationSwapchainCreateInfoMSFT, XrSwapchainCreateInfoFoveationFB

  • createFlags must be 0 or a valid combination of XrSwapchainCreateFlagBits values

    @@ -14436,7 +14550,7 @@

    type must be one of the following XrStructureType values: XR_TYPE_COMPOSITION_LAYER_CUBE_KHR, XR_TYPE_COMPOSITION_LAYER_CYLINDER_KHR, XR_TYPE_COMPOSITION_LAYER_EQUIRECT2_KHR, XR_TYPE_COMPOSITION_LAYER_EQUIRECT_KHR, XR_TYPE_COMPOSITION_LAYER_PROJECTION, XR_TYPE_COMPOSITION_LAYER_QUAD

  • -

    next must be NULL or a valid pointer to the next structure in a structure chain. See also: XrCompositionLayerColorScaleBiasKHR

    +

    next must be NULL or a valid pointer to the next structure in a structure chain. See also: XrCompositionLayerAlphaBlendFB, XrCompositionLayerColorScaleBiasKHR, XrCompositionLayerImageLayoutFB, XrCompositionLayerSecureContentFB

  • layerFlags must be 0 or a valid combination of XrCompositionLayerFlagBits values

    @@ -16143,11 +16257,11 @@

    may vary from device to device or component to component and are left as an implementation detail. If the path refers to the parent of input values instead of to an input -value itself, the runtime must use …/example/path/value instead -of …/example/path if it is available and apply the same -thresholding that would be applied to any scalar input. -If a parent path does not have a …/value subpath, the runtime -must use …/click. +value itself, the runtime must use …/example/path/click instead +of …/example/path if it is available. +If a parent path does not have a …/click subpath, the runtime +must use …/value and apply the same thresholding that would be +applied to any scalar input. In any other situation the runtime may provide an alternate binding for the action or it will be unbound.

  • @@ -16158,6 +16272,8 @@

    must use /example/path/value instead of …/example/path as the source of the value. +If a parent path does not have a …/value subpath, the runtime +must use …/click. If the input value is boolean, the runtime must supply 0.0 or 1.0 as a conversion of the boolean value. In any other situation, the runtime may provide an alternate binding for @@ -19049,7 +19165,7 @@

    11.8. Act

    -

    12. List of Extensions

    +

    12. List of Current Extensions

      @@ -22889,7 +23023,7 @@

      1

      The application is responsible for transitioning the swapchain image back to the resource state and queue availability that the OpenXR runtime requires. If the image is not in a resource state match with the above specifications -the runtime may exhibit undefined behaviour.

      +the runtime may exhibit undefined behavior.

    New Object Types

    @@ -25197,7 +25331,133 @@

    -

    12.18. XR_KHR_visibility_mask

    +

    12.18. XR_KHR_swapchain_usage_input_attachment_bit

    +
    +
    +
    Name String
    +
    +

    XR_KHR_swapchain_usage_input_attachment_bit

    +
    +
    Extension Type
    +
    +

    Instance extension

    +
    +
    Registered Extension Number
    +
    +

    166

    +
    +
    Revision
    +
    +

    3

    +
    +
    Extension and Version Dependencies
    +
    +
    +
      +
    • +

      Requires OpenXR 1.0

      +
    • +
    +
    +
    +
    Last Modified Date
    +
    +

    2021-05-11

    +
    +
    IP Status
    +
    +

    No known IP claims.

    +
    +
    Contributors
    +
    +

    Jakob Bornecrantz, Collabora
    +Ryan Pavlik, Collabora

    +
    +
    +
    +
    +

    Overview

    +
    +
    +

    This extension enables an application to specify that swapchain images +should be created in a way so that they can be used as input attachments. +At the time of writing this bit only affects Vulkan swapchains.

    +
    +
    +

    New Object Types

    +
    +
    +

    New Flag Types

    +
    +
    +

    New Enum Constants

    +
    +
    +

    XrSwapchainUsageFlagBits enumeration is extended with:

    +
    +
    +
      +
    • +

      XR_SWAPCHAIN_USAGE_INPUT_ATTACHMENT_BIT_KHR - indicates that the +image format may be used as an input attachment.

      +
    • +
    +
    +
    +

    New Enums

    +
    +
    +

    New Structures

    +
    +
    +

    New Functions

    +
    +
    +

    Issues

    +
    +
    +

    Version History

    +
    +
    +
      +
    • +

      Revision 1, 2020-07-23 (Jakob Bornecrantz)

      +
      +
        +
      • +

        Initial draft

        +
      • +
      +
      +
    • +
    • +

      Revision 2, 2020-07-24 (Jakob Bornecrantz)

      +
      +
        +
      • +

        Added note about only affecting Vulkan

        +
      • +
      • +

        Changed from MNDX to MND

        +
      • +
      +
      +
    • +
    • +

      Revision 3, 2021-05-11 (Ryan Pavlik)

      +
      +
        +
      • +

        Updated for promotion from MND to KHR

        +
      • +
      +
      +
    • +
    +
    +
    +
    +

    12.19. XR_KHR_visibility_mask

    Name String
    @@ -25686,7 +25946,7 @@

    -

    12.19. XR_KHR_vulkan_enable

    +

    12.20. XR_KHR_vulkan_enable

    Name String
    @@ -25793,8 +26053,8 @@

    Populating an XrGraphicsBindingVulkanKHR with a VkInstance, VkDevice, or VkPhysicalDevice that does not meet the -requirements outlined by this extension may result in undefined behaviour -by the OpenXR runtime.

    +requirements outlined by this extension may result in undefined behavior by +the OpenXR runtime.

    The API version, instance extension, device extension and physical device @@ -25879,7 +26139,7 @@

    The application is responsible for transitioning the swapchain image back to the image layout and queue ownership that the OpenXR runtime requires. If the image is not in a layout compatible with the above specifications the -runtime may exhibit undefined behaviour.

    +runtime may exhibit undefined behavior.

    Swapchain Flag Bits

    @@ -25932,8 +26192,13 @@

    VK_IMAGE_CREATE_MUTABLE_FORMAT_BIT

    +

    XR_SWAPCHAIN_USAGE_INPUT_ATTACHMENT_BIT_KHR + (Added by XR_KHR_swapchain_usage_input_attachment_bit and only available when that extension is enabled)

    +

    VK_IMAGE_USAGE_INPUT_ATTACHMENT_BIT

    + +

    XR_SWAPCHAIN_USAGE_INPUT_ATTACHMENT_BIT_MND - (Added by XR_MND_swapchain_usage_input_attachment_bit and only available when that extension is enabled)

    + (Added by the now deprecated XR_MND_swapchain_usage_input_attachment_bit extension and only available when that extension is enabled)

    VK_IMAGE_USAGE_INPUT_ATTACHMENT_BIT

    @@ -26163,7 +26428,7 @@

    type must be XR_TYPE_SWAPCHAIN_IMAGE_VULKAN_KHR

  • -

    next must be NULL or a valid pointer to the next structure in a structure chain

    +

    next must be NULL or a valid pointer to the next structure in a structure chain. See also: XrSwapchainImageFoveationVulkanFB

  • image must be a valid VkImage value

    @@ -26828,7 +27093,7 @@

  • -

    12.20. XR_KHR_vulkan_enable2

    +

    12.21. XR_KHR_vulkan_enable2

    Name String
    @@ -26884,7 +27149,7 @@

    <

    -

    12.20.1. Overview

    +

    12.21.1. Overview

    This extension enables the use of the Vulkan graphics API in an OpenXR runtime. @@ -26924,7 +27189,7 @@

    12.20.1. Overview

    -

    12.20.2. Initialization

    +

    12.21.2. Initialization

    When operating in Vulkan mode, the OpenXR runtime and the application will share the Vulkan queue described in the XrGraphicsBindingVulkan2KHR @@ -27897,9 +28162,9 @@

    -

    Populating a XrGraphicsBindingVulkan2KHR structure with a member that +

    Populating an XrGraphicsBindingVulkan2KHR structure with a member that does not meet the requirements outlined by this extension may result in -undefined behaviour by the OpenXR runtime.

    +undefined behavior by the OpenXR runtime.

    The requirements outlined in this extension only apply to the @@ -27910,7 +28175,7 @@

    -

    12.20.3. Concurrency

    +

    12.21.3. Concurrency

    Vulkan requires that concurrent access to a VkQueue from multiple threads be externally synchronized. @@ -27944,11 +28209,11 @@

    12.20.3. Concur

    Failure by the application to synchronize access to VkQueue may -result in undefined behaviour in the OpenXR runtime.

    +result in undefined behavior in the OpenXR runtime.

    -

    12.20.4. Swapchain Interactions

    +

    12.21.4. Swapchain Interactions

    Swapchain Images
    @@ -28036,7 +28301,7 @@
    Swapc

    type must be XR_TYPE_SWAPCHAIN_IMAGE_VULKAN_KHR

  • -

    next must be NULL or a valid pointer to the next structure in a structure chain

    +

    next must be NULL or a valid pointer to the next structure in a structure chain. See also: XrSwapchainImageFoveationVulkanFB

  • image must be a valid VkImage value

    @@ -28096,7 +28361,7 @@
    may exhibit undefined behaviour.

    +runtime may exhibit undefined behavior.

  • @@ -28149,8 +28414,13 @@

    VK_IMAGE_CREATE_MUTABLE_FORMAT_BIT

    +

    XR_SWAPCHAIN_USAGE_INPUT_ATTACHMENT_BIT_KHR + (Added by XR_KHR_swapchain_usage_input_attachment_bit and only available when that extension is enabled)

    +

    VK_IMAGE_USAGE_INPUT_ATTACHMENT_BIT

    + +

    XR_SWAPCHAIN_USAGE_INPUT_ATTACHMENT_BIT_MND - (Added by XR_MND_swapchain_usage_input_attachment_bit and only available when that extension is enabled)

    + (Added by the now deprecated XR_MND_swapchain_usage_input_attachment_bit extension and only available when that extension is enabled)

    VK_IMAGE_USAGE_INPUT_ATTACHMENT_BIT

    @@ -28158,7 +28428,7 @@
    -

    12.20.5. Appendix

    +

    12.21.5. Appendix

    Questions
    @@ -28284,7 +28554,7 @@
    Version
    -

    12.21. XR_KHR_vulkan_swapchain_format_list

    +

    12.22. XR_KHR_vulkan_swapchain_format_list

    Name String
    @@ -28499,7 +28769,7 @@

    -

    12.22. XR_KHR_win32_convert_performance_counter_time

    +

    12.23. XR_KHR_win32_convert_performance_counter_time

    Name String
    @@ -28821,7 +29091,7 @@

    -

    12.23. XR_EXT_conformance_automation

    +

    12.24. XR_EXT_conformance_automation

    Name String
    @@ -29606,7 +29876,7 @@

    -

    12.24. XR_EXT_debug_utils

    +

    12.25. XR_EXT_debug_utils

    Name String
    @@ -29682,7 +29952,7 @@

    12.

    -

    12.24.1. Object Debug Annotation

    +

    12.25.1. Object Debug Annotation

    It can be useful for an application to provide its own content relative to a specific OpenXR handle.

    @@ -29708,7 +29978,7 @@
    Object Naming
    -

    12.24.2. Debug Messengers

    +

    12.25.2. Debug Messengers

    OpenXR allows an application to register arbitrary number of callbacks with all the OpenXR components wishing to report debug information. @@ -29731,7 +30001,7 @@

    12.24.2

    -

    12.24.3. Debug Message Categorization

    +

    12.25.3. Debug Message Categorization

    Messages that are triggered by the debug messenger are categorized by their message type and severity. @@ -29882,7 +30152,7 @@

    Message IDs
    -

    12.24.4. Session Labels

    +

    12.25.4. Session Labels

    All OpenXR work is performed inside of an XrSession. There are times that it helps to label areas in your OpenXR session to allow @@ -31692,7 +31962,7 @@

    12.24.4. Se

    -

    12.25. XR_EXT_eye_gaze_interaction

    +

    12.26. XR_EXT_eye_gaze_interaction

    Name String
    @@ -31750,8 +32020,8 @@

    -

    This extension provides a XrPath for getting eye gaze input from an -eye tracker to enable eye gaze interactions.

    +

    This extension provides an XrPath for getting eye gaze input from +an eye tracker to enable eye gaze interactions.

    The intended use for this extension is to provide:

    @@ -31763,7 +32033,7 @@

    XrPath for real time eye tracking that exposes an accurate and +

    an XrPath for real time eye tracking that exposes an accurate and precise eye gaze pose to be used to enable eye gaze interactions.

  • @@ -31779,7 +32049,7 @@

    -

    12.25.1. Eye tracker

    +

    12.26.1. Eye tracker

    An eye tracker is a sensory device that tracks eyes and accurately maps what the user is looking at. @@ -31813,7 +32083,7 @@

    12.25.1. Eye tr

  • -

    12.25.2. Device enumeration

    +

    12.26.2. Device enumeration

    When the eye gaze input extension is enabled an application may pass in a XrSystemEyeGazeInteractionPropertiesEXT structure in next chain @@ -31884,7 +32154,7 @@

    1

    -

    12.25.3. Eye gaze input

    +

    12.26.3. Eye gaze input

    This extension exposes a new interaction profile path /interaction_profiles/ext/eye_gaze_interaction that is valid for @@ -31953,7 +32223,7 @@

    12.25.3. cases such as aiming or targeting, while a sub-nominal eye gaze pose has degraded performance and should not be relied on for all input scenarios. Applications should be very careful when using sub-nominal eye gaze pose, -since the behaviour can vary considerably for different users and +since the behavior can vary considerably for different users and manufacturers, and some manufacturers may not provide sub-nominal eye gaze pose at all.

    @@ -32021,7 +32291,7 @@

    12.25.3.

    -

    12.25.4. Sample code

    +

    12.26.4. Sample code

    The following example code shows how to bind the eye pose to the action system.

    @@ -32127,7 +32397,7 @@

    12.25.4. Sample

    -

    12.26. XR_EXT_hand_joints_motion_range

    +

    12.27. XR_EXT_hand_joints_motion_range

    Name String
    @@ -32369,7 +32639,7 @@

    -

    12.27. XR_EXT_hand_tracking

    +

    12.28. XR_EXT_hand_tracking

    Name String
    @@ -32676,7 +32946,7 @@

    The XrHandTrackerCreateInfoEXT structure describes the information to -create a XrHandTrackerEXT handle.

    +create an XrHandTrackerEXT handle.

    @@ -33117,7 +33387,7 @@

    XrHandJointVelocitiesEXT.

  • -

    isActive is a XrBool32 indicating if the hand tracker is +

    isActive is an XrBool32 indicating if the hand tracker is actively tracking.

  • @@ -33865,7 +34135,7 @@

  • -

    12.28. XR_EXT_hp_mixed_reality_controller

    +

    12.29. XR_EXT_hp_mixed_reality_controller

    Name String
    @@ -34025,7 +34295,7 @@

    -

    12.29. XR_EXT_performance_settings

    +

    12.30. XR_EXT_performance_settings

    Name String
    @@ -34071,7 +34341,7 @@

    -

    12.29.1. Overview

    +

    12.30.1. Overview

    This extension defines an API for the application to give performance hints to the runtime and for the runtime to send performance related notifications @@ -34099,7 +34369,7 @@

    12.29.1. Overview

    -

    12.29.2. Setting Performance Levels Hints

    +

    12.30.2. Setting Performance Levels Hints

    Performance level hint definition
    @@ -34312,7 +34582,7 @@
    - +

    The XR runtime shall provide performance related notifications to the application in the following situations:

    @@ -34837,7 +35107,7 @@
    -

    12.30. XR_EXT_samsung_odyssey_controller

    +

    12.31. XR_EXT_samsung_odyssey_controller

    Name String
    @@ -34942,7 +35212,7 @@

    -

    12.31. XR_EXT_thermal_query

    +

    12.32. XR_EXT_thermal_query

    Name String
    @@ -34987,14 +35257,14 @@

    -

    12.31.1. Overview

    +

    12.32.1. Overview

    This extension provides an API to query a domain’s current thermal warning level and current thermal trend.

    -

    12.31.2. Querying the current thermal level and trend

    +

    12.32.2. Querying the current thermal level and trend

    This query allows to determine the extent and urgency of the needed workload reduction and to verify that the mitigation measures efficiently reduce the @@ -35214,7 +35484,7 @@

    -

    12.32. XR_EXT_view_configuration_depth_range

    +

    12.33. XR_EXT_view_configuration_depth_range

    Name String
    @@ -35422,7 +35692,7 @@

    -

    12.33. XR_EXT_win32_appcontainer_compatible

    +

    12.34. XR_EXT_win32_appcontainer_compatible

    Name String
    @@ -35541,7 +35811,7 @@

    -

    12.34. XR_EPIC_view_configuration_fov

    +

    12.35. XR_EPIC_view_configuration_fov

    Name String
    @@ -35718,7 +35988,7 @@

    -

    12.35. XR_FB_android_surface_swapchain_create

    +

    12.36. XR_FB_android_surface_swapchain_create

    Name String
    @@ -35766,16 +36036,15 @@

    -

    In order to enable the functionality of this extension, you must pass the -name of the extension into xrCreateInstance via the +

    In order to enable the functionality of this extension, the application +must pass the name of the extension into xrCreateInstance via the XrInstanceCreateInfo::enabledExtensionNames parameter as indicated in the Extensions section.

    -

    To specify the additional create flags, you must create a -XrAndroidSurfaceSwapchainCreateInfoFB structure and pass it on the -call to xrCreateSwapchainAndroidSurfaceKHR via the -XrSwapchainCreateInfo structure’s next parameter.

    +

    These additional create flags are specified by attaching a +XrAndroidSurfaceSwapchainCreateInfoFB structure to the next +chain of an XrSwapchainCreateInfo structure.

    New Object Types

    @@ -35958,7 +36227,7 @@

    -

    12.36. XR_FB_color_space

    +

    12.37. XR_FB_color_space

    Name String
    @@ -36022,8 +36291,8 @@

    12.36

    -

    In order to enable the functionality of this extension, you must pass the -name of the extension into xrCreateInstance via the +

    In order to enable the functionality of this extension, the application +must pass the name of the extension into xrCreateInstance via the XrInstanceCreateInfo::enabledExtensionNames parameter as indicated in the Extensions section.

    @@ -36440,7 +36709,7 @@

    12.36 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. -Facebook HMDs for both PC and Mobile product lines default to +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 @@ -36541,12 +36810,12 @@

    12.36

    -
    -
      -
    • -

      A video application may choose a display refresh rate which better matches -the video content playback rate in order to achieve smoother video frames.

      -
    • -
    • -

      An application which can support a higher frame rate may choose to render -at the higher rate to improve the overall perceptual quality, for example, -lower latency and less flicker.

      -
    • -
    +

    This extension provides explicit control over source and destination blend +factors, with separate controls for color and alpha. +When specified, these blend controls supersede the behavior of +XR_COMPOSITION_LAYER_BLEND_TEXTURE_SOURCE_ALPHA_BIT.

    -

    This extension allows:

    +

    When XR_COMPOSITION_LAYER_UNPREMULTIPLIED_ALPHA_BIT is specified, the +source color is unpremultiplied alpha.

    -
    -
      -
    • -

      An application to identify what display refresh rates the session -supports and the current display refresh rate.

      -
    • -
    • -

      An application to request a display refresh rate to indicate its -preference to the runtime.

      -
    • -
    • -

      An application to receive notification of changes to the display refresh -rate which are delivered via events.

      -
    • -
    +
    +

    Like color, destination alpha is initialized to 0 before composition begins.

    -

    In order to enable the functionality of this extension, you must pass the -name of the extension into xrCreateInstance via the +

    In order to enable the functionality of this extension, the application +must pass the name of the extension into xrCreateInstance via the XrInstanceCreateInfo::enabledExtensionNames parameter as indicated in the Extensions section.

    +

    These blend factors are specified by attaching a +XrCompositionLayerAlphaBlendFB structure to the next chain of a +XrCompositionLayerBaseHeader-derived layer structure.

    +
    +

    New Object Types

    -

    XrResult enumeration is extended with:

    -
    -
    -
      -
    • -

      XR_ERROR_DISPLAY_REFRESH_RATE_UNSUPPORTED_FB

      -
    • -
    +

    New Enums

    +
    +
    -

    New Enums

    +

    The possible blend factors are specified by the XrBlendFactorFB +enumeration.

    +
    +
    +

    +
    +
    +
    +
    typedef enum XrBlendFactorFB {
    +    XR_BLEND_FACTOR_ZERO_FB = 0,
    +    XR_BLEND_FACTOR_ONE_FB = 1,
    +    XR_BLEND_FACTOR_SRC_ALPHA_FB = 2,
    +    XR_BLEND_FACTOR_ONE_MINUS_SRC_ALPHA_FB = 3,
    +    XR_BLEND_FACTOR_DST_ALPHA_FB = 4,
    +    XR_BLEND_FACTOR_ONE_MINUS_DST_ALPHA_FB = 5,
    +    XR_BLEND_FACTOR_MAX_ENUM_FB = 0x7FFFFFFF
    +} XrBlendFactorFB;
    +
    +
    +

    New Structures

    @@ -36661,23 +36926,21 @@

    -

    Receiving the XrEventDataDisplayRefreshRateChangedFB event structure -indicates that the display refresh rate has changed.

    -
    -
    -

    The XrEventDataDisplayRefreshRateChangedFB structure is defined as:

    +

    The XrCompositionLayerAlphaBlendFB structure is defined as:

    -
    +

    -
    typedef struct XrEventDataDisplayRefreshRateChangedFB {
    +
    typedef struct XrCompositionLayerAlphaBlendFB {
         XrStructureType    type;
    -    const void*        next;
    -    float              fromDisplayRefreshRate;
    -    float              toDisplayRefreshRate;
    -} XrEventDataDisplayRefreshRateChangedFB;
    + void* next; + XrBlendFactorFB srcFactorColor; + XrBlendFactorFB dstFactorColor; + XrBlendFactorFB srcFactorAlpha; + XrBlendFactorFB dstFactorAlpha; +} XrCompositionLayerAlphaBlendFB;
    @@ -36690,32 +36953,57 @@

    +

    XrCompositionLayerAlphaBlendFB provides applications with explicit +control over source and destination blend factors.

    +

    +
    +

    The XrCompositionLayerAlphaBlendFB structure must be provided in the +next chain of the XrCompositionLayerBaseHeader structure.

    +
    Valid Usage (Implicit)
    @@ -36726,282 +37014,219 @@

    New Functions

    -
    -
    -

    The xrEnumerateDisplayRefreshRatesFB function is defined as:

    -
    -
    -

    -
    -
    -
    -
    XrResult xrEnumerateDisplayRefreshRatesFB(
    -    XrSession                                   session,
    -    uint32_t                                    displayRefreshRateCapacityInput,
    -    uint32_t*                                   displayRefreshRateCountOutput,
    -    float*                                      displayRefreshRates);
    -
    +

    Issues

    -
    -
    -
    Parameter Descriptions
    • -

      session is the session that enumerates the supported display refresh -rates.

      -
    • -
    • -

      displayRefreshRateCapacityInput is the capacity of the -displayRefreshRates, or 0 to retrieve the required capacity.

      -
    • -
    • -

      displayRefreshRateCountOutput is a pointer to the count of -float displayRefreshRates written, or a pointer to the required -capacity in the case that displayRefreshRateCapacityInput is 0.

      -
    • -
    • -

      displayRefreshRates is a pointer to an array of float display -refresh rates, but can be NULL if -displayRefreshRateCapacityInput is 0.

      -
    • +

      Should we add separate blend controls for color and alpha?

      +
      +
      • -

        See Buffer Size Parameters chapter for a -detailed description of retrieving the required displayRefreshRates -size.

        +

        Yes. +New use cases necessitated adding separate blend controls for color and +alpha.

      -
    + +
    -

    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.

    +

    Version History

    -
    -
    -
    Valid Usage (Implicit)
    • -

      The XR_FB_display_refresh_rate extension must be enabled prior to calling xrEnumerateDisplayRefreshRatesFB

      -
    • +

      Revision 1, 2020-06-22 (Gloria Kennickell)

      +
      +
      • -

        session must be a valid XrSession handle

        +

        Initial draft

      • -
      • -

        displayRefreshRateCountOutput must be a pointer to a uint32_t value

        +
      +
    • -

      If displayRefreshRateCapacityInput is not 0, displayRefreshRates must be a pointer to an array of displayRefreshRateCapacityInput float values

      +

      Revision 2, 2020-06-22 (Gloria Kennickell)

      +
      +
        +
      • +

        Provide separate controls for color and alpha blend factors.

      +
    • +
    -
    -
    -
    Return Codes
    +
    +

    12.39. XR_FB_composition_layer_image_layout

    -
    Success
    +
    Name String
    -
    -
      -
    • -

      XR_SUCCESS

      -
    • -
    • -

      XR_SESSION_LOSS_PENDING

      -
    • -
    -
    +

    XR_FB_composition_layer_image_layout

    -
    Failure
    +
    Extension Type
    +
    +

    Instance extension

    +
    +
    Registered Extension Number
    +
    +

    41

    +
    +
    Revision
    +
    +

    1

    +
    +
    Extension and Version Dependencies
    • -

      XR_ERROR_FUNCTION_UNSUPPORTED

      -
    • -
    • -

      XR_ERROR_VALIDATION_FAILURE

      -
    • -
    • -

      XR_ERROR_RUNTIME_FAILURE

      -
    • -
    • -

      XR_ERROR_HANDLE_INVALID

      -
    • -
    • -

      XR_ERROR_INSTANCE_LOST

      -
    • -
    • -

      XR_ERROR_SESSION_LOST

      -
    • -
    • -

      XR_ERROR_SIZE_INSUFFICIENT

      +

      Requires OpenXR 1.0

    +
    Contributors
    +
    +

    Cass Everitt, Facebook
    +Gloria Kennickell, Facebook

    +
    +
    +

    Overview

    +
    +
    +

    This extension does not define a new composition layer type, but rather it +defines parameters that change the interpretation of the image layout, where +the default image layout is dictated by the Graphics API.

    +
    +

    In order to enable the functionality of this extension, you must pass the +name of the extension into xrCreateInstance via the +XrInstanceCreateInfo::enabledExtensionNames parameter as +indicated in the Extensions section.

    +
    +

    New Object Types

    +
    +

    New Flag Types

    -
    -

    The xrGetDisplayRefreshRateFB function is defined as:

    -
    -
    +

    -
    XrResult xrGetDisplayRefreshRateFB(
    -    XrSession                                   session,
    -    float*                                      displayRefreshRate);
    +
    typedef XrFlags64 XrCompositionLayerImageLayoutFlagsFB;
    -
    +
    +
    +
    -
    Parameter Descriptions
    -
    -
      -
    • -

      session is the XrSession to query.

      -
    • -
    • -

      displayRefreshRate is a pointer to a float into which the current -display refresh rate will be placed.

      -
    • -
    +
    +

    +
    +
    +
    +
    // Flag bits for XrCompositionLayerImageLayoutFlagsFB
    +static const XrCompositionLayerImageLayoutFlagsFB XR_COMPOSITION_LAYER_IMAGE_LAYOUT_VERTICAL_FLIP_BIT_FB = 0x00000001;
    -
    -

    xrGetDisplayRefreshRateFB retrieves the current display refresh rate.

    -
    Valid Usage (Implicit)
    +
    Flag Descriptions
    • -

      The XR_FB_display_refresh_rate extension must be enabled prior to calling xrGetDisplayRefreshRateFB

      -
    • -
    • -

      session must be a valid XrSession handle

      -
    • -
    • -

      displayRefreshRate must be a pointer to a float value

      +

      XR_COMPOSITION_LAYER_IMAGE_LAYOUT_VERTICAL_FLIP_BIT_FB indicates the +coordinate origin must be considered flipped vertically.

    -
    -
    -
    Return Codes
    -
    -
    -
    Success
    -
    +
    +

    New Enum Constants

    +
    +
    +

    XrStructureType enumeration is extended with:

    +
    • -

      XR_SUCCESS

      -
    • -
    • -

      XR_SESSION_LOSS_PENDING

      +

      XR_TYPE_COMPOSITION_LAYER_IMAGE_LAYOUT_FB

    -
    -
    Failure
    -
    +
    +

    New Enums

    +
    • -

      XR_ERROR_FUNCTION_UNSUPPORTED

      -
    • -
    • -

      XR_ERROR_VALIDATION_FAILURE

      -
    • -
    • -

      XR_ERROR_RUNTIME_FAILURE

      -
    • -
    • -

      XR_ERROR_HANDLE_INVALID

      -
    • -
    • -

      XR_ERROR_INSTANCE_LOST

      -
    • -
    • -

      XR_ERROR_SESSION_LOST

      +

      XR_COMPOSITION_LAYER_IMAGE_LAYOUT_VERTICAL_FLIP_BIT_FB

    -
    -
    -
    -
    -
    -
    +
    +

    New Structures

    -

    The xrRequestDisplayRefreshRateFB function is defined as:

    +

    The XrCompositionLayerImageLayoutFB structure is defined as:

    -
    +

    -
    XrResult xrRequestDisplayRefreshRateFB(
    -    XrSession                                   session,
    -    float                                       displayRefreshRate);
    +
    typedef struct XrCompositionLayerImageLayoutFB {
    +    XrStructureType                         type;
    +    void*                                   next;
    +    XrCompositionLayerImageLayoutFlagsFB    flags;
    +} XrCompositionLayerImageLayoutFB;
    -
    Parameter Descriptions
    +
    Member Descriptions
    -

    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.

    +

    XrCompositionLayerImageLayoutFB contains additional flags used to +change the interpretation of the image layout for a composition layer.

    -

    Note that this is only a request and does not guarantee the system will -switch to the requested display refresh rate.

    +

    To specify the additional flags, you must create a +XrCompositionLayerImageLayoutFB structure and pass it via the +XrCompositionLayerBaseHeader structure’s next parameter.

    @@ -37009,81 +37234,28 @@

    -

    -
    -
    -
    -
    -
    Return Codes
    -
    -
    -
    Success
    -
    -
    -
      -
    • -

      XR_SUCCESS

      -
    • -
    • -

      XR_SESSION_LOSS_PENDING

      -
    • -
    -
    -
    -
    Failure
    -
    -
    -
    -
    -
    -
    -

    Issues

    +

    New Functions

    -

    Changing the display refresh rate from its system default does not come -without trade-offs. -Increasing the display refresh rate puts more load on the entire system and -can lead to thermal degradation. -Conversely, lowering the display refresh rate can provide better thermal -sustainability but at the cost of more perceptual issues, like higher -latency and flickering.

    +

    Issues

    -
    -

    New Enum Constants

    +
    +
    +
    +

    +
    +
    +
    +
    typedef XrFlags64 XrCompositionLayerSecureContentFlagsFB;
    +
    -
    -

    New Enums

    -
    -

    New Structures

    -
    -

    The XrSwapchainStateBaseHeaderFB structure is defined as:

    -
    -
    +

    -
    typedef struct XrSwapchainStateBaseHeaderFB {
    -    XrStructureType    type;
    -    void*              next;
    -} XrSwapchainStateBaseHeaderFB;
    +
    // Flag bits for XrCompositionLayerSecureContentFlagsFB
    +static const XrCompositionLayerSecureContentFlagsFB XR_COMPOSITION_LAYER_SECURE_CONTENT_EXCLUDE_LAYER_BIT_FB = 0x00000001;
    +static const XrCompositionLayerSecureContentFlagsFB XR_COMPOSITION_LAYER_SECURE_CONTENT_REPLACE_LAYER_BIT_FB = 0x00000002;
    -
    Member Descriptions
    +
    Flag Descriptions
    • -

      type is the XrStructureType of this structure. -This base structure itself has no associated XrStructureType value.

      +

      XR_COMPOSITION_LAYER_SECURE_CONTENT_EXCLUDE_LAYER_BIT_FB — Indicates the layer will only be visible inside the HMD, and not visible to external sources

    • -

      next is NULL or a pointer to the next structure in a structure -chain. -No such structures are defined in core OpenXR or this extension.

      +

      XR_COMPOSITION_LAYER_SECURE_CONTENT_REPLACE_LAYER_BIT_FB — Indicates the layer will be displayed inside the HMD, but replaced by proxy content when written to external sources

    +
    +
    -

    The XrSwapchainStateBaseHeaderFB is a base structure that can be -overridden by a specific XrSwapchainState* child structure.

    +

    New Enum Constants

    +
    +
    +

    XrStructureType enumeration is extended with:

    -
    -
    -
    Valid Usage (Implicit)
    +
    +
    +

    New Enums

    +
    +
    +
    • -

      type must be one of the following XrStructureType values: XR_TYPE_SWAPCHAIN_STATE_ANDROID_SURFACE_DIMENSIONS_FB, XR_TYPE_SWAPCHAIN_STATE_SAMPLER_OPENGL_ES_FB, XR_TYPE_SWAPCHAIN_STATE_SAMPLER_VULKAN_FB

      +

      XR_COMPOSITION_LAYER_SECURE_CONTENT_EXCLUDE_LAYER_BIT_FB

    • -

      next must be NULL or a valid pointer to the next structure in a structure chain

      +

      XR_COMPOSITION_LAYER_SECURE_CONTENT_REPLACE_LAYER_BIT_FB

    -
    -
    -
    -
    -

    New Functions

    +

    New Structures

    -

    The xrUpdateSwapchainFB function is defined as:

    +

    The XrCompositionLayerSecureContentFB structure is defined as:

    -
    +

    -
    XrResult xrUpdateSwapchainFB(
    -    XrSwapchain                                 swapchain,
    -    const XrSwapchainStateBaseHeaderFB*         state);
    +
    typedef struct XrCompositionLayerSecureContentFB {
    +    XrStructureType                           type;
    +    const void*                               next;
    +    XrCompositionLayerSecureContentFlagsFB    flags;
    +} XrCompositionLayerSecureContentFB;
    -
    Parameter Descriptions
    +
    Member Descriptions
    -

    xrUpdateSwapchainFB provides support for an application to update -specific mutable state associated with an XrSwapchain.

    +

    XrCompositionLayerSecureContentFB contains additional flags to +indicate a composition layer contains secure content and must not be written +to external outputs.

    -
    -
    +
    +

    If both XR_COMPOSITION_LAYER_SECURE_CONTENT_EXCLUDE_LAYER_BIT_FB and +XR_COMPOSITION_LAYER_SECURE_CONTENT_REPLACE_LAYER_BIT_FB are set, +XR_COMPOSITION_LAYER_SECURE_CONTENT_EXCLUDE_LAYER_BIT_FB will take +precedence.

    +
    +
    +

    To specify the additional flags, you must create a +XrCompositionLayerSecureContentFB structure and pass it via the +XrCompositionLayerBaseHeader structure’s next parameter.

    +
    +
    +
    +
    Valid Usage (Implicit)
    +
    + +
    +
    +
    +
    +
    +
    +

    New Functions

    +
    +
    +

    Issues

    +
    +
    +

    Version History

    +
    +
    +
      +
    • +

      Revision 1, 2020-06-16 (Gloria Kennickell)

      +
      +
        +
      • +

        Initial draft

        +
      • +
      +
      +
    • +
    +
    +
    +
    +

    12.41. XR_FB_display_refresh_rate

    +
    +
    +
    Name String
    +
    +

    XR_FB_display_refresh_rate

    +
    +
    Extension Type
    +
    +

    Instance extension

    +
    +
    Registered Extension Number
    +
    +

    102

    +
    +
    Revision
    +
    +

    1

    +
    +
    Extension and Version Dependencies
    +
    +
    +
      +
    • +

      Requires OpenXR 1.0

      +
    • +
    +
    +
    +
    Contributors
    +
    +

    Cass Everitt, Facebook
    +Gloria Kennickell, Facebook

    +
    +
    +
    +
    +

    Overview

    +
    +
    +

    On platforms which support dynamically adjusting the display refresh rate, +application developers may request a specific display refresh rate in order +to improve the overall user experience, examples include:

    +
    +
    +
      +
    • +

      A video application may choose a display refresh rate which better matches +the video content playback rate in order to achieve smoother video frames.

      +
    • +
    • +

      An application which can support a higher frame rate may choose to render +at the higher rate to improve the overall perceptual quality, for example, +lower latency and less flicker.

      +
    • +
    +
    +
    +

    This extension allows:

    +
    +
    +
      +
    • +

      An application to identify what display refresh rates the session +supports and the current display refresh rate.

      +
    • +
    • +

      An application to request a display refresh rate to indicate its +preference to the runtime.

      +
    • +
    • +

      An application to receive notification of changes to the display refresh +rate which are delivered via events.

      +
    • +
    +
    +
    +

    In order to enable the functionality of this extension, the application +must pass the name of the extension into xrCreateInstance via the +XrInstanceCreateInfo::enabledExtensionNames parameter as +indicated in the Extensions section.

    +
    +
    +

    New Object Types

    +
    +
    +

    New Flag Types

    +
    +
    +

    New Enum Constants

    +
    +
    +

    XrStructureType enumeration is extended with:

    +
    +
    +
      +
    • +

      XR_TYPE_EVENT_DATA_DISPLAY_REFRESH_RATE_CHANGED_FB

      +
    • +
    +
    +
    +

    XrResult enumeration is extended with:

    +
    +
    +
      +
    • +

      XR_ERROR_DISPLAY_REFRESH_RATE_UNSUPPORTED_FB

      +
    • +
    +
    +
    +

    New Enums

    +
    +
    +

    New Structures

    +
    +
    +
    +
    +

    Receiving the XrEventDataDisplayRefreshRateChangedFB event structure +indicates that the display refresh rate has changed.

    +
    +
    +

    The XrEventDataDisplayRefreshRateChangedFB structure is defined as:

    +
    +
    +

    +
    +
    +
    +
    typedef struct XrEventDataDisplayRefreshRateChangedFB {
    +    XrStructureType    type;
    +    const void*        next;
    +    float              fromDisplayRefreshRate;
    +    float              toDisplayRefreshRate;
    +} XrEventDataDisplayRefreshRateChangedFB;
    +
    +
    +
    +
    +
    Member Descriptions
    +
    +
      +
    • +

      type is the XrStructureType of this structure.

      +
    • +
    • +

      next is NULL or a pointer to the next structure in a structure +chain. +No such structures are defined in core OpenXR or this extension.

      +
    • +
    • +

      fromDisplayRefreshRate is the previous display refresh rate.

      +
    • +
    • +

      toDisplayRefreshRate is the new display refresh rate.

      +
    • +
    +
    +
    +
    +
    +
    +
    Valid Usage (Implicit)
    +
    + +
    +
    +
    +
    +
    +
    +

    New Functions

    +
    +
    +
    +
    +

    The xrEnumerateDisplayRefreshRatesFB function is defined as:

    +
    +
    +

    +
    +
    +
    +
    XrResult xrEnumerateDisplayRefreshRatesFB(
    +    XrSession                                   session,
    +    uint32_t                                    displayRefreshRateCapacityInput,
    +    uint32_t*                                   displayRefreshRateCountOutput,
    +    float*                                      displayRefreshRates);
    +
    +
    +
    +
    +
    Parameter Descriptions
    +
    +
      +
    • +

      session is the session that enumerates the supported display refresh +rates.

      +
    • +
    • +

      displayRefreshRateCapacityInput is the capacity of the +displayRefreshRates, or 0 to retrieve the required capacity.

      +
    • +
    • +

      displayRefreshRateCountOutput is a pointer to the count of +float displayRefreshRates written, or a pointer to the required +capacity in the case that displayRefreshRateCapacityInput is 0.

      +
    • +
    • +

      displayRefreshRates is a pointer to an array of float display +refresh rates, but can be NULL if +displayRefreshRateCapacityInput is 0.

      +
    • +
    • +

      See Buffer Size Parameters chapter for a +detailed description of retrieving the required displayRefreshRates +size.

      +
    • +
    +
    +
    +
    +
    +

    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.

    +
    +
    +
    +
    Valid Usage (Implicit)
    +
    +
      +
    • +

      The XR_FB_display_refresh_rate extension must be enabled prior to calling xrEnumerateDisplayRefreshRatesFB

      +
    • +
    • +

      session must be a valid XrSession handle

      +
    • +
    • +

      displayRefreshRateCountOutput must be a pointer to a uint32_t value

      +
    • +
    • +

      If displayRefreshRateCapacityInput is not 0, displayRefreshRates must be a pointer to an array of displayRefreshRateCapacityInput float values

      +
    • +
    +
    +
    +
    +
    +
    +
    Return Codes
    +
    +
    +
    Success
    +
    +
    +
      +
    • +

      XR_SUCCESS

      +
    • +
    • +

      XR_SESSION_LOSS_PENDING

      +
    • +
    +
    +
    +
    Failure
    +
    +
    +
      +
    • +

      XR_ERROR_FUNCTION_UNSUPPORTED

      +
    • +
    • +

      XR_ERROR_VALIDATION_FAILURE

      +
    • +
    • +

      XR_ERROR_RUNTIME_FAILURE

      +
    • +
    • +

      XR_ERROR_HANDLE_INVALID

      +
    • +
    • +

      XR_ERROR_INSTANCE_LOST

      +
    • +
    • +

      XR_ERROR_SESSION_LOST

      +
    • +
    • +

      XR_ERROR_SIZE_INSUFFICIENT

      +
    • +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    +

    The xrGetDisplayRefreshRateFB function is defined as:

    +
    +
    +

    +
    +
    +
    +
    XrResult xrGetDisplayRefreshRateFB(
    +    XrSession                                   session,
    +    float*                                      displayRefreshRate);
    +
    +
    +
    +
    +
    Parameter Descriptions
    +
    +
      +
    • +

      session is the XrSession to query.

      +
    • +
    • +

      displayRefreshRate is a pointer to a float into which the current +display refresh rate will be placed.

      +
    • +
    +
    +
    +
    +
    +

    xrGetDisplayRefreshRateFB retrieves the current display refresh rate.

    +
    +
    +
    +
    Valid Usage (Implicit)
    +
    + +
    +
    +
    +
    +
    +
    Return Codes
    +
    +
    +
    Success
    +
    +
    +
      +
    • +

      XR_SUCCESS

      +
    • +
    • +

      XR_SESSION_LOSS_PENDING

      +
    • +
    +
    +
    +
    Failure
    +
    +
    +
      +
    • +

      XR_ERROR_FUNCTION_UNSUPPORTED

      +
    • +
    • +

      XR_ERROR_VALIDATION_FAILURE

      +
    • +
    • +

      XR_ERROR_RUNTIME_FAILURE

      +
    • +
    • +

      XR_ERROR_HANDLE_INVALID

      +
    • +
    • +

      XR_ERROR_INSTANCE_LOST

      +
    • +
    • +

      XR_ERROR_SESSION_LOST

      +
    • +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    +

    The xrRequestDisplayRefreshRateFB function is defined as:

    +
    +
    +

    +
    +
    +
    +
    XrResult xrRequestDisplayRefreshRateFB(
    +    XrSession                                   session,
    +    float                                       displayRefreshRate);
    +
    +
    +
    +
    +
    Parameter Descriptions
    +
    + +
    +
    +
    +
    +

    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.

    +
    +
    +
    +
    Valid Usage (Implicit)
    +
    + +
    +
    +
    +
    +
    +
    Return Codes
    +
    +
    +
    Success
    +
    +
    +
      +
    • +

      XR_SUCCESS

      +
    • +
    • +

      XR_SESSION_LOSS_PENDING

      +
    • +
    +
    +
    +
    Failure
    +
    +
    +
      +
    • +

      XR_ERROR_FUNCTION_UNSUPPORTED

      +
    • +
    • +

      XR_ERROR_VALIDATION_FAILURE

      +
    • +
    • +

      XR_ERROR_RUNTIME_FAILURE

      +
    • +
    • +

      XR_ERROR_HANDLE_INVALID

      +
    • +
    • +

      XR_ERROR_INSTANCE_LOST

      +
    • +
    • +

      XR_ERROR_SESSION_LOST

      +
    • +
    • +

      XR_ERROR_FEATURE_UNSUPPORTED

      +
    • +
    • +

      XR_ERROR_DISPLAY_REFRESH_RATE_UNSUPPORTED_FB

      +
    • +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    +

    Issues

    +
    +
    +

    Changing the display refresh rate from its system default does not come +without trade-offs. +Increasing the display refresh rate puts more load on the entire system and +can lead to thermal degradation. +Conversely, lowering the display refresh rate can provide better thermal +sustainability but at the cost of more perceptual issues, like higher +latency and flickering.

    +
    +
    +

    Version History

    +
    +
    +
      +
    • +

      Revision 1, 2020-10-05 (Gloria Kennickell)

      +
      +
        +
      • +

        Initial extension description

        +
      • +
      +
      +
    • +
    +
    +
    +
    +

    12.42. XR_FB_foveation

    +
    +
    +
    Name String
    +
    +

    XR_FB_foveation

    +
    +
    Extension Type
    +
    +

    Instance extension

    +
    +
    Registered Extension Number
    +
    +

    115

    +
    +
    Revision
    +
    +

    1

    +
    +
    Extension and Version Dependencies
    +
    +
    + +
    +
    +
    Contributors
    +
    +

    Kevin Xiao, Facebook
    +Ross Ning, Facebook
    +Remi Palandri, Facebook
    +Cass Everitt, Facebook
    +Gloria Kennickell, Facebook

    +
    +
    +
    +
    +

    Overview

    +
    +
    +

    Foveation in the context of XR is a rendering technique that allows the area +of an image near the focal point or fovea of the eye to be displayed at +higher resolution than areas in the periphery. +This trades some visual fidelity in the periphery, where it is less +noticeable for the user, for improved rendering performance, most notably +regarding the fragment shader, as fewer pixels or subpixels in the periphery +need to be shaded and processed. +On platforms which support foveation patterns and features tailored towards +the optical properties, performance profiles, and hardware support of +specific HMDs, application developers may request and use available +foveation profiles from the runtime. +Foveation profiles refer to a set of properties describing how, when, and +where foveation will be applied.

    +
    +
    +

    This extension allows:

    +
    +
    +
      +
    • +

      An application to create swapchains that can support foveation for its +graphics API.

      +
    • +
    • +

      An application to request foveation profiles supported by the runtime and +apply them to foveation-supported swapchains.

      +
    • +
    +
    +
    +

    In order to enable the functionality of this extension, you must pass the +name of the extension into xrCreateInstance via the +XrInstanceCreateInfo enabledExtensionNames parameter as +indicated in the Extensions section.

    +
    +
    +

    New Object Types

    +
    +
    +
    +
    +

    +
    +
    +
    +
    XR_DEFINE_HANDLE(XrFoveationProfileFB)
    +
    +
    +
    +

    XrFoveationProfileFB represents a set of properties and resources that +define a foveation pattern for the runtime, which can be applied to +individual swapchains.

    +
    +
    +
    +
    +

    New Flag Types

    +
    +
    +
    +
    +

    +
    +
    +
    +
    typedef XrFlags64 XrSwapchainCreateFoveationFlagsFB;
    +
    +
    +
    +
    +
    +
    +
    +

    +
    +
    +
    +
    // Flag bits for XrSwapchainCreateFoveationFlagsFB
    +static const XrSwapchainCreateFoveationFlagsFB XR_SWAPCHAIN_CREATE_FOVEATION_SCALED_BIN_BIT_FB = 0x00000001;
    +static const XrSwapchainCreateFoveationFlagsFB XR_SWAPCHAIN_CREATE_FOVEATION_FRAGMENT_DENSITY_MAP_BIT_FB = 0x00000002;
    +
    +
    +
    +
    +
    Flag Descriptions
    +
    +
      +
    • +

      XR_SWAPCHAIN_CREATE_FOVEATION_SCALED_BIN_BIT_FB — Explicitly create the swapchain with scaled bin foveation support. The application must ensure that the swapchain is using the OpenGL graphics API and that the QCOM_texture_foveated extension is supported and enabled.

      +
    • +
    • +

      XR_SWAPCHAIN_CREATE_FOVEATION_FRAGMENT_DENSITY_MAP_BIT_FB — Explicitly create the swapchain with fragment density map foveation support. The application must ensure that the swapchain is using the Vulkan graphics API and that the VK_EXT_fragment_density_map extension is supported and enabled.

      +
    • +
    +
    +
    +
    +
    +
    +
    +
    +
    +

    +
    +
    +
    +
    typedef XrFlags64 XrSwapchainStateFoveationFlagsFB;
    +
    +
    +
    +
    +
    +
    +
    +

    +
    +
    +
    +
    // Flag bits for XrSwapchainStateFoveationFlagsFB
    +
    +
    +
    +

    There are currently no foveation swapchain state flags. +This is reserved for future use.

    +
    +
    +
    +
    +

    New Enum Constants

    +
    +
    +

    XrObjectType enumeration is extended with:

    +
    +
    +
      +
    • +

      XR_OBJECT_TYPE_FOVEATION_PROFILE_FB

      +
    • +
    +
    +
    +

    XrStructureType enumeration is extended with:

    +
    +
    +
      +
    • +

      XR_TYPE_FOVEATION_PROFILE_CREATE_INFO_FB

      +
    • +
    • +

      XR_TYPE_SWAPCHAIN_CREATE_INFO_FOVEATION_FB

      +
    • +
    • +

      XR_TYPE_SWAPCHAIN_STATE_FOVEATION_FB

      +
    • +
    +
    +
    +

    New Enums

    +
    +
    +

    New Structures

    +
    +
    +
    +
    +

    XrFoveationProfileCreateInfoFB must be provided when calling +xrCreateFoveationProfileFB. +The runtime must interpret XrFoveationProfileCreateInfoFB without any +additional structs in its next chain as a request to create a +foveation profile that will apply no foveation to any area of the swapchain.

    +
    +
    +

    The XrFoveationProfileCreateInfoFB structure is defined as:

    +
    +
    +

    +
    +
    +
    +
    typedef struct XrFoveationProfileCreateInfoFB {
    +    XrStructureType    type;
    +    void*              next;
    +} XrFoveationProfileCreateInfoFB;
    +
    +
    +
    +
    +
    Member Descriptions
    +
    +
      +
    • +

      type is the XrStructureType of this structure.

      +
    • +
    • +

      next is NULL or a pointer to the next structure in a structure +chain. +No such structures are defined in core OpenXR or this extension.

      +
    • +
    +
    +
    +
    +
    +
    +
    Valid Usage (Implicit)
    +
    + +
    +
    +
    +
    +
    +
    +
    +
    +

    XrSwapchainCreateInfoFoveationFB can be provided in the next +chain of XrSwapchainCreateInfo when calling xrCreateSwapchain to +indicate to the runtime that the swapchain must be created with foveation +support in the corresponding graphics API. +XrSwapchainCreateInfoFoveationFB contains additional +foveation-specific flags for swapchain creation.

    +
    +
    +

    The XrSwapchainCreateInfoFoveationFB structure is defined as:

    +
    +
    +

    +
    +
    +
    +
    typedef struct XrSwapchainCreateInfoFoveationFB {
    +    XrStructureType                      type;
    +    void*                                next;
    +    XrSwapchainCreateFoveationFlagsFB    flags;
    +} XrSwapchainCreateInfoFoveationFB;
    +
    +
    +
    +
    +
    Member Descriptions
    +
    +
      +
    • +

      type is the XrStructureType of this structure.

      +
    • +
    • +

      next is NULL or a pointer to the next structure in a structure +chain. +No such structures are defined in core OpenXR or this extension.

      +
    • +
    • +

      flags is a bitmask of XrSwapchainCreateFoveationFlagBitsFB +which indicate various characteristics for how foveation is enabled on the +swapchain.

      +
    • +
    +
    +
    +
    +
    +
    +
    Valid Usage (Implicit)
    +
    + +
    +
    +
    +
    +
    +
    +
    +
    +

    XrSwapchainStateFoveationFB can be provided in place of +XrSwapchainStateBaseHeaderFB when calling xrUpdateSwapchainFB to +update the foveation properties of the swapchain. +XrSwapchainCreateInfoFoveationFB contains the desired foveation +profile and additional foveation specific flags for updating the swapchain.

    +
    +
    +

    The XrSwapchainStateFoveationFB structure is defined as:

    +
    +
    +

    +
    +
    +
    +
    typedef struct XrSwapchainStateFoveationFB {
    +    XrStructureType                     type;
    +    void*                               next;
    +    XrSwapchainStateFoveationFlagsFB    flags;
    +    XrFoveationProfileFB                profile;
    +} XrSwapchainStateFoveationFB;
    +
    +
    +
    +
    +
    Member Descriptions
    +
    +
      +
    • +

      type is the XrStructureType of this structure.

      +
    • +
    • +

      next is NULL or a pointer to the next structure in a structure +chain. +No such structures are defined in core OpenXR or this extension.

      +
    • +
    • +

      flags is a bitmask of XrSwapchainStateFoveationFlagBitsFB +which indicate various characteristics of how and when the foveation +properties of the swapchain must be updated.

      +
    • +
    • +

      profile is an XrFoveationProfileFB defining the desired +foveation properties to be applied to the swapchain.

      +
    • +
    +
    +
    +
    +
    +
    +
    Valid Usage (Implicit)
    +
    + +
    +
    +
    +
    +
    +
    +

    New Functions

    +
    +
    +
    +
    +

    The xrCreateFoveationProfileFB function is defined as:

    +
    +
    +

    +
    +
    +
    +
    XrResult xrCreateFoveationProfileFB(
    +    XrSession                                   session,
    +    const XrFoveationProfileCreateInfoFB*       createInfo,
    +    XrFoveationProfileFB*                       profile);
    +
    +
    +
    +
    +
    Parameter Descriptions
    +
    +
      +
    • +

      session is the XrSession that created the swapchains to which +this foveation profile will be applied.

      +
    • +
    • +

      createInfo is a pointer to an XrFoveationProfileCreateInfoFB +structure containing parameters to be used to create the foveation +profile.

      +
    • +
    • +

      profile is a pointer to a handle in which the created +XrFoveationProfileFB is returned.

      +
    • +
    +
    +
    +
    +
    +

    Creates an XrFoveationProfileFB handle. +The returned foveation profile handle may be subsequently used in API +calls.

    +
    +
    +
    +
    Valid Usage (Implicit)
    +
    + +
    +
    +
    +
    +
    +
    Return Codes
    +
    +
    +
    Success
    +
    +
    +
      +
    • +

      XR_SUCCESS

      +
    • +
    • +

      XR_SESSION_LOSS_PENDING

      +
    • +
    +
    +
    +
    Failure
    +
    +
    +
      +
    • +

      XR_ERROR_FUNCTION_UNSUPPORTED

      +
    • +
    • +

      XR_ERROR_VALIDATION_FAILURE

      +
    • +
    • +

      XR_ERROR_RUNTIME_FAILURE

      +
    • +
    • +

      XR_ERROR_HANDLE_INVALID

      +
    • +
    • +

      XR_ERROR_INSTANCE_LOST

      +
    • +
    • +

      XR_ERROR_SESSION_LOST

      +
    • +
    • +

      XR_ERROR_OUT_OF_MEMORY

      +
    • +
    • +

      XR_ERROR_LIMIT_REACHED

      +
    • +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    +

    The xrDestroyFoveationProfileFB function is defined as:

    +
    +
    +

    +
    +
    +
    +
    XrResult xrDestroyFoveationProfileFB(
    +    XrFoveationProfileFB                        profile);
    +
    +
    +
    +
    +
    Parameter Descriptions
    +
    + +
    +
    +
    +
    +

    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.

    +
    +
    +
    +
    Valid Usage (Implicit)
    +
    + +
    +
    +
    +
    +
    +
    Thread Safety
    +
    +
      +
    • +

      Access to profile, and any child handles, must be externally synchronized

      +
    • +
    +
    +
    +
    +
    +
    +
    Return Codes
    +
    +
    +
    Success
    +
    +
    +
      +
    • +

      XR_SUCCESS

      +
    • +
    +
    +
    +
    Failure
    +
    +
    +
      +
    • +

      XR_ERROR_FUNCTION_UNSUPPORTED

      +
    • +
    • +

      XR_ERROR_RUNTIME_FAILURE

      +
    • +
    • +

      XR_ERROR_HANDLE_INVALID

      +
    • +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    +

    Issues

    +
    +
    +

    Version History

    +
    +
    +
      +
    • +

      Revision 1, 2021-05-13 (Kevin Xiao)

      +
      +
        +
      • +

        Initial extension description

        +
      • +
      +
      +
    • +
    +
    +
    +
    +

    12.43. XR_FB_foveation_configuration

    +
    +
    +
    Name String
    +
    +

    XR_FB_foveation_configuration

    +
    +
    Extension Type
    +
    +

    Instance extension

    +
    +
    Registered Extension Number
    +
    +

    116

    +
    +
    Revision
    +
    +

    1

    +
    +
    Extension and Version Dependencies
    +
    +
    + +
    +
    +
    Contributors
    +
    +

    Kevin Xiao, Facebook
    +Ross Ning, Facebook
    +Remi Palandri, Facebook
    +Cass Everitt, Facebook
    +Gloria Kennickell, Facebook

    +
    +
    +
    +
    +

    Overview

    +
    +
    +

    On Facebook HMDs, developers may create foveation profiles generated by the +runtime for the optical properties and performance profile of the specific +HMD.

    +
    +
    +

    This extension allows:

    +
    +
    +
      +
    • +

      An application to request foveation profiles generated by the runtime for +the current HMD.

      +
    • +
    +
    +
    +

    In order to enable the functionality of this extension, you must pass the +name of the extension into xrCreateInstance via the +XrInstanceCreateInfo enabledExtensionNames parameter as +indicated in the Extensions section.

    +
    +
    +

    New Object Types

    +
    +
    +

    New Flag Types

    +
    +
    +

    New Enum Constants

    +
    +
    +

    XrStructureType enumeration is extended with:

    +
    +
    +
      +
    • +

      XR_TYPE_FOVEATION_LEVEL_PROFILE_CREATE_INFO_FB

      +
    • +
    +
    +
    +

    New Enums

    +
    +
    +
    +
    +

    The possible foveation levels are specified by the XrFoveationLevelFB +enumeration:

    +
    +
    +

    +
    +
    +
    +
    typedef enum XrFoveationLevelFB {
    +    XR_FOVEATION_LEVEL_NONE_FB = 0,
    +    XR_FOVEATION_LEVEL_LOW_FB = 1,
    +    XR_FOVEATION_LEVEL_MEDIUM_FB = 2,
    +    XR_FOVEATION_LEVEL_HIGH_FB = 3,
    +    XR_FOVEATION_LEVEL_MAX_ENUM_FB = 0x7FFFFFFF
    +} XrFoveationLevelFB;
    +
    +
    +
    +
    +
    Enumerant Descriptions
    +
    +
      +
    • +

      XR_FOVEATION_LEVEL_NONE_FB — No foveation

      +
    • +
    • +

      XR_FOVEATION_LEVEL_LOW_FB — Less foveation (higher periphery visual fidelity, lower performance)

      +
    • +
    • +

      XR_FOVEATION_LEVEL_MEDIUM_FB — Medium foveation (medium periphery visual fidelity, medium performance)

      +
    • +
    • +

      XR_FOVEATION_LEVEL_HIGH_FB — High foveation (lower periphery visual fidelity, higher performance)

      +
    • +
    +
    +
    +
    +
    +
    +
    +
    +
    +

    The possible foveation levels are specified by the +XrFoveationDynamicFB enumeration:

    +
    +
    +

    +
    +
    +
    +
    typedef enum XrFoveationDynamicFB {
    +    XR_FOVEATION_DYNAMIC_DISABLED_FB = 0,
    +    XR_FOVEATION_DYNAMIC_LEVEL_ENABLED_FB = 1,
    +    XR_FOVEATION_DYNAMIC_MAX_ENUM_FB = 0x7FFFFFFF
    +} XrFoveationDynamicFB;
    +
    +
    +
    +
    +
    Enumerant Descriptions
    +
    +
      +
    • +

      XR_FOVEATION_DYNAMIC_DISABLED_FB — Static foveation at the maximum desired level

      +
    • +
    • +

      XR_FOVEATION_DYNAMIC_LEVEL_ENABLED_FB — Dynamic changing foveation based on performance headroom available up to the maximum desired level

      +
    • +
    +
    +
    +
    +
    +
    +
    +

    New Structures

    +
    +
    +
    +
    +

    XrFoveationLevelProfileCreateInfoFB can be provided in the next +chain of XrFoveationProfileCreateInfoFB when calling +xrCreateFoveationProfileFB. +The runtime must interpret XrSwapchainCreateInfoFoveationFB with +XrFoveationLevelProfileCreateInfoFB in its next chain as a +request to create a foveation profile that will apply a fixed foveation +pattern according to the parameters defined in the +XrFoveationLevelProfileCreateInfoFB.

    +
    +
    +

    The XrFoveationLevelProfileCreateInfoFB structure is defined as:

    +
    +
    +

    +
    +
    +
    +
    typedef struct XrFoveationLevelProfileCreateInfoFB {
    +    XrStructureType         type;
    +    void*                   next;
    +    XrFoveationLevelFB      level;
    +    float                   verticalOffset;
    +    XrFoveationDynamicFB    dynamic;
    +} XrFoveationLevelProfileCreateInfoFB;
    +
    +
    +
    +
    +
    Member Descriptions
    +
    +
      +
    • +

      type is the XrStructureType of this structure.

      +
    • +
    • +

      next is NULL or a pointer to the next structure in a structure +chain. +No such structures are defined in core OpenXR or this extension.

      +
    • +
    • +

      level is the maximum desired foveation level.

      +
    • +
    • +

      verticalOffset is the desired vertical offset in degrees for the +center of the foveation pattern.

      +
    • +
    • +

      dynamic is the desired dynamic foveation setting.

      +
    • +
    +
    +
    +
    +
    +
    +
    Valid Usage (Implicit)
    +
    + +
    +
    +
    +
    +
    +
    +

    New Functions

    +
    +
    +

    Issues

    +
    +
    +

    Version History

    +
    +
    +
      +
    • +

      Revision 1, 2021-05-13 (Kevin Xiao)

      +
      +
        +
      • +

        Initial extension description

        +
      • +
      +
      +
    • +
    +
    +
    +
    +

    12.44. XR_FB_foveation_vulkan

    +
    +
    +
    Name String
    +
    +

    XR_FB_foveation_vulkan

    +
    +
    Extension Type
    +
    +

    Instance extension

    +
    +
    Registered Extension Number
    +
    +

    161

    +
    +
    Revision
    +
    +

    1

    +
    +
    Extension and Version Dependencies
    +
    +
    + +
    +
    +
    Contributors
    +
    +

    Kevin Xiao, Facebook
    +Ross Ning, Facebook
    +Remi Palandri, Facebook
    +Cass Everitt, Facebook
    +Gloria Kennickell, Facebook

    +
    +
    +
    +
    +

    Overview

    +
    +
    +

    The Vulkan graphics API requires an image to be applied to the swapchain to +apply a foveation pattern.

    +
    +
    +

    This extension allows:

    +
    +
    +
      +
    • +

      An application to obtain foveation textures or constructs needed for +foveated rendering in Vulkan.

      +
    • +
    +
    +
    +

    In order to enable the functionality of this extension, you must pass the +name of the extension into xrCreateInstance via the +XrInstanceCreateInfo enabledExtensionNames parameter as +indicated in the Extensions section.

    +
    +
    +

    New Object Types

    +
    +
    +

    New Flag Types

    +
    +
    +

    New Enum Constants

    +
    +
    +

    XrStructureType enumeration is extended with:

    +
    +
    +
      +
    • +

      XR_TYPE_SWAPCHAIN_IMAGE_FOVEATION_VULKAN_FB

      +
    • +
    +
    +
    +

    New Enums

    +
    +
    +

    New Structures

    +
    +
    +
    +
    +

    XrSwapchainImageFoveationVulkanFB can be provided in the next +chain of XrSwapchainImageVulkanKHR when calling +xrEnumerateSwapchainImages on a swapchain created with +xrCreateSwapchain, if XrSwapchainCreateInfoFoveationFB was in +the next chain of XrSwapchainCreateInfo and +XrSwapchainCreateInfoFoveationFB had the +XR_SWAPCHAIN_CREATE_FOVEATION_FRAGMENT_DENSITY_MAP_BIT_FB flag set. +The image, width, and height will be populated by +xrEnumerateSwapchainImages to be compatible with the corresponding +XrSwapchainImageVulkanKHR.

    +
    +
    +

    The XrSwapchainImageFoveationVulkanFB structure is defined as:

    +
    +
    +

    +
    +
    +
    +
    typedef struct XrSwapchainImageFoveationVulkanFB {
    +    XrStructureType    type;
    +    void*              next;
    +    VkImage            image;
    +    uint32_t           width;
    +    uint32_t           height;
    +} XrSwapchainImageFoveationVulkanFB;
    +
    +
    +
    +
    +
    Member Descriptions
    +
    +
      +
    • +

      type is the XrStructureType of this structure.

      +
    • +
    • +

      next is NULL or a pointer to the next structure in a structure +chain. +No such structures are defined in core OpenXR or this extension.

      +
    • +
    • +

      image is a valid Vulkan VkImage to use.

      +
    • +
    • +

      width is the horizontal width in pixels of the image.

      +
    • +
    • +

      height is the vertical height in pixels of the image.

      +
    • +
    +
    +
    +
    +
    +
    +
    Valid Usage (Implicit)
    +
    + +
    +
    +
    +
    +
    +
    +

    New Functions

    +
    +
    +

    Issues

    +
    +
    +

    Version History

    +
    +
    +
      +
    • +

      Revision 1, 2021-05-26 (Kevin Xiao)

      +
      +
        +
      • +

        Initial extension description

        +
      • +
      +
      +
    • +
    +
    +
    +
    +

    12.45. XR_FB_swapchain_update_state

    +
    +
    +
    Name String
    +
    +

    XR_FB_swapchain_update_state

    +
    +
    Extension Type
    +
    +

    Instance extension

    +
    +
    Registered Extension Number
    +
    +

    72

    +
    +
    Revision
    +
    +

    3

    +
    +
    Extension and Version Dependencies
    +
    +
    +
      +
    • +

      Requires OpenXR 1.0

      +
    • +
    +
    +
    +
    Contributors
    +
    +

    Cass Everitt, Facebook
    +Gloria Kennickell, Facebook

    +
    +
    +
    +
    +

    Overview

    +
    +
    +

    This extension enables the application to modify and query specific mutable +state associated with a swapchain.

    +
    +
    +

    In order to enable the functionality of this extension, the application +must pass the name of the extension into xrCreateInstance via the +XrInstanceCreateInfo::enabledExtensionNames parameter as +indicated in the Extensions section.

    +
    +
    +

    New Object Types

    +
    +
    +

    New Flag Types

    +
    +
    +

    New Enum Constants

    +
    +
    +

    New Enums

    +
    +
    +

    New Structures

    +
    +
    +
    +
    +

    The XrSwapchainStateBaseHeaderFB structure is defined as:

    +
    +
    +

    +
    +
    +
    +
    typedef struct XrSwapchainStateBaseHeaderFB {
    +    XrStructureType    type;
    +    void*              next;
    +} XrSwapchainStateBaseHeaderFB;
    +
    +
    +
    +
    +
    Member Descriptions
    +
    +
      +
    • +

      type is the XrStructureType of this structure. +This base structure itself has no associated XrStructureType value.

      +
    • +
    • +

      next is NULL or a pointer to the next structure in a structure +chain. +No such structures are defined in core OpenXR or this extension.

      +
    • +
    +
    +
    +
    +
    +

    The XrSwapchainStateBaseHeaderFB is a base structure that can be +overridden by a specific XrSwapchainState* child structure.

    +
    +
    +
    +
    Valid Usage (Implicit)
    +
    + +
    +
    +
    +
    +
    +
    +

    New Functions

    +
    +
    +
    +
    +

    The xrUpdateSwapchainFB function is defined as:

    +
    +
    +

    +
    +
    +
    +
    XrResult xrUpdateSwapchainFB(
    +    XrSwapchain                                 swapchain,
    +    const XrSwapchainStateBaseHeaderFB*         state);
    +
    +
    +
    +
    +
    Parameter Descriptions
    +
    + +
    +
    +
    +
    +

    xrUpdateSwapchainFB provides support for an application to update +specific mutable state associated with an XrSwapchain.

    +
    +
    +
    Valid Usage (Implicit)
    @@ -37378,7 +39474,7 @@

    swapchain must be a valid XrSwapchain handle

  • -

    state must be a pointer to an XrSwapchainStateBaseHeaderFB-based structure. See also: XrSwapchainStateAndroidSurfaceDimensionsFB, XrSwapchainStateSamplerOpenGLESFB, XrSwapchainStateSamplerVulkanFB

    +

    state must be a pointer to an XrSwapchainStateBaseHeaderFB-based structure. See also: XrSwapchainStateAndroidSurfaceDimensionsFB, XrSwapchainStateFoveationFB, XrSwapchainStateSamplerOpenGLESFB, XrSwapchainStateSamplerVulkanFB

  • @@ -37492,7 +39588,7 @@

    -

    12.39. XR_FB_swapchain_update_state_android_surface

    +

    12.46. XR_FB_swapchain_update_state_android_surface

    Name String
    @@ -37519,6 +39615,9 @@

    XR_KHR_android_surface_swapchain

    + +
  • Requires XR_FB_swapchain_update_state

  • @@ -37554,8 +39653,8 @@

    -

    In order to enable the functionality of this extension, you must pass the -name of the extension into xrCreateInstance via the +

    In order to enable the functionality of this extension, the application +must pass the name of the extension into xrCreateInstance via the XrInstanceCreateInfo enabledExtensionNames parameter as indicated in the Extensions section.

    @@ -37694,7 +39793,7 @@

    -

    12.40. XR_FB_swapchain_update_state_opengl_es

    +

    12.47. XR_FB_swapchain_update_state_opengl_es

    Name String
    @@ -37721,6 +39820,9 @@

    XR_KHR_opengl_es_enable

    + +
  • Requires XR_FB_swapchain_update_state

  • @@ -37752,8 +39854,8 @@

    -

    In order to enable the functionality of this extension, you must pass the -name of the extension into xrCreateInstance via the +

    In order to enable the functionality of this extension, the application +must pass the name of the extension into xrCreateInstance via the XrInstanceCreateInfo enabledExtensionNames parameter as indicated in the Extensions section.

    @@ -37960,7 +40062,7 @@

    -

    12.41. XR_FB_swapchain_update_state_vulkan

    +

    12.48. XR_FB_swapchain_update_state_vulkan

    Name String
    @@ -37987,6 +40089,9 @@

    XR_KHR_vulkan_enable

    + +
  • Requires XR_FB_swapchain_update_state

  • @@ -38018,8 +40123,8 @@

    -

    In order to enable the functionality of this extension, you must pass the -name of the extension into xrCreateInstance via the +

    In order to enable the functionality of this extension, the application +must pass the name of the extension into xrCreateInstance via the XrInstanceCreateInfo enabledExtensionNames parameter as indicated in the Extensions section.

    @@ -38218,7 +40323,7 @@

    -

    12.42. XR_HTC_vive_cosmos_controller_interaction

    +

    12.49. XR_HTC_vive_cosmos_controller_interaction

    -
    -
    -

    12.43. XR_HUAWEI_controller_interaction

    -
    -
    -
    Name String
    -
    -

    XR_HUAWEI_controller_interaction

    -
    -
    Extension Type
    -
    -

    Instance extension

    -
    -
    Registered Extension Number
    -
    -

    70

    -
    -
    Revision
    -
    -

    1

    -
    -
    Extension and Version Dependencies
    -
    -
    -
      -
    • -

      Requires OpenXR 1.0

      -
    • -
    -
    -
    -
    Last Modified Date
    -
    -

    2020-05-26

    -
    -
    IP Status
    -
    -

    No known IP claims.

    -
    -
    Contributors
    -
    -

    Guodong Chen, Huawei
    -Kai Shao, Huawei
    -Yang Tao, Huawei
    -Gang Shen, Huawei
    -Yihong Huang, Huawei

    -
    -
    -
    -
    -

    Overview

    -
    -
    -

    This extension defines a new interaction profile for the Huawei Controller, -including but not limited to Huawei VR Glasses Controller.

    -
    -
    -

    Huawei Controller interaction profile

    -
    -
    -

    Interaction profile path:

    -
    -
    -
      -
    • -

      /interaction_profiles/huawei/controller

      -
    • -
    -
    -
    -

    Valid for user paths:

    -
    -
    -
      -
    • -

      /user/hand/left

      -
    • -
    • -

      /user/hand/right

      -
    • -
    -
    -
    -

    This interaction profile represents the input sources and haptics on the -Huawei Controller.

    -
    -
    -

    Supported component paths:

    -
    -
    -
      -
    • -

      …/input/home/click

      -
    • -
    • -

      …/input/back/click

      -
    • -
    • -

      …/input/volume_up/click

      -
    • -
    • -

      …/input/volume_down/click

      -
    • -
    • -

      …/input/trigger/value

      -
    • -
    • -

      …/input/trigger/click

      -
    • -
    • -

      …/input/trackpad/x

      -
    • -
    • -

      …/input/trackpad/y

      -
    • -
    • -

      …/input/trackpad/click

      -
    • -
    • -

      …/input/trackpad/touch

      -
    • -
    • -

      …/input/aim/pose

      -
    • -
    • -

      …/input/grip/pose

      -
    • -
    • -

      …/output/haptic

      -
    • -
    -
    -
    -

    New Object Types

    -
    -
    -

    New Flag Types

    -
    -
    -

    New Enum Constants

    -
    -
    -

    New Enums

    -
    -
    -

    New Structures

    -
    -
    -

    New Functions

    -
    -
    -

    Issues

    -
    -
    -

    Version History

    -
    -
    -