diff options
author | rsjtdrjgfuzkfg <public@rsjtdrjgfuzkfg.com> | 2022-10-29 16:39:35 +0200 |
---|---|---|
committer | rsjtdrjgfuzkfg <public@rsjtdrjgfuzkfg.com> | 2022-11-04 01:57:48 +0100 |
commit | 4243b859902d3978471ed8cdf745ffcd8b3fe7ad (patch) | |
tree | a7af4cae9c0962ac823b477633b6a47aec2c63b6 /modules/openxr/openxr_api.cpp | |
parent | c98d6142d0c8cf4ac284a595ad1156a4b74736ad (diff) | |
download | redot-engine-4243b859902d3978471ed8cdf745ffcd8b3fe7ad.tar.gz |
OpenXR: support XR_KHR_android_create_instance
This commit adds support for the OpenXR extension
XR_KHR_android_create_instance, which seems to be required on Pico
devices.
Diffstat (limited to 'modules/openxr/openxr_api.cpp')
-rw-r--r-- | modules/openxr/openxr_api.cpp | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/modules/openxr/openxr_api.cpp b/modules/openxr/openxr_api.cpp index 8b189cf027..8502592439 100644 --- a/modules/openxr/openxr_api.cpp +++ b/modules/openxr/openxr_api.cpp @@ -269,9 +269,17 @@ bool OpenXRAPI::create_instance() { XR_CURRENT_API_VERSION // apiVersion }; + void *next_pointer = nullptr; + for (OpenXRExtensionWrapper *wrapper : registered_extension_wrappers) { + void *np = wrapper->set_instance_create_info_and_get_next_pointer(next_pointer); + if (np != nullptr) { + next_pointer = np; + } + } + XrInstanceCreateInfo instance_create_info = { XR_TYPE_INSTANCE_CREATE_INFO, // type - nullptr, // next + next_pointer, // next 0, // createFlags application_info, // applicationInfo 0, // enabledApiLayerCount, need to find out if we need support for this? |