vulkan/runtime: avoid emitting empty build_leaves

Seen in GravityMark.

Signed-off-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Reviewed-by: Sagar Ghuge <sagar.ghuge@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/32835>
This commit is contained in:
Lionel Landwerlin 2025-01-02 15:33:06 +02:00 committed by Marge Bot
parent 2b9b34887e
commit a224105a26

View file

@ -546,6 +546,9 @@ build_leaves(VkCommandBuffer commandBuffer,
const VkAccelerationStructureBuildRangeInfoKHR *build_range_info = &ppBuildRangeInfos[i][j];
if (build_range_info->primitiveCount == 0)
continue;
leaf_consts.geom_data = vk_fill_geometry_data(pInfos[i].type, bvh_states[i].leaf_node_count, j, geom, build_range_info);
disp->CmdPushConstants(commandBuffer, layout,