Complete transformation and coordinate system chapters
This commit is contained in:
1 parent
efa4b7a6a8
commit
318c000391
3 files changed
+72
-30
No files matched your search
@@ -1,6 +1,5 @@
|
||||
#version 330 core
|
||||
|
||||
in vec3 vert_color;
|
||||
in vec2 tex_coords;
|
||||
|
||||
out vec4 color;
|
||||
|
||||
+5
-6
@@ -1,16 +1,15 @@
|
||||
#version 330 core
|
||||
|
||||
layout(location=0) in vec3 position;
|
||||
layout(location=1) in vec3 color;
|
||||
layout(location=2) in vec2 uv;
|
||||
layout(location=1) in vec2 uv;
|
||||
|
||||
uniform mat4 matrix;
|
||||
uniform mat4 model;
|
||||
uniform mat4 view;
|
||||
uniform mat4 projection;
|
||||
|
||||
out vec3 vert_color;
|
||||
out vec2 tex_coords;
|
||||
|
||||
void main() {
|
||||
tex_coords = uv;
|
||||
vert_color = color;
|
||||
gl_Position = matrix * vec4(position, 1.0);
|
||||
gl_Position = projection * view * model * vec4(position, 1.0);
|
||||
};
|
||||
Reference in new issue
Block a user