mirror of
https://github.com/curioustorvald/Terrarum.git
synced 2026-03-10 05:41:51 +09:00
spritebatch with hdr colour
This commit is contained in:
@@ -2,16 +2,18 @@
|
||||
|
||||
in vec4 a_position;
|
||||
in vec4 a_color;
|
||||
in vec4 a_generic;
|
||||
in vec2 a_texCoord0;
|
||||
|
||||
uniform mat4 u_projTrans;
|
||||
|
||||
out vec4 v_color;
|
||||
out vec2 v_texCoords;
|
||||
out vec4 v_generic;
|
||||
|
||||
void main() {
|
||||
v_color = a_color;
|
||||
v_color.a = v_color.a * (255.0/254.0); // GDX will crush the alpha value to 0,2,4,6,8,10,...,254; see com.badlogic.gdx.utils.NumberUtils.intToFloatColor
|
||||
v_texCoords = a_texCoord0;
|
||||
v_generic = a_generic;
|
||||
gl_Position = u_projTrans * a_position;
|
||||
}
|
||||
Reference in New Issue
Block a user