mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-11-27 04:01:08 +00:00
plugins: retry pool config
if gst_buffer_pool_set_config returns FALSE, check the modified config and retry set_config if the config is still acceptable. Signed-off-by: Scott D Phillips <scott.d.phillips@intel.com> https://bugzilla.gnome.org/show_bug.cgi?id=766184
This commit is contained in:
parent
fec82052d5
commit
2e5367a23c
1 changed files with 12 additions and 2 deletions
|
@ -597,8 +597,18 @@ gst_vaapi_plugin_base_create_pool (GstVaapiPluginBase * plugin, GstCaps * caps,
|
|||
#endif
|
||||
if (allocator)
|
||||
gst_buffer_pool_config_set_allocator (config, allocator, NULL);
|
||||
if (!gst_buffer_pool_set_config (pool, config))
|
||||
goto error_pool_config;
|
||||
if (!gst_buffer_pool_set_config (pool, config)) {
|
||||
config = gst_buffer_pool_get_config (pool);
|
||||
|
||||
if (!gst_buffer_pool_config_validate_params (config, caps, size,
|
||||
min_buffers, max_buffers)) {
|
||||
gst_structure_free (config);
|
||||
goto error_pool_config;
|
||||
}
|
||||
|
||||
if (!gst_buffer_pool_set_config (pool, config))
|
||||
goto error_pool_config;
|
||||
}
|
||||
return pool;
|
||||
|
||||
/* ERRORS */
|
||||
|
|
Loading…
Reference in a new issue