ALSA backend can handle int32 and float32 data directly.
authorRyan C. Gordon <icculus@icculus.org>
Thu, 31 Aug 2006 21:28:21 +0000
changeset 19950ca6ba107642
parent 1994 6abc7e6f9817
child 1996 f25d771fe6f2
ALSA backend can handle int32 and float32 data directly.
src/audio/alsa/SDL_alsa_audio.c
     1.1 --- a/src/audio/alsa/SDL_alsa_audio.c	Thu Aug 31 21:00:10 2006 +0000
     1.2 +++ b/src/audio/alsa/SDL_alsa_audio.c	Thu Aug 31 21:28:21 2006 +0000
     1.3 @@ -542,6 +542,18 @@
     1.4          case AUDIO_U16MSB:
     1.5              format = SND_PCM_FORMAT_U16_BE;
     1.6              break;
     1.7 +        case AUDIO_S32LSB:
     1.8 +            format = SND_PCM_FORMAT_U32_LE;
     1.9 +            break;
    1.10 +        case AUDIO_S32MSB:
    1.11 +            format = SND_PCM_FORMAT_U32_BE;
    1.12 +            break;
    1.13 +        case AUDIO_F32LSB:
    1.14 +            format = SND_PCM_FORMAT_FLOAT_LE;
    1.15 +            break;
    1.16 +        case AUDIO_F32MSB:
    1.17 +            format = SND_PCM_FORMAT_FLOAT_BE;
    1.18 +            break;
    1.19          default:
    1.20              format = 0;
    1.21              break;