Merge pull request #67176 from cooperra/negative-scale-culling-fix
Vulkan Clustered: Fix culling of negatively-scaled objects
This commit is contained in:
commit
422c398962
1 changed files with 1 additions and 1 deletions
|
@ -754,7 +754,7 @@ void RenderForwardClustered::_fill_instance_data(RenderListType p_render_list, i
|
|||
|
||||
bool cant_repeat = instance_data.flags & INSTANCE_DATA_FLAG_MULTIMESH || inst->mesh_instance.is_valid();
|
||||
|
||||
if (prev_surface != nullptr && !cant_repeat && prev_surface->sort.sort_key1 == surface->sort.sort_key1 && prev_surface->sort.sort_key2 == surface->sort.sort_key2 && repeats < RenderElementInfo::MAX_REPEATS) {
|
||||
if (prev_surface != nullptr && !cant_repeat && prev_surface->sort.sort_key1 == surface->sort.sort_key1 && prev_surface->sort.sort_key2 == surface->sort.sort_key2 && inst->mirror == prev_surface->owner->mirror && repeats < RenderElementInfo::MAX_REPEATS) {
|
||||
//this element is the same as the previous one, count repeats to draw it using instancing
|
||||
repeats++;
|
||||
} else {
|
||||
|
|
Loading…
Reference in a new issue