mirror of
https://gitlab.freedesktop.org/pipewire/pipewire.git
synced 2026-04-23 06:47:02 -04:00
vulkan: fix wrong descriptor image info index
When streams are skipped via continue in updateDescriptors(), the loop index i and descriptorSetLen diverge. The image info is written at descriptorSetLen but pImageInfo was referencing index i, pointing to uninitialized memory and causing incorrect Vulkan descriptor updates. Fix by using descriptorSetLen consistently. Signed-off-by: Wang Yu <wangyu@uniontech.com>
This commit is contained in:
parent
da19aa4eb1
commit
2953f48d9b
1 changed files with 1 additions and 1 deletions
|
|
@ -147,7 +147,7 @@ static int updateDescriptors(struct vulkan_compute_state *s)
|
|||
.descriptorType = i == 0 ?
|
||||
VK_DESCRIPTOR_TYPE_STORAGE_IMAGE :
|
||||
VK_DESCRIPTOR_TYPE_COMBINED_IMAGE_SAMPLER,
|
||||
.pImageInfo = &descriptorImageInfo[i],
|
||||
.pImageInfo = &descriptorImageInfo[descriptorSetLen],
|
||||
};
|
||||
descriptorSetLen++;
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue