21 lines
385 B
GLSL
21 lines
385 B
GLSL
|
#version 330 core
|
||
|
|
||
|
layout(location = 0) in vec3 in_pos;
|
||
|
layout(location = 1) in vec3 in_norm;
|
||
|
layout(location = 2) in vec2 in_uv;
|
||
|
|
||
|
out vec3 norm;
|
||
|
out vec2 uv;
|
||
|
out vec3 frag_pos;
|
||
|
|
||
|
uniform mat4 proj;
|
||
|
uniform mat4 view;
|
||
|
uniform mat4 model;
|
||
|
|
||
|
void main() {
|
||
|
gl_Position = proj * view * model * vec4(in_pos, 1.0);
|
||
|
norm = in_norm;
|
||
|
uv = in_uv;
|
||
|
frag_pos = vec3(model * vec4(in_pos, 1.0));
|
||
|
}
|