ffmpegenc: properly handle caps event

... which comes down to unconditionally eating incoming caps event,
since that one could never correctly describe the setup for downstream
elements.
This commit is contained in:
Mark Nauwelaerts 2011-06-30 09:20:11 +02:00
parent bd5e3a51dd
commit e937db0f92

View file

@ -1158,11 +1158,12 @@ gst_ffmpegenc_event_sink (GstPad * pad, GstEvent * event)
}
case GST_EVENT_CAPS:{
GstCaps *caps;
gboolean ret;
gst_event_parse_caps (event, &caps);
if (!gst_ffmpegenc_setcaps (ffmpegenc, caps)) {
gst_event_unref (event);
return FALSE;
}
ret = gst_ffmpegenc_setcaps (ffmpegenc, caps);
gst_event_unref (event);
return ret;
break;
}
default: