We can also accept caps with missing fields.
{
gst_base_parse_set_min_frame_size (GST_BASE_PARSE (diracparse), 13);
gst_base_parse_set_pts_interpolation (GST_BASE_PARSE (diracparse), FALSE);
+ GST_PAD_SET_ACCEPT_INTERSECT (GST_BASE_PARSE_SINK_PAD (diracparse));
}
void
res = gst_caps_intersect_full (peercaps, templ, GST_CAPS_INTERSECT_FIRST);
gst_caps_unref (peercaps);
- res = gst_caps_make_writable (res);
-
- /* Append the template caps because we still want to accept
- * caps without any fields in the case upstream does not
- * know anything.
- */
- gst_caps_append (res, templ);
+ gst_caps_unref (templ);
} else {
res = templ;
}
static void
gst_h263_parse_init (GstH263Parse * h263parse)
{
+ GST_PAD_SET_ACCEPT_INTERSECT (GST_BASE_PARSE_SINK_PAD (h263parse));
}
static gboolean
res = gst_caps_intersect_full (peercaps, templ, GST_CAPS_INTERSECT_FIRST);
gst_caps_unref (peercaps);
- res = gst_caps_make_writable (res);
-
- /* Append the template caps because we still want to accept
- * caps without any fields in the case upstream does not
- * know anything.
- */
- gst_caps_append (res, templ);
+ gst_caps_unref (templ);
} else {
res = templ;
}
{
h264parse->frame_out = gst_adapter_new ();
gst_base_parse_set_pts_interpolation (GST_BASE_PARSE (h264parse), FALSE);
+ GST_PAD_SET_ACCEPT_INTERSECT (GST_BASE_PARSE_SINK_PAD (h264parse));
}
res = gst_caps_intersect_full (peercaps, templ, GST_CAPS_INTERSECT_FIRST);
gst_caps_unref (peercaps);
- res = gst_caps_make_writable (res);
-
- /* Append the template caps because we still want to accept
- * caps without any fields in the case upstream does not
- * know anything.
- */
- gst_caps_append (res, templ);
+ gst_caps_unref (templ);
} else {
res = templ;
}
{
h265parse->frame_out = gst_adapter_new ();
gst_base_parse_set_pts_interpolation (GST_BASE_PARSE (h265parse), FALSE);
+ GST_PAD_SET_ACCEPT_INTERSECT (GST_BASE_PARSE_SINK_PAD (h265parse));
}
res = gst_caps_intersect_full (peercaps, templ, GST_CAPS_INTERSECT_FIRST);
gst_caps_unref (peercaps);
- res = gst_caps_make_writable (res);
-
- /* Append the template caps because we still want to accept
- * caps without any fields in the case upstream does not
- * know anything.
- */
- gst_caps_append (res, templ);
+ gst_caps_unref (templ);
} else {
res = templ;
}
parse->last_report = GST_CLOCK_TIME_NONE;
gst_base_parse_set_pts_interpolation (GST_BASE_PARSE (parse), FALSE);
+ GST_PAD_SET_ACCEPT_INTERSECT (GST_BASE_PARSE_SINK_PAD (parse));
}
static void
res = gst_caps_intersect_full (peercaps, templ, GST_CAPS_INTERSECT_FIRST);
gst_caps_unref (peercaps);
- res = gst_caps_make_writable (res);
-
- /* Append the template caps because we still want to accept
- * caps without any fields in the case upstream does not
- * know anything.
- */
- gst_caps_append (res, templ);
+ gst_caps_unref (templ);
} else {
res = templ;
}
parse->config_flags = FLAG_NONE;
gst_base_parse_set_pts_interpolation (GST_BASE_PARSE (parse), FALSE);
+ GST_PAD_SET_ACCEPT_INTERSECT (GST_BASE_PARSE_SINK_PAD (parse));
}
static void
res = gst_caps_intersect_full (peercaps, templ, GST_CAPS_INTERSECT_FIRST);
gst_caps_unref (peercaps);
- res = gst_caps_make_writable (res);
-
- /* Append the template caps because we still want to accept
- * caps without any fields in the case upstream does not
- * know anything.
- */
- gst_caps_append (res, templ);
+ gst_caps_unref (templ);
} else {
res = templ;
}
gst_base_parse_set_has_timing_info (GST_BASE_PARSE (vc1parse), FALSE);
gst_vc1_parse_reset (vc1parse);
+ GST_PAD_SET_ACCEPT_INTERSECT (GST_BASE_PARSE_SINK_PAD (vc1parse));
}
static void