Commit b23a6173 authored by BlackAngle233's avatar BlackAngle233
Browse files

FunctionMesh test

parent 659d04e2
/MRTK test2
/build test
/MRTK package/MRTK.Tutorials.PCHolographicRemoting.unitypackage
\ No newline at end of file
%YAML 1.1
%TAG !u! tag:unity3d.com,2011:
--- !u!21 &2100000
Material:
serializedVersion: 6
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_Name: Appx-Platform
m_Shader: {fileID: 4800000, guid: 5bdea20278144b11916d77503ba1467a, type: 3}
m_ShaderKeywords: _BORDER_LIGHT_USES_HOVER_COLOR _DISABLE_ALBEDO_MAP _INNER_GLOW
_LIGHTMAPPING_REALTIME _SPECULAR_HIGHLIGHTS
m_LightmapFlags: 1
m_EnableInstancingVariants: 1
m_DoubleSidedGI: 0
m_CustomRenderQueue: 2000
stringTagMap:
RenderType: Opaque
disabledShaderPasses: []
m_SavedProperties:
serializedVersion: 3
m_TexEnvs:
- _BumpMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _ChannelMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _DetailAlbedoMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _DetailMask:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _DetailNormalMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _EmissionMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _IridescentSpectrumMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _MainTex:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _MetallicGlossMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _NormalMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _OcclusionMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _ParallaxMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
m_Floats:
- _AlbedoAlphaMode: 0
- _AlbedoAssignedAtRuntime: 0
- _BlendOp: 0
- _BlendedClippingWidth: 1
- _BorderLight: 0
- _BorderLightOpaque: 0
- _BorderLightOpaqueAlpha: 1
- _BorderLightReplacesAlbedo: 0
- _BorderLightUsesHoverColor: 1
- _BorderMinValue: 0.138
- _BorderWidth: 0.187
- _BumpScale: 1
- _ClippingBorder: 0
- _ClippingBorderWidth: 0.025
- _ClippingBox: 0
- _ClippingPlane: 0
- _ClippingPlaneBorder: 0
- _ClippingPlaneBorderWidth: 0.025
- _ClippingSphere: 0
- _ColorWriteMask: 15
- _CullMode: 2
- _CustomMode: 0
- _Cutoff: 0.5
- _DetailNormalMapScale: 1
- _DirectionalLight: 0
- _DstBlend: 0
- _EdgeSmoothingValue: 0.2
- _EmissionScaleUI: 0
- _EnableChannelMap: 0
- _EnableEmission: 0
- _EnableHoverColorOpaqueOverride: 0
- _EnableHoverColorOverride: 0
- _EnableLocalSpaceTriplanarMapping: 0
- _EnableNormalMap: 0
- _EnableProximityLightColorOverride: 0
- _EnableTriplanarMapping: 0
- _EnvironmentColorIntensity: 0.5
- _EnvironmentColorThreshold: 1.5
- _EnvironmentColoring: 0
- _FadeBeginDistance: 0.85
- _FadeCompleteDistance: 0.5
- _FadeMinValue: 0
- _FluentLightIntensity: 1
- _GlossMapScale: 1
- _Glossiness: 0
- _GlossyReflections: 1
- _HoverLight: 0
- _HoverLightOpaque: 0
- _IgnoreZScale: 0
- _IndependentCorners: 0
- _InnerGlow: 1
- _InnerGlowPower: 32
- _InstancedColor: 0
- _Iridescence: 0
- _IridescenceAngle: -0.78
- _IridescenceIntensity: 0.5
- _IridescenceThreshold: 0.05
- _Lightmapping: 1
- _Metallic: 0
- _Mode: 0
- _NearLightFade: 0
- _NearPlaneFade: 0
- _NormalMapScale: 1
- _OcclusionStrength: 1
- _Parallax: 0.02
- _ProximityLight: 0
- _ProximityLightSubtractive: 0
- _ProximityLightTwoSided: 0
- _Reflections: 0
- _Refraction: 0
- _RefractiveIndex: 1.1
- _RenderQueueOverride: -1
- _RimLight: 0
- _RimPower: 0.25
- _RoundCornerMargin: 0
- _RoundCornerRadius: 0.052
- _RoundCorners: 0
- _Smoothness: 0.5
- _SmoothnessTextureChannel: 0
- _SpecularHighlights: 1
- _SphericalHarmonics: 0
- _SrcBlend: 1
- _Stencil: 0
- _StencilComparison: 0
- _StencilOperation: 0
- _StencilReference: 0
- _TriplanarMappingBlendSharpness: 4
- _UVSec: 0
- _VertexColors: 0
- _VertexExtrusion: 0
- _VertexExtrusionSmoothNormals: 0
- _VertexExtrusionValue: 0
- _ZOffsetFactor: 0
- _ZOffsetUnits: 0
- _ZTest: 4
- _ZWrite: 1
m_Colors:
- _ClipPlane: {r: 0, g: 1, b: 0, a: 0}
- _ClippingBorderColor: {r: 1, g: 0.2, b: 0, a: 1}
- _ClippingPlaneBorderColor: {r: 1, g: 0.2, b: 0, a: 1}
- _Color: {r: 0.06915272, g: 0.42746955, b: 0.6981132, a: 0.8862745}
- _EmissionColor: {r: 0, g: 0, b: 0, a: 0}
- _EmissionColorUI: {r: 1, g: 1, b: 1, a: 1}
- _EmissiveColor: {r: 0, g: 0, b: 0, a: 1}
- _EnvironmentColorX: {r: 1, g: 0, b: 0, a: 1}
- _EnvironmentColorY: {r: 0, g: 1, b: 0, a: 1}
- _EnvironmentColorZ: {r: 0, g: 0, b: 1, a: 1}
- _HoverColorOpaqueOverride: {r: 1, g: 1, b: 1, a: 1}
- _HoverColorOverride: {r: 1, g: 1, b: 1, a: 1}
- _InnerGlowColor: {r: 0.3773585, g: 0.3773585, b: 0.3773585, a: 1}
- _ProximityLightCenterColorOverride: {r: 1, g: 0, b: 0, a: 0}
- _ProximityLightMiddleColorOverride: {r: 0, g: 1, b: 0, a: 0.5}
- _ProximityLightOuterColorOverride: {r: 0, g: 0, b: 1, a: 1}
- _RimColor: {r: 0.5, g: 0.5, b: 0.5, a: 1}
- _RoundCornersRadius: {r: 0.5, g: 0.5, b: 0.5, a: 0.5}
%YAML 1.1
%TAG !u! tag:unity3d.com,2011:
--- !u!1 &2727431865389705374
GameObject:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
serializedVersion: 6
m_Component:
- component: {fileID: 2727431865389705369}
- component: {fileID: 2727431865389705371}
- component: {fileID: 2727431865389705368}
m_Layer: 0
m_Name: BackPlate
m_TagString: Untagged
m_Icon: {fileID: 0}
m_NavMeshLayer: 0
m_StaticEditorFlags: 0
m_IsActive: 1
--- !u!4 &2727431865389705369
Transform:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 2727431865389705374}
m_LocalRotation: {x: -0, y: -0, z: -0, w: 1}
m_LocalPosition: {x: 0, y: 0.0289, z: 0.01}
m_LocalScale: {x: 0.032, y: 0.04, z: 0.02}
m_Children: []
m_Father: {fileID: 2727431866408081646}
m_RootOrder: 0
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
--- !u!33 &2727431865389705371
MeshFilter:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 2727431865389705374}
m_Mesh: {fileID: 10210, guid: 0000000000000000e000000000000000, type: 0}
--- !u!23 &2727431865389705368
MeshRenderer:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 2727431865389705374}
m_Enabled: 1
m_CastShadows: 1
m_ReceiveShadows: 1
m_DynamicOccludee: 1
m_MotionVectors: 1
m_LightProbeUsage: 1
m_ReflectionProbeUsage: 1
m_RayTracingMode: 2
m_RenderingLayerMask: 1
m_RendererPriority: 0
m_Materials:
- {fileID: 2100000, guid: ec72a3a105768f746b556a8dfdae61a8, type: 2}
m_StaticBatchInfo:
firstSubMesh: 0
subMeshCount: 0
m_StaticBatchRoot: {fileID: 0}
m_ProbeAnchor: {fileID: 0}
m_LightProbeVolumeOverride: {fileID: 0}
m_ScaleInLightmap: 1
m_ReceiveGI: 1
m_PreserveUVs: 0
m_IgnoreNormalsForChartDetection: 0
m_ImportantGI: 0
m_StitchLightmapSeams: 0
m_SelectedEditorRenderState: 3
m_MinimumChartSize: 4
m_AutoUVMaxDistance: 0.5
m_AutoUVMaxAngle: 89
m_LightmapParameters: {fileID: 0}
m_SortingLayerID: 0
m_SortingLayer: 0
m_SortingOrder: 0
--- !u!1 &2727431865493585564
GameObject:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
serializedVersion: 6
m_Component:
- component: {fileID: 2727431865493585567}
- component: {fileID: 2727431865493585560}
- component: {fileID: 2727431865493585561}
- component: {fileID: 2727431865493585566}
- component: {fileID: 917949849985424103}
- component: {fileID: 6620965912072422122}
m_Layer: 0
m_Name: HandSpatialMapButton
m_TagString: Untagged
m_Icon: {fileID: 0}
m_NavMeshLayer: 0
m_StaticEditorFlags: 0
m_IsActive: 0
--- !u!4 &2727431865493585567
Transform:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 2727431865493585564}
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
m_LocalPosition: {x: 0.369, y: -0.269, z: 1}
m_LocalScale: {x: 1, y: 1, z: 1}
m_Children:
- {fileID: 2727431866408081646}
m_Father: {fileID: 0}
m_RootOrder: 0
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
--- !u!114 &2727431865493585560
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 2727431865493585564}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: 248664dc0e60dca4fb35d70cd0c5695b, type: 3}
m_Name:
m_EditorClassIdentifier:
drawBoundsGizmo: 1
--- !u!114 &2727431865493585561
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 2727431865493585564}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: b55691ad5b034fe6966763a6e23818d2, type: 3}
m_Name:
m_EditorClassIdentifier:
trackedTargetType: 6
trackedHandness: 3
trackedHandJoint: 2
transformOverride: {fileID: 0}
additionalOffset: {x: 0, y: 0, z: 0.1}
additionalRotation: {x: 0, y: -20, z: 0}
updateSolvers: 1
--- !u!114 &2727431865493585566
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 2727431865493585564}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: 956af6ee031a2eb47b9c0ab5dcd50fd7, type: 3}
m_Name:
m_EditorClassIdentifier:
updateLinkedTransform: 0
moveLerpTime: 0.1
rotateLerpTime: 0.1
scaleLerpTime: 0
maintainScale: 1
smoothing: 1
lifetime: 0
safeZone: 0
safeZoneBuffer: 0.15
updateWhenOppositeHandNear: 0
hideHandCursorsOnActivate: 1
rotationBehavior: 2
onHandActivate:
m_PersistentCalls:
m_Calls: []
onHandDeactivate:
m_PersistentCalls:
m_Calls: []
onFirstHandDetected:
m_PersistentCalls:
m_Calls:
- m_Target: {fileID: 2727431866408081647}
m_MethodName: SetActive
m_Mode: 6
m_Arguments:
m_ObjectArgument: {fileID: 0}
m_ObjectArgumentAssemblyTypeName: UnityEngine.Object, UnityEngine
m_IntArgument: 0
m_FloatArgument: 0
m_StringArgument:
m_BoolArgument: 1
m_CallState: 2
onLastHandLost:
m_PersistentCalls:
m_Calls:
- m_Target: {fileID: 2727431866408081647}
m_MethodName: SetActive
m_Mode: 6
m_Arguments:
m_ObjectArgument: {fileID: 0}
m_ObjectArgumentAssemblyTypeName: UnityEngine.Object, UnityEngine
m_IntArgument: 0
m_FloatArgument: 0
m_StringArgument:
m_BoolArgument: 0
m_CallState: 2
facingThreshold: 75
requireFlatHand: 0
flatHandThreshold: 45
--- !u!114 &917949849985424103
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 2727431865493585564}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: 0f27531d515ec6a44a1ee19fa69eb509, type: 3}
m_Name:
m_EditorClassIdentifier:
--- !u!114 &6620965912072422122
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 2727431865493585564}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: 1410eac1ae94b4d4492a09cc368e152c, type: 3}
m_Name:
m_EditorClassIdentifier:
states: {fileID: 11400000, guid: 5eac1712038236e4b8ffdb3893804fe1, type: 2}
InputActionId: 0
isGlobal: 0
Dimensions: 1
dimensionIndex: 0
startDimensionIndex: 0
CanSelect: 1
CanDeselect: 1
VoiceCommand:
voiceRequiresFocus: 1
profiles:
- Target: {fileID: 0}
Themes:
- {fileID: 0}
OnClick:
m_PersistentCalls:
m_Calls:
- m_Target: {fileID: 917949849985424103}
m_MethodName: ToggleSpatialMaps
m_Mode: 1
m_Arguments:
m_ObjectArgument: {fileID: 0}
m_ObjectArgumentAssemblyTypeName: UnityEngine.Object, UnityEngine
m_IntArgument: 0
m_FloatArgument: 0
m_StringArgument:
m_BoolArgument: 0
m_CallState: 2
Events: []
enabledOnStart: 1
--- !u!1 &2727431866408081647
GameObject:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
serializedVersion: 6
m_Component:
- component: {fileID: 2727431866408081646}
m_Layer: 0
m_Name: Visuals
m_TagString: Untagged
m_Icon: {fileID: 0}
m_NavMeshLayer: 0
m_StaticEditorFlags: 0
m_IsActive: 1
--- !u!4 &2727431866408081646
Transform:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 2727431866408081647}
m_LocalRotation: {x: -0, y: -0, z: -0, w: 1}
m_LocalPosition: {x: 0, y: 0, z: 0}
m_LocalScale: {x: 1, y: 1, z: 1}
m_Children:
- {fileID: 2727431865389705369}
- {fileID: 7139619605013124960}
m_Father: {fileID: 2727431865493585567}
m_RootOrder: 0
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
--- !u!1 &8967150157657768027
GameObject:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
serializedVersion: 6
m_Component:
- component: {fileID: 7139619605013124960}
- component: {fileID: 4035158392542168902}
m_Layer: 0
m_Name: ButtonCollection
m_TagString: Untagged
m_Icon: {fileID: 0}
m_NavMeshLayer: 0
m_StaticEditorFlags: 0
m_IsActive: 1
--- !u!4 &7139619605013124960
Transform:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 8967150157657768027}
m_LocalRotation: {x: -0, y: -0, z: -0, w: 1}
m_LocalPosition: {x: 0, y: 0, z: 0}
m_LocalScale: {x: 1, y: 1, z: 1}
m_Children:
- {fileID: 2727431866271043440}
m_Father: {fileID: 2727431866408081646}
m_RootOrder: 1
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
--- !u!114 &4035158392542168902
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 8967150157657768027}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: cf12ee76e7e00a44a9a84256760020e6, type: 3}
m_Name:
m_EditorClassIdentifier:
nodeList: []
ignoreInactiveTransforms: 1
sortType: 0
surfaceType: 1
orientType: 0
layout: 1
anchor: 4
radius: 2
radialRange: 180
distance: 0
rows: 3
columns: 3
cellWidth: 0.032
cellHeight: 0.032
assetVersion: 1
--- !u!1001 &2727431864385238879
PrefabInstance:
m_ObjectHideFlags: 0
serializedVersion: 2
m_Modification:
m_TransformParent: {fileID: 7139619605013124960}
m_Modifications:
- target: {fileID: 316800718, guid: 45fd0ad89d6d17b4fbe68eb48dbe9de9, type: 3}
propertyPath: m_Name
value: PressableButton
objectReference: {fileID: 0}
- target: {fileID: 937783102, guid: 45fd0ad89d6d17b4fbe68eb48dbe9de9, type: 3}
propertyPath: m_text
value: Spatial Map
objectReference: {fileID: 0}
- target: {fileID: 937783102, guid: 45fd0ad89d6d17b4fbe68eb48dbe9de9, type: 3}
propertyPath: m_textInfo.characterCount
value: 11
objectReference: {fileID: 0}
- target: {fileID: 937783102, guid: 45fd0ad89d6d17b4fbe68eb48dbe9de9, type: 3}
propertyPath: m_textInfo.spaceCount
value: 1
objectReference: {fileID: 0}
- target: {fileID: 937783102, guid: 45fd0ad89d6d17b4fbe68eb48dbe9de9, type: 3}
propertyPath: m_textInfo.wordCount
value: 2
objectReference: {fileID: 0}
- target: {fileID: 1911902820, guid: 45fd0ad89d6d17b4fbe68eb48dbe9de9, type: 3}
propertyPath: m_Materials.Array.data[0]
value:
objectReference: {fileID: 2100000, guid: 3d0d8cbbeb901c54dbf0ff1dfab58703, type: 2}
- target: {fileID: 1944713263, guid: 45fd0ad89d6d17b4fbe68eb48dbe9de9, type: 3}
propertyPath: m_LocalPosition.x
value: 0
objectReference: {fileID: 0}
- target: {fileID: 1944713263, guid: 45fd0ad89d6d17b4fbe68eb48dbe9de9, type: 3}
propertyPath: m_LocalPosition.y
value: 0.031999998
objectReference: {fileID: 0}
- target: {fileID: 1944713263, guid: 45fd0ad89d6d17b4fbe68eb48dbe9de9, type: 3}
propertyPath: m_LocalPosition.z
value: 0
objectReference: {fileID: 0}
- target: {fileID: 1944713263, guid: 45fd0ad89d6d17b4fbe68eb48dbe9de9, type: 3}
propertyPath: m_LocalRotation.x
value: -0
objectReference: {fileID: 0}
- target: {fileID: 1944713263, guid: 45fd0ad89d6d17b4fbe68eb48dbe9de9, type: 3}
propertyPath: m_LocalRotation.y
value: -0
objectReference: {fileID: 0}
- target: {fileID: 1944713263, guid: 45fd0ad89d6d17b4fbe68eb48dbe9de9, type: 3}
propertyPath: m_LocalRotation.z
value: -0
objectReference: {fileID: 0}
- target: {fileID: 1944713263, guid: 45fd0ad89d6d17b4fbe68eb48dbe9de9, type: 3}
propertyPath: m_LocalRotation.w
value: 1
objectReference: {fileID: 0}
- target: {fileID: 1944713263, guid: 45fd0ad89d6d17b4fbe68eb48dbe9de9, type: 3}
propertyPath: m_RootOrder
value: 0
objectReference: {fileID: 0}
- target: {fileID: 1944713263, guid: 45fd0ad89d6d17b4fbe68eb48dbe9de9, type: 3}
propertyPath: m_LocalEulerAnglesHint.x
value: 0
objectReference: {fileID: 0}
- target: {fileID: 1944713263, guid: 45fd0ad89d6d17b4fbe68eb48dbe9de9, type: 3}
propertyPath: m_LocalEulerAnglesHint.y
value: 0
objectReference: {fileID: 0}
- target: {fileID: 1944713263, guid: 45fd0ad89d6d17b4fbe68eb48dbe9de9, type: 3}
propertyPath: m_LocalEulerAnglesHint.z
value: 0
objectReference: {fileID: 0}
- target: {fileID: 7440800412470431853, guid: 45fd0ad89d6d17b4fbe68eb48dbe9de9,
type: 3}
propertyPath: OnClick.m_PersistentCalls.m_Calls.Array.data[0].m_Target
value:
objectReference: {fileID: 917949849985424103}
- target: {fileID: 7440800412470431853, guid: 45fd0ad89d6d17b4fbe68eb48dbe9de9,
type: 3}
propertyPath: OnClick.m_PersistentCalls.m_Calls.Array.data[0].m_MethodName
value: ToggleSpatialMaps
objectReference: {fileID: 0}
- target: {fileID: 9181818329810857364, guid: 45fd0ad89d6d17b4fbe68eb48dbe9de9,
type: 3}
propertyPath: m_text
value: Say "Spatil Map"
objectReference: {fileID: 0}
- target: {fileID: 9181818329810857364, guid: 45fd0ad89d6d17b4fbe68eb48dbe9de9,
type: 3}
propertyPath: m_textInfo.characterCount
value: 16
objectReference: {fileID: 0}
- target: {fileID: 9181818329810857364, guid: 45fd0ad89d6d17b4fbe68eb48dbe9de9,
type: 3}
propertyPath: m_textInfo.spaceCount
value: 2
objectReference: {fileID: 0}
- target: {fileID: 9181818329810857364, guid: 45fd0ad89d6d17b4fbe68eb48dbe9de9,
type: 3}
propertyPath: m_textInfo.wordCount
value: 3
objectReference: {fileID: 0}
m_RemovedComponents: []
m_SourcePrefab: {fileID: 100100000, guid: 45fd0ad89d6d17b4fbe68eb48dbe9de9, type: 3}
--- !u!4 &2727431866271043440 stripped
Transform:
m_CorrespondingSourceObject: {fileID: 1944713263, guid: 45fd0ad89d6d17b4fbe68eb48dbe9de9,
type: 3}
m_PrefabInstance: {fileID: 2727431864385238879}
m_PrefabAsset: {fileID: 0}
%YAML 1.1
%TAG !u! tag:unity3d.com,2011:
--- !u!1 &2461738174043341969
GameObject:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
serializedVersion: 6
m_Component:
- component: {fileID: 2461738174043341971}
- component: {fileID: 2461738174043341970}
m_Layer: 0
m_Name: HolographicRemoting
m_TagString: Untagged
m_Icon: {fileID: 0}
m_NavMeshLayer: 0
m_StaticEditorFlags: 0
m_IsActive: 1
--- !u!4 &2461738174043341971
Transform:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 2461738174043341969}
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
m_LocalPosition: {x: 0.1753877, y: 0.19457991, z: 3.2157607}
m_LocalScale: {x: 1, y: 1, z: 1}
m_Children: []
m_Father: {fileID: 0}
m_RootOrder: 0
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
--- !u!114 &2461738174043341970
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 2461738174043341969}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: 07b9ce6ef60864645a1e9ff0ca0aa81f, type: 3}
m_Name:
m_EditorClassIdentifier:
IP:
%YAML 1.1
%TAG !u! tag:unity3d.com,2011:
--- !u!1 &5896636668037311865
GameObject:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
serializedVersion: 6
m_Component:
- component: {fileID: 5896636668037311869}
- component: {fileID: 5896636668037311868}
- component: {fileID: 5896636668037311867}
- component: {fileID: 5896636668037311866}
m_Layer: 0
m_Name: Platform
m_TagString: Untagged
m_Icon: {fileID: 0}
m_NavMeshLayer: 0
m_StaticEditorFlags: 0
m_IsActive: 1
--- !u!4 &5896636668037311869
Transform:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 5896636668037311865}
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
m_LocalPosition: {x: -0.07, y: -0.613, z: 1.897}
m_LocalScale: {x: 1.25, y: 0.01, z: 1}
m_Children: []
m_Father: {fileID: 0}
m_RootOrder: 0
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
--- !u!33 &5896636668037311868
MeshFilter:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 5896636668037311865}
m_Mesh: {fileID: 10202, guid: 0000000000000000e000000000000000, type: 0}
--- !u!23 &5896636668037311867
MeshRenderer:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 5896636668037311865}
m_Enabled: 1
m_CastShadows: 1
m_ReceiveShadows: 1
m_DynamicOccludee: 1
m_MotionVectors: 1
m_LightProbeUsage: 1
m_ReflectionProbeUsage: 1
m_RayTracingMode: 2
m_RenderingLayerMask: 1
m_RendererPriority: 0
m_Materials:
- {fileID: 2100000, guid: 5fa438a6360547448ac23d8402acdebf, type: 2}
m_StaticBatchInfo:
firstSubMesh: 0
subMeshCount: 0
m_StaticBatchRoot: {fileID: 0}
m_ProbeAnchor: {fileID: 0}
m_LightProbeVolumeOverride: {fileID: 0}
m_ScaleInLightmap: 1
m_ReceiveGI: 1
m_PreserveUVs: 0
m_IgnoreNormalsForChartDetection: 0
m_ImportantGI: 0
m_StitchLightmapSeams: 1
m_SelectedEditorRenderState: 3
m_MinimumChartSize: 4
m_AutoUVMaxDistance: 0.5
m_AutoUVMaxAngle: 89
m_LightmapParameters: {fileID: 0}
m_SortingLayerID: 0
m_SortingLayer: 0
m_SortingOrder: 0
--- !u!65 &5896636668037311866
BoxCollider:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 5896636668037311865}
m_Material: {fileID: 0}
m_IsTrigger: 0
m_Enabled: 1
serializedVersion: 2
m_Size: {x: 1, y: 1, z: 1}
m_Center: {x: 0, y: 0, z: 0}
using System.Collections;
using System.Collections.Generic;
using UnityEngine;
using UnityEngine.XR;
using UnityEngine.XR.WSA;
public class HolographicRemoteConnect : MonoBehaviour
{
[SerializeField]
private string IP;
private bool connected = false;
public void Connect()
{
if (HolographicRemoting.ConnectionState != HolographicStreamerConnectionState.Connected)
{
//HolographicRemoting.Connect(IP); //For HL1
HolographicRemoting.Connect(IP, 99999, RemoteDeviceVersion.V2);
}
}
void Update()
{
if (!connected && HolographicRemoting.ConnectionState == HolographicStreamerConnectionState.Connected)
{
connected = true;
StartCoroutine(LoadDevice("WindowsMR"));
}
}
IEnumerator LoadDevice(string newDevice)
{
XRSettings.LoadDeviceByName(newDevice);
yield return null;
XRSettings.enabled = true;
}
private void OnGUI()
{
IP = GUI.TextField(new Rect(10, 10, 200, 30), IP, 25);
string button = (connected ? "Disconnect" : "Connect");
if (GUI.Button(new Rect(220, 10, 100, 30), button))
{
if (connected)
{
HolographicRemoting.Disconnect();
connected = false;
}
else
Connect();
Debug.Log(button);
}
}
}
\ No newline at end of file
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License. See LICENSE in the project root for license information.
using Microsoft.MixedReality.Toolkit.Input;
using Microsoft.MixedReality.Toolkit.Physics;
using UnityEngine;
using UnityEngine.Events;
using UnityPhysics = UnityEngine.Physics;
namespace Microsoft.MixedReality.Toolkit.Utilities.Solvers
{
/// <summary>
/// Tap to place is a far interaction component used to place objects on a surface.
/// </summary>
public class TapToPlace : Solver, IMixedRealityPointerHandler
{
[Space(10)]
[SerializeField]
[Tooltip("If true, the game object to place will start selected. The object will immediately start" +
" following the TrackedTargetType (Head or Controller Ray) and then a tap is required to place the object." +
" This value must be modified before Start() is invoked in order to have any effect")]
private bool autoStart = false;
/// <summary>
/// If true, the game object to place will start out selected. The object will immediately start
/// following the TrackedTargetType (Head or Controller Ray) and then a tap is required to place the object.
/// This value must be modified before Start() is invoked in order to have any effect.
/// </summary>
public bool AutoStart
{
get => autoStart;
set => autoStart = value;
}
[SerializeField]
[Tooltip("The default distance (in meters) an object will be placed relative to the TrackedTargetType forward in the SolverHandler." +
" The GameObjectToPlace will be placed at the default placement distance if a surface is not hit by the raycast.")]
private float defaultPlacementDistance = 1.5f;
/// <summary>
/// The default distance (in meters) an object will be placed relative to the TrackedTargetType forward in the SolverHandler.
/// The GameObjectToPlace will be placed at the default placement distance if a surface is not hit by the raycast.
/// </summary>
public float DefaultPlacementDistance
{
get => defaultPlacementDistance;
set => defaultPlacementDistance = value;
}
[SerializeField]
[Tooltip("Max distance (in meters) to place an object if there is a raycast hit on a surface.")]
private float maxRaycastDistance = 20.0f;
/// <summary>
/// The max distance (in meters) to place an object if there is a raycast hit on a surface
/// </summary>
public float MaxRaycastDistance
{
get => maxRaycastDistance;
set => maxRaycastDistance = value;
}
/// <summary>
/// If true, the game object to place is selected.
/// </summary>
public bool IsBeingPlaced { get; protected set; }
[SerializeField]
[Tooltip("The distance between the center of the game object to place and a surface along the surface normal, if the raycast hits a surface")]
private float surfaceNormalOffset = 0.0f;
/// <summary>
/// The distance between the center of the game object to place and a surface along the surface normal, if the raycast hits a surface.
/// </summary>
public float SurfaceNormalOffset
{
get => surfaceNormalOffset;
set => surfaceNormalOffset = value;
}
[SerializeField]
[Tooltip("If true, the game object to place will remain upright and in line with Vector3.up")]
private bool keepOrientationVertical = false;
/// <summary>
/// If true, the game object to place will remain upright and in line with Vector3.up
/// </summary>
public bool KeepOrientationVertical
{
get => keepOrientationVertical;
set => keepOrientationVertical = value;
}
[SerializeField]
[Tooltip("If false, the game object to place will not change its rotation according to the surface hit. The object will" +
" remain facing the camera while IsBeingPlaced is true. If true, the object will rotate according to the surface normal" +
" if there is a hit.")]
private bool rotateAccordingToSurface = false;
/// <summary>
/// If false, the game object to place will not change its rotation according to the surface hit. The object will
/// remain facing the camera while IsBeingPlaced is true. If true, the object will rotate according to the surface normal
/// if there is a hit.
/// </summary>
public bool RotateAccordingToSurface
{
get => rotateAccordingToSurface;
set => rotateAccordingToSurface = value;
}
[SerializeField]
[Tooltip("Array of LayerMask to execute from highest to lowest priority. First layermask to provide a raycast hit will be used by component.")]
private LayerMask[] magneticSurfaces = { UnityEngine.Physics.DefaultRaycastLayers };
/// <summary>
/// Array of LayerMask to execute from highest to lowest priority. First layermask to provide a raycast hit will be used by component.
/// </summary>
public LayerMask[] MagneticSurfaces
{
get => magneticSurfaces;
set => magneticSurfaces = value;
}
[SerializeField]
[Tooltip("If true and in the Unity Editor, the normal of the raycast hit will be drawn in yellow.")]
private bool debugEnabled = true;
/// <summary>
/// If true and in the Unity Editor, the normal of the raycast hit will be drawn in yellow.
/// </summary>
public bool DebugEnabled
{
get => debugEnabled;
set => debugEnabled = value;
}
[SerializeField]
[Tooltip("This event is triggered once when the game object to place is selected.")]
private UnityEvent onPlacingStarted = new UnityEvent();
/// <summary>
/// This event is triggered once when the game object to place is selected.
/// </summary>
public UnityEvent OnPlacingStarted
{
get => onPlacingStarted;
set => onPlacingStarted = value;
}
[SerializeField]
[Tooltip("This event is triggered once when the game object to place is unselected, placed.")]
private UnityEvent onPlacingStopped = new UnityEvent();
/// <summary>
/// This event is triggered once when the game object to place is unselected, placed.
/// </summary>
public UnityEvent OnPlacingStopped
{
get => onPlacingStopped;
set => onPlacingStopped = value;
}
/// <summary>
/// The current game object layer before it is temporarily switched to IgnoreRaycast while placing the game object.
/// </summary>
protected internal int GameObjectLayer { get; protected set; }
protected internal bool IsColliderPresent => gameObject != null ? gameObject.GetComponent<Collider>() != null : false;
private int ignoreRaycastLayer;
/// <summary>
/// The current ray is based on the TrackedTargetType (Controller Ray, Head, Hand Joint).
/// The following properties are updated each frame while the game object is selected to determine
/// object placement if there is a hit on a surface.
/// </summary>
protected RayStep CurrentRay;
protected bool DidHitSurface;
protected RaycastHit CurrentHit;
// Used to record the time (seconds) between OnPointerClicked calls to avoid two calls in a row.
protected float LastTimeClicked = 0;
protected float DoubleClickTimeout = 0.5f;
#region MonoBehaviour Implementation
protected override void Start()
{
base.Start();
Debug.Assert(IsColliderPresent, $"The game object {gameObject.name} does not have a collider attached, please attach a collider to use Tap to Place");
// When a game object is created via script, the bounds of the collider remain at the default size
// of (1, 1, 1) which always returns a 0.5 SurfaceNormalOffset. Adding SyncTransforms updates the
// size of the collider to match the game object before we calculate the SurfaceNormalOffset.
UnityPhysics.SyncTransforms();
SurfaceNormalOffset = gameObject.GetComponent<Collider>().bounds.extents.z;
ignoreRaycastLayer = LayerMask.NameToLayer("Ignore Raycast");
if (AutoStart)
{
StartPlacement();
}
else
{
SolverHandler.UpdateSolvers = false;
}
}
private void OnDisable()
{
CoreServices.InputSystem?.UnregisterHandler<IMixedRealityPointerHandler>(this);
}
#endregion
/// <summary>
/// Start the placement of a game object without the need of the OnPointerClicked event. The game object will begin to follow the
/// TrackedTargetType (Head by default) at a default distance. StopPlacement() must be called after StartPlacement() to stop the
/// game object from following the TrackedTargetType. The game object layer is changed to IgnoreRaycast temporarily and then
/// restored to its original layer in StopPlacement().
/// </summary>
public void StartPlacement()
{
// Added for code configurability to avoid multiple calls to StartPlacement in a row
if (!IsBeingPlaced)
{
// Store the initial game object layer
GameObjectLayer = gameObject.layer;
// Temporarily change the game object layer to IgnoreRaycastLayer to enable a surface hit beyond the game object
gameObject.layer = ignoreRaycastLayer;
SolverHandler.UpdateSolvers = true;
IsBeingPlaced = true;
OnPlacingStarted?.Invoke();
// A global pointer handler is needed to enable object placement without the need for focus.
// The object's layer is changed to IgnoreRaycast in this method, which means the game object cannot receive focus.
// Without a global handler, the game object would not receive pointer events.
CoreServices.InputSystem?.RegisterHandler<IMixedRealityPointerHandler>(this);
}
}
/// <summary>
/// Stop the placement of a game object without the need of the OnPointerClicked event.
/// </summary>
public void StopPlacement()
{
// Added for code configurability to avoid multiple calls to StopPlacement in a row
if (IsBeingPlaced)
{
// Change the game object layer back to the game object's layer on start
gameObject.layer = GameObjectLayer;
SolverHandler.UpdateSolvers = false;
IsBeingPlaced = false;
OnPlacingStopped?.Invoke();
CoreServices.InputSystem?.UnregisterHandler<IMixedRealityPointerHandler>(this);
}
}
/// <inheritdoc/>
public override void SolverUpdate()
{
// Make sure the Transform target is not null, added for the case where auto start is true
// and the tracked target type is the controller ray, if the hand is not in the frame we cannot
// calculate the position of the object
if (SolverHandler.TransformTarget != null)
{
PerformRaycast();
SetPosition();
SetRotation();
}
}
protected virtual void PerformRaycast()
{
// The transform target is the transform of the TrackedTargetType, i.e. Controller Ray, Head or Hand Joint
var transform = SolverHandler.TransformTarget;
Vector3 origin = transform.position;
Vector3 endpoint = transform.position + transform.forward;
CurrentRay.UpdateRayStep(ref origin, ref endpoint);
// Check if the current ray hits a magnetic surface
DidHitSurface = MixedRealityRaycaster.RaycastSimplePhysicsStep(CurrentRay, MaxRaycastDistance, MagneticSurfaces, false, out CurrentHit);
}
/// <summary>
/// Change the position of the game object if there was a hit, if not then place the object at the default distance
/// relative to the TrackedTargetType origin position
/// </summary>
protected virtual void SetPosition()
{
if (DidHitSurface)
{
// Take the current hit point and add an offset relative to the surface to avoid half of the object in the surface
GoalPosition = CurrentHit.point;
AddOffset(CurrentHit.normal * SurfaceNormalOffset);
#if UNITY_EDITOR
if (DebugEnabled)
{
// Draw the normal of the raycast hit for debugging
Debug.DrawRay(CurrentHit.point, CurrentHit.normal * 0.5f, Color.yellow);
}
#endif // UNITY_EDITOR
}
else
{
GoalPosition = SolverHandler.TransformTarget.position + (SolverHandler.TransformTarget.forward * DefaultPlacementDistance);
}
}
protected virtual void SetRotation()
{
Vector3 direction = CurrentRay.Direction;
Vector3 surfaceNormal = CurrentHit.normal;
if (KeepOrientationVertical)
{
direction.y = 0;
surfaceNormal.y = 0;
}
// If the object is on a surface then change the rotation according to the normal of the hit point
if (DidHitSurface && rotateAccordingToSurface)
{
GoalRotation = Quaternion.LookRotation(-surfaceNormal, Vector3.up);
}
else
{
GoalRotation = Quaternion.LookRotation(direction, Vector3.up);
}
}
#region IMixedRealityPointerHandler
/// <inheritdoc/>
public void OnPointerDown(MixedRealityPointerEventData eventData) { }
/// <inheritdoc/>
public void OnPointerDragged(MixedRealityPointerEventData eventData) { }
/// <inheritdoc/>
public void OnPointerUp(MixedRealityPointerEventData eventData) { }
/// <inheritdoc/>
public void OnPointerClicked(MixedRealityPointerEventData eventData)
{
// Checking the amount of time passed between OnPointerClicked calls is handling the case when OnPointerClicked is called
// twice after one click. If OnPointerClicked is called twice after one click, the object will be selected and then immediately
// unselected. If OnPointerClicked calls are within 0.5 secs of each other, then return to prevent an immediate object state switch.
if ((Time.time - LastTimeClicked) < DoubleClickTimeout)
{
return;
}
if (!IsBeingPlaced)
{
StartPlacement();
}
else
{
StopPlacement();
}
// Get the time of this click action
LastTimeClicked = Time.time;
}
#endregion
}
}
\ No newline at end of file
using System.Collections;
using System.Collections.Generic;
using UnityEngine;
public class ToggleButton : MonoBehaviour
{
public GameObject ClipingObject;
public void ToggleClipping()
{
ClipingObject.SetActive(!ClipingObject.activeInHierarchy);
}
}
using Microsoft.MixedReality.Toolkit;
using System.Linq;
using Microsoft.MixedReality.Toolkit.SpatialAwareness;
using UnityEngine;
public class ToggleSpatialMap : MonoBehaviour
{
public void ToggleSpatialMaps()
{
if (CoreServices.SpatialAwarenessSystem != null)
{
if (IsObserverRunning)
{
CoreServices.SpatialAwarenessSystem.SuspendObservers();
CoreServices.SpatialAwarenessSystem.ClearObservations();
}
else
{
CoreServices.SpatialAwarenessSystem.ResumeObservers();
}
}
}
private bool IsObserverRunning
{
get
{
var providers =
((IMixedRealityDataProviderAccess)CoreServices.SpatialAwarenessSystem)
.GetDataProviders<IMixedRealitySpatialAwarenessObserver>();
return providers.FirstOrDefault()?.IsRunning == true;
}
}
}
using System.Collections;
using System.Collections.Generic;
using UnityEngine;
public class ViewButtonControl : MonoBehaviour
{
public GameObject[] Models;
private int ModelIndex = 0;
void Start()
{
Models[0].SetActive(true);
}
public void NextModel()
{
foreach (GameObject model in Models)
{
model.SetActive(false);
}
ModelIndex = ModelIndex + 1;
if(ModelIndex < Models.Length)
{
Models[ModelIndex].SetActive(true);
}
else
{
ModelIndex = 0;
Models[ModelIndex].SetActive(true);
}
}
public void PreviousModel()
{
foreach (GameObject model in Models)
{
model.SetActive(false);
}
ModelIndex = ModelIndex - 1;
if(ModelIndex >= 0)
{
Models[ModelIndex].SetActive(true);
}
else
{
ModelIndex = Models.Length-1;
Models[ModelIndex].SetActive(true);
}
}
}
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment