mirror of
https://github.com/mkxp-z/mkxp-z.git
synced 2024-10-28 03:09:36 +01:00
a53163660f
Don't globally set float precision to mediump, only fragment shaders need that and defining it for vertex shaders causes tilemap cracks. Also manually define low precision for variables that hold color / alpha values.
20 lines
330 B
GLSL
20 lines
330 B
GLSL
|
|
uniform mat4 projMat;
|
|
uniform mat4 matrix;
|
|
|
|
uniform vec2 texSizeInv;
|
|
|
|
attribute vec2 position;
|
|
attribute vec2 texCoord;
|
|
attribute lowp vec4 color;
|
|
|
|
varying vec2 v_texCoord;
|
|
varying lowp vec4 v_color;
|
|
|
|
void main()
|
|
{
|
|
gl_Position = projMat * matrix * vec4(position, 0, 1);
|
|
|
|
v_texCoord = texCoord * texSizeInv;
|
|
v_color = color;
|
|
}
|