videoscale: Don't copy scaled metas
authorJames Cowgill <james.cowgill@blaize.com>
Wed, 2 Feb 2022 15:28:21 +0000 (15:28 +0000)
committerGStreamer Marge Bot <gitlab-merge-bot@gstreamer-foundation.org>
Fri, 22 Apr 2022 13:00:01 +0000 (13:00 +0000)
Returning TRUE from the `transform_meta` function tells
GstBaseTransform to copy the meta into the new buffer. If videoscale
has already transformed a meta by scaling it, it should always return
FALSE to avoid duplicating the meta.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/1630>

subprojects/gst-plugins-base/gst/videoconvertscale/gstvideoconvertscale.c

index c418125..577a03c 100644 (file)
@@ -726,7 +726,7 @@ gst_video_convert_scale_transform_meta (GstBaseTransform * trans,
         { &videofilter->in_info, &videofilter->out_info };
 
     if (info->transform_func)
-      return info->transform_func (outbuf, meta, inbuf, _scale_quark, &trans);
+      info->transform_func (outbuf, meta, inbuf, _scale_quark, &trans);
     return FALSE;
   }