diff options
author | Kostya Shishkov <kostya.shishkov@gmail.com> | 2008-11-19 14:57:48 +0000 |
---|---|---|
committer | Kostya Shishkov <kostya.shishkov@gmail.com> | 2008-11-19 14:57:48 +0000 |
commit | eeee48b26b6cfc2e8595071a806a8641a99cd71f (patch) | |
tree | 05202af64fe8daf76adcc768d9ba92ee47ebe9c6 | |
parent | ff16d6e49557ce7bb939eb6b7e88de221608ffdc (diff) | |
download | ffmpeg-eeee48b26b6cfc2e8595071a806a8641a99cd71f.tar.gz |
Add channel layout to several audio decoders I maintain
Originally committed as revision 15884 to svn://svn.ffmpeg.org/ffmpeg/trunk
-rw-r--r-- | libavcodec/apedec.c | 1 | ||||
-rw-r--r-- | libavcodec/mpc7.c | 1 | ||||
-rw-r--r-- | libavcodec/mpc8.c | 1 | ||||
-rw-r--r-- | libavcodec/smacker.c | 1 | ||||
-rw-r--r-- | libavcodec/wavpack.c | 1 |
5 files changed, 5 insertions, 0 deletions
diff --git a/libavcodec/apedec.c b/libavcodec/apedec.c index 82d567f4cf..8746724133 100644 --- a/libavcodec/apedec.c +++ b/libavcodec/apedec.c @@ -199,6 +199,7 @@ static av_cold int ape_decode_init(AVCodecContext * avctx) dsputil_init(&s->dsp, avctx); avctx->sample_fmt = SAMPLE_FMT_S16; + avctx->channel_layout = (avctx->channels==2) ? CH_LAYOUT_STEREO : CH_LAYOUT_MONO; return 0; } diff --git a/libavcodec/mpc7.c b/libavcodec/mpc7.c index 565b8589ec..2db417280c 100644 --- a/libavcodec/mpc7.c +++ b/libavcodec/mpc7.c @@ -109,6 +109,7 @@ static av_cold int mpc7_decode_init(AVCodecContext * avctx) } vlc_initialized = 1; avctx->sample_fmt = SAMPLE_FMT_S16; + avctx->channel_layout = (avctx->channels==2) ? CH_LAYOUT_STEREO : CH_LAYOUT_MONO; return 0; } diff --git a/libavcodec/mpc8.c b/libavcodec/mpc8.c index 0d4f128912..c47e74dde2 100644 --- a/libavcodec/mpc8.c +++ b/libavcodec/mpc8.c @@ -178,6 +178,7 @@ static av_cold int mpc8_decode_init(AVCodecContext * avctx) } vlc_initialized = 1; avctx->sample_fmt = SAMPLE_FMT_S16; + avctx->channel_layout = (avctx->channels==2) ? CH_LAYOUT_STEREO : CH_LAYOUT_MONO; return 0; } diff --git a/libavcodec/smacker.c b/libavcodec/smacker.c index 1690518b6b..5de3769e3c 100644 --- a/libavcodec/smacker.c +++ b/libavcodec/smacker.c @@ -559,6 +559,7 @@ static av_cold int decode_end(AVCodecContext *avctx) static av_cold int smka_decode_init(AVCodecContext *avctx) { avctx->sample_fmt = SAMPLE_FMT_S16; + avctx->channel_layout = (avctx->channels==2) ? CH_LAYOUT_STEREO : CH_LAYOUT_MONO; return 0; } diff --git a/libavcodec/wavpack.c b/libavcodec/wavpack.c index e8703b38dc..b89723e2f2 100644 --- a/libavcodec/wavpack.c +++ b/libavcodec/wavpack.c @@ -361,6 +361,7 @@ static av_cold int wavpack_decode_init(AVCodecContext *avctx) s->avctx = avctx; s->stereo = (avctx->channels == 2); avctx->sample_fmt = SAMPLE_FMT_S16; + avctx->channel_layout = (avctx->channels==2) ? CH_LAYOUT_STEREO : CH_LAYOUT_MONO; return 0; } |