You've already forked godot
mirror of
https://github.com/godotengine/godot.git
synced 2025-11-04 12:00:25 +00:00
Fix bug where material with double-sided shadows ignores backface culling on compatibility renderer
(cherry picked from commit d6aca93c1a)
This commit is contained in:
committed by
Thaddeus Crews
parent
82fc85aae9
commit
d78a95f971
@@ -3124,7 +3124,7 @@ void RasterizerSceneGLES3::_render_list_template(RenderListParameters *p_params,
|
|||||||
// Find cull variant.
|
// Find cull variant.
|
||||||
RS::CullMode cull_mode = shader->cull_mode;
|
RS::CullMode cull_mode = shader->cull_mode;
|
||||||
|
|
||||||
if (p_pass_mode == PASS_MODE_MATERIAL || (surf->flags & GeometryInstanceSurface::FLAG_USES_DOUBLE_SIDED_SHADOWS)) {
|
if (p_pass_mode == PASS_MODE_MATERIAL || (p_pass_mode == PASS_MODE_SHADOW && (surf->flags & GeometryInstanceSurface::FLAG_USES_DOUBLE_SIDED_SHADOWS))) {
|
||||||
cull_mode = RS::CULL_MODE_DISABLED;
|
cull_mode = RS::CULL_MODE_DISABLED;
|
||||||
} else {
|
} else {
|
||||||
bool mirror = inst->mirror;
|
bool mirror = inst->mirror;
|
||||||
|
|||||||
Reference in New Issue
Block a user