Skip to content
This repository was archived by the owner on Nov 8, 2019. It is now read-only.

Commit a637035

Browse files
committed
GVR Unity SDK v1.70.0
1 parent 2f69898 commit a637035

File tree

6,937 files changed

+31189
-1621133
lines changed

Some content is hidden

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

6,937 files changed

+31189
-1621133
lines changed
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,53 @@
1+
// Copyright 2016 Google Inc. All rights reserved.
2+
//
3+
// Licensed under the Apache License, Version 2.0 (the "License");
4+
// you may not use this file except in compliance with the License.
5+
// You may obtain a copy of the License at
6+
//
7+
// http://www.apache.org/licenses/LICENSE-2.0
8+
//
9+
// Unless required by applicable law or agreed to in writing, software
10+
// distributed under the License is distributed on an "AS IS" BASIS,
11+
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12+
// See the License for the specific language governing permissions and
13+
// limitations under the License.
14+
15+
using UnityEngine;
16+
using UnityEditor;
17+
18+
[CustomEditor(typeof(DemoInputManager))]
19+
public class DemoInputManagerEditor : Editor {
20+
SerializedProperty emulatedPlatformTypeProp;
21+
SerializedProperty gvrControllerMainProp;
22+
SerializedProperty gvrControllerPointerProp;
23+
SerializedProperty gvrReticlePointerProp;
24+
25+
void OnEnable () {
26+
gvrControllerMainProp =
27+
serializedObject.FindProperty(DemoInputManager.CONTROLLER_MAIN_PROP_NAME);
28+
gvrControllerPointerProp =
29+
serializedObject.FindProperty(DemoInputManager.CONTROLLER_POINTER_PROP_NAME);
30+
gvrReticlePointerProp =
31+
serializedObject.FindProperty(DemoInputManager.RETICLE_POINTER_PROP_NAME);
32+
33+
emulatedPlatformTypeProp =
34+
serializedObject.FindProperty(DemoInputManager.EMULATED_PLATFORM_PROP_NAME);
35+
}
36+
37+
public override void OnInspectorGUI() {
38+
serializedObject.Update();
39+
40+
EditorGUILayout.PropertyField(gvrControllerMainProp);
41+
EditorGUILayout.PropertyField(gvrControllerPointerProp);
42+
EditorGUILayout.PropertyField(gvrReticlePointerProp);
43+
44+
if (DemoInputManager.playerSettingsHasCardboard() ==
45+
DemoInputManager.playerSettingsHasDaydream()) {
46+
// Show the platform emulation dropdown only if both or neither VR SDK selected in
47+
// Player Settings > Virtual Reality supported,
48+
EditorGUILayout.PropertyField(emulatedPlatformTypeProp);
49+
}
50+
51+
serializedObject.ApplyModifiedProperties();
52+
}
53+
}

GoogleVR/Demos/Editor/PermissionsDemoBuildEditor.cs renamed to Assets/GoogleVR/Demos/Editor/PermissionsDemoBuildEditor.cs

+1-2
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,6 @@
1414

1515
// This script only works in Unity 5.6 or newer since older versions of Unity
1616
// don't have IPreprocessBuild and IPostprocessBuild.
17-
1817
#if UNITY_5_6_OR_NEWER && UNITY_ANDROID
1918
using System;
2019
using UnityEditor;
@@ -137,4 +136,4 @@ public void OnPostprocessBuild(BuildTarget target, string path)
137136
m_cardboardAddedFromCode = false;
138137
}
139138
}
140-
#endif // UNITY_5_6_OR_NEWER
139+
#endif // UNITY_5_6_OR_NEWER && UNITY_ANDROID
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,57 @@
1+
// Copyright 2016 Google Inc. All rights reserved.
2+
//
3+
// Licensed under the Apache License, Version 2.0 (the "License");
4+
// you may not use this file except in compliance with the License.
5+
// You may obtain a copy of the License at
6+
//
7+
// http://www.apache.org/licenses/LICENSE-2.0
8+
//
9+
// Unless required by applicable law or agreed to in writing, software
10+
// distributed under the License is distributed on an "AS IS" BASIS,
11+
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12+
// See the License for the specific language governing permissions and
13+
// limitations under the License.
14+
15+
Shader "GoogleVR/Demos/Unlit/Env Unlit Grayscale" {
16+
Properties {
17+
_MainTex ("Texture (A)", 2D) = "" {}
18+
}
19+
20+
SubShader {
21+
Tags { "Queue"="Geometry" "RenderType"="Geometry"}
22+
23+
Pass {
24+
CGPROGRAM
25+
#pragma vertex vert
26+
#pragma fragment frag
27+
#pragma target 2.0
28+
#include "UnityCG.cginc"
29+
30+
struct appdata {
31+
float4 vertex : POSITION;
32+
float2 uv : TEXCOORD0;
33+
};
34+
35+
struct v2f {
36+
float2 uv : TEXCOORD0;
37+
float4 vertex : SV_POSITION;
38+
};
39+
40+
sampler2D _MainTex;
41+
float4 _MainTex_ST;
42+
43+
v2f vert (appdata v) {
44+
v2f o;
45+
o.vertex = UnityObjectToClipPos(v.vertex);
46+
o.uv = TRANSFORM_TEX(v.uv, _MainTex);
47+
return o;
48+
}
49+
50+
fixed4 frag (v2f i) : SV_TARGET {
51+
fixed4 col = tex2D(_MainTex, i.uv).a;
52+
return col;
53+
}
54+
ENDCG
55+
}
56+
}
57+
}
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,173 @@
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: 1000013165000468}
13+
m_IsPrefabParent: 1
14+
--- !u!1 &1000010534735224
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: 4000010284511462}
22+
- 114: {fileID: 114000010983088856}
23+
m_Layer: 0
24+
m_Name: GvrAudioRoom
25+
m_TagString: Untagged
26+
m_Icon: {fileID: 0}
27+
m_NavMeshLayer: 0
28+
m_StaticEditorFlags: 0
29+
m_IsActive: 1
30+
--- !u!1 &1000011959013568
31+
GameObject:
32+
m_ObjectHideFlags: 0
33+
m_PrefabParentObject: {fileID: 0}
34+
m_PrefabInternal: {fileID: 100100000}
35+
serializedVersion: 4
36+
m_Component:
37+
- 4: {fileID: 4000010083050526}
38+
- 33: {fileID: 33000012572763690}
39+
- 23: {fileID: 23000013708927898}
40+
- 64: {fileID: 64000011095866406}
41+
m_Layer: 0
42+
m_Name: cubeRoomEnv
43+
m_TagString: Untagged
44+
m_Icon: {fileID: 0}
45+
m_NavMeshLayer: 0
46+
m_StaticEditorFlags: 0
47+
m_IsActive: 1
48+
--- !u!1 &1000013165000468
49+
GameObject:
50+
m_ObjectHideFlags: 0
51+
m_PrefabParentObject: {fileID: 0}
52+
m_PrefabInternal: {fileID: 100100000}
53+
serializedVersion: 4
54+
m_Component:
55+
- 4: {fileID: 4000014274899290}
56+
m_Layer: 0
57+
m_Name: cubeRoom
58+
m_TagString: Untagged
59+
m_Icon: {fileID: 0}
60+
m_NavMeshLayer: 0
61+
m_StaticEditorFlags: 0
62+
m_IsActive: 1
63+
--- !u!4 &4000010083050526
64+
Transform:
65+
m_ObjectHideFlags: 1
66+
m_PrefabParentObject: {fileID: 0}
67+
m_PrefabInternal: {fileID: 100100000}
68+
m_GameObject: {fileID: 1000011959013568}
69+
m_LocalRotation: {x: 0, y: -0, z: -0, w: 1}
70+
m_LocalPosition: {x: -0, y: 0, z: 0}
71+
m_LocalScale: {x: 1, y: 1, z: 1}
72+
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
73+
m_Children: []
74+
m_Father: {fileID: 4000014274899290}
75+
m_RootOrder: 0
76+
--- !u!4 &4000010284511462
77+
Transform:
78+
m_ObjectHideFlags: 1
79+
m_PrefabParentObject: {fileID: 0}
80+
m_PrefabInternal: {fileID: 100100000}
81+
m_GameObject: {fileID: 1000010534735224}
82+
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
83+
m_LocalPosition: {x: 0, y: 3, z: 0}
84+
m_LocalScale: {x: 10, y: 6, z: 10}
85+
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
86+
m_Children: []
87+
m_Father: {fileID: 4000014274899290}
88+
m_RootOrder: 1
89+
--- !u!4 &4000014274899290
90+
Transform:
91+
m_ObjectHideFlags: 1
92+
m_PrefabParentObject: {fileID: 0}
93+
m_PrefabInternal: {fileID: 100100000}
94+
m_GameObject: {fileID: 1000013165000468}
95+
m_LocalRotation: {x: 0, y: -0, z: -0, w: 1}
96+
m_LocalPosition: {x: -0, y: 0, z: 0}
97+
m_LocalScale: {x: 1, y: 1, z: 1}
98+
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
99+
m_Children:
100+
- {fileID: 4000010083050526}
101+
- {fileID: 4000010284511462}
102+
m_Father: {fileID: 0}
103+
m_RootOrder: 0
104+
--- !u!23 &23000013708927898
105+
MeshRenderer:
106+
m_ObjectHideFlags: 1
107+
m_PrefabParentObject: {fileID: 0}
108+
m_PrefabInternal: {fileID: 100100000}
109+
m_GameObject: {fileID: 1000011959013568}
110+
m_Enabled: 1
111+
m_CastShadows: 1
112+
m_ReceiveShadows: 1
113+
m_MotionVectors: 1
114+
m_LightProbeUsage: 1
115+
m_ReflectionProbeUsage: 1
116+
m_Materials:
117+
- {fileID: 2100000, guid: 7ac05d4c78dbc4bd792428649b027747, type: 2}
118+
m_SubsetIndices:
119+
m_StaticBatchRoot: {fileID: 0}
120+
m_ProbeAnchor: {fileID: 0}
121+
m_LightProbeVolumeOverride: {fileID: 0}
122+
m_ScaleInLightmap: 1
123+
m_PreserveUVs: 0
124+
m_IgnoreNormalsForChartDetection: 0
125+
m_ImportantGI: 0
126+
m_SelectedWireframeHidden: 0
127+
m_MinimumChartSize: 4
128+
m_AutoUVMaxDistance: 0.5
129+
m_AutoUVMaxAngle: 89
130+
m_LightmapParameters: {fileID: 0}
131+
m_SortingLayerID: 0
132+
m_SortingOrder: 0
133+
--- !u!33 &33000012572763690
134+
MeshFilter:
135+
m_ObjectHideFlags: 1
136+
m_PrefabParentObject: {fileID: 0}
137+
m_PrefabInternal: {fileID: 100100000}
138+
m_GameObject: {fileID: 1000011959013568}
139+
m_Mesh: {fileID: 4300000, guid: 1b781ad67e8a54061b9897ddfbfdb479, type: 3}
140+
--- !u!64 &64000011095866406
141+
MeshCollider:
142+
m_ObjectHideFlags: 1
143+
m_PrefabParentObject: {fileID: 0}
144+
m_PrefabInternal: {fileID: 100100000}
145+
m_GameObject: {fileID: 1000011959013568}
146+
m_Material: {fileID: 0}
147+
m_IsTrigger: 0
148+
m_Enabled: 1
149+
serializedVersion: 2
150+
m_Convex: 0
151+
m_Mesh: {fileID: 4300000, guid: 1b781ad67e8a54061b9897ddfbfdb479, type: 3}
152+
--- !u!114 &114000010983088856
153+
MonoBehaviour:
154+
m_ObjectHideFlags: 1
155+
m_PrefabParentObject: {fileID: 0}
156+
m_PrefabInternal: {fileID: 100100000}
157+
m_GameObject: {fileID: 1000010534735224}
158+
m_Enabled: 1
159+
m_EditorHideFlags: 0
160+
m_Script: {fileID: 11500000, guid: 1d2722c2401e34d51bf5b473ef7aeefb, type: 3}
161+
m_Name:
162+
m_EditorClassIdentifier:
163+
leftWall: 4
164+
rightWall: 4
165+
floor: 16
166+
ceiling: 15
167+
backWall: 4
168+
frontWall: 4
169+
reflectivity: 1
170+
reverbGainDb: 0
171+
reverbBrightness: -0.5
172+
reverbTime: 1
173+
size: {x: 1, y: 1, z: 1}

0 commit comments

Comments
 (0)