From: Jan Schmidt Date: Mon, 5 Oct 2009 18:49:06 +0000 (+0100) Subject: schroenc: When the source pad isn't linked, use the pad template X-Git-Tag: 1.19.3~507^2~17977 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=f80e4a71814511af70478dd7fa012ea5c871e84e;p=platform%2Fupstream%2Fgstreamer.git schroenc: When the source pad isn't linked, use the pad template For negotiation, use the source pad pad template when it doesn't have a peer. --- diff --git a/ext/schroedinger/gstschroenc.c b/ext/schroedinger/gstschroenc.c index 70312eedc4..e69ac62292 100644 --- a/ext/schroedinger/gstschroenc.c +++ b/ext/schroedinger/gstschroenc.c @@ -263,6 +263,11 @@ gst_schro_enc_set_format (GstBaseVideoEncoder * base_video_encoder, caps = gst_pad_get_allowed_caps (GST_BASE_VIDEO_CODEC_SRC_PAD (base_video_encoder)); + if (caps == NULL) { + caps = + gst_caps_copy (gst_pad_get_pad_template_caps + (GST_BASE_VIDEO_CODEC_SRC_PAD (base_video_encoder))); + } if (gst_caps_is_empty (caps)) { gst_caps_unref (caps);