X-Git-Url: https://git.lukelau.me/?p=opengl.git;a=blobdiff_plain;f=vertex.glsl;fp=vertex.glsl;h=f886c9bf2650af8771ec501cbc0a601b21091861;hp=e7a74dd8f1adfc9bf818565b7778b02a79900199;hb=37cba564a96018a5500e942498d4e48c0ebe73ed;hpb=ba5e08bf25de722d907748ce55b27a45b2b270bf diff --git a/vertex.glsl b/vertex.glsl index e7a74dd..f886c9b 100644 --- a/vertex.glsl +++ b/vertex.glsl @@ -2,6 +2,7 @@ in vec3 vPosition; in vec4 vColor; in vec3 vNormal; +in vec2 vTexCoord; uniform mat4 model; uniform mat4 view; uniform mat4 projection; @@ -9,6 +10,7 @@ out vec4 color; out vec3 normal; out vec3 fragPos; out vec3 normalEye; +out vec2 texCoord; void main() { vec4 pos = model * vec4(vPosition, 1.f); @@ -17,4 +19,5 @@ void main() { color = vColor; normal = vNormal; normalEye = vec3(view * vec4(normal, 0.0)); + texCoord = vTexCoord; }