aboutsummaryrefslogtreecommitdiffstats
path: root/Alc/ALu.c
diff options
context:
space:
mode:
authorChris Robinson <[email protected]>2011-08-16 18:33:10 -0700
committerChris Robinson <[email protected]>2011-08-16 18:33:10 -0700
commit04dad28228a694e681d722826615245466a3aa16 (patch)
tree54860fb951339bb4af88df4c620383323427a5fd /Alc/ALu.c
parenta96f8177387818d3ef69778e3f78a9ed251326c1 (diff)
Use mini/maxi/clampi and minu/maxu/clampu to replace min/max calls
Diffstat (limited to 'Alc/ALu.c')
-rw-r--r--Alc/ALu.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/Alc/ALu.c b/Alc/ALu.c
index aaf79fe3..a2352de9 100644
--- a/Alc/ALu.c
+++ b/Alc/ALu.c
@@ -152,7 +152,7 @@ ALvoid CalcNonAttnSourceParams(ALsource *ALSource, const ALCcontext *ALContext)
ALSource->SampleSize;
maxstep -= ResamplerPadding[ALSource->Resampler] +
ResamplerPrePadding[ALSource->Resampler] + 1;
- maxstep = min(maxstep, INT_MAX>>FRACTIONBITS);
+ maxstep = mini(maxstep, INT_MAX>>FRACTIONBITS);
Pitch = Pitch * ALBuffer->Frequency / Frequency;
if(Pitch > (ALfloat)maxstep)
@@ -677,7 +677,7 @@ ALvoid CalcSourceParams(ALsource *ALSource, const ALCcontext *ALContext)
ALSource->SampleSize;
maxstep -= ResamplerPadding[ALSource->Resampler] +
ResamplerPrePadding[ALSource->Resampler] + 1;
- maxstep = min(maxstep, INT_MAX>>FRACTIONBITS);
+ maxstep = mini(maxstep, INT_MAX>>FRACTIONBITS);
Pitch = Pitch * ALBuffer->Frequency / Frequency;
if(Pitch > (ALfloat)maxstep)
@@ -975,7 +975,7 @@ ALvoid aluMixData(ALCdevice *device, ALvoid *buffer, ALsizei size)
while(size > 0)
{
/* Setup variables */
- SamplesToDo = min(size, BUFFERSIZE);
+ SamplesToDo = minu(size, BUFFERSIZE);
/* Clear mixing buffer */
memset(device->DryBuffer, 0, SamplesToDo*MAXCHANNELS*sizeof(ALfloat));