treesummaryrefslogcommitdiff
path: root/shaders/ts_vert.glsl
diff options
context:
space:
mode:
Diffstat (limited to 'shaders/ts_vert.glsl')
-rw-r--r--shaders/ts_vert.glsl21
1 files changed, 21 insertions, 0 deletions
diff --git a/shaders/ts_vert.glsl b/shaders/ts_vert.glsl
new file mode 100644
index 0000000..f8e790a
--- /dev/null
+++ b/shaders/ts_vert.glsl
@@ -0,0 +1,21 @@
+#version 330 core
+
+layout (location = 0) in vec3 pos;
+layout (location = 1) in vec3 normal;
+layout (location = 2) in vec2 uv;
+
+out vec3 Normal;
+out vec3 FragPos;
+out vec2 UV;
+
+uniform mat4 model;
+uniform mat4 view;
+uniform mat4 projection;
+
+void main()
+{
+ gl_Position = projection * view * model * vec4(pos, 1.0);
+ FragPos = vec3(model * vec4(pos, 1.0));
+ Normal = normal;
+ UV = uv;
+}