Merge branch 'upstream/1.16' into tizen_gst_1.16.2
[platform/upstream/gst-plugins-base.git] / gst / videoconvert / gstvideoconvert.c
index 18fea35..eab0e3b 100644 (file)
@@ -389,7 +389,13 @@ static gboolean
 gst_video_convert_filter_meta (GstBaseTransform * trans, GstQuery * query,
     GType api, const GstStructure * params)
 {
-  /* propose all metadata upstream */
+  /* This element cannot passthrough the crop meta, because it would convert the
+   * wrong sub-region of the image, and worst, our output image may not be large
+   * enough for the crop to be applied later */
+  if (api == GST_VIDEO_CROP_META_API_TYPE)
+    return FALSE;
+
+  /* propose all other metadata upstream */
   return TRUE;
 }
 
@@ -525,6 +531,7 @@ gst_video_convert_finalize (GObject * obj)
   if (space->convert) {
     gst_video_converter_free (space->convert);
   }
+
   G_OBJECT_CLASS (parent_class)->finalize (obj);
 }
 
@@ -737,6 +744,7 @@ gst_video_convert_transform_frame (GstVideoFilter * filter,
       "doing colorspace conversion from %s -> to %s",
       GST_VIDEO_INFO_NAME (&filter->in_info),
       GST_VIDEO_INFO_NAME (&filter->out_info));
+
   gst_video_converter_frame (space->convert, in_frame, out_frame);
 
   return GST_FLOW_OK;