Fixed channel swizzling for ALSA target with 6-channel output.
Fixes Bugzilla #942.
1.1 --- a/src/audio/alsa/SDL_alsa_audio.c Fri Feb 05 19:20:49 2010 +0000
1.2 +++ b/src/audio/alsa/SDL_alsa_audio.c Fri Feb 12 16:59:34 2010 +0000
1.3 @@ -264,9 +264,8 @@
1.4 */
1.5 #define SWIZ6(T) \
1.6 T *ptr = (T *) mixbuf; \
1.7 - const Uint32 count = (this->spec.samples / 6); \
1.8 Uint32 i; \
1.9 - for (i = 0; i < count; i++, ptr += 6) { \
1.10 + for (i = 0; i < this->spec.samples; i++, ptr += 6) { \
1.11 T tmp; \
1.12 tmp = ptr[2]; ptr[2] = ptr[4]; ptr[4] = tmp; \
1.13 tmp = ptr[3]; ptr[3] = ptr[5]; ptr[5] = tmp; \