From a58ad97e30eaf2f7542f2151245320eb48ef08ba Mon Sep 17 00:00:00 2001 From: Fridolin Wild Date: Tue, 3 Sep 2024 14:26:03 +0100 Subject: [PATCH] going through the settings --- .../Tutorial/ArrowHighlightingTutorialStep.cs | 4 ++-- Assets/XR/Loaders/MockHMDLoader.asset | 14 ++++++++++++++ Assets/XR/Loaders/MockHMDLoader.asset.meta | 8 ++++++++ Assets/XR/Settings/MockHMDBuildSettings.asset | 17 +++++++++++++++++ .../XR/Settings/MockHMDBuildSettings.asset.meta | 8 ++++++++ .../XR/Settings/Open XR Package Settings.asset | 16 ++++++++-------- Assets/XR/Settings/OpenXR Editor Settings.asset | 3 ++- Assets/XR/XRGeneralSettings.asset | 3 ++- Packages/manifest.json | 1 + Packages/packages-lock.json | 9 +++++++++ ProjectSettings/EditorBuildSettings.asset | 2 ++ ProjectSettings/ProjectSettings.asset | 2 +- 12 files changed, 74 insertions(+), 13 deletions(-) create mode 100644 Assets/XR/Loaders/MockHMDLoader.asset create mode 100644 Assets/XR/Loaders/MockHMDLoader.asset.meta create mode 100644 Assets/XR/Settings/MockHMDBuildSettings.asset create mode 100644 Assets/XR/Settings/MockHMDBuildSettings.asset.meta diff --git a/Assets/MirageXR/Tutorial/ArrowHighlightingTutorialStep.cs b/Assets/MirageXR/Tutorial/ArrowHighlightingTutorialStep.cs index 8cd8ec938..ab30f0918 100644 --- a/Assets/MirageXR/Tutorial/ArrowHighlightingTutorialStep.cs +++ b/Assets/MirageXR/Tutorial/ArrowHighlightingTutorialStep.cs @@ -12,7 +12,7 @@ namespace MirageXR public abstract class ArrowHighlightingTutorialStep : TutorialStep { protected string instructionText; - protected GameObject arrow; + protected TutorialArrow arrow; protected Vector3? arrowPositionOffset; protected Vector3? arrowRotationOffset; @@ -52,7 +52,7 @@ protected void SetupArrow() if (highlightedObject != null) { TutorialArrowFactory factory = TutorialArrowFactory.Instance(); - //this.arrow = factory.CreateArrow(); + this.arrow = factory.CreateArrow(TutorialArrowFactory.ArrowType.DEFAULT); TutorialArrow arrowScript = arrow.GetComponent(); if (arrowScript is Tutorial3DArrow) diff --git a/Assets/XR/Loaders/MockHMDLoader.asset b/Assets/XR/Loaders/MockHMDLoader.asset new file mode 100644 index 000000000..431e1d02e --- /dev/null +++ b/Assets/XR/Loaders/MockHMDLoader.asset @@ -0,0 +1,14 @@ +%YAML 1.1 +%TAG !u! tag:unity3d.com,2011: +--- !u!114 &11400000 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 0} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 0660e8fc444734757ae6f6c40c2d33a0, type: 3} + m_Name: MockHMDLoader + m_EditorClassIdentifier: diff --git a/Assets/XR/Loaders/MockHMDLoader.asset.meta b/Assets/XR/Loaders/MockHMDLoader.asset.meta new file mode 100644 index 000000000..91942cb43 --- /dev/null +++ b/Assets/XR/Loaders/MockHMDLoader.asset.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 8c81a910c77264b2b84be372b9ba5a82 +NativeFormatImporter: + externalObjects: {} + mainObjectFileID: 11400000 + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/XR/Settings/MockHMDBuildSettings.asset b/Assets/XR/Settings/MockHMDBuildSettings.asset new file mode 100644 index 000000000..c6126a5b0 --- /dev/null +++ b/Assets/XR/Settings/MockHMDBuildSettings.asset @@ -0,0 +1,17 @@ +%YAML 1.1 +%TAG !u! tag:unity3d.com,2011: +--- !u!114 &11400000 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 0} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: c8bf066bf8a4947a1be502d267edb82f, type: 3} + m_Name: MockHMDBuildSettings + m_EditorClassIdentifier: + renderMode: 1 + foveationEnabled: 0 + gazeSimulationMode: 0 diff --git a/Assets/XR/Settings/MockHMDBuildSettings.asset.meta b/Assets/XR/Settings/MockHMDBuildSettings.asset.meta new file mode 100644 index 000000000..136b15e6b --- /dev/null +++ b/Assets/XR/Settings/MockHMDBuildSettings.asset.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: a148c5c03c6464fcf9211037664a662a +NativeFormatImporter: + externalObjects: {} + mainObjectFileID: 11400000 + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/XR/Settings/Open XR Package Settings.asset b/Assets/XR/Settings/Open XR Package Settings.asset index d6e55400c..07a3a4a5c 100644 --- a/Assets/XR/Settings/Open XR Package Settings.asset +++ b/Assets/XR/Settings/Open XR Package Settings.asset @@ -1588,7 +1588,7 @@ MonoBehaviour: m_Script: {fileID: 11500000, guid: f928d0d73a35f294fbe357ca17aa3547, type: 3} m_Name: MicrosoftHandInteraction Standalone m_EditorClassIdentifier: - m_enabled: 0 + m_enabled: 1 nameUi: Microsoft Hand Interaction Profile version: 0.0.1 featureIdInternal: com.unity.openxr.feature.input.handtracking @@ -1808,7 +1808,7 @@ MonoBehaviour: m_Script: {fileID: 11500000, guid: 2a24be4b5ebfe5f4d8ed1de9b25cb7aa, type: 3} m_Name: HandCommonPosesInteraction Standalone m_EditorClassIdentifier: - m_enabled: 0 + m_enabled: 1 nameUi: Hand Interaction Poses version: 0.0.1 featureIdInternal: com.unity.openxr.feature.input.handinteractionposes @@ -2044,7 +2044,7 @@ MonoBehaviour: m_Script: {fileID: 11500000, guid: 761fdd4502cb7a84e9ec7a2b24f33f37, type: 3} m_Name: MicrosoftMotionControllerProfile Standalone m_EditorClassIdentifier: - m_enabled: 0 + m_enabled: 1 nameUi: Microsoft Motion Controller Profile version: 0.0.1 featureIdInternal: com.unity.openxr.feature.input.microsoftmotioncontroller @@ -3004,7 +3004,7 @@ MonoBehaviour: m_Script: {fileID: 11500000, guid: c79c911b38743a649b1c1eddb5097202, type: 3} m_Name: HandTrackingFeaturePlugin Standalone m_EditorClassIdentifier: - m_enabled: 0 + m_enabled: 1 nameUi: Hand Tracking version: 1.10.0 featureIdInternal: com.microsoft.openxr.feature.handtracking @@ -3092,7 +3092,7 @@ MonoBehaviour: m_Script: {fileID: 11500000, guid: 0c8f1ce8139888c4ab621f6b3c8bb558, type: 3} m_Name: MotionControllerFeaturePlugin Standalone m_EditorClassIdentifier: - m_enabled: 0 + m_enabled: 1 nameUi: Motion Controller Model version: 1.10.0 featureIdInternal: com.microsoft.openxr.feature.controller @@ -3536,7 +3536,7 @@ MonoBehaviour: - {fileID: 2223349053056229755} - {fileID: -6752644166009978575} m_renderMode: 1 - m_depthSubmissionMode: 0 + m_depthSubmissionMode: 1 m_optimizeBufferDiscards: 0 m_symmetricProjection: 0 --- !u!114 &4047102087758151018 @@ -3956,7 +3956,7 @@ MonoBehaviour: m_Script: {fileID: 11500000, guid: b3cf79659a011bd419c7a2a30eb74e9a, type: 3} m_Name: EyeGazeInteraction Standalone m_EditorClassIdentifier: - m_enabled: 0 + m_enabled: 1 nameUi: Eye Gaze Interaction Profile version: 0.0.1 featureIdInternal: com.unity.openxr.feature.input.eyetracking @@ -4561,7 +4561,7 @@ MonoBehaviour: m_Script: {fileID: 11500000, guid: 3f8ec2975f18d5e479159feb34b4dc86, type: 3} m_Name: MixedRealityFeaturePlugin Standalone m_EditorClassIdentifier: - m_enabled: 0 + m_enabled: 1 nameUi: Mixed Reality Features version: 1.10.0 featureIdInternal: com.microsoft.openxr.feature.hololens diff --git a/Assets/XR/Settings/OpenXR Editor Settings.asset b/Assets/XR/Settings/OpenXR Editor Settings.asset index 66a55d3c5..cc3869c73 100644 --- a/Assets/XR/Settings/OpenXR Editor Settings.asset +++ b/Assets/XR/Settings/OpenXR Editor Settings.asset @@ -14,6 +14,7 @@ MonoBehaviour: m_EditorClassIdentifier: Keys: 010000000e000000 Values: - - featureSets: [] + - featureSets: + - com.microsoft.openxr.featureset.wmr - featureSets: [] m_vulkanAdditionalGraphicsQueue: 0 diff --git a/Assets/XR/XRGeneralSettings.asset b/Assets/XR/XRGeneralSettings.asset index f61034b2a..2cb3b9888 100644 --- a/Assets/XR/XRGeneralSettings.asset +++ b/Assets/XR/XRGeneralSettings.asset @@ -140,4 +140,5 @@ MonoBehaviour: m_RequiresSettingsUpdate: 0 m_AutomaticLoading: 0 m_AutomaticRunning: 0 - m_Loaders: [] + m_Loaders: + - {fileID: 11400000, guid: c73c5a5c556b15941bedcb9cf431f61a, type: 2} diff --git a/Packages/manifest.json b/Packages/manifest.json index b3e4dd166..95706958b 100644 --- a/Packages/manifest.json +++ b/Packages/manifest.json @@ -46,6 +46,7 @@ "com.unity.xr.arfoundation": "5.0.7", "com.unity.xr.arkit": "5.0.7", "com.unity.xr.management": "4.4.1", + "com.unity.xr.mock-hmd": "1.4.0-preview.2", "com.unity.xr.oculus": "4.0.0", "com.unity.xr.openxr": "1.10.0", "com.utilities.async": "https://github.com/RageAgainstThePixel/com.utilities.async.git#upm", diff --git a/Packages/packages-lock.json b/Packages/packages-lock.json index ab7a74221..feba1cb8d 100644 --- a/Packages/packages-lock.json +++ b/Packages/packages-lock.json @@ -505,6 +505,15 @@ }, "url": "https://packages.unity.com" }, + "com.unity.xr.mock-hmd": { + "version": "1.4.0-preview.2", + "depth": 0, + "source": "registry", + "dependencies": { + "com.unity.xr.management": "4.0.1" + }, + "url": "https://packages.unity.com" + }, "com.unity.xr.oculus": { "version": "4.0.0", "depth": 0, diff --git a/ProjectSettings/EditorBuildSettings.asset b/ProjectSettings/EditorBuildSettings.asset index e2828fa1b..c53707ba4 100644 --- a/ProjectSettings/EditorBuildSettings.asset +++ b/ProjectSettings/EditorBuildSettings.asset @@ -36,3 +36,5 @@ EditorBuildSettings: type: 2} com.unity.xr.openxr.settings4: {fileID: 11400000, guid: b3a3cc9ae17858f4a9346913737e2188, type: 2} + xr.sdk.mock-hmd.settings: {fileID: 11400000, guid: a148c5c03c6464fcf9211037664a662a, + type: 2} diff --git a/ProjectSettings/ProjectSettings.asset b/ProjectSettings/ProjectSettings.asset index 721b129be..648ab2b35 100644 --- a/ProjectSettings/ProjectSettings.asset +++ b/ProjectSettings/ProjectSettings.asset @@ -51,7 +51,7 @@ PlayerSettings: defaultScreenHeight: 768 defaultScreenWidthWeb: 960 defaultScreenHeightWeb: 600 - m_StereoRenderingPath: 0 + m_StereoRenderingPath: 1 m_ActiveColorSpace: 0 m_SpriteBatchVertexThreshold: 300 m_MTRendering: 1