diff options
Diffstat (limited to 'code/client')
-rw-r--r-- | code/client/snd_mix.c | 17 | ||||
-rw-r--r-- | code/client/snd_openal.c | 8 |
2 files changed, 12 insertions, 13 deletions
diff --git a/code/client/snd_mix.c b/code/client/snd_mix.c index 0538973..c1ad06b 100644 --- a/code/client/snd_mix.c +++ b/code/client/snd_mix.c @@ -467,15 +467,14 @@ static void S_PaintChannelFrom16_scalar( channel_t *ch, const sfx_t *sc, int cou } static void S_PaintChannelFrom16( channel_t *ch, const sfx_t *sc, int count, int sampleOffset, int bufferOffset ) { - #if idppc_altivec - extern cvar_t *com_altivec; - if (com_altivec->integer) { - // must be in a seperate function or G3 systems will crash. - S_PaintChannelFrom16_altivec( ch, sc, count, sampleOffset, bufferOffset ); - return; - } - #endif - S_PaintChannelFrom16_scalar( ch, sc, count, sampleOffset, bufferOffset ); +#if idppc_altivec + if (com_altivec->integer) { + // must be in a seperate function or G3 systems will crash. + S_PaintChannelFrom16_altivec( ch, sc, count, sampleOffset, bufferOffset ); + return; + } +#endif + S_PaintChannelFrom16_scalar( ch, sc, count, sampleOffset, bufferOffset ); } void S_PaintChannelFromWavelet( channel_t *ch, sfx_t *sc, int count, int sampleOffset, int bufferOffset ) { diff --git a/code/client/snd_openal.c b/code/client/snd_openal.c index 0b66223..5206bf3 100644 --- a/code/client/snd_openal.c +++ b/code/client/snd_openal.c @@ -847,8 +847,8 @@ static void S_AL_SrcLoop( alSrcPriority_t priority, sfxHandle_t sfx, // Set up the position and velocity VectorScale(entityList[entnum].origin, POSITION_SCALE, sorigin); - qalSourcefv(srcList[src].source, AL_POSITION, sorigin); - qalSourcefv(srcList[src].source, AL_VELOCITY, velocity); + qalSourcefv(srcList[src].source, AL_POSITION, (ALfloat *)sorigin); + qalSourcefv(srcList[src].source, AL_VELOCITY, (ALfloat *)velocity); // Flag it entityList[entnum].touched = qtrue; @@ -1067,7 +1067,7 @@ void S_AL_RawSamples(int samples, int rate, int width, int channels, const byte // Create a buffer, and stuff the data into it qalGenBuffers(1, &buffer); - qalBufferData(buffer, format, data, (samples * width * channels), rate); + qalBufferData(buffer, format, (ALvoid *)data, (samples * width * channels), rate); // Shove the data onto the streamSource qalSourceQueueBuffers(streamSource, 1, &buffer); @@ -1384,7 +1384,7 @@ void S_AL_Respatialize( int entityNum, const vec3_t origin, vec3_t axis[3], int // Set OpenAL listener paramaters VectorScale(origin, POSITION_SCALE, sorigin); - qalListenerfv(AL_POSITION, origin); + qalListenerfv(AL_POSITION, (ALfloat *)origin); qalListenerfv(AL_VELOCITY, velocity); qalListenerfv(AL_ORIENTATION, orientation); } |