Avoid accessing EAX-only reverb properties for non-EAX updates

This commit is contained in:
Chris Robinson 2011-09-11 08:50:48 -07:00
parent d51b93f869
commit 8028770901

View File

@ -1113,7 +1113,8 @@ static ALvoid ReverbUpdate(ALeffectState *effect, ALCcontext *Context, const ALe
}
// Calculate the master low-pass filter (from the master effect HF gain).
cw = CalcI3DL2HFreq(Slot->effect.Reverb.HFReference, frequency);
if(isEAX) cw = CalcI3DL2HFreq(Slot->effect.Reverb.HFReference, frequency);
else cw = CalcI3DL2HFreq(LOWPASSFREQCUTOFF, frequency);
// This is done with 2 chained 1-pole filters, so no need to square g.
State->LpFilter.coeff = lpCoeffCalc(Slot->effect.Reverb.GainHF, cw);