Added color multiplier stack to shaders, fixed dynamic font colors

- ShapeFragment.glsl now declares uniformColorMultiplier, which is used
as an additional fragment color multiplier (independent from VBAs)
  - Managed with a new stack by ShapeRenderHelper
- Fixed dynamic font colors
This commit is contained in:
2021-01-05 19:08:53 +03:00
parent d197c0a73e
commit 008e8b33a5
4 changed files with 50 additions and 10 deletions

View File

@@ -1,5 +1,7 @@
#version 120
uniform vec4 uniformColorMultiplier;
varying vec4 varyingColorMultiplier;
varying vec2 varyingTextureCoords;
@@ -17,6 +19,7 @@ void applyTexture() {
void applyColorMultiplier() {
gl_FragColor *= varyingColorMultiplier;
gl_FragColor *= uniformColorMultiplier;
}
void applyAlpha() {