prosperon/source/shaders/gridvert.glsl

21 lines
327 B
Plaintext
Raw Normal View History

2022-06-21 23:16:14 -05:00
#version 330
layout (location = 0) in vec2 pos;
2023-05-12 13:22:05 -05:00
out vec2 apos;
2023-02-13 08:30:35 -06:00
2022-06-21 23:16:14 -05:00
layout (std140) uniform Projection {
mat4 projection;
};
2023-05-12 13:22:05 -05:00
uniform vec2 offset;
2022-06-21 23:16:14 -05:00
void main()
{
2023-05-12 13:22:05 -05:00
// vec4 ipos = inverse(projection) * vec4(pos, 0.f, 1.f);
apos = pos * vec2(600, 360);
// apos = pos + offset;
2022-06-21 23:16:14 -05:00
gl_Position = vec4(pos, 0.f, 1.f);
2023-02-13 08:30:35 -06:00
}