mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2025-02-20 21:16:24 +00:00
Request minimum buffer even if need_pool is FALSE
When tee is used, it will not request a pool, but still it wants to know how many buffers are required. https://bugzilla.gnome.org/show_bug.cgi?id=730758
This commit is contained in:
parent
6e3bfbc014
commit
2039eb882e
1 changed files with 9 additions and 4 deletions
|
@ -850,20 +850,25 @@ gst_vaapi_plugin_base_propose_allocation (GstVaapiPluginBase * plugin,
|
|||
GstQuery * query)
|
||||
{
|
||||
GstCaps *caps = NULL;
|
||||
GstBufferPool *pool = NULL;
|
||||
gboolean need_pool;
|
||||
|
||||
gst_query_parse_allocation (query, &caps, &need_pool);
|
||||
if (!caps)
|
||||
goto error_no_caps;
|
||||
|
||||
/* FIXME re-using buffer pool breaks renegotiation */
|
||||
if (!ensure_sinkpad_buffer_pool (plugin, caps))
|
||||
return FALSE;
|
||||
|
||||
if (need_pool) {
|
||||
if (!ensure_sinkpad_buffer_pool (plugin, caps))
|
||||
return FALSE;
|
||||
gst_query_add_allocation_pool (query, plugin->sinkpad_buffer_pool,
|
||||
plugin->sinkpad_buffer_size, BUFFER_POOL_SINK_MIN_BUFFERS, 0);
|
||||
pool = plugin->sinkpad_buffer_pool;
|
||||
gst_query_add_allocation_param (query, plugin->sinkpad_allocator, NULL);
|
||||
}
|
||||
|
||||
gst_query_add_allocation_pool (query, pool, plugin->sinkpad_buffer_size,
|
||||
BUFFER_POOL_SINK_MIN_BUFFERS, 0);
|
||||
|
||||
gst_query_add_allocation_meta (query, GST_VAAPI_VIDEO_META_API_TYPE, NULL);
|
||||
gst_query_add_allocation_meta (query, GST_VIDEO_META_API_TYPE, NULL);
|
||||
return TRUE;
|
||||
|
|
Loading…
Reference in a new issue