#version 400 core

layout (location = 0) in vec3  pos;
layout (location = 1) in vec3  normal;
layout (location = 2) in vec2  tex_coord;
layout (location = 3) in float face_index;

flat out float v2f_face_index;

void main ()
{
    // Transform from uv space to normalized device coordinates
    vec2 ndc = 2 * (tex_coord - vec2(0.5, 0.5));

    gl_Position = vec4(ndc.x, ndc.y, 0.0, 1.0);
    v2f_face_index = face_index;
}
