v4l2transform: copy metdata

This commit is contained in:
Víctor Manuel Jáquez Leal 2014-03-15 16:53:54 +00:00 committed by Nicolas Dufresne
parent b781156625
commit 4f7ee5c130

View file

@ -407,6 +407,7 @@ gst_v4l2_transform_prepare_output_buffer (GstBaseTransform * trans,
GstV4l2Transform *self = GST_V4L2_TRANSFORM (trans);
GstBufferPool *pool = GST_BUFFER_POOL (self->v4l2output->pool);
GstFlowReturn ret = GST_FLOW_OK;
GstBaseTransformClass *bclass = GST_BASE_TRANSFORM_CLASS (parent_class);
if (gst_base_transform_is_passthrough (trans)) {
GST_DEBUG_OBJECT (self, "Passthrough, no need to do anything");
@ -441,6 +442,13 @@ gst_v4l2_transform_prepare_output_buffer (GstBaseTransform * trans,
*outbuf = NULL;
}
if (bclass->copy_metadata)
if (!bclass->copy_metadata (trans, inbuf, *outbuf)) {
/* something failed, post a warning */
GST_ELEMENT_WARNING (self, STREAM, NOT_IMPLEMENTED,
("could not copy metadata"), (NULL));
}
beach:
return ret;