diff options
Diffstat (limited to 'video')
-rw-r--r-- | video/out/vulkan/utils.c | 13 |
1 files changed, 8 insertions, 5 deletions
diff --git a/video/out/vulkan/utils.c b/video/out/vulkan/utils.c index 5b9be3216f..1fd674d28f 100644 --- a/video/out/vulkan/utils.c +++ b/video/out/vulkan/utils.c @@ -519,14 +519,17 @@ bool mpvk_device_init(struct mpvk_ctx *vk, struct mpvk_device_opts opts) if (!pool) goto error; MP_TARRAY_APPEND(NULL, vk->pools, vk->num_pools, pool); - } - vk->pool_graphics = vk->pools[idx_gfx]; - vk->pool_compute = idx_comp >= 0 ? vk->pools[idx_comp] : NULL; - vk->pool_transfer = idx_tf >= 0 ? vk->pools[idx_tf] : NULL; + // Update the pool_* pointers based on the corresponding QF index + if (qf == idx_gfx) + vk->pool_graphics = pool; + if (qf == idx_comp) + vk->pool_compute = pool; + if (qf == idx_tf) + vk->pool_transfer = pool; + } vk_malloc_init(vk); - talloc_free(tmp); return true; |