mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-11-27 20:21:24 +00:00
vaapisink: ensures raw caps at start()
Calls gst_vaapi_plugin_base_get_allowed_raw_caps() at start() to avoid race conditions at get_caps(), especially with multiple src elements. https://bugzilla.gnome.org/show_bug.cgi?id=776303
This commit is contained in:
parent
dde4db3b3e
commit
5e09f57dea
1 changed files with 12 additions and 1 deletions
|
@ -1214,7 +1214,18 @@ gst_vaapisink_display_changed (GstVaapiPluginBase * plugin)
|
|||
static gboolean
|
||||
gst_vaapisink_start (GstBaseSink * base_sink)
|
||||
{
|
||||
return gst_vaapisink_ensure_display (GST_VAAPISINK_CAST (base_sink));
|
||||
GstVaapiSink *const sink = GST_VAAPISINK_CAST (base_sink);
|
||||
GstVaapiPluginBase *const plugin = GST_VAAPI_PLUGIN_BASE (base_sink);
|
||||
|
||||
if (!gst_vaapisink_ensure_display (sink))
|
||||
return FALSE;
|
||||
|
||||
/* Ensures possible raw caps earlier to avoid race conditions at
|
||||
* get_caps() */
|
||||
if (!gst_vaapi_plugin_base_get_allowed_raw_caps (plugin))
|
||||
return FALSE;
|
||||
|
||||
return TRUE;
|
||||
}
|
||||
|
||||
static gboolean
|
||||
|
|
Loading…
Reference in a new issue