mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2025-02-20 21:16:24 +00:00
eglglessink: unref last buffer on DRAIN
Similar to 093574053f
in gstbasesink
https://bugzilla.gnome.org/show_bug.cgi?id=726107
This commit is contained in:
parent
2008ec409b
commit
7dd3b2fff7
1 changed files with 14 additions and 0 deletions
|
@ -1693,6 +1693,20 @@ gst_eglglessink_query (GstBaseSink * bsink, GstQuery * query)
|
|||
}
|
||||
break;
|
||||
}
|
||||
case GST_QUERY_DRAIN:
|
||||
{
|
||||
GST_OBJECT_LOCK (eglglessink);
|
||||
/* no need to do a copy here as the textures which are being rendered are
|
||||
* in eglglessink->egl_context->texture[i] and they are not part of a pool.
|
||||
* See comment in gst_egl_image_buffer_pool_acquire_buffer to know what is
|
||||
* this last_buffer ref is about */
|
||||
if (eglglessink->pool)
|
||||
gst_egl_image_buffer_pool_replace_last_buffer (GST_EGL_IMAGE_BUFFER_POOL
|
||||
(eglglessink->pool), NULL);
|
||||
GST_OBJECT_UNLOCK (eglglessink);
|
||||
|
||||
return TRUE;
|
||||
}
|
||||
#endif
|
||||
default:
|
||||
return GST_BASE_SINK_CLASS (gst_eglglessink_parent_class)->query (bsink,
|
||||
|
|
Loading…
Reference in a new issue