1
0
Fork 0

experimental new rendering

This commit is contained in:
Sen 2025-08-30 21:00:34 +02:00
parent d4c7c5bbea
commit 2006e31a71
Signed by: sen
GPG key ID: 3AC50A6F47D1B722
96 changed files with 1658 additions and 3104 deletions

View file

@ -0,0 +1,7 @@
out vec4 FragColor;
in vec4 tex_color;
void main() {
FragColor = tex_color;
}

View file

@ -0,0 +1,13 @@
layout (location = 0) in vec3 pos;
layout (location = 1) in vec4 norm;
layout (location = 2) in vec2 coord;
layout (location = 3) in vec4 color;
out vec4 tex_color;
uniform vec2 screen_size;
void main() {
tex_color = color;
gl_Position = vec4(-1.0 + pos.x / screen_size.x * 2.0, -1.0 + pos.y / screen_size.y * 2.0, 0.0, 1.0);
}

View file

@ -0,0 +1,10 @@
out vec4 FragColor;
in vec2 tex_coord;
in vec4 tex_color;
uniform sampler2D tex;
void main() {
FragColor = texture(tex, tex_coord) * tex_color;
}

View file

@ -0,0 +1,15 @@
layout (location = 0) in vec3 pos;
layout (location = 1) in vec4 norm;
layout (location = 2) in vec2 coord;
layout (location = 3) in vec4 color;
out vec2 tex_coord;
out vec4 tex_color;
uniform vec2 screen_size;
void main() {
tex_coord = coord;
tex_color = color;
gl_Position = vec4(pos.x, pos.y, 0.0, 1.0);
}