From dcfc66a1ac8f3f755ed87e245643b34f4f8d8e53 Mon Sep 17 00:00:00 2001 From: Diego Nieto Date: Sat, 7 Sep 2024 11:53:05 +0200 Subject: [PATCH] fakevideodec: fix minimum allocation pool size Before it was setting the minimum between 2 and the minimum gst_query_parse_nth_allocation_pool(). So, always giving 2 or less. Part-of: --- subprojects/gst-plugins-base/gst/debugutils/gstfakevideodec.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/subprojects/gst-plugins-base/gst/debugutils/gstfakevideodec.c b/subprojects/gst-plugins-base/gst/debugutils/gstfakevideodec.c index 3e8b1a3d17..6cc3dc8f36 100644 --- a/subprojects/gst-plugins-base/gst/debugutils/gstfakevideodec.c +++ b/subprojects/gst-plugins-base/gst/debugutils/gstfakevideodec.c @@ -460,7 +460,7 @@ gst_fake_video_dec_decide_allocation (GstVideoDecoder * bdec, GstQuery * query) g_assert (pool != NULL); /* Initialize at least 2 buffers. */ - dec->min_buffers = MIN (min_buffers, 2); + dec->min_buffers = MAX (min_buffers, 2); config = gst_buffer_pool_get_config (pool); if (gst_query_find_allocation_meta (query, GST_VIDEO_META_API_TYPE, NULL)) {