diff options
author | Lynne <dev@lynne.ee> | 2024-11-23 19:03:29 +0100 |
---|---|---|
committer | Lynne <dev@lynne.ee> | 2024-11-26 14:14:14 +0100 |
commit | f582de8f343d25c7a67c6419f3bbbc8b102de994 (patch) | |
tree | b5daceb67fb5059bc59203fa6cdf8af5ca2424c8 | |
parent | 8ac49ae9e0fab632e5b1a7428e9f911d4a258873 (diff) | |
download | ffmpeg-f582de8f343d25c7a67c6419f3bbbc8b102de994.tar.gz |
vulkan: only apply shortcut for next context selection if selection has a submission
-rw-r--r-- | libavutil/vulkan.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/libavutil/vulkan.c b/libavutil/vulkan.c index 5c463b731c..5e8d69a297 100644 --- a/libavutil/vulkan.c +++ b/libavutil/vulkan.c @@ -494,7 +494,8 @@ FFVkExecContext *ff_vk_exec_get(FFVulkanContext *s, FFVkExecPool *pool) /* Check if last submission has already finished. * If so, don't waste resources and reuse the same buffer. */ - if (vk->GetFenceStatus(s->hwctx->act_dev, e->fence) == VK_SUCCESS) + if (e->had_submission && + vk->GetFenceStatus(s->hwctx->act_dev, e->fence) == VK_SUCCESS) return e; pool->idx = (pool->idx + 1) % pool->pool_size; |