2021-01-10 06:52:27 +00:00
|
|
|
#version 450
|
|
|
|
|
|
|
|
layout (set = 0, binding = 0) uniform Matrices {
|
2021-12-08 06:28:21 +00:00
|
|
|
mat4 Projection3d;
|
|
|
|
mat4 View;
|
|
|
|
mat4 Sky;
|
|
|
|
mat4 Projection2d;
|
2021-01-10 06:52:27 +00:00
|
|
|
};
|
|
|
|
/** Vertex position.
|
|
|
|
|
|
|
|
x, y, s, t
|
|
|
|
|
|
|
|
\a vertex provides the onscreen location at which to draw the icon
|
|
|
|
(\a x, \a y) and texture coordinate for the icon (\a s=z, \a t=w).
|
|
|
|
*/
|
2021-01-12 02:27:41 +00:00
|
|
|
layout (location = 0) in vec2 vertex;
|
2021-01-12 04:51:41 +00:00
|
|
|
layout (location = 1) in vec2 uv;
|
2021-01-12 02:27:41 +00:00
|
|
|
layout (location = 2) in vec4 vcolor;
|
2021-01-10 06:52:27 +00:00
|
|
|
|
|
|
|
layout (location = 0) out vec2 st;
|
|
|
|
layout (location = 1) out vec4 color;
|
|
|
|
|
|
|
|
void
|
|
|
|
main (void)
|
|
|
|
{
|
2021-12-08 06:28:21 +00:00
|
|
|
gl_Position = Projection2d * vec4 (vertex.xy, 0.0, 1.0);
|
2021-01-12 04:51:41 +00:00
|
|
|
st = uv;
|
2021-01-10 06:52:27 +00:00
|
|
|
color = vcolor;
|
|
|
|
}
|