glcolorconvert: Apply GstVideoOverlayCompositionMeta buffer to converted buffer

Since glcolorconvert creates a new GstBuffer,
without the GstVideoOverlayCompositionMeta data,
it needs to be copied to not be dropped.

https://bugzilla.gnome.org/show_bug.cgi?id=745107
This commit is contained in:
Lubosz Sarnecki 2015-04-20 13:17:09 +02:00 committed by Tim-Philipp Müller
parent 076d0517c8
commit 26e6be8fad

View file

@ -1667,6 +1667,7 @@ _do_convert (GstGLContext * context, GstGLColorConvert * convert)
GstVideoInfo *in_info = &convert->in_info; GstVideoInfo *in_info = &convert->in_info;
gboolean res = TRUE; gboolean res = TRUE;
gint views, v; gint views, v;
GstVideoOverlayCompositionMeta *composition_meta;
convert->outbuf = NULL; convert->outbuf = NULL;
@ -1705,6 +1706,14 @@ _do_convert (GstGLContext * context, GstGLColorConvert * convert)
gst_gl_sync_meta_set_sync_point (sync_meta, convert->context); gst_gl_sync_meta_set_sync_point (sync_meta, convert->context);
} }
composition_meta =
gst_buffer_get_video_overlay_composition_meta (convert->inbuf);
if (composition_meta) {
GST_DEBUG ("found video overlay composition meta, appliying on output.");
gst_buffer_add_video_overlay_composition_meta
(convert->outbuf, composition_meta->overlay);
}
convert->priv->result = res; convert->priv->result = res;
return; return;
} }