diff --git a/src/render/shaders/Border.hpp b/src/render/shaders/Border.hpp index d881dc5b5..4e2d485db 100644 --- a/src/render/shaders/Border.hpp +++ b/src/render/shaders/Border.hpp @@ -109,11 +109,14 @@ void main() { discard; } - if (pixColor[3] == 0.0) + if (additionalAlpha == 0.0) discard; pixColor = getColorForCoord(v_texcoord); + pixColor.rgb *= pixColor[3]; - gl_FragColor = pixColor * alpha * additionalAlpha; + pixColor *= alpha * additionalAlpha; + + gl_FragColor = pixColor; } )#"; diff --git a/src/render/shaders/Shadow.hpp b/src/render/shaders/Shadow.hpp index 49f548d78..2c7b07b28 100644 --- a/src/render/shaders/Shadow.hpp +++ b/src/render/shaders/Shadow.hpp @@ -79,9 +79,7 @@ void main() { } // premultiply - pixColor[0] *= pixColor[3]; - pixColor[1] *= pixColor[3]; - pixColor[2] *= pixColor[3]; + pixColor.rgb *= pixColor[3]; gl_FragColor = pixColor; })#";