Mercurial > sdl-ios-xcode
diff src/audio/SDL_mixer.c @ 574:64fe373be3dc
Cth converted the MMX audio mixing routines to VC++ syntax
author | Sam Lantinga <slouken@libsdl.org> |
---|---|
date | Mon, 20 Jan 2003 16:01:20 +0000 |
parents | a9e38f3b8e4d |
children | 873c2598f969 |
line wrap: on
line diff
--- a/src/audio/SDL_mixer.c Mon Jan 20 02:34:04 2003 +0000 +++ b/src/audio/SDL_mixer.c Mon Jan 20 16:01:20 2003 +0000 @@ -36,6 +36,7 @@ #include "SDL_timer.h" #include "SDL_sysaudio.h" #include "SDL_mixer_MMX.h" +#include "SDL_mixer_MMX_VC.h" /* Function to check the CPU flags */ #define MMX_CPU 0x800000 @@ -147,7 +148,6 @@ break; case AUDIO_S8: { - #if defined(i386) && defined(__GNUC__) && defined(USE_ASMBLIT) if (CPU_Flags() & MMX_CPU) { @@ -155,6 +155,13 @@ } else #endif +#if defined(USE_ASM_MIXER_VC) + if (SDL_IsMMX_VC()) + { + SDL_MixAudio_MMX_S8_VC((char*)dst,(char*)src,(unsigned int)len,(int)volume); + } + else +#endif { Sint8 *dst8, *src8; Sint8 src_sample; @@ -190,6 +197,12 @@ SDL_MixAudio_MMX_S16((char*)dst,(char*)src,(unsigned int)len,(int)volume); } else +#elif defined(USE_ASM_MIXER_VC) + if (SDL_IsMMX_VC()) + { + SDL_MixAudio_MMX_S16_VC((char*)dst,(char*)src,(unsigned int)len,(int)volume); + } + else #endif { Sint16 src1, src2; @@ -251,3 +264,4 @@ return; } } +