Allow color modulation of sprites, refactor renderer init

This commit is contained in:
2016-07-09 16:08:03 +10:00
parent ea2656c0bd
commit ea50aeb44e
7 changed files with 57 additions and 40 deletions
Binary file not shown.
+2 -1
View File
@@ -4,8 +4,9 @@ in vec2 texCoord;
out vec4 color;
uniform sampler2D tex;
uniform vec4 spriteColor;
void main()
{
color = texture(tex, texCoord);
color = spriteColor * texture(tex, texCoord);
}