shader/sprite_negative: modulate color

This commit is contained in:
Andrei Alexeyev 2023-01-31 05:40:48 +01:00
parent 9a7121e329
commit 7ac97455ef
No known key found for this signature in database
GPG key ID: 72D26128040B9690

View file

@ -4,5 +4,5 @@
void spriteMain(out vec4 fragColor) {
vec4 texel = texture(tex, texCoord);
fragColor = vec4((1.0 - texel.rgb / max(0.01, texel.a)) * texel.a, 0);
fragColor = color * vec4((1.0 - texel.rgb / max(0.01, texel.a)) * texel.a, 0);
}