[0.11] gst-ffmpeg: ffmpeg: Channel layouts are now set for DTS and (E) AC3 by libav

Sebastian Dröge slomo at kemper.freedesktop.org
Tue Jan 10 01:38:23 PST 2012


Module: gst-ffmpeg
Branch: 0.11
Commit: 09efbe103fa743742d55e9ad13bed6142bb8d684
URL:    http://cgit.freedesktop.org/gstreamer/gst-ffmpeg/commit/?id=09efbe103fa743742d55e9ad13bed6142bb8d684

Author: Sebastian Dröge <sebastian.droege at collabora.co.uk>
Date:   Tue Jan 10 10:08:05 2012 +0100

ffmpeg: Channel layouts are now set for DTS and (E)AC3 by libav

---

 ext/ffmpeg/gstffmpegcodecmap.c |   20 --------------------
 1 files changed, 0 insertions(+), 20 deletions(-)

diff --git a/ext/ffmpeg/gstffmpegcodecmap.c b/ext/ffmpeg/gstffmpegcodecmap.c
index 0f6fe9e..2be5892 100644
--- a/ext/ffmpeg/gstffmpegcodecmap.c
+++ b/ext/ffmpeg/gstffmpegcodecmap.c
@@ -328,26 +328,6 @@ gst_ff_aud_caps_new (AVCodecContext * context, enum CodecID codec_id,
 
     gst_audio_info_init (&info);
 
-
-    if (channel_layout == 0) {
-      const guint64 default_channel_set[] = {
-        0, 0, CH_LAYOUT_SURROUND, CH_LAYOUT_QUAD, CH_LAYOUT_5POINT0,
-        CH_LAYOUT_5POINT1, 0, CH_LAYOUT_7POINT1
-      };
-
-      switch (codec_id) {
-        case CODEC_ID_EAC3:
-        case CODEC_ID_AC3:
-        case CODEC_ID_DTS:
-          if (context->channels > 0
-              && context->channels < G_N_ELEMENTS (default_channel_set))
-            channel_layout = default_channel_set[context->channels - 1];
-          break;
-        default:
-          break;
-      }
-    }
-
     caps = gst_caps_new_simple (mimetype,
         "rate", G_TYPE_INT, context->sample_rate,
         "channels", G_TYPE_INT, context->channels, NULL);



More information about the gstreamer-commits mailing list