zink: handle 0 ubos and 0 ssbos in pipeline layout
this is the number of types needed, and it can be zero cc: mesa-stable Reviewed-by: Dave Airlie <airlied@redhat.com> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/15853>
This commit is contained in:

committed by
Marge Bot

parent
c7ae22e4b8
commit
23c758807e
@@ -132,12 +132,12 @@ descriptor_program_num_sizes(VkDescriptorPoolSize *sizes, enum zink_descriptor_t
|
||||
{
|
||||
switch (type) {
|
||||
case ZINK_DESCRIPTOR_TYPE_UBO:
|
||||
return 1;
|
||||
return !!sizes[ZDS_INDEX_UBO].descriptorCount;
|
||||
case ZINK_DESCRIPTOR_TYPE_SAMPLER_VIEW:
|
||||
return !!sizes[ZDS_INDEX_COMBINED_SAMPLER].descriptorCount +
|
||||
!!sizes[ZDS_INDEX_UNIFORM_TEXELS].descriptorCount;
|
||||
case ZINK_DESCRIPTOR_TYPE_SSBO:
|
||||
return 1;
|
||||
return !!sizes[ZDS_INDEX_STORAGE_BUFFER].descriptorCount;
|
||||
case ZINK_DESCRIPTOR_TYPE_IMAGE:
|
||||
return !!sizes[ZDS_INDEX_STORAGE_IMAGE].descriptorCount +
|
||||
!!sizes[ZDS_INDEX_STORAGE_TEXELS].descriptorCount;
|
||||
|
Reference in New Issue
Block a user