Initial import

This commit is contained in:
2023-04-27 14:31:06 +03:00
commit 708215a2ee
43 changed files with 1244 additions and 0 deletions
+17
View File
@@ -0,0 +1,17 @@
precision highp float;
varying vec2 uv;
varying vec2 position_background;
uniform sampler2D image;
uniform vec4 background_color;
void main() {
vec2 frac = position_background - floor(position_background);
float checkerboard = ((frac.x > .5) == (frac.y > .5)) ? 0.4 : 0.5;
vec4 background = (1.0 - background_color.a) * vec4(vec3(checkerboard), 1.0) +
background_color.a * vec4(background_color.rgb, 1.0);
vec4 value = texture2D(image, uv);
gl_FragColor = (1.0 - value.a) * background + value.a * vec4(value.rgb, 1.0);
}