diff --git a/Assets/HTC.UnityPlugin/VRModule/Modules/OculusVRModule.cs b/Assets/HTC.UnityPlugin/VRModule/Modules/OculusVRModule.cs index 9e3a09bc..61317961 100644 --- a/Assets/HTC.UnityPlugin/VRModule/Modules/OculusVRModule.cs +++ b/Assets/HTC.UnityPlugin/VRModule/Modules/OculusVRModule.cs @@ -1,4 +1,4 @@ -//========= Copyright 2016-2018, HTC Corporation. All rights reserved. =========== +//========= Copyright 2016-2018, HTC Corporation. All rights reserved. =========== #if VIU_OCULUSVR using UnityEngine; @@ -141,7 +141,8 @@ public override void BeforeRenderUpdate() // update device connected state if (!prevState.isConnected) { - var ovrProductName = OVRPlugin.productName; + var platform = OVRPlugin.GetSystemHeadsetType(); + var ovrProductName = platform.ToString(); var deviceClass = s_node2class[(int)node]; currState.isConnected = true; @@ -160,15 +161,24 @@ public override void BeforeRenderUpdate() currState.deviceModel = VRModuleDeviceModel.OculusSensor; break; case VRModuleDeviceClass.Controller: - switch (ovrProductName) + switch (platform) { - case "Oculus Go": + case OVRPlugin.SystemHeadset.Oculus_Go: currState.deviceModel = VRModuleDeviceModel.OculusGoController; break; - case "Gear VR": + + case OVRPlugin.SystemHeadset.GearVR_R320: + case OVRPlugin.SystemHeadset.GearVR_R321: + case OVRPlugin.SystemHeadset.GearVR_R322: + case OVRPlugin.SystemHeadset.GearVR_R323: + case OVRPlugin.SystemHeadset.GearVR_R324: + case OVRPlugin.SystemHeadset.GearVR_R325: currState.deviceModel = VRModuleDeviceModel.OculusGearVrController; break; - case "Oculus Rift": + + case OVRPlugin.SystemHeadset.Rift_DK1: + case OVRPlugin.SystemHeadset.Rift_DK2: + case OVRPlugin.SystemHeadset.Rift_CV1: default: switch (node) { @@ -288,4 +298,4 @@ public override void BeforeRenderUpdate() } #endif } -} \ No newline at end of file +} diff --git a/Assets/HTC.UnityPlugin/ViveInputUtility/Scripts/VIUVersion.cs b/Assets/HTC.UnityPlugin/ViveInputUtility/Scripts/VIUVersion.cs index ad6ab22a..97bec4b7 100644 --- a/Assets/HTC.UnityPlugin/ViveInputUtility/Scripts/VIUVersion.cs +++ b/Assets/HTC.UnityPlugin/ViveInputUtility/Scripts/VIUVersion.cs @@ -6,6 +6,6 @@ namespace HTC.UnityPlugin.Vive { public static class VIUVersion { - public static readonly Version current = new Version("1.10.1.3"); + public static readonly Version current = new Version("1.10.1.4"); } } \ No newline at end of file