26 lines
273 B
GLSL
26 lines
273 B
GLSL
[[vertex]]
|
|
|
|
uniform mat4 mvp;
|
|
|
|
in vec4 pos;
|
|
in vec2 uvs;
|
|
out vec2 uv;
|
|
|
|
void main()
|
|
{
|
|
uv = uvs;
|
|
gl_Position = mvp * vec4(pos.xyz, 1.0);
|
|
}
|
|
|
|
[[fragment]]
|
|
|
|
uniform sampler2D tex;
|
|
|
|
in mediump vec2 uv;
|
|
out mediump vec4 frag;
|
|
|
|
void main()
|
|
{
|
|
frag = texture(tex, uv);
|
|
}
|