mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-05-06 09:28:07 +02:00
VkImageCreateInfo should ignore queeu family indices in some situation
The spec says indices pointer should be ignored when sharingMode is not VK_SHARING_MODE_CONCURRENT. We need to explicitly set index count to 0 and index pointer to null, otherwise encoder will still try to encode it. Spec: https://registry.khronos.org/vulkan/specs/1.3/html/vkspec.html#VUID-VkBufferCreateInfo-sharingMode-00913 Reviewed-by: Aaron Ruby <aruby@blackberry.com> Acked-by: Yonggang Luo <luoyonggang@gmail.com> Acked-by: Adam Jackson <ajax@redhat.com> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/27246>
This commit is contained in:
parent
00d26a31fa
commit
822c88f173
1 changed files with 5 additions and 0 deletions
|
|
@ -4045,6 +4045,11 @@ VkResult ResourceTracker::on_vkCreateImage(void* context, VkResult, VkDevice dev
|
|||
VkEncoder* enc = (VkEncoder*)context;
|
||||
|
||||
VkImageCreateInfo localCreateInfo = vk_make_orphan_copy(*pCreateInfo);
|
||||
if (localCreateInfo.sharingMode != VK_SHARING_MODE_CONCURRENT) {
|
||||
localCreateInfo.queueFamilyIndexCount = 0;
|
||||
localCreateInfo.pQueueFamilyIndices = nullptr;
|
||||
}
|
||||
|
||||
vk_struct_chain_iterator structChainIter = vk_make_chain_iterator(&localCreateInfo);
|
||||
VkExternalMemoryImageCreateInfo localExtImgCi;
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue