Replace ITintableRenderable with IModifyableRenderable.

This commit is contained in:
Paul Chote
2020-12-11 22:19:30 +00:00
committed by abcdefg30
parent 67754e8693
commit 8edd9de278
16 changed files with 117 additions and 56 deletions

View File

@@ -228,9 +228,17 @@ void main()
#endif
}
else
#if __VERSION__ == 120
gl_FragColor = c * vTint;
{
// A negative tint alpha indicates that the tint should replace the colour instead of multiplying it
if (vTint.a < 0.0)
c = vec4(vTint.rgb, -vTint.a);
else
c *= vTint;
#if __VERSION__ == 120
gl_FragColor = c;
#else
fragColor = c * vTint;
fragColor = c;
#endif
}
}