The max step is no longer dependent on the channel count

This commit is contained in:
Chris Robinson
2012-10-10 03:40:01 -07:00
parent a4f21aaa64
commit 1b7f01b7cc
+2 -2
View File
@@ -207,7 +207,7 @@ ALvoid CalcNonAttnSourceParams(ALsource *ALSource, const ALCcontext *ALContext)
ALbuffer *ALBuffer;
if((ALBuffer=BufferListItem->buffer) != NULL)
{
ALsizei maxstep = BUFFERSIZE / ALSource->NumChannels;
ALsizei maxstep = BUFFERSIZE;
maxstep -= ResamplerPadding[Resampler] +
ResamplerPrePadding[Resampler] + 1;
maxstep = mini(maxstep, INT_MAX>>FRACTIONBITS);
@@ -701,7 +701,7 @@ ALvoid CalcSourceParams(ALsource *ALSource, const ALCcontext *ALContext)
{
/* Calculate fixed-point stepping value, based on the pitch, buffer
* frequency, and output frequency. */
ALsizei maxstep = BUFFERSIZE / ALSource->NumChannels;
ALsizei maxstep = BUFFERSIZE;
maxstep -= ResamplerPadding[Resampler] +
ResamplerPrePadding[Resampler] + 1;
maxstep = mini(maxstep, INT_MAX>>FRACTIONBITS);