diff options
Diffstat (limited to 'OpenAL32/alFilter.c')
-rw-r--r-- | OpenAL32/alFilter.c | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/OpenAL32/alFilter.c b/OpenAL32/alFilter.c index c740e4ff..174d4d8d 100644 --- a/OpenAL32/alFilter.c +++ b/OpenAL32/alFilter.c @@ -231,14 +231,16 @@ AL_API ALvoid AL_APIENTRY alFilterf(ALuint filter, ALenum param, ALfloat flValue switch(param) { case AL_LOWPASS_GAIN: - if(flValue >= 0.0f && flValue <= 1.0f) + if(flValue >= AL_LOWPASS_MIN_GAIN && + flValue <= AL_LOWPASS_MAX_GAIN) ALFilter->Gain = flValue; else alSetError(Context, AL_INVALID_VALUE); break; case AL_LOWPASS_GAINHF: - if(flValue >= 0.0f && flValue <= 1.0f) + if(flValue >= AL_LOWPASS_MIN_GAINHF && + flValue <= AL_LOWPASS_MAX_GAINHF) ALFilter->GainHF = flValue; else alSetError(Context, AL_INVALID_VALUE); @@ -446,6 +448,6 @@ static void InitFilterParams(ALfilter *filter, ALenum type) { filter->type = type; - filter->Gain = 1.0; - filter->GainHF = 1.0; + filter->Gain = AL_LOWPASS_DEFAULT_GAIN; + filter->GainHF = AL_LOWPASS_DEFAULT_GAINHF; } |