[Bf-blender-cvs] [0b9cc6725cc] master: XR: Use #ifdef for Vive Focus 3 extension

Peter Kim noreply at git.blender.org
Tue Feb 22 22:56:21 CET 2022


Commit: 0b9cc6725cca193ec20868caf266ea35c173b956
Author: Peter Kim
Date:   Wed Feb 23 06:56:08 2022 +0900
Branches: master
https://developer.blender.org/rB0b9cc6725cca193ec20868caf266ea35c173b956

XR: Use #ifdef for Vive Focus 3 extension

Helps with building against different OpenXR SDK versions (i.e. for
downstream builds that require specific versions), as the extension was
only defined since OpenXR 1.0.22.

===================================================================

M	intern/ghost/intern/GHOST_XrContext.cpp

===================================================================

diff --git a/intern/ghost/intern/GHOST_XrContext.cpp b/intern/ghost/intern/GHOST_XrContext.cpp
index 716b60799f9..2ac3d9ec2a5 100644
--- a/intern/ghost/intern/GHOST_XrContext.cpp
+++ b/intern/ghost/intern/GHOST_XrContext.cpp
@@ -412,7 +412,9 @@ void GHOST_XrContext::getExtensionsToEnable(
   /* Interaction profile extensions. */
   try_ext.push_back(XR_EXT_HP_MIXED_REALITY_CONTROLLER_EXTENSION_NAME);
   try_ext.push_back(XR_HTC_VIVE_COSMOS_CONTROLLER_INTERACTION_EXTENSION_NAME);
+#ifdef XR_HTC_VIVE_FOCUS3_CONTROLLER_INTERACTION_EXTENSION_NAME
   try_ext.push_back(XR_HTC_VIVE_FOCUS3_CONTROLLER_INTERACTION_EXTENSION_NAME);
+#endif
   try_ext.push_back(XR_HUAWEI_CONTROLLER_INTERACTION_EXTENSION_NAME);
 
   /* Controller model extension. */



More information about the Bf-blender-cvs mailing list