update cmake

This commit is contained in:
2026-07-10 22:29:14 -07:00
parent d7890c9808
commit ccf305fdf5
5 changed files with 78 additions and 8 deletions
+29
View File
@@ -0,0 +1,29 @@
#version 330
in vec2 fragTexCoord;
uniform sampler2D texture0;
uniform vec2 resolution;
uniform float angle;
out vec4 rotOut;
void main()
{
vec2 uv_space = fragTexCoord - 0.5;
uv_space.x *= resolution.x / resolution.y;
float i = cos(-angle);
float j = sin(-angle);
vec2 rot = vec2((uv_space.x * i) - (uv_space.y * j), (uv_space.x * j) + (uv_space.y * i));
rot.x /= resolution.x / resolution.y;
rot += 0.5;
if (rot.x < 0.0 || rot.x > 1.0 || rot.y < 0.0 || rot.y > 1.0) {
rotOut = vec4(0.0, 0.0, 0.0, 1.0);
} else {
rotOut = texture(texture0, rot);
}
}