diff options
Diffstat (limited to 'shaders')
-rw-r--r-- | shaders/fragment.frag | 3 | ||||
-rw-r--r-- | shaders/vertex.vert | 8 |
2 files changed, 8 insertions, 3 deletions
diff --git a/shaders/fragment.frag b/shaders/fragment.frag index ea1ca7d..60791c2 100644 --- a/shaders/fragment.frag +++ b/shaders/fragment.frag @@ -1,8 +1,9 @@ #version 330 core -uniform vec3 triangle_color; out vec4 out_color; +uniform vec3 triangle_color; + void main() { out_color = vec4(triangle_color, 1.0); }
\ No newline at end of file diff --git a/shaders/vertex.vert b/shaders/vertex.vert index d1cc433..a44217b 100644 --- a/shaders/vertex.vert +++ b/shaders/vertex.vert @@ -1,7 +1,11 @@ #version 330 core -in vec2 position; +in vec3 position; + +uniform mat4 proj; +uniform mat4 view; +uniform mat4 model; void main() { - gl_Position = vec4(position, 0.0, 1.0); + gl_Position = proj * view * model * vec4(position, 1.0); }
\ No newline at end of file |