mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-11-24 02:31:03 +00:00
deinterlace: support filter in getcaps
This commit is contained in:
parent
a4458f5f74
commit
9d4579b38a
1 changed files with 10 additions and 1 deletions
|
@ -2115,7 +2115,6 @@ gst_fraction_double (gint * n_out, gint * d_out, gboolean half)
|
|||
return TRUE;
|
||||
}
|
||||
|
||||
/* FIXME: use filter in getcaps */
|
||||
static GstCaps *
|
||||
gst_deinterlace_getcaps (GstDeinterlace * self, GstPad * pad, GstCaps * filter)
|
||||
{
|
||||
|
@ -2246,6 +2245,16 @@ gst_deinterlace_getcaps (GstDeinterlace * self, GstPad * pad, GstCaps * filter)
|
|||
}
|
||||
}
|
||||
|
||||
if (filter) {
|
||||
GstCaps *filter_caps;
|
||||
|
||||
GST_LOG_OBJECT (pad, "intersecting with %" GST_PTR_FORMAT, filter);
|
||||
filter_caps = gst_caps_intersect_full (filter, ret,
|
||||
GST_CAPS_INTERSECT_FIRST);
|
||||
gst_caps_unref (ret);
|
||||
ret = filter_caps;
|
||||
}
|
||||
|
||||
GST_DEBUG_OBJECT (pad, "Returning caps %" GST_PTR_FORMAT, ret);
|
||||
|
||||
return ret;
|
||||
|
|
Loading…
Reference in a new issue