Skip to content

Commit

Permalink
Initial commit
Browse files Browse the repository at this point in the history
  • Loading branch information
Malik-Jehangir committed Feb 24, 2020
1 parent 3a06632 commit 972f76f
Show file tree
Hide file tree
Showing 19,472 changed files with 443,912 additions and 0 deletions.
The diff you're trying to view is too large. We only load the first 3000 changed files.
194 changes: 194 additions & 0 deletions Active Structure NEW.sln

Large diffs are not rendered by default.

800 changes: 800 additions & 0 deletions Assembly-CSharp.csproj

Large diffs are not rendered by default.

500 changes: 500 additions & 0 deletions Assets/ActiveStructure.unity

Large diffs are not rendered by default.

7 changes: 7 additions & 0 deletions Assets/ActiveStructure.unity.meta

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

8 changes: 8 additions & 0 deletions Assets/MixedRealityToolkit.Generated.meta

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

8 changes: 8 additions & 0 deletions Assets/MixedRealityToolkit.Generated/CustomProfiles.meta

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Original file line number Diff line number Diff line change
@@ -0,0 +1,56 @@
%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: 7612acbc1a4a4ed0afa5f4ccbe42bee4, type: 3}
m_Name: New MixedRealityToolkitConfigurationProfile
m_EditorClassIdentifier:
isCustomProfile: 1
targetExperienceScale: 3
enableCameraSystem: 1
cameraProfile: {fileID: 11400000, guid: 8089ccfdd4494cd38f676f9fc1f46a04, type: 2}
cameraSystemType:
reference: Microsoft.MixedReality.Toolkit.CameraSystem.MixedRealityCameraSystem,
Microsoft.MixedReality.Toolkit.Services.CameraSystem
enableInputSystem: 1
inputSystemProfile: {fileID: 11400000, guid: ad2080e8e71c35f4e8bcde94fa68f098, type: 2}
inputSystemType:
reference: Microsoft.MixedReality.Toolkit.Input.MixedRealityInputSystem, Microsoft.MixedReality.Toolkit.Services.InputSystem
enableBoundarySystem: 1
boundarySystemType:
reference: Microsoft.MixedReality.Toolkit.Boundary.MixedRealityBoundarySystem,
Microsoft.MixedReality.Toolkit.Services.BoundarySystem
boundaryVisualizationProfile: {fileID: 11400000, guid: 6d28cce596b44bd3897ca86f8b24e076,
type: 2}
enableTeleportSystem: 1
teleportSystemType:
reference: Microsoft.MixedReality.Toolkit.Teleport.MixedRealityTeleportSystem,
Microsoft.MixedReality.Toolkit.Services.TeleportSystem
enableSpatialAwarenessSystem: 0
spatialAwarenessSystemType:
reference: Microsoft.MixedReality.Toolkit.SpatialAwareness.MixedRealitySpatialAwarenessSystem,
Microsoft.MixedReality.Toolkit.Services.SpatialAwarenessSystem
spatialAwarenessSystemProfile: {fileID: 11400000, guid: 97da727944a3d7b4caf42d2273271a24,
type: 2}
diagnosticsSystemProfile: {fileID: 11400000, guid: 478436bd1083882479a52d067e98e537,
type: 2}
enableDiagnosticsSystem: 0
diagnosticsSystemType:
reference: Microsoft.MixedReality.Toolkit.Diagnostics.MixedRealityDiagnosticsSystem,
Microsoft.MixedReality.Toolkit.Services.DiagnosticsSystem
sceneSystemProfile: {fileID: 11400000, guid: 069efa41032a317409790a6a08435311, type: 2}
enableSceneSystem: 0
sceneSystemType:
reference: Microsoft.MixedReality.Toolkit.SceneSystem.MixedRealitySceneSystem,
Microsoft.MixedReality.Toolkit.Services.SceneSystem
registeredServiceProvidersProfile: {fileID: 11400000, guid: efbaf6ea540c69f4fb75415a5d145a53,
type: 2}
useServiceInspectors: 1
renderDepthBuffer: 0

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

8 changes: 8 additions & 0 deletions Assets/MixedRealityToolkit.Providers.meta

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

21 changes: 21 additions & 0 deletions Assets/MixedRealityToolkit.Providers/License.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
MIT License

Copyright (c) 2019 Microsoft Corporation

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.
7 changes: 7 additions & 0 deletions Assets/MixedRealityToolkit.Providers/License.txt.meta

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Empty file.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

8 changes: 8 additions & 0 deletions Assets/MixedRealityToolkit.Providers/ObjectMeshObserver.meta

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License. See LICENSE in the project root for license information.

using System.Reflection;

[assembly: AssemblyVersion("2.2.0.0")]
[assembly: AssemblyFileVersion("2.2.0.0")]

[assembly: AssemblyProduct("Microsoft® Mixed Reality Toolkit Providers")]
[assembly: AssemblyCopyright("Copyright © Microsoft Corporation")]

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
{
"name": "Microsoft.MixedReality.Toolkit.Providers.ObjectMeshObserver",
"references": [
"Microsoft.MixedReality.Toolkit",
"Microsoft.MixedReality.Toolkit.Editor.Inspectors",
"Microsoft.MixedReality.Toolkit.Editor.Utilities"
],
"optionalUnityReferences": [],
"includePlatforms": [
"Editor"
],
"excludePlatforms": [],
"allowUnsafeCode": false,
"overrideReferences": false,
"precompiledReferences": [],
"autoReferenced": true,
"defineConstraints": []
}

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
%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: e3c1af9621e40064b907d18085e21fb7, type: 3}
m_Name: DefaultObjectMeshObserverProfile
m_EditorClassIdentifier:
isCustomProfile: 0
startupBehavior: 0
isStationaryObserver: 0
observationExtents: {x: 3, y: 3, z: 3}
observerVolumeType: 1
updateInterval: 3.5
meshPhysicsLayer: 31
levelOfDetail: 0
trianglesPerCubicMeter: 0
recalculateNormals: 1
displayOption: 1
visibleMaterial: {fileID: 2100000, guid: 47c3d3b0d8143e3489351498fceed55d, type: 2}
occlusionMaterial: {fileID: 2100000, guid: a809c7ea182b699409443d46d5b42435, type: 2}
spatialMeshObject: {fileID: 100000, guid: 2d029f2a1321676428ce89872882c605, type: 3}

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Original file line number Diff line number Diff line change
@@ -0,0 +1,63 @@
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License. See LICENSE in the project root for license information.

using System.Collections.Generic;
using System.IO;
using UnityEditor.Experimental.AssetImporters;
using UnityEngine;

namespace Microsoft.MixedReality.Toolkit.SpatialObjectMeshObserver.RoomFile
{
[ScriptedImporter(1, "room")]
public class RoomFileImporter : ScriptedImporter
{
public override void OnImportAsset(AssetImportContext context)
{
FileInfo fileInfo = new FileInfo(context.assetPath);
string name = fileInfo.Name.Split(new char[] { '.' })[0];

IList<Mesh> meshes;

using (BinaryReader reader = OpenFileForRead(fileInfo.FullName))
{
meshes = RoomFileSerializer.Deserialize(reader);
}

GameObject model = new GameObject(name);
context.AddObjectToAsset(name, model);

for (int i = 0; i < meshes.Count; i++)
{
string meshName = $"{name}_{i}";
GameObject meshObject = new GameObject(meshName, new System.Type[] { typeof(MeshRenderer), typeof(MeshFilter) });

meshes[i].name = meshName;
meshObject.GetComponent<MeshFilter>().sharedMesh = meshes[i];
context.AddObjectToAsset(meshName, meshes[i]);
meshObject.transform.parent = model.transform;
}
}

/// <summary>
/// Opens the specified file for reading.
/// </summary>
/// <param name="fileName">The name of the file, including extension. </param>
/// <returns>The reader used to read the file's contents.</returns>
private BinaryReader OpenFileForRead(string fileName)
{
if (!File.Exists(fileName))
{
Debug.LogError($"Unable to open {fileName}, the file does not exist.");
return null;
}

Stream stream = new FileStream(fileName, FileMode.Open, FileAccess.Read);
if (stream == null)
{
return null;
}

return new BinaryReader(stream);
}
}
}

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading

0 comments on commit 972f76f

Please sign in to comment.