summaryrefslogtreecommitdiff
path: root/modules/openxr/extensions/openxr_android_extension.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'modules/openxr/extensions/openxr_android_extension.cpp')
-rw-r--r--modules/openxr/extensions/openxr_android_extension.cpp6
1 files changed, 5 insertions, 1 deletions
diff --git a/modules/openxr/extensions/openxr_android_extension.cpp b/modules/openxr/extensions/openxr_android_extension.cpp
index ea539f2053..753fc5fa89 100644
--- a/modules/openxr/extensions/openxr_android_extension.cpp
+++ b/modules/openxr/extensions/openxr_android_extension.cpp
@@ -47,11 +47,15 @@ OpenXRAndroidExtension *OpenXRAndroidExtension::get_singleton() {
OpenXRAndroidExtension::OpenXRAndroidExtension(OpenXRAPI *p_openxr_api) :
OpenXRExtensionWrapper(p_openxr_api) {
singleton = this;
- request_extensions[XR_KHR_LOADER_INIT_ANDROID_EXTENSION_NAME] = nullptr; // must be available
+ request_extensions[XR_KHR_LOADER_INIT_ANDROID_EXTENSION_NAME] = &loader_init_extension_available;
request_extensions[XR_KHR_ANDROID_CREATE_INSTANCE_EXTENSION_NAME] = &create_instance_extension_available;
}
void OpenXRAndroidExtension::on_before_instance_created() {
+ if (!loader_init_extension_available) {
+ print_line("OpenXR: XR_KHR_loader_init_android is not reported as available - trying to initialize anyway...");
+ }
+
EXT_INIT_XR_FUNC(xrInitializeLoaderKHR);
JNIEnv *env = get_jni_env();