IntegratedQuantum 9898db654b Specify the location of all shader in/out parameters.
also normalized the version and layout formatting
progress towards #1376
2025-05-02 14:53:57 +02:00

16 lines
356 B
GLSL

#version 460
layout(location = 0) out vec4 frag_color;
uniform sampler2D image;
layout(location = 0) in vec2 startCoord;
layout(location = 1) flat in vec4 fColor;
uniform float scale;
void main() {
frag_color = texture(image, (gl_FragCoord.xy - startCoord)/(2*scale)/textureSize(image, 0));
frag_color.a *= fColor.a;
frag_color.rgb += fColor.rgb;
}