You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When switching to the OpenXR Plugin OVRManager.IsPassthroughRecommended() always returns false.
Using the Oculus XR Plugin the OVRManager.IsPassthroughRecommended() returns true or false depending on whether passthrough is enabled in the home screen
Setup
Unity: 2021.3.36f1
Packages: Meta XR Core SDK v 62.0.0; OpenXR Plugin 1.10.0; XR Plugin Management 4.4.0
Device: Quest 3, OS version 63.0.0.399.366
Repro
Add the following script to the sample project
usingTMPro;usingUnityEngine;publicclassIsPassthroughPreferred:MonoBehaviour{TextMeshPro_text;// Start is called before the first frame updatevoidStart(){vargo=newGameObject("Debug Text");_text=go.AddComponent<TextMeshPro>();varrectTransform=go.GetComponent<RectTransform>();rectTransform.position=newVector3(0,0.8f,1);rectTransform.localScale=newVector3(0.02f,0.02f,0.02f);rectTransform.sizeDelta=newVector2(50,5);OVRManager.instance.isInsightPassthroughEnabled=true;}// Update is called once per framevoidUpdate(){_text.text=$"Passthrough Preferred {OVRManager.IsPassthroughRecommended()}";}}
Add the script to any game object in the StartScene.unity
Save the scene
Build using Oculus > Samples > Build Starter Scene and deploy to device
Ensure that the device has passthrough on in the OS
Run the app and observe the text field saying "Passthrough Preferred True"
Back in Unity, install the OpenXR Plugin package
Under Project Settings > XR Plug-in Management switch Plug-in Provider to OpenXR
Build using Oculus > Samples > Build Starter Scene and deploy to device
Run the app and observe the text field saying "Passthrough Preferred False"
Expected Results
OVRManager.IsPassthroughRecommended() returns a value that reflects the passthrough setting in the OS, as it does with the Oculus XR plugin.
The cause of this bug seems to be due to the missing OpenXR extension XR_META_passthrough_preferences. You can create a custom OpenXR feature (as mentioned in this issue #12) which includes that extension and the call to OVRManager.IsPassthroughRecommended() now works
The text was updated successfully, but these errors were encountered:
@AlexThiv great to see the fix for #15 make it into v66. Any update on when this one will be fixed? It's a similar fix of just adding an extra string to the OpenXrExtensionList.
Description
When switching to the OpenXR Plugin OVRManager.IsPassthroughRecommended() always returns false.
Using the Oculus XR Plugin the OVRManager.IsPassthroughRecommended() returns true or false depending on whether passthrough is enabled in the home screen
Setup
Unity: 2021.3.36f1
Packages: Meta XR Core SDK v 62.0.0; OpenXR Plugin 1.10.0; XR Plugin Management 4.4.0
Device: Quest 3, OS version 63.0.0.399.366
Repro
Add the following script to the sample project
Expected Results
OVRManager.IsPassthroughRecommended() returns a value that reflects the passthrough setting in the OS, as it does with the Oculus XR plugin.
Actual Results
OVRManager.IsPassthroughRecommended() always returns false
Workarounds
The cause of this bug seems to be due to the missing OpenXR extension
XR_META_passthrough_preferences
. You can create a custom OpenXR feature (as mentioned in this issue #12) which includes that extension and the call to OVRManager.IsPassthroughRecommended() now worksThe text was updated successfully, but these errors were encountered: