vulkan: add vk_descriptor_type_is_dynamic helper
There's a few variants of this in the tree already, let's add a reusable one that we can switch to. Reviewed-by: Alyssa Rosenzweig <alyssa@rosenzweig.io> Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com> Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com> Reviewed-by: Boris Brezillon <boris.brezillon@collabora.com> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/32627>
This commit is contained in:
committed by
Marge Bot
parent
42b29837c9
commit
d6047f3c33
@@ -384,6 +384,19 @@ vk_index_to_restart(VkIndexType type)
|
||||
}
|
||||
}
|
||||
|
||||
static inline bool
|
||||
vk_descriptor_type_is_dynamic(VkDescriptorType type)
|
||||
{
|
||||
switch (type) {
|
||||
case VK_DESCRIPTOR_TYPE_UNIFORM_BUFFER_DYNAMIC:
|
||||
case VK_DESCRIPTOR_TYPE_STORAGE_BUFFER_DYNAMIC:
|
||||
return true;
|
||||
|
||||
default:
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
Reference in New Issue
Block a user