diff options
author | 2009-11-10 00:45:19 +0000 | |
---|---|---|
committer | 2009-11-10 00:45:19 +0000 | |
commit | 3c2afd67861769e82034b2ca276d2670964fc09c (patch) | |
tree | 9fa61272171332b4352fb34bde7ced4999244444 /libmpcodecs/ae_pcm.c | |
parent | 1d30062395914bbc9eef1299c70018df9f333628 (diff) |
Add support for 8 channel audio.
Where 8 channel support is non-trivial (e.g. ao_dsound), at least ensure we
fail gracefully.
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@29868 b3059339-0415-0410-9bf9-f77b7e298cf2
Diffstat (limited to 'libmpcodecs/ae_pcm.c')
-rw-r--r-- | libmpcodecs/ae_pcm.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/libmpcodecs/ae_pcm.c b/libmpcodecs/ae_pcm.c index c3aaeee724..c0ebf18283 100644 --- a/libmpcodecs/ae_pcm.c +++ b/libmpcodecs/ae_pcm.c @@ -39,7 +39,8 @@ static int bind_pcm(audio_encoder_t *encoder, muxer_stream_t *mux_a) static int encode_pcm(audio_encoder_t *encoder, uint8_t *dest, void *src, int nsamples, int max_size) { max_size = FFMIN(nsamples, max_size); - if (encoder->params.channels == 6 || encoder->params.channels == 5) { + if (encoder->params.channels == 5 || encoder->params.channels == 6 || + encoder->params.channels == 8) { max_size -= max_size % (encoder->params.channels * 2); reorder_channel_copy_nch(src, AF_CHANNEL_LAYOUT_MPLAYER_DEFAULT, dest, AF_CHANNEL_LAYOUT_WAVEEX_DEFAULT, |