2023-07-11 18:35:02 -04:00
|
|
|
#ifdef __cplusplus
|
|
|
|
#include <string>
|
2023-07-12 21:38:34 -04:00
|
|
|
static std::string UIShaderVertex = R"("
|
2023-07-11 18:35:02 -04:00
|
|
|
#version 460 core
|
|
|
|
|
|
|
|
layout (location = 0) in vec3 position;
|
2023-07-12 21:38:34 -04:00
|
|
|
layout (location = 1) in vec2 uv;
|
2023-07-11 18:35:02 -04:00
|
|
|
|
|
|
|
out vec2 uvs;
|
|
|
|
|
|
|
|
layout (std140) uniform Matrices
|
|
|
|
{
|
|
|
|
mat4 perspective;
|
|
|
|
mat4 view;
|
|
|
|
mat4 pvm;
|
|
|
|
mat4 ortho;
|
|
|
|
};
|
|
|
|
|
2023-07-12 21:38:34 -04:00
|
|
|
uniform mat4 transform;
|
|
|
|
|
2023-07-11 18:35:02 -04:00
|
|
|
void main()
|
|
|
|
{
|
2023-07-12 21:38:34 -04:00
|
|
|
gl_Position = ortho * transform * vec4(position.x, position.y, position.z, 1.0);
|
2023-07-11 18:35:02 -04:00
|
|
|
uvs = uv;
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
")";
|
|
|
|
#endif
|