summary refs log tree commit diff
path: root/res/shaders
diff options
context:
space:
mode:
authoriurii plugatarov <[email protected]>2024-08-17 17:38:07 +0200
committeriurii plugatarov <[email protected]>2024-08-17 17:38:07 +0200
commit20f1e487c8cbb8a23b2759d1934fffc5b6b38156 (patch)
treeb67cbf36b29cd2c536e68fe3c3e1b625b3ee1e65 /res/shaders
parent76dfca79570ae1f4dc058ced03f48980466ef777 (diff)
downloadfunhalla-20f1e487c8cbb8a23b2759d1934fffc5b6b38156.tar.gz
transformations
Diffstat (limited to '')
-rw-r--r--res/shaders/triangle.vs6
1 files changed, 4 insertions, 2 deletions
diff --git a/res/shaders/triangle.vs b/res/shaders/triangle.vs
index a6b5b4b..c607a81 100644
--- a/res/shaders/triangle.vs
+++ b/res/shaders/triangle.vs
@@ -6,11 +6,13 @@ layout (location = 2) in vec2 a_tex_coord;
 out vec3 our_color;
 out vec2 TexCoord;
 
-uniform mat4 transform;
+uniform mat4 model;
+uniform mat4 view;
+uniform mat4 projection;
 
 void main()
 {
-    gl_Position = transform * vec4(a_pos, 1.0);
+    gl_Position = projection * view * model * vec4(a_pos, 1.0);
     our_color = a_color;
     TexCoord = vec2(a_tex_coord.x, a_tex_coord.y);
 }