You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
18 lines
396 B
GLSL
18 lines
396 B
GLSL
#ifdef GL_ES
|
|
precision mediump float;
|
|
#endif
|
|
|
|
const vec3 background = vec3(1.0);
|
|
const vec3 primary = vec3(0., 0.345, 0.761);
|
|
const vec3 tertiary = vec3(0.675, 0.514, 0.682);
|
|
|
|
varying float vHeight;
|
|
varying float vColor;
|
|
|
|
void main() {
|
|
float height = vHeight * 2.0 + 0.9;
|
|
|
|
vec3 color = mix(primary, tertiary, vColor * 3.0 + 0.5);
|
|
|
|
gl_FragColor = vec4(mix(color, background, height), 1.0);
|
|
} |