diff --git a/.appveyor.yml b/.appveyor.yml index b17f46f..6ce4f68 100644 --- a/.appveyor.yml +++ b/.appveyor.yml @@ -2,7 +2,7 @@ # # SPDX-License-Identifier: Apache-2.0 -version: 1.0.29.{build} +version: 1.0.30.{build} image: Visual Studio 2017 diff --git a/.reuse/dep5 b/.reuse/dep5 index 3df6553..c905fc9 100644 --- a/.reuse/dep5 +++ b/.reuse/dep5 @@ -1,7 +1,7 @@ Format: https://www.debian.org/doc/packaging-manuals/copyright-format/1.0/ Upstream-Name: OpenXR Upstream-Contact: Ryan Pavlik -Source: https://khronos.org/registry/OpenXR/ +Source: https://registry.khronos.org/OpenXR/ Files: changes/conformance/* changes/registry/* @@ -54,8 +54,8 @@ Comment: Unmodified, vendored copy of a subset of the tiny-gltf repo v2.8.9 Files: src/external/d3dx12/* Copyright: Copyright (c) Microsoft Corporation. License: MIT -Comment: Unmodified, vendored copy of DirectX-Headers commit da7aedb - of https://github.com/microsoft/DirectX-Headers filtered to just d3dx12 headers +Comment: Unmodified, vendored copy of d3dx12.h from directx-vs-templates commit 86b9c45 + This repo includes ifdefs to improve compatibility with older Windows SDK verions. Files: src/external/mikktspace/* Copyright: 2011 by Morten S. Mikkelsen diff --git a/CHANGELOG.SDK.md b/CHANGELOG.SDK.md index af900f4..5fda193 100644 --- a/CHANGELOG.SDK.md +++ b/CHANGELOG.SDK.md @@ -19,6 +19,45 @@ along with any public pull requests that have been accepted. In this repository in particular, since it is primarily software, pull requests may be integrated as they are accepted even between periodic updates. +## OpenXR SDK 1.0.30 (2023-09-20) + +This release is primarily a quality improvement release, fixing a range of +issues in the registry and SDK, including fixing a loader bug related to layers, +in addition to a new vendor extension and an updated vendor extension. + +- Registry + - Add missing enum tags for enum-sized array struct members. + ([internal MR 2731](https://gitlab.khronos.org/openxr/openxr/merge_requests/2731)) + - Fix EGL "get proc addr" function pointer typedef. + ([internal MR 2939](https://gitlab.khronos.org/openxr/openxr/merge_requests/2939)) + - New vendor extension: `XR_YVR_controller_interaction` + ([internal MR 2841](https://gitlab.khronos.org/openxr/openxr/merge_requests/2841)) + - `XR_BD_controller_interaction`: Add support for G3 devices + ([internal MR 2872](https://gitlab.khronos.org/openxr/openxr/merge_requests/2872)) + - Fix specification errors highlighted by fixed tooling. + ([internal MR 2923](https://gitlab.khronos.org/openxr/openxr/merge_requests/2923)) +- SDK + - Add installable manual page for `openxr_runtime_list_json`. + ([internal MR 2899](https://gitlab.khronos.org/openxr/openxr/merge_requests/2899)) + - Remove unused diagram exports from loader directory. + ([internal MR 2907](https://gitlab.khronos.org/openxr/openxr/merge_requests/2907)) + - Update URLs in manual pages. + ([internal MR 2935](https://gitlab.khronos.org/openxr/openxr/merge_requests/2935)) + - Validation Layer: Remove conditional `XR_KHR_headless` support as the extension + is not part of OpenXR 1.0. + ([internal MR 2901](https://gitlab.khronos.org/openxr/openxr/merge_requests/2901)) + - build system: Add CTest support for running the loader test. + ([internal MR 2289](https://gitlab.khronos.org/openxr/openxr/merge_requests/2289), + [OpenXR-SDK-Source issue 309](https://github.com/KhronosGroup/OpenXR-SDK-Source/issues/309), + [internal issue 1733](https://gitlab.khronos.org/openxr/openxr/issues/1733)) + - hello_xr: Clean up how we specify the default graphics plugin on Android. + ([internal MR 2917](https://gitlab.khronos.org/openxr/openxr/merge_requests/2917)) + - list_json: Add missing return statement for exit code. + ([internal MR 2936](https://gitlab.khronos.org/openxr/openxr/merge_requests/2936)) + - loader: fix for implicit/explicit api layer loading logic + ([OpenXR-SDK-Source PR 421](https://github.com/KhronosGroup/OpenXR-SDK-Source/pull/421), + [internal issue 2079](https://gitlab.khronos.org/openxr/openxr/issues/2079)) + ## OpenXR SDK 1.0.29 (2023-08-25) This release contains several fixes to the specification registry, improvements diff --git a/CMakeLists.txt b/CMakeLists.txt index 43ab332..03df11b 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -25,6 +25,7 @@ cmake_minimum_required(VERSION 3.0) project(OPENXR) find_package(PythonInterp 3) +include(CTest) # Enable IDE GUI folders. "Helper targets" that don't have interesting source code should set their FOLDER property to this set_property(GLOBAL PROPERTY USE_FOLDERS ON) diff --git a/include/openxr/openxr.h b/include/openxr/openxr.h index 889d9ac..1faee71 100644 --- a/include/openxr/openxr.h +++ b/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, 29) +#define XR_CURRENT_API_VERSION XR_MAKE_VERSION(1, 0, 30) #define XR_VERSION_MAJOR(version) (uint16_t)(((uint64_t)(version) >> 48)& 0xffffULL) #define XR_VERSION_MINOR(version) (uint16_t)(((uint64_t)(version) >> 32) & 0xffffULL) @@ -1800,7 +1800,7 @@ XRAPI_ATTR XrResult XRAPI_CALL xrThermalGetTemperatureTrendEXT( #define XR_EXT_debug_utils 1 XR_DEFINE_HANDLE(XrDebugUtilsMessengerEXT) -#define XR_EXT_debug_utils_SPEC_VERSION 4 +#define XR_EXT_debug_utils_SPEC_VERSION 5 #define XR_EXT_DEBUG_UTILS_EXTENSION_NAME "XR_EXT_debug_utils" typedef XrFlags64 XrDebugUtilsMessageSeverityFlagsEXT; @@ -2116,9 +2116,9 @@ XRAPI_ATTR XrResult XRAPI_CALL xrSetInputDeviceLocationEXT( #define XR_MSFT_spatial_graph_bridge 1 XR_DEFINE_HANDLE(XrSpatialGraphNodeBindingMSFT) +#define XR_GUID_SIZE_MSFT 16 #define XR_MSFT_spatial_graph_bridge_SPEC_VERSION 2 #define XR_MSFT_SPATIAL_GRAPH_BRIDGE_EXTENSION_NAME "XR_MSFT_spatial_graph_bridge" -#define XR_GUID_SIZE_MSFT 16 typedef enum XrSpatialGraphNodeTypeMSFT { XR_SPATIAL_GRAPH_NODE_TYPE_STATIC_MSFT = 1, @@ -2454,9 +2454,9 @@ typedef struct XrSecondaryViewConfigurationSwapchainCreateInfoMSFT { #define XR_NULL_CONTROLLER_MODEL_KEY_MSFT 0 XR_DEFINE_ATOM(XrControllerModelKeyMSFT) +#define XR_MAX_CONTROLLER_MODEL_NODE_NAME_SIZE_MSFT 64 #define XR_MSFT_controller_model_SPEC_VERSION 2 #define XR_MSFT_CONTROLLER_MODEL_EXTENSION_NAME "XR_MSFT_controller_model" -#define XR_MAX_CONTROLLER_MODEL_NODE_NAME_SIZE_MSFT 64 typedef struct XrControllerModelKeyStateMSFT { XrStructureType type; void* XR_MAY_ALIAS next; @@ -3452,7 +3452,7 @@ typedef struct XrSystemColorSpacePropertiesFB { } XrSystemColorSpacePropertiesFB; typedef XrResult (XRAPI_PTR *PFN_xrEnumerateColorSpacesFB)(XrSession session, uint32_t colorSpaceCapacityInput, uint32_t* colorSpaceCountOutput, XrColorSpaceFB* colorSpaces); -typedef XrResult (XRAPI_PTR *PFN_xrSetColorSpaceFB)(XrSession session, const XrColorSpaceFB colorspace); +typedef XrResult (XRAPI_PTR *PFN_xrSetColorSpaceFB)(XrSession session, const XrColorSpaceFB colorSpace); #ifndef XR_NO_PROTOTYPES #ifdef XR_EXTENSION_PROTOTYPES @@ -3464,7 +3464,7 @@ XRAPI_ATTR XrResult XRAPI_CALL xrEnumerateColorSpacesFB( XRAPI_ATTR XrResult XRAPI_CALL xrSetColorSpaceFB( XrSession session, - const XrColorSpaceFB colorspace); + const XrColorSpaceFB colorSpace); #endif /* XR_EXTENSION_PROTOTYPES */ #endif /* !XR_NO_PROTOTYPES */ @@ -3757,9 +3757,9 @@ typedef struct XrFoveationLevelProfileCreateInfoFB { #define XR_FB_keyboard_tracking 1 +#define XR_MAX_KEYBOARD_TRACKING_NAME_SIZE_FB 128 #define XR_FB_keyboard_tracking_SPEC_VERSION 1 #define XR_FB_KEYBOARD_TRACKING_EXTENSION_NAME "XR_FB_keyboard_tracking" -#define XR_MAX_KEYBOARD_TRACKING_NAME_SIZE_FB 128 typedef XrFlags64 XrKeyboardTrackingFlagsFB; // Flag bits for XrKeyboardTrackingFlagsFB @@ -3894,9 +3894,9 @@ XRAPI_ATTR XrResult XRAPI_CALL xrTriangleMeshEndVertexBufferUpdateFB( XR_DEFINE_HANDLE(XrPassthroughFB) XR_DEFINE_HANDLE(XrPassthroughLayerFB) XR_DEFINE_HANDLE(XrGeometryInstanceFB) +#define XR_PASSTHROUGH_COLOR_MAP_MONO_SIZE_FB 256 #define XR_FB_passthrough_SPEC_VERSION 3 #define XR_FB_PASSTHROUGH_EXTENSION_NAME "XR_FB_passthrough" -#define XR_PASSTHROUGH_COLOR_MAP_MONO_SIZE_FB 256 typedef enum XrPassthroughLayerPurposeFB { XR_PASSTHROUGH_LAYER_PURPOSE_RECONSTRUCTION_FB = 0, @@ -4085,9 +4085,9 @@ XRAPI_ATTR XrResult XRAPI_CALL xrGeometryInstanceSetTransformFB( #define XR_NULL_RENDER_MODEL_KEY_FB 0 XR_DEFINE_ATOM(XrRenderModelKeyFB) +#define XR_MAX_RENDER_MODEL_NAME_SIZE_FB 64 #define XR_FB_render_model_SPEC_VERSION 4 #define XR_FB_RENDER_MODEL_EXTENSION_NAME "XR_FB_render_model" -#define XR_MAX_RENDER_MODEL_NAME_SIZE_FB 64 typedef XrFlags64 XrRenderModelFlagsFB; // Flag bits for XrRenderModelFlagsFB @@ -4244,7 +4244,7 @@ typedef struct XrMarkerSpaceCreateInfoVARJO { typedef XrResult (XRAPI_PTR *PFN_xrSetMarkerTrackingVARJO)(XrSession session, XrBool32 enabled); typedef XrResult (XRAPI_PTR *PFN_xrSetMarkerTrackingTimeoutVARJO)(XrSession session, uint64_t markerId, XrDuration timeout); -typedef XrResult (XRAPI_PTR *PFN_xrSetMarkerTrackingPredictionVARJO)(XrSession session, uint64_t markerId, XrBool32 enabled); +typedef XrResult (XRAPI_PTR *PFN_xrSetMarkerTrackingPredictionVARJO)(XrSession session, uint64_t markerId, XrBool32 enable); typedef XrResult (XRAPI_PTR *PFN_xrGetMarkerSizeVARJO)(XrSession session, uint64_t markerId, XrExtent2Df* size); typedef XrResult (XRAPI_PTR *PFN_xrCreateMarkerSpaceVARJO)(XrSession session, const XrMarkerSpaceCreateInfoVARJO* createInfo, XrSpace* space); @@ -4262,7 +4262,7 @@ XRAPI_ATTR XrResult XRAPI_CALL xrSetMarkerTrackingTimeoutVARJO( XRAPI_ATTR XrResult XRAPI_CALL xrSetMarkerTrackingPredictionVARJO( XrSession session, uint64_t markerId, - XrBool32 enabled); + XrBool32 enable); XRAPI_ATTR XrResult XRAPI_CALL xrGetMarkerSizeVARJO( XrSession session, @@ -5960,7 +5960,7 @@ XRAPI_ATTR XrResult XRAPI_CALL xrApplyForceFeedbackCurlMNDX( #define XR_BD_controller_interaction 1 -#define XR_BD_controller_interaction_SPEC_VERSION 1 +#define XR_BD_controller_interaction_SPEC_VERSION 2 #define XR_BD_CONTROLLER_INTERACTION_EXTENSION_NAME "XR_BD_controller_interaction" @@ -6154,6 +6154,11 @@ XRAPI_ATTR XrResult XRAPI_CALL xrGetPlanePolygonBufferEXT( #define XR_OPPO_controller_interaction_SPEC_VERSION 1 #define XR_OPPO_CONTROLLER_INTERACTION_EXTENSION_NAME "XR_OPPO_controller_interaction" + +#define XR_YVR_controller_interaction 1 +#define XR_YVR_controller_interaction_SPEC_VERSION 1 +#define XR_YVR_CONTROLLER_INTERACTION_EXTENSION_NAME "XR_YVR_controller_interaction" + #ifdef __cplusplus } #endif diff --git a/include/openxr/openxr_platform.h b/include/openxr/openxr_platform.h index fcfe90a..e4ddfcb 100644 --- a/include/openxr/openxr_platform.h +++ b/include/openxr/openxr_platform.h @@ -491,7 +491,7 @@ XRAPI_ATTR XrResult XRAPI_CALL xrGetVulkanGraphicsRequirements2KHR( #define XR_MNDX_egl_enable 1 #define XR_MNDX_egl_enable_SPEC_VERSION 1 #define XR_MNDX_EGL_ENABLE_EXTENSION_NAME "XR_MNDX_egl_enable" -typedef void *(*PFN_xrEglGetProcAddressMNDX)(const char *name); +typedef PFN_xrVoidFunction (*PFN_xrEglGetProcAddressMNDX)(const char *name); // XrGraphicsBindingEGLMNDX extends XrSessionCreateInfo typedef struct XrGraphicsBindingEGLMNDX { XrStructureType type; diff --git a/include/openxr/openxr_reflection.h b/include/openxr/openxr_reflection.h index 0901ef4..8c9aabf 100644 --- a/include/openxr/openxr_reflection.h +++ b/include/openxr/openxr_reflection.h @@ -4588,6 +4588,7 @@ XR_ENUM_STR(XrResult); _(XR_EXT_hand_tracking_data_source, 429) \ _(XR_EXT_plane_detection, 430) \ _(XR_OPPO_controller_interaction, 454) \ + _(XR_YVR_controller_interaction, 498) \ #endif diff --git a/specification/registry/xr.xml b/specification/registry/xr.xml index add5a2c..7bbddee 100644 --- a/specification/registry/xr.xml +++ b/specification/registry/xr.xml @@ -82,7 +82,6 @@ maintained in the default branch of the Khronos OpenXR GitHub project. - @@ -132,7 +131,7 @@ maintained in the default branch of the Khronos OpenXR GitHub project. updates them automatically by processing a line at a time. --> // OpenXR current version number. -#define XR_CURRENT_API_VERSION XR_MAKE_VERSION(1, 0, 29) +#define XR_CURRENT_API_VERSION XR_MAKE_VERSION(1, 0, 30) - typedef void *(*PFN_xrEglGetProcAddressMNDX)(const char *name); + typedef PFN_xrVoidFunction (*PFN_xrEglGetProcAddressMNDX)(const char *name); XrStructureType type @@ -1491,7 +1490,7 @@ maintained in the default branch of the Khronos OpenXR GitHub project. XrStructureType type const void* next XrSpatialGraphNodeTypeMSFT nodeType - uint8_t nodeId[XR_GUID_SIZE_MSFT] + uint8_t nodeId[XR_GUID_SIZE_MSFT] XrPosef pose @@ -1508,7 +1507,7 @@ maintained in the default branch of the Khronos OpenXR GitHub project. XrStructureType type void* next - uint8_t nodeId[XR_GUID_SIZE_MSFT] + uint8_t nodeId[XR_GUID_SIZE_MSFT] XrPosef poseInNodeSpace @@ -1890,8 +1889,8 @@ maintained in the default branch of the Khronos OpenXR GitHub project. XrStructureType type void* next - char parentNodeName[XR_MAX_CONTROLLER_MODEL_NODE_NAME_SIZE_MSFT] - char nodeName[XR_MAX_CONTROLLER_MODEL_NODE_NAME_SIZE_MSFT] + char parentNodeName[XR_MAX_CONTROLLER_MODEL_NODE_NAME_SIZE_MSFT] + char nodeName[XR_MAX_CONTROLLER_MODEL_NODE_NAME_SIZE_MSFT] XrStructureType type @@ -2281,7 +2280,7 @@ maintained in the default branch of the Khronos OpenXR GitHub project. XrStructureType type void* next uint32_t vendorId - char modelName[XR_MAX_RENDER_MODEL_NAME_SIZE_FB] + char modelName[XR_MAX_RENDER_MODEL_NAME_SIZE_FB] XrRenderModelKeyFB modelKey uint32_t modelVersion XrRenderModelFlagsFB flags @@ -2508,7 +2507,7 @@ maintained in the default branch of the Khronos OpenXR GitHub project. uint64_t trackedKeyboardId XrVector3f size XrKeyboardTrackingFlagsFB flags - char name[XR_MAX_KEYBOARD_TRACKING_NAME_SIZE_FB] + char name[XR_MAX_KEYBOARD_TRACKING_NAME_SIZE_FB] XrStructureType type @@ -2631,12 +2630,12 @@ maintained in the default branch of the Khronos OpenXR GitHub project. XrStructureType type const void* next - XrColor4f textureColorMap[XR_PASSTHROUGH_COLOR_MAP_MONO_SIZE_FB] + XrColor4f textureColorMap[XR_PASSTHROUGH_COLOR_MAP_MONO_SIZE_FB] XrStructureType type const void* next - uint8_t textureColorMap[XR_PASSTHROUGH_COLOR_MAP_MONO_SIZE_FB] + uint8_t textureColorMap[XR_PASSTHROUGH_COLOR_MAP_MONO_SIZE_FB] XrStructureType type @@ -5102,7 +5101,7 @@ maintained in the default branch of the Khronos OpenXR GitHub project. XrResult xrSetColorSpaceFB XrSession session - const XrColorSpaceFB colorspace + const XrColorSpaceFB colorSpace @@ -5524,7 +5523,7 @@ maintained in the default branch of the Khronos OpenXR GitHub project. XrResult xrSetMarkerTrackingPredictionVARJO XrSession session uint64_t markerId - XrBool32 enabled + XrBool32 enable @@ -6272,6 +6271,18 @@ maintained in the default branch of the Khronos OpenXR GitHub project. + + + + + + + + + + + + @@ -6316,6 +6327,32 @@ maintained in the default branch of the Khronos OpenXR GitHub project. + + + + + + + + + + + + + + + + + + + + + + + + + + @@ -6619,7 +6656,7 @@ maintained in the default branch of the Khronos OpenXR GitHub project. - + @@ -10510,10 +10547,11 @@ maintained in the default branch of the Khronos OpenXR GitHub project. - + + @@ -10530,6 +10568,13 @@ maintained in the default branch of the Khronos OpenXR GitHub project. + + + + + + + @@ -10538,19 +10583,22 @@ maintained in the default branch of the Khronos OpenXR GitHub project. + + + - - - - + + + + @@ -11384,10 +11432,33 @@ maintained in the default branch of the Khronos OpenXR GitHub project. - + - - + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/src/loader/api_layer_interface.cpp b/src/loader/api_layer_interface.cpp index 5560c31..c9e24ec 100644 --- a/src/loader/api_layer_interface.cpp +++ b/src/loader/api_layer_interface.cpp @@ -237,21 +237,23 @@ XrResult ApiLayerInterface::LoadApiLayers(const std::string& openxr_command, uin for (const auto& layer_name : enabled_explicit_api_layer_names) { bool found_this_layer = false; - for (auto it = explicit_layer_manifest_files.begin(); it != explicit_layer_manifest_files.end();) { - bool erased_layer_manifest_file = false; - - if (layers_already_found.count(layer_name) > 0) { - found_this_layer = true; - } else if (layer_name == (*it)->LayerName()) { - found_this_layer = true; - layers_already_found.insert(layer_name); - enabled_layer_manifest_files_in_init_order.push_back(std::move(*it)); - it = explicit_layer_manifest_files.erase(it); - erased_layer_manifest_file = true; - } + if (layers_already_found.count(layer_name) > 0) { + found_this_layer = true; + } else { + for (auto it = explicit_layer_manifest_files.begin(); it != explicit_layer_manifest_files.end();) { + bool erased_layer_manifest_file = false; + + if (layer_name == (*it)->LayerName()) { + found_this_layer = true; + layers_already_found.insert(layer_name); + enabled_layer_manifest_files_in_init_order.push_back(std::move(*it)); + it = explicit_layer_manifest_files.erase(it); + erased_layer_manifest_file = true; + } - if (!erased_layer_manifest_file) { - it++; + if (!erased_layer_manifest_file) { + it++; + } } }