Starting on UI panel for status as well as AlignmentManager.

This commit is contained in:
Jared Bienz 2018-07-20 14:57:06 -05:00
Родитель ab8bdea70f
Коммит e137c73287
6 изменённых файлов: 35840 добавлений и 6 удалений

Разница между файлами не показана из-за своего большого размера Загрузить разницу

Просмотреть файл

@ -0,0 +1,8 @@
fileFormatVersion: 2
guid: 1b1cd4c719f517049869491c70c96e4a
folderAsset: yes
DefaultImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:

Просмотреть файл

@ -0,0 +1,65 @@
//
// Copyright (c) Microsoft. All rights reserved.
// Licensed under the MIT license.
//
// MIT License:
// Permission is hereby granted, free of charge, to any person obtaining
// a copy of this software and associated documentation files (the
// "Software"), to deal in the Software without restriction, including
// without limitation the rights to use, copy, modify, merge, publish,
// distribute, sublicense, and/or sell copies of the Software, and to
// permit persons to whom the Software is furnished to do so, subject to
// the following conditions:
//
// The above copyright notice and this permission notice shall be
// included in all copies or substantial portions of the Software.
//
// THE SOFTWARE IS PROVIDED ""AS IS"", WITHOUT WARRANTY OF ANY KIND,
// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
//
using System.Collections;
using System.Collections.Generic;
using UnityEngine;
namespace Microsoft.MR.SharedAlignment
{
/// <summary>
/// The main manager for shared alignment control.
/// </summary>
public class AlignmentManager : MonoBehaviour
{
#region Unity Inspector Variables
[Tooltip("The optimized model")]
public GameObject optimizedModel;
[Tooltip("The original unoptimized model")]
public GameObject originalModel;
#endregion // Unity Inspector Variables
#region Public Methods
/// <summary>
/// Shows the optimized model.
/// </summary>
public void ShowOptimized()
{
if (originalModel != null) { originalModel.SetActive(false); }
if (optimizedModel != null) { optimizedModel.SetActive(true); }
}
/// <summary>
/// Shows the original model
/// </summary>
public void ShowOriginal()
{
if (optimizedModel != null) { optimizedModel.SetActive(false); }
if (originalModel != null) { originalModel.SetActive(true); }
}
#endregion // Public Methods
}
}

Просмотреть файл

@ -0,0 +1,11 @@
fileFormatVersion: 2
guid: 6a1e65e5f34258e45b11979a8e9a6b9f
MonoImporter:
externalObjects: {}
serializedVersion: 2
defaultReferences: []
executionOrder: 0
icon: {instanceID: 0}
userData:
assetBundleName:
assetBundleVariant:

Просмотреть файл

@ -1303,8 +1303,12 @@
<Compile Include="Assets\HoloToolkit-Examples\UX\Scripts\Widgets\ScaleThemeWidget.cs" />
<Compile Include="Assets\HoloToolkit-Examples\UX\Scripts\Widgets\TextMeshColorThemeWidget.cs" />
<Compile Include="Assets\HoloToolkit-Examples\UX\Scripts\Widgets\TextureThemeWidget.cs" />
<Compile Include="Assets\SharedAlignment\Scripts\AlignmentManager.cs" />
</ItemGroup>
<ItemGroup>
<None Include="..\..\LICENSE.licenseheader">
<Link>LICENSE.licenseheader</Link>
</None>
<None Include="Assets\HoloToolkit-Examples\Medical\Shaders\PlaneCut.cginc" />
<None Include="Assets\HoloToolkit-Examples\Medical\Shaders\VolumeRenderShared.cginc" />
<None Include="Assets\HoloToolkit-Examples\Medical\Shaders\VolumeRenderSlice.shader" />

Просмотреть файл

@ -3,8 +3,6 @@ Microsoft Visual Studio Solution File, Format Version 12.00
# Visual Studio 2017
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "SharedAlignment", "SharedAlignment.csproj", "{822160F1-D84B-4B71-F9E7-6D66D3834A0B}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "SharedAlignment.Player", "SharedAlignment.Player.csproj", "{035EB7C2-8746-2628-7438-0AAD0CCF7EB5}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Unity.PackageManagerUI.Editor", "Unity.PackageManagerUI.Editor.csproj", "{6877705C-FBD9-0C4F-5AFB-6FB431E5D39D}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "UnityEditor.StandardEvents", "UnityEditor.StandardEvents.csproj", "{6800202F-4402-D405-F8CB-03DC7BD78B92}"
@ -21,10 +19,6 @@ Global
{822160F1-D84B-4B71-F9E7-6D66D3834A0B}.Debug|Any CPU.Build.0 = Debug|Any CPU
{822160F1-D84B-4B71-F9E7-6D66D3834A0B}.Release|Any CPU.ActiveCfg = Release|Any CPU
{822160F1-D84B-4B71-F9E7-6D66D3834A0B}.Release|Any CPU.Build.0 = Release|Any CPU
{035EB7C2-8746-2628-7438-0AAD0CCF7EB5}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{035EB7C2-8746-2628-7438-0AAD0CCF7EB5}.Debug|Any CPU.Build.0 = Debug|Any CPU
{035EB7C2-8746-2628-7438-0AAD0CCF7EB5}.Release|Any CPU.ActiveCfg = Release|Any CPU
{035EB7C2-8746-2628-7438-0AAD0CCF7EB5}.Release|Any CPU.Build.0 = Release|Any CPU
{6877705C-FBD9-0C4F-5AFB-6FB431E5D39D}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{6877705C-FBD9-0C4F-5AFB-6FB431E5D39D}.Debug|Any CPU.Build.0 = Debug|Any CPU
{6877705C-FBD9-0C4F-5AFB-6FB431E5D39D}.Release|Any CPU.ActiveCfg = Release|Any CPU