Fix wrong arguments to wxClip in AudioIO...

... the bug began at commit 494ab4eafe

Now, a sine wave with the gain turned up really sounds like a square wave
This commit is contained in:
Paul Licameli 2019-06-29 23:36:31 -04:00
parent 22ce129f8d
commit 0b7a4d07b9
1 changed files with 1 additions and 1 deletions

View File

@ -3741,7 +3741,7 @@ void AudioIoCallback::AddToOutputChannel( unsigned int chan,
// Limit values to -1.0..+1.0
void ClampBuffer(float * pBuffer, unsigned long len){
for(unsigned i = 0; i < len; i++)
pBuffer[i] = wxClip( -1.0f, pBuffer[i], 1.0f);
pBuffer[i] = wxClip( pBuffer[i], -1.0f, 1.0f);
};