fix broken 2D light blending, addresses #49922
This commit is contained in:
parent
f74491fdee
commit
2047be4516
@ -595,6 +595,8 @@ void main() {
|
|||||||
color = vec4(0.0); //invisible by default due to using light mask
|
color = vec4(0.0); //invisible by default due to using light mask
|
||||||
}
|
}
|
||||||
|
|
||||||
|
vec4 original_color = color;
|
||||||
|
|
||||||
#ifdef MODE_LIGHT_ONLY
|
#ifdef MODE_LIGHT_ONLY
|
||||||
color = vec4(0.0);
|
color = vec4(0.0);
|
||||||
#else
|
#else
|
||||||
@ -636,6 +638,8 @@ void main() {
|
|||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
light_color.rgb *= original_color.rgb;
|
||||||
|
|
||||||
light_blend_compute(light_base, light_color, color.rgb);
|
light_blend_compute(light_base, light_color, color.rgb);
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -732,6 +736,8 @@ void main() {
|
|||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
light_color.rgb *= original_color.rgb;
|
||||||
|
|
||||||
light_blend_compute(light_base, light_color, color.rgb);
|
light_blend_compute(light_base, light_color, color.rgb);
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
Loading…
Reference in New Issue
Block a user