vkencoder-private: early return if dpb pool or dpb buffer already exist

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/7974>
This commit is contained in:
Víctor Manuel Jáquez Leal 2024-10-03 22:31:54 +02:00 committed by GStreamer Marge Bot
parent 52bd1931b8
commit 066144f78c

View file

@ -983,6 +983,10 @@ gst_vulkan_encoder_create_dpb_pool (GstVulkanEncoder * self, GstCaps * caps)
if (!priv->started)
return FALSE;
if ((!priv->layered_dpb && priv->dpb_pool)
|| (priv->layered_dpb && priv->layered_buffer))
return TRUE;
if (priv->layered_dpb) {
min_buffers = max_buffers = 1;
} else {