Skip to content

Commit 8212457

Browse files
authored
Merge pull request #316 from mister-liss/master
Heads Up Direction Indicator
2 parents b030961 + 30a25c9 commit 8212457

File tree

78 files changed

+4837
-2
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

78 files changed

+4837
-2
lines changed

Assets/HoloToolkit/Utilities/Materials.meta

Lines changed: 2 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.
Lines changed: 157 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,157 @@
1+
%YAML 1.1
2+
%TAG !u! tag:unity3d.com,2011:
3+
--- !u!21 &2100000
4+
Material:
5+
serializedVersion: 6
6+
m_ObjectHideFlags: 0
7+
m_PrefabParentObject: {fileID: 0}
8+
m_PrefabInternal: {fileID: 0}
9+
m_Name: ArrowOnTop
10+
m_Shader: {fileID: 4800000, guid: e1fd48673918ae242b03ad1ae08a38bd, type: 3}
11+
m_ShaderKeywords: _EMISSION
12+
m_LightmapFlags: 1
13+
m_CustomRenderQueue: -1
14+
stringTagMap: {}
15+
m_SavedProperties:
16+
serializedVersion: 2
17+
m_TexEnvs:
18+
- first:
19+
name: _BumpMap
20+
second:
21+
m_Texture: {fileID: 0}
22+
m_Scale: {x: 1, y: 1}
23+
m_Offset: {x: 0, y: 0}
24+
- first:
25+
name: _DetailAlbedoMap
26+
second:
27+
m_Texture: {fileID: 0}
28+
m_Scale: {x: 1, y: 1}
29+
m_Offset: {x: 0, y: 0}
30+
- first:
31+
name: _DetailMask
32+
second:
33+
m_Texture: {fileID: 0}
34+
m_Scale: {x: 1, y: 1}
35+
m_Offset: {x: 0, y: 0}
36+
- first:
37+
name: _DetailNormalMap
38+
second:
39+
m_Texture: {fileID: 0}
40+
m_Scale: {x: 1, y: 1}
41+
m_Offset: {x: 0, y: 0}
42+
- first:
43+
name: _DetailTex
44+
second:
45+
m_Texture: {fileID: 0}
46+
m_Scale: {x: 1, y: 1}
47+
m_Offset: {x: 0, y: 0}
48+
- first:
49+
name: _EmissionMap
50+
second:
51+
m_Texture: {fileID: 0}
52+
m_Scale: {x: 1, y: 1}
53+
m_Offset: {x: 0, y: 0}
54+
- first:
55+
name: _MainTex
56+
second:
57+
m_Texture: {fileID: 2800000, guid: b7e7ac1cdf109fd4a921ab2ba712a48b, type: 3}
58+
m_Scale: {x: 1, y: 1}
59+
m_Offset: {x: 0, y: 0}
60+
- first:
61+
name: _MetallicGlossMap
62+
second:
63+
m_Texture: {fileID: 0}
64+
m_Scale: {x: 1, y: 1}
65+
m_Offset: {x: 0, y: 0}
66+
- first:
67+
name: _OcclusionMap
68+
second:
69+
m_Texture: {fileID: 0}
70+
m_Scale: {x: 1, y: 1}
71+
m_Offset: {x: 0, y: 0}
72+
- first:
73+
name: _ParallaxMap
74+
second:
75+
m_Texture: {fileID: 0}
76+
m_Scale: {x: 1, y: 1}
77+
m_Offset: {x: 0, y: 0}
78+
m_Floats:
79+
- first:
80+
name: _BumpScale
81+
second: 1
82+
- first:
83+
name: _ColorMask
84+
second: 15
85+
- first:
86+
name: _Cutoff
87+
second: 0.5
88+
- first:
89+
name: _DetailNormalMapScale
90+
second: 1
91+
- first:
92+
name: _DstBlend
93+
second: 0
94+
- first:
95+
name: _GlossMapScale
96+
second: 1
97+
- first:
98+
name: _Glossiness
99+
second: 0.5
100+
- first:
101+
name: _GlossyReflections
102+
second: 1
103+
- first:
104+
name: _Metallic
105+
second: 0
106+
- first:
107+
name: _Mode
108+
second: 0
109+
- first:
110+
name: _OcclusionStrength
111+
second: 1
112+
- first:
113+
name: _Parallax
114+
second: 0.02
115+
- first:
116+
name: _SmoothnessTextureChannel
117+
second: 0
118+
- first:
119+
name: _SpecularHighlights
120+
second: 1
121+
- first:
122+
name: _SrcBlend
123+
second: 1
124+
- first:
125+
name: _Stencil
126+
second: 0
127+
- first:
128+
name: _StencilComp
129+
second: 8
130+
- first:
131+
name: _StencilOp
132+
second: 0
133+
- first:
134+
name: _StencilReadMask
135+
second: 255
136+
- first:
137+
name: _StencilWriteMask
138+
second: 255
139+
- first:
140+
name: _Strength
141+
second: 0.2
142+
- first:
143+
name: _UVSec
144+
second: 0
145+
- first:
146+
name: _UseUIAlphaClip
147+
second: 0
148+
- first:
149+
name: _ZWrite
150+
second: 1
151+
m_Colors:
152+
- first:
153+
name: _Color
154+
second: {r: 1, g: 1, b: 1, a: 1}
155+
- first:
156+
name: _EmissionColor
157+
second: {r: 0, g: 0, b: 0, a: 1}

Assets/HoloToolkit/Utilities/Materials/ArrowOnTop.mat.meta

Lines changed: 8 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.
Lines changed: 60 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,60 @@
1+
%YAML 1.1
2+
%TAG !u! tag:unity3d.com,2011:
3+
--- !u!1001 &100100000
4+
Prefab:
5+
m_ObjectHideFlags: 1
6+
serializedVersion: 2
7+
m_Modification:
8+
m_TransformParent: {fileID: 0}
9+
m_Modifications: []
10+
m_RemovedComponents: []
11+
m_ParentPrefab: {fileID: 0}
12+
m_RootGameObject: {fileID: 1000012707223274}
13+
m_IsPrefabParent: 1
14+
--- !u!1 &1000012707223274
15+
GameObject:
16+
m_ObjectHideFlags: 0
17+
m_PrefabParentObject: {fileID: 0}
18+
m_PrefabInternal: {fileID: 100100000}
19+
serializedVersion: 4
20+
m_Component:
21+
- 4: {fileID: 4000013931524940}
22+
- 114: {fileID: 114000010146961468}
23+
m_Layer: 0
24+
m_Name: HeadsUpDirectionIndicator
25+
m_TagString: Untagged
26+
m_Icon: {fileID: 0}
27+
m_NavMeshLayer: 0
28+
m_StaticEditorFlags: 0
29+
m_IsActive: 1
30+
--- !u!4 &4000013931524940
31+
Transform:
32+
m_ObjectHideFlags: 1
33+
m_PrefabParentObject: {fileID: 0}
34+
m_PrefabInternal: {fileID: 100100000}
35+
m_GameObject: {fileID: 1000012707223274}
36+
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
37+
m_LocalPosition: {x: 0, y: 0, z: 0}
38+
m_LocalScale: {x: 1, y: 1, z: 1}
39+
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
40+
m_Children: []
41+
m_Father: {fileID: 0}
42+
m_RootOrder: 0
43+
--- !u!114 &114000010146961468
44+
MonoBehaviour:
45+
m_ObjectHideFlags: 1
46+
m_PrefabParentObject: {fileID: 0}
47+
m_PrefabInternal: {fileID: 100100000}
48+
m_GameObject: {fileID: 1000012707223274}
49+
m_Enabled: 1
50+
m_EditorHideFlags: 0
51+
m_Script: {fileID: 11500000, guid: aaf540edf943b014c9b1cb13622dd844, type: 3}
52+
m_Name:
53+
m_EditorClassIdentifier:
54+
TargetObject: {fileID: 0}
55+
Depth: 15
56+
Pivot: {x: 0, y: 0.5, z: 0}
57+
PointerPrefab: {fileID: 1000013959014570, guid: 6145c0073e089ec44ade2d6ee028ae9b,
58+
type: 2}
59+
IndicatorMarginPercent: 0.1
60+
DebugDrawPointerOrientationPlanes: 0

Assets/HoloToolkit/Utilities/Prefabs/HeadsUpDirectionIndicator.prefab.meta

Lines changed: 8 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.
Lines changed: 92 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,92 @@
1+
%YAML 1.1
2+
%TAG !u! tag:unity3d.com,2011:
3+
--- !u!1001 &100100000
4+
Prefab:
5+
m_ObjectHideFlags: 1
6+
serializedVersion: 2
7+
m_Modification:
8+
m_TransformParent: {fileID: 0}
9+
m_Modifications: []
10+
m_RemovedComponents: []
11+
m_ParentPrefab: {fileID: 0}
12+
m_RootGameObject: {fileID: 1000013959014570}
13+
m_IsPrefabParent: 1
14+
--- !u!1 &1000013959014570
15+
GameObject:
16+
m_ObjectHideFlags: 0
17+
m_PrefabParentObject: {fileID: 0}
18+
m_PrefabInternal: {fileID: 100100000}
19+
serializedVersion: 4
20+
m_Component:
21+
- 4: {fileID: 4000014200002438}
22+
- 33: {fileID: 33000013990238068}
23+
- 64: {fileID: 64000012096101712}
24+
- 23: {fileID: 23000012460074050}
25+
m_Layer: 0
26+
m_Name: HeadsUpDirectionIndicatorPointer
27+
m_TagString: Untagged
28+
m_Icon: {fileID: 0}
29+
m_NavMeshLayer: 0
30+
m_StaticEditorFlags: 0
31+
m_IsActive: 1
32+
--- !u!4 &4000014200002438
33+
Transform:
34+
m_ObjectHideFlags: 1
35+
m_PrefabParentObject: {fileID: 0}
36+
m_PrefabInternal: {fileID: 100100000}
37+
m_GameObject: {fileID: 1000013959014570}
38+
m_LocalRotation: {x: -0, y: -0, z: -0, w: 1}
39+
m_LocalPosition: {x: 0, y: 0, z: 0}
40+
m_LocalScale: {x: 1, y: 1, z: 1}
41+
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
42+
m_Children: []
43+
m_Father: {fileID: 0}
44+
m_RootOrder: 0
45+
--- !u!23 &23000012460074050
46+
MeshRenderer:
47+
m_ObjectHideFlags: 1
48+
m_PrefabParentObject: {fileID: 0}
49+
m_PrefabInternal: {fileID: 100100000}
50+
m_GameObject: {fileID: 1000013959014570}
51+
m_Enabled: 1
52+
m_CastShadows: 0
53+
m_ReceiveShadows: 0
54+
m_MotionVectors: 0
55+
m_LightProbeUsage: 0
56+
m_ReflectionProbeUsage: 0
57+
m_Materials:
58+
- {fileID: 2100000, guid: 5238ed24c9726a1459b60cb16df01a9d, type: 2}
59+
m_SubsetIndices:
60+
m_StaticBatchRoot: {fileID: 0}
61+
m_ProbeAnchor: {fileID: 0}
62+
m_LightProbeVolumeOverride: {fileID: 0}
63+
m_ScaleInLightmap: 1
64+
m_PreserveUVs: 1
65+
m_IgnoreNormalsForChartDetection: 0
66+
m_ImportantGI: 0
67+
m_SelectedWireframeHidden: 0
68+
m_MinimumChartSize: 4
69+
m_AutoUVMaxDistance: 0.5
70+
m_AutoUVMaxAngle: 89
71+
m_LightmapParameters: {fileID: 0}
72+
m_SortingLayerID: 0
73+
m_SortingOrder: 0
74+
--- !u!33 &33000013990238068
75+
MeshFilter:
76+
m_ObjectHideFlags: 1
77+
m_PrefabParentObject: {fileID: 0}
78+
m_PrefabInternal: {fileID: 100100000}
79+
m_GameObject: {fileID: 1000013959014570}
80+
m_Mesh: {fileID: 10210, guid: 0000000000000000e000000000000000, type: 0}
81+
--- !u!64 &64000012096101712
82+
MeshCollider:
83+
m_ObjectHideFlags: 1
84+
m_PrefabParentObject: {fileID: 0}
85+
m_PrefabInternal: {fileID: 100100000}
86+
m_GameObject: {fileID: 1000013959014570}
87+
m_Material: {fileID: 0}
88+
m_IsTrigger: 0
89+
m_Enabled: 1
90+
serializedVersion: 2
91+
m_Convex: 0
92+
m_Mesh: {fileID: 10210, guid: 0000000000000000e000000000000000, type: 0}

Assets/HoloToolkit/Utilities/Prefabs/HeadsUpDirectionIndicatorPointer.prefab.meta

Lines changed: 8 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Assets/HoloToolkit/Utilities/README.md

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,12 @@ Common useful prefabs not particularly related to a particular HoloLens feature.
77
#### FPSDisplay.prefab
88
Simple Tagalong billboard displaying application's frames per second.
99

10+
#### HeadsUpDirectionIndicator.prefab
11+
A drop in direction indicator that stays in the users view at all times.
12+
13+
#### HeadsUpDirectionIndicatorPointer.prefab
14+
A quad based pointer to be used with the HeadsUpDirectionIndicator prefab to create an out of box direction indicator.k
15+
1016
#### Main Camera.prefab
1117
Unity camera that has been customized for Holographic development.
1218
1. Camera.Transform set to 0,0,0
@@ -35,6 +41,9 @@ You must provide GameObjects for the **_Cursor_** and **_DirectionIndicatorObjec
3541
#### FixedAngularSize.cs
3642
Causes a hologram to maintain a fixed angular size, which is to say it occupies the same pixels in the view regardless of its distance from the camera.
3743

44+
#### HeadsUpDirectionIndicator.cs
45+
Spawns a user specified "pointer" object and startup and alligns it to aim at a target object which keeping the pointer in view at all times.
46+
3847
#### Interpolator.cs
3948
A MonoBehaviour that interpolates a transform's position, rotation or scale.
4049

@@ -79,6 +88,9 @@ Feature configurable unlit shader. Use when no lighting is desired.
7988
#### UnlitConfigurableTransparent.shader
8089
Feature configurable unlit transparent shader. Use when transparency and no lighting are desired.
8190

91+
#### UnlitNoDepthTest.shader
92+
Render with a single texture but ignore depth test resuls so object always appears on top.
93+
8294
#### VertexLitConfigurable.cginc
8395
Code shared between VertexLitConfigurable.shader and VertexLitConfigurableTransparent.shader.
8496

@@ -93,6 +105,16 @@ A simple occlusion shader that can be used to hide other objects. This prevents
93105

94106
### [Tests](Tests)
95107

108+
#### HeadsUpDirectionIndicator.unity
109+
This scene shows 7 marker objects with 7 HeadsUpDirectionIndicators pointing to each. Each indicator has a label that matches its corresponding marker. 6 of the marker/indicator pairs are used to test the edge cases of axis aligned markers. The 7th is an arbitrary point off of the cartesean axes. From the starting position, the user should be able to follow the direction of each indicator and arrive at the marker with the corresponding axis label. At the start, the labels should be in the following screen locations.
110+
111+
- \-X at the left
112+
- +X at the right
113+
- \-Y at the bottom
114+
- +Y at the top
115+
- \-Z also at the bottom
116+
- +Z in front
117+
96118
#### ManualCameraControl.unity
97119

98120
This scene shows how to use ManualCameraControl.cs. The script is on the main camera of the scene. When preview mode in Unity is activated, the user can move around the scene using WASD and look around using ctrl + mouse.

0 commit comments

Comments
 (0)