videofilter: shortcut transform_ip when not set

We can ask the base class to not call our transform_ip method when the subclass
didn't provide an in-place transform function.
This commit is contained in:
Wim Taymans 2012-04-14 11:26:28 +02:00
parent fd4c8d9252
commit 66615a8a6a

View file

@ -202,6 +202,8 @@ gst_video_filter_set_caps (GstBaseTransform * trans, GstCaps * incaps,
filter->out_info = out_info; filter->out_info = out_info;
if (fclass->transform_frame == NULL) if (fclass->transform_frame == NULL)
gst_base_transform_set_in_place (trans, TRUE); gst_base_transform_set_in_place (trans, TRUE);
if (fclass->transform_frame_ip == NULL)
GST_BASE_TRANSFORM_CLASS (fclass)->transform_ip_on_passthrough = FALSE;
} }
filter->negotiated = res; filter->negotiated = res;