Files
MapLibreParticleLab/shaders/debug.vertex.glsl
mwilsnd 4828cc7a8b Upgrade OpenGL backend to ES 3.0 (#995)
Co-authored-by: Tadej Novak <tadej@tano.si>
2023-04-13 23:24:45 +02:00

13 lines
365 B
GLSL

layout (location = 0) in vec2 a_pos;
out vec2 v_uv;
uniform mat4 u_matrix;
uniform float u_overlay_scale;
void main() {
// This vertex shader expects a EXTENT x EXTENT quad,
// The UV co-ordinates for the overlay texture can be calculated using that knowledge
v_uv = a_pos / 8192.0;
gl_Position = u_matrix * vec4(a_pos * u_overlay_scale, 0, 1);
}