diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index da4c2909e3..9522b3ffe7 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -232,7 +232,7 @@ jobs: cache: Android_Vulkan extraoptions: -btb-il2cpp versionSuffix: 1 - extra_defines: OCULUS_SUPPORTED USE_QUEST_PACKAGE_NAME ENABLE_BOUNDARYLESS_APP + extra_defines: OCULUS_SUPPORTED USE_QUEST_PACKAGE_NAME ENABLE_CONTEXTUAL_BOUNDARYLESS_APP - name: Android Pico targetPlatform: Android diff --git a/Assets/Editor/BuildTiltBrushPostProcess.cs b/Assets/Editor/BuildTiltBrushPostProcess.cs index b674298e86..780f0c2dad 100644 --- a/Assets/Editor/BuildTiltBrushPostProcess.cs +++ b/Assets/Editor/BuildTiltBrushPostProcess.cs @@ -69,13 +69,13 @@ public void OnPostGenerateGradleAndroidProject(string path) ); #endif -#if ENABLE_BOUNDARYLESS_APP - UnityEngine.Debug.Log("Add com.oculus.feature.BOUNDARYLESS_APP"); +#if ENABLE_CONTEXTUAL_BOUNDARYLESS_APP + UnityEngine.Debug.Log("Add com.oculus.feature.CONTEXTUAL_BOUNDARYLESS_APP"); AddOrRemoveTag(doc, androidNamespaceURI, "/manifest", "uses-feature", - "com.oculus.feature.BOUNDARYLESS_APP", + "com.oculus.feature.CONTEXTUAL_BOUNDARYLESS_APP", true, true, "required", "true" diff --git a/Assets/Scripts/PassthroughManager.cs b/Assets/Scripts/PassthroughManager.cs index 3663d5c0a6..ca61695e0e 100644 --- a/Assets/Scripts/PassthroughManager.cs +++ b/Assets/Scripts/PassthroughManager.cs @@ -23,7 +23,15 @@ void Start() #if OCULUS_SUPPORTED var passthrough = gameObject.AddComponent(); passthrough.overlayType = OVROverlay.OverlayType.Underlay; + App.VrSdk.m_OvrManager.shouldBoundaryVisibilityBeSuppressed = true; #endif // OCULUS_SUPPORTED } + + void OnDestroy() + { +#if OCULUS_SUPPORTED + App.VrSdk.m_OvrManager.shouldBoundaryVisibilityBeSuppressed = false; +#endif + } } } diff --git a/Assets/Scripts/VrSdk.cs b/Assets/Scripts/VrSdk.cs index faa874e792..16953fe571 100644 --- a/Assets/Scripts/VrSdk.cs +++ b/Assets/Scripts/VrSdk.cs @@ -93,7 +93,9 @@ public class VrSdk : MonoBehaviour // out of date for a frame when controllers change. private VrControllers m_VrControls; public VrControllers VrControls { get { return m_VrControls; } } - +#if OCULUS_SUPPORTED + [NonSerialized] public OVRManager m_OvrManager; +#endif private bool m_HasVrFocus = true; private Bounds? m_RoomBoundsAabbCached; @@ -204,10 +206,10 @@ void Awake() // ---------------------------------------------------------------------------------------- // // OculusVR // ---------------------------------------------------------------------------------------- // - OVRManager manager = gameObject.AddComponent(); - manager.trackingOriginType = OVRManager.TrackingOrigin.Stage; - manager.useRecommendedMSAALevel = false; - manager.isInsightPassthroughEnabled = true; + m_OvrManager = gameObject.AddComponent(); + m_OvrManager.trackingOriginType = OVRManager.TrackingOrigin.Stage; + m_OvrManager.useRecommendedMSAALevel = false; + m_OvrManager.isInsightPassthroughEnabled = true; // adding components to the VR Camera needed for fading view and getting controller poses. m_VrCamera.gameObject.AddComponent();