[Audio Output] Fix for previous commit
This fixes the problem caused by the following commit:
050aaaf852
Signed-off-by: Christopher Snowhill <kode54@gmail.com>
lastfm
parent
adbf8aa7d1
commit
f04761ff42
|
@ -180,16 +180,17 @@ static OSStatus eqRenderCallback(void *inRefCon, AudioUnitRenderActionFlags *ioA
|
||||||
int samplesProcessed;
|
int samplesProcessed;
|
||||||
size_t totalDone = 0;
|
size_t totalDone = 0;
|
||||||
size_t inDone = 0;
|
size_t inDone = 0;
|
||||||
|
size_t visFrameCount = frameCount;
|
||||||
{
|
{
|
||||||
[currentPtsLock lock];
|
[currentPtsLock lock];
|
||||||
samplesProcessed = (int)r8bstate_resample(r8bvis, &visAudio[totalDone], frameCount, &inDone, &visTemp[0], 8192);
|
samplesProcessed = (int)r8bstate_resample(r8bvis, &visAudio[totalDone], visFrameCount, &inDone, &visTemp[0], 8192);
|
||||||
[currentPtsLock unlock];
|
[currentPtsLock unlock];
|
||||||
if(samplesProcessed) {
|
if(samplesProcessed) {
|
||||||
[visController postVisPCM:&visTemp[0] amount:samplesProcessed];
|
[visController postVisPCM:&visTemp[0] amount:samplesProcessed];
|
||||||
}
|
}
|
||||||
totalDone += inDone;
|
totalDone += inDone;
|
||||||
frameCount -= inDone;
|
visFrameCount -= inDone;
|
||||||
} while(samplesProcessed && frameCount);
|
} while(samplesProcessed && visFrameCount);
|
||||||
}
|
}
|
||||||
} else if(r8bvis) {
|
} else if(r8bvis) {
|
||||||
for(;;) {
|
for(;;) {
|
||||||
|
|
Loading…
Reference in New Issue