forked from AuroraMiddleware/gtk
gl renderer: Only take glyph texture alpha into account
This way, we can use the very same coloring program to draw text shadows of fonts with colored glyphs.
This commit is contained in:
parent
075e6ac266
commit
eb221ff305
@ -1,4 +1,3 @@
|
||||
|
||||
uniform vec4 u_color;
|
||||
|
||||
void main() {
|
||||
@ -8,5 +7,7 @@ void main() {
|
||||
// pre-multiply
|
||||
color.rgb *= color.a;
|
||||
|
||||
setOutputColor((diffuse * color) * u_alpha);
|
||||
color = vec4(u_color.rgb * diffuse.a * u_alpha, diffuse.a * color.a * u_alpha);
|
||||
|
||||
setOutputColor(color);
|
||||
}
|
||||
|
@ -7,7 +7,7 @@ void main() {
|
||||
// pre-multiply
|
||||
color.rgb *= color.a;
|
||||
|
||||
color = vec4(u_color.rgb * diffuse.a, diffuse.a * color.a);
|
||||
color = vec4(u_color.rgb * diffuse.a * u_alpha, diffuse.a * color.a * u_alpha);
|
||||
|
||||
setOutputColor(color);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user