summaryrefslogtreecommitdiffstats
path: root/gst/real/gstrealaudiodec.c
diff options
context:
space:
mode:
authorTim-Philipp Müller <tim@centricular.net>2007-02-26 10:32:30 +0000
committerTim-Philipp Müller <tim@centricular.net>2007-02-26 10:32:30 +0000
commit13f01565870862c80e9485ebaf4a9e95ff2cea58 (patch)
tree20507c3fb65fe71d9cd4f2a0075632be1fd2fcdf /gst/real/gstrealaudiodec.c
parentbc8d60a4e34445d4fe95e50654a737ad91d52772 (diff)
downloadgst-plugins-bad-13f01565870862c80e9485ebaf4a9e95ff2cea58.tar.gz
gst-plugins-bad-13f01565870862c80e9485ebaf4a9e95ff2cea58.tar.bz2
gst-plugins-bad-13f01565870862c80e9485ebaf4a9e95ff2cea58.zip
gst/real/: Use gst_pad_use_fixed_caps() on source pads, to avoid negotiation errors in certain situations (e.g. dec !...
Original commit message from CVS: * gst/real/gstrealaudiodec.c: (gst_real_audio_dec_init): * gst/real/gstrealvideodec.c: (gst_real_video_dec_init): Use gst_pad_use_fixed_caps() on source pads, to avoid negotiation errors in certain situations (e.g. dec ! cs ! ximagesink and the imagesink window is resized); also, some minor clean-ups.
Diffstat (limited to 'gst/real/gstrealaudiodec.c')
-rw-r--r--gst/real/gstrealaudiodec.c14
1 files changed, 8 insertions, 6 deletions
diff --git a/gst/real/gstrealaudiodec.c b/gst/real/gstrealaudiodec.c
index f2bbdc37..9e167578 100644
--- a/gst/real/gstrealaudiodec.c
+++ b/gst/real/gstrealaudiodec.c
@@ -319,13 +319,15 @@ could_not_set_caps:
static void
gst_real_audio_dec_init (GstRealAudioDec * dec, GstRealAudioDecClass * klass)
{
- dec->snk =
- gst_pad_new_from_template (gst_static_pad_template_get (&snk_t), "sink");
- gst_pad_set_setcaps_function (dec->snk, gst_real_audio_dec_setcaps);
- gst_pad_set_chain_function (dec->snk, gst_real_audio_dec_chain);
+ dec->snk = gst_pad_new_from_static_template (&snk_t, "sink");
+ gst_pad_set_setcaps_function (dec->snk,
+ GST_DEBUG_FUNCPTR (gst_real_audio_dec_setcaps));
+ gst_pad_set_chain_function (dec->snk,
+ GST_DEBUG_FUNCPTR (gst_real_audio_dec_chain));
gst_element_add_pad (GST_ELEMENT (dec), dec->snk);
- dec->src =
- gst_pad_new_from_template (gst_static_pad_template_get (&src_t), "src");
+
+ dec->src = gst_pad_new_from_static_template (&src_t, "src");
+ gst_pad_use_fixed_caps (dec->src);
gst_element_add_pad (GST_ELEMENT (dec), dec->src);
}