2 #extension GL_ARB_shading_language_420pack : require
3 #extension GL_ARB_explicit_attrib_location : require
5 layout(std140, binding=0) uniform Viewport
11 layout(location = 0) in vec2 position;
12 layout(location = 1) in vec2 tex_coord;
14 out vec2 fp_tex_coord;
18 // Transform to clip coordinates (-1,1, -1,1).
19 gl_Position.x = (position.x*2/width) - 1;
20 gl_Position.y = 1 - (position.y*2/height);
23 fp_tex_coord = tex_coord;