From 1c0596c233525e9a582269faa4ccb017e5938a28 Mon Sep 17 00:00:00 2001 From: Chris Robinson Date: Fri, 31 Oct 2014 16:55:19 -0700 Subject: Check the absolute gain value for silence Future B-Format support will be using negative gains, which still need to be applied. --- Alc/mixer_c.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'Alc/mixer_c.c') diff --git a/Alc/mixer_c.c b/Alc/mixer_c.c index f3a229e5..0fdcc087 100644 --- a/Alc/mixer_c.c +++ b/Alc/mixer_c.c @@ -118,7 +118,7 @@ void Mix_C(const ALfloat *data, ALuint OutChans, ALfloat (*restrict OutBuffer)[B Gains[c].Current = gain; } - if(!(gain > GAIN_SILENCE_THRESHOLD)) + if(!(fabsf(gain) > GAIN_SILENCE_THRESHOLD)) continue; for(;pos < BufferSize;pos++) OutBuffer[c][OutPos+pos] += data[pos]*gain; -- cgit v1.2.3