surprise
2024-04-18 caceb47d790cedaf68ddcda983b6c38280d11d8e
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
glTFH< {"accessors":{"accessor_21":{"bufferView":"bufferView_1","byteOffset":0,"byteStride":0,"componentType":5123,"count":276,"type":"SCALAR","min":[0],"max":[193]},"accessor_23":{"bufferView":"bufferView_0","byteOffset":0,"byteStride":0,"componentType":5123,"count":120,"max":[65535,65535,65535],"min":[0,0,0],"type":"VEC3","extensions":{"WEB3D_quantized_attributes":{"decodedMin":[-0.06679610908031464,39.30294418334961,-15.075913429260254],"decodedMax":[0.06680509448051453,46.10021209716797,-14.942313194274902],"decodeMatrix":[0.000002038623690559688,0,0,0,0,0.00010371965993466635,0,0,0,0,0.000002038608911045267,0,-0.06679610908031464,39.30294418334961,-15.075913429260254,1]}}},"accessor_25":{"bufferView":"bufferView_0","byteOffset":720,"byteStride":0,"componentType":5121,"count":120,"max":[255,255],"min":[0,0],"type":"VEC2"}},"animations":{},"asset":{"generator":"collada2gltf@","premultipliedAlpha":true,"profile":{"api":"WebGL","version":"1.0.2"},"version":"1.0"},"bufferViews":{"bufferView_0":{"buffer":"binary_glTF","byteLength":960,"byteOffset":0,"target":34962},"bufferView_1":{"buffer":"binary_glTF","byteLength":552,"byteOffset":960,"target":34963},"binary_bufferView0":{"buffer":"binary_glTF","byteLength":629,"byteOffset":1512},"binary_bufferView1":{"buffer":"binary_glTF","byteLength":1947,"byteOffset":2141}},"buffers":{"binary_glTF":{"type":"arraybuffer","byteLength":4088,"uri":"data:,"}},"materials":{"_9_-_Default":{"name":"_9_-_Default","technique":"technique0","values":{"ambient":[0.9019609689712523,0.9019609689712523,0.9019609689712523,1],"diffuse":[0.9019609689712523,0.9019609689712523,0.9019609689712523,1],"emission":[0.9019609689712523,0.9019609689712523,0.9019609689712523,1],"shininess":10,"specular":[0,0,0,1]}}},"meshes":{"geom-______":{"name":"______","primitives":[{"attributes":{"NORMAL":"accessor_25","POSITION":"accessor_23"},"indices":"accessor_21","material":"_9_-_Default","mode":4}]}},"nodes":{"rootNode":{"children":[],"meshes":["geom-______"],"matrix":[1,0,0,0,0,1,0,0,0,0,1,0,0,0,0,1]}},"programs":{"program_0":{"attributes":["a_normal","a_position"],"fragmentShader":"input0FS","vertexShader":"input0VS"}},"scene":"defaultScene","scenes":{"defaultScene":{"nodes":["rootNode"]}},"shaders":{"input0FS":{"type":35632,"uri":"data:,","extensions":{"KHR_binary_glTF":{"bufferView":"binary_bufferView0"}}},"input0VS":{"type":35633,"uri":"data:,","extensions":{"KHR_binary_glTF":{"bufferView":"binary_bufferView1"}}}},"skins":{},"techniques":{"technique0":{"attributes":{"a_normal":"normal","a_position":"position"},"parameters":{"ambient":{"type":35666},"diffuse":{"type":35666},"emission":{"type":35666},"modelViewMatrix":{"semantic":"MODELVIEW","type":35676},"normal":{"semantic":"NORMAL","type":35667},"normalMatrix":{"semantic":"MODELVIEWINVERSETRANSPOSE","type":35675},"position":{"semantic":"POSITION","type":35665},"projectionMatrix":{"semantic":"PROJECTION","type":35676},"shininess":{"type":5126},"specular":{"type":35666}},"program":"program_0","states":{"enable":[2929,2884],"disable":[]},"uniforms":{"u_ambient":"ambient","u_diffuse":"diffuse","u_emission":"emission","u_modelViewMatrix":"modelViewMatrix","u_normalMatrix":"normalMatrix","u_projectionMatrix":"projectionMatrix","u_shininess":"shininess","u_specular":"specular"}}},"extensionsUsed":["WEB3D_quantized_attributes"],"cameras":{},"images":{},"samplers":{},"textures":{}}  €öP ^ö ^ ^ÿÿ ^€ÿÿPß¡ö ^ß¡ÿÿ ^篏ö€ç¯ÿÿ€ ^ö ^Pö€Pÿÿ€ ^ÿÿ ^ ^öß¡ ^ÿÿß¡ ^öß¡€ö節ÿÿ篠^ÿÿߡߡöߡߡÿÿߡߡöߡ篏ö€ç¯ÿÿ€ß¡ÿÿß¡ç¯ÿÿ€ß¡ÿÿ ^€ÿÿPß¡ÿÿß¡€ÿÿ篠^ÿÿß¡Pÿÿ€ ^ÿÿ ^P€ ^ ^€P ^ߡ節ߡߡ€ç¯ß¡ ^€P ^ ^ ^&7 ^ÿ&7Pß¡ ^ß¡&7 ^節ç¯&7€ ^ ^P€P&7€ ^&7 ^ ^ß¡ ^&7ß¡ ^ß¡€ç¯ÿ&7篠^&7ߡߡߡߡ&7ߡߡߡ節ç¯&7€ß¡&7ß¡ÿ&7}%&7}%~%ö~%€öÚ&7}%‚ڏö~%ÿÿ&7ÿÿÿö€}%&7}%&7€ö€~%ö~%}%&7Ú~%ö‚Ú}%&7Úÿ&7ÿÿ€öÿÿ~%ö‚ځÚ&7Ú‚ڏö‚ځÚ&7Úÿÿ&7ÿÿÿö€‚ڏö‚Úÿ&7P ^&7 ^}%&7}%ÿ&7ß¡&7 ^P&7€&7€ ^&7ß¡}%&7Úÿ&7ç¯ÿ&7ÿÿß¡&7ß¡Ú&7Úç¯&7€ÿÿ&7ÿÚ&7}% ^ö ^€öP€ö~%ö~%Pö€ß¡ö ^‚ڏö~%篏ö€ÿÿö€ß¡öß¡‚ڏö‚Ú€ö節öÿÿ ^öß¡~%ö‚ڏö€%%ÿ¿ÿ¿ÿ¥ÿ¥ZZ%%Z€€€Z¥€¥€Ú€Ú€Ú€Ú€€ÿ€ÿ€ÿ€ÿ€ÿ€ÿ€ÿ€ÿÿ%%ÿ¿ÿ¿ÿ¥ÿ¥ZZ%%Z€€€€Z¥€¥€Ú€Ú€Ú€Ú€ÿÚÚÿÿ@ÿ¿ÿZÿ¥¥€€¥%€%€Z€€Z€¥¥ÚÚÚÚ€ÿ€ÿ€ÿ€ÿ€ÿ€ÿ€ÿ€ÿ€ÿ€ÿ€ÿ€ÿ€ÿ€ÿ€ÿ€ÿ    
 
    
     !"# ""$%"%&#"&'$"()**+(,(++-,.,--/.0122301455216788967:;;87<=>>?<@ABBC@D@CCEDFDEEGFHIJJKHILMMJINOPPQNORSSPOTUVVWTXYZZ[X\X[Y]^^ZY]_``^]_abb`_acddbaceffdce\ggfe[g\hijjkhlhkimnnjimoppnmoqrrpoqsttrqsuvvtsulwwvukwlprecision highp float;
varying vec3 v_normal;
uniform vec4 u_ambient;
uniform vec4 u_diffuse;
uniform vec4 u_emission;
uniform vec4 u_specular;
uniform float u_shininess;
void main(void) {
vec3 normal = normalize(v_normal);
vec4 color = vec4(0., 0., 0., 0.);
vec4 diffuse = vec4(0., 0., 0., 1.);
vec4 emission;
vec4 ambient;
vec4 specular;
ambient = u_ambient;
diffuse = u_diffuse;
emission = u_emission;
specular = u_specular;
diffuse.xyz *= max(dot(normal,vec3(0.,0.,1.)), 0.);
color.xyz += diffuse.xyz;
color.xyz += emission.xyz;
color = vec4(color.rgb * diffuse.a, diffuse.a);
gl_FragColor = color;
}
 
 
 
 
 
 
 
 
 
 
float gltf_signNotZero(float value)
{
    return value >= 0.0 ? 1.0 : -1.0;
}
 
vec2 gltf_signNotZero(vec2 value)
{
    return vec2(gltf_signNotZero(value.x), gltf_signNotZero(value.y));
}
 
vec3 gltf_signNotZero(vec3 value)
{
    return vec3(gltf_signNotZero(value.x), gltf_signNotZero(value.y), gltf_signNotZero(value.z));
}
 
vec4 gltf_signNotZero(vec4 value)
{
    return vec4(gltf_signNotZero(value.x), gltf_signNotZero(value.y), gltf_signNotZero(value.z), gltf_signNotZero(value.w));
}
 
 
 
 
 
 
 
 
 
 vec3 gltf_octDecode(vec2 encoded)
 {
    encoded = encoded / 255.0 * 2.0 - 1.0;
    vec3 v = vec3(encoded.x, encoded.y, 1.0 - abs(encoded.x) - abs(encoded.y));
    if (v.z < 0.0)
    {
        v.xy = (1.0 - abs(v.yx)) * gltf_signNotZero(v.xy);
    }
    
    return normalize(v);
 }
 
 
 
 
 
 
 
 
 
 
 vec3 gltf_octDecode(float encoded)
 {
    float temp = encoded / 256.0;
    float x = floor(temp);
    float y = (temp - x) * 256.0;
    return gltf_octDecode(vec2(x, y));
 }
 
 
 
 
 
 
 
 
 
 
 
 
  void gltf_octDecode(vec2 encoded, out vec3 vector1, out vec3 vector2, out vec3 vector3)
 {
    float temp = encoded.x / 65536.0;
    float x = floor(temp);
    float encodedFloat1 = (temp - x) * 65536.0;
 
    temp = encoded.y / 65536.0;
    float y = floor(temp);
    float encodedFloat2 = (temp - y) * 65536.0;
 
    vector1 = gltf_octDecode(encodedFloat1);
    vector2 = gltf_octDecode(encodedFloat2);
    vector3 = gltf_octDecode(vec2(x, y));
 }
 
 
 
#line 0
 
#line 0
attribute vec2 a_normal;
vec3 gltf_oct_dec_a_normal;
 
attribute vec3 a_position;
 
varying vec3 v_normal;
uniform mat3 u_normalMatrix;
uniform mat4 u_modelViewMatrix;
uniform mat4 u_projectionMatrix;
void gltf_oct_dec_normal() {
vec4 pos = u_modelViewMatrix * vec4(a_position,1.0);
v_normal = u_normalMatrix * gltf_oct_dec_a_normal;
gl_Position = u_projectionMatrix * pos;
}
 
void main() {
    gltf_oct_dec_a_normal = gltf_octDecode(a_normal);
    gltf_oct_dec_normal();
}