From 3acd7d9287278f9c4eff53a2210b4b40e34d8444 Mon Sep 17 00:00:00 2001 From: Matt Schoen Date: Wed, 19 Aug 2020 18:04:19 -0700 Subject: [PATCH] Fix warnings in 2020.2 --- Runtime/Scripts/Core/VRView.cs | 2 ++ Runtime/Scripts/Proxies/Vive/ViveProxy.cs | 4 +++- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/Runtime/Scripts/Core/VRView.cs b/Runtime/Scripts/Core/VRView.cs index d497f9636..9fcfd17ad 100644 --- a/Runtime/Scripts/Core/VRView.cs +++ b/Runtime/Scripts/Core/VRView.cs @@ -28,7 +28,9 @@ sealed class VRView static bool s_ExistingSceneMainCameraEnabledState; #if UNITY_EDITOR +#if !UNITY_2020_2_OR_NEWER DrawCameraMode m_RenderMode = DrawCameraMode.Textured; +#endif // To allow for alternate previews (e.g. smoothing) public static Camera customPreviewCamera diff --git a/Runtime/Scripts/Proxies/Vive/ViveProxy.cs b/Runtime/Scripts/Proxies/Vive/ViveProxy.cs index 576d42cbc..d559e0412 100644 --- a/Runtime/Scripts/Proxies/Vive/ViveProxy.cs +++ b/Runtime/Scripts/Proxies/Vive/ViveProxy.cs @@ -24,7 +24,9 @@ sealed class ViveProxy : TwoHandedProxyBase protected override void Awake() { -#if !UNITY_2020_2_OR_NEWER +#if UNITY_2020_2_OR_NEWER + m_IsOculus = true; // TODO: Use XR Management +#else #pragma warning disable 618 m_IsOculus = XRDevice.model.IndexOf("oculus", StringComparison.OrdinalIgnoreCase) >= 0; #pragma warning restore 618