From 38bd96aa03e7ba5ff4bcb1d552ac4872f579370f Mon Sep 17 00:00:00 2001 From: Pascal Serrarens Date: Wed, 26 Jan 2022 16:57:25 +0100 Subject: [PATCH] Add check on Vive HandTracking support availability --- Editor/HumanoidFree/Configuration_Editor.cs | 16 +++++++++++----- 1 file changed, 11 insertions(+), 5 deletions(-) diff --git a/Editor/HumanoidFree/Configuration_Editor.cs b/Editor/HumanoidFree/Configuration_Editor.cs index c3e8ba2..28d71b0 100644 --- a/Editor/HumanoidFree/Configuration_Editor.cs +++ b/Editor/HumanoidFree/Configuration_Editor.cs @@ -834,7 +834,7 @@ namespace Passer.Humanoid { } public static bool CheckExtensionOpenVR(Configuration configuration) { - bool enabled = true; // configuration.openVRSupport; + bool enabled = isViveHandSupportAvailable; // configuration.openVRSupport; CheckExtension(isViveHandTrackingAvailable, "hVIVEHAND"); return CheckExtension(enabled, openVRPath, "hOPENVR"); } @@ -1277,9 +1277,9 @@ namespace Passer.Humanoid { } -#endregion SDKs + #endregion SDKs -#region Support + #region Support private static bool isOpenVrSupportAvailable { get { @@ -1293,6 +1293,12 @@ namespace Passer.Humanoid { } } + private static bool isViveHandSupportAvailable { + get { + return DoesTypeExist("Passer.Tracking.ViveHandSkeleton"); + } + } + private static bool isViveTrackerSupportAvailable { get { return DoesTypeExist("Passer.Tracking.ViveTrackerComponent"); @@ -1435,9 +1441,9 @@ namespace Passer.Humanoid { } } -#endregion Support + #endregion Support -#endregion + #endregion } public static class CustomAssetUtility {