From 0dd9705d85cee519fbae9bca39ba6fa8baf1fa40 Mon Sep 17 00:00:00 2001 From: "Ronald S. Bultje" Date: Thu, 18 Dec 2003 09:31:50 +0000 Subject: [PATCH] Sorry Dave... Add mpegversion=1 to mp3 caps everywhere so that the autoplugger uses mad and not faad for mp3 decoding... Original commit message from CVS: Sorry Dave... Add mpegversion=1 to mp3 caps everywhere so that the autoplugger uses mad and not faad for mp3 decoding. This should fix mp3 playback. --- gst-libs/gst/riff/riff-media.c | 5 +++-- gst/asfdemux/gstasfdemux.c | 2 ++ gst/asfdemux/gstasfmux.c | 1 + gst/mpegstream/gstmpegdemux.c | 3 ++- 4 files changed, 8 insertions(+), 3 deletions(-) diff --git a/gst-libs/gst/riff/riff-media.c b/gst-libs/gst/riff/riff-media.c index ef617e1080..eeb6fd6312 100644 --- a/gst-libs/gst/riff/riff-media.c +++ b/gst-libs/gst/riff/riff-media.c @@ -233,8 +233,9 @@ gst_riff_create_audio_caps (guint16 codec_id, case GST_RIFF_WAVE_FORMAT_MPEGL12: /* mp1 or mp2 */ caps = GST_CAPS_NEW ("riff_audio_mp1l12", - "audio/mpeg", - "layer", GST_PROPS_INT (2)); + "audio/mpeg", + "mpegversion", GST_PROPS_INT (1), + "layer", GST_PROPS_INT (2)); break; case GST_RIFF_WAVE_FORMAT_PCM: /* PCM/wav */ { diff --git a/gst/asfdemux/gstasfdemux.c b/gst/asfdemux/gstasfdemux.c index 4fe057d52e..578c90bf05 100644 --- a/gst/asfdemux/gstasfdemux.c +++ b/gst/asfdemux/gstasfdemux.c @@ -1257,12 +1257,14 @@ gst_asf_demux_audio_caps (guint16 codec_id, case GST_RIFF_WAVE_FORMAT_MPEGL3: /* mp3 */ caps = GST_ASF_AUD_CAPS_NEW ("asf_demux_audio_src_mp3", "audio/mpeg", + "mpegversion", GST_PROPS_INT (1), "layer", GST_PROPS_INT (3)); break; case GST_RIFF_WAVE_FORMAT_MPEGL12: /* mp1 or mp2 */ caps = GST_ASF_AUD_CAPS_NEW ("asf_demux_audio_src_mp12", "audio/mpeg", + "mpegversion", GST_PROPS_INT (1), "layer", GST_PROPS_INT (2)); break; diff --git a/gst/asfdemux/gstasfmux.c b/gst/asfdemux/gstasfmux.c index 3b073e2b5a..b95d160c5d 100644 --- a/gst/asfdemux/gstasfmux.c +++ b/gst/asfdemux/gstasfmux.c @@ -183,6 +183,7 @@ GST_PAD_TEMPLATE_FACTORY (audio_sink_factory, GST_CAPS_NEW ( "asfmux_sink_audio_mpeg", "audio/mpeg", + "mpegversion", GST_PROPS_INT (1), "layer", GST_PROPS_INT_RANGE (1, 3), "rate", GST_PROPS_INT_RANGE (1000, 96000), "channels", GST_PROPS_INT_RANGE (1, 2) diff --git a/gst/mpegstream/gstmpegdemux.c b/gst/mpegstream/gstmpegdemux.c index 8042c29edb..9c24587204 100644 --- a/gst/mpegstream/gstmpegdemux.c +++ b/gst/mpegstream/gstmpegdemux.c @@ -67,7 +67,8 @@ GST_PAD_TEMPLATE_FACTORY (audio_factory, GST_CAPS_NEW ( "mpeg_demux_audio", "audio/mpeg", - NULL + "mpegversion", GST_PROPS_INT (1), + "layer", GST_PROPS_INT_RANGE (1, 2) ) );