tes-tiger/resources/shader.vertex

22 lines
630 B
Plaintext
Raw Normal View History

2018-06-15 13:48:45 +00:00
#version 460 core
layout(location = 0) in vec3 vPosition;
layout(location = 1) in vec3 vNormal;
layout(location = 2) in vec2 vTextureCoordinates;
layout(location = 3) in vec3 vColor;
layout(location = 0) uniform mat4 modelTransform;
layout(location = 1) uniform mat4 viewTransform;
layout(location = 2) uniform mat4 projectionTransform;
out vec3 fNormal;
out vec2 fTextureCoordinates;
out vec3 fColor;
void main() {
gl_Position = projectionTransform * viewTransform * modelTransform * vec4(vPosition, 1.0f);
fNormal = vNormal;
fTextureCoordinates = vTextureCoordinates;
fColor = vColor;
}