SOF/renderer/shaders/ui-pane.vert

19 lines
406 B
GLSL
Raw Normal View History

#version 460
// vertex geometry data
layout(location = 0) in vec2 inPos;
// instance data
layout(location = 1) in vec2 inInstancePos;
layout(location = 2) in vec2 inInstanceScale;
layout(location = 3) in vec4 inInstanceColor;
layout(location = 0) out vec4 fragColor;
void main()
{
vec2 pos = inPos * inInstanceScale + inInstancePos;
gl_Position = vec4(pos, 0.0, 1.0);
fragColor = inInstanceColor;
}