|
|
@ -6,6 +6,7 @@ void main() {
|
|
6
|
6
|
gl_FragColor = vec4(gl_FragCoord.xy / iResolution, blue, 1.0);
|
|
7
|
7
|
}`,
|
|
8
|
8
|
"default.frag": `//#include "includes/sphere-tracer.frag"
|
|
|
9
|
//#include "includes/default-main.frag"
|
|
9
|
10
|
//#include "includes/iq-primitives.frag"
|
|
10
|
11
|
//#include "includes/cupe-primitives.frag"
|
|
11
|
12
|
|
|
|
@ -20,10 +21,7 @@ float DistanceEstimator(vec3 pos) {
|
|
20
|
21
|
// udBox(pos, vec3(1.0, 0.3, 1.0)));
|
|
21
|
22
|
return min(max(-sphere(pos), udBox(pos, vec3(0.75))),
|
|
22
|
23
|
sphere(pos, 0.05 + 0.25 * (1.0 + sin(iGlobalTime * 0.5)*0.5)));
|
|
23
|
|
}
|
|
24
|
|
|
|
25
|
|
//#include "includes/default-main.frag"
|
|
26
|
|
`,
|
|
|
24
|
}`,
|
|
27
|
25
|
"includes/iq-primitives.frag": `float sphere(vec3 pos) {
|
|
28
|
26
|
return length(pos) - 1.0;
|
|
29
|
27
|
}
|