aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--al/source.cpp12
-rw-r--r--alc/effects/compressor.cpp2
-rw-r--r--alc/effects/reverb.cpp4
3 files changed, 9 insertions, 9 deletions
diff --git a/al/source.cpp b/al/source.cpp
index f8d5fbcd..53d2a705 100644
--- a/al/source.cpp
+++ b/al/source.cpp
@@ -1126,14 +1126,14 @@ bool SetSourceiv(ALsource *Source, ALCcontext *Context, SourceProp prop, const a
CHECKSIZE(values, 1);
CHECKVAL(values[0] == AL_FALSE || values[0] == AL_TRUE);
- Source->HeadRelative = static_cast<ALboolean>(values[0]);
+ Source->HeadRelative = values[0] != AL_FALSE;
return UpdateSourceProps(Source, Context);
case AL_LOOPING:
CHECKSIZE(values, 1);
CHECKVAL(values[0] == AL_FALSE || values[0] == AL_TRUE);
- Source->Looping = static_cast<ALboolean>(values[0]);
+ Source->Looping = values[0] != AL_FALSE;
if(IsPlayingOrPaused(Source))
{
if(ALvoice *voice{GetSourceVoice(Source, Context)})
@@ -1258,28 +1258,28 @@ bool SetSourceiv(ALsource *Source, ALCcontext *Context, SourceProp prop, const a
CHECKSIZE(values, 1);
CHECKVAL(values[0] == AL_FALSE || values[0] == AL_TRUE);
- Source->DryGainHFAuto = values[0];
+ Source->DryGainHFAuto = values[0] != AL_FALSE;
return UpdateSourceProps(Source, Context);
case AL_AUXILIARY_SEND_FILTER_GAIN_AUTO:
CHECKSIZE(values, 1);
CHECKVAL(values[0] == AL_FALSE || values[0] == AL_TRUE);
- Source->WetGainAuto = values[0];
+ Source->WetGainAuto = values[0] != AL_FALSE;
return UpdateSourceProps(Source, Context);
case AL_AUXILIARY_SEND_FILTER_GAINHF_AUTO:
CHECKSIZE(values, 1);
CHECKVAL(values[0] == AL_FALSE || values[0] == AL_TRUE);
- Source->WetGainHFAuto = values[0];
+ Source->WetGainHFAuto = values[0] != AL_FALSE;
return UpdateSourceProps(Source, Context);
case AL_DIRECT_CHANNELS_SOFT:
CHECKSIZE(values, 1);
CHECKVAL(values[0] == AL_FALSE || values[0] == AL_TRUE);
- Source->DirectChannels = values[0];
+ Source->DirectChannels = values[0] != AL_FALSE;
return UpdateSourceProps(Source, Context);
case AL_DISTANCE_MODEL:
diff --git a/alc/effects/compressor.cpp b/alc/effects/compressor.cpp
index 176e5a58..44ffaaef 100644
--- a/alc/effects/compressor.cpp
+++ b/alc/effects/compressor.cpp
@@ -161,7 +161,7 @@ void Compressor_setParami(EffectProps *props, ALCcontext *context, ALenum param,
case AL_COMPRESSOR_ONOFF:
if(!(val >= AL_COMPRESSOR_MIN_ONOFF && val <= AL_COMPRESSOR_MAX_ONOFF))
SETERR_RETURN(context, AL_INVALID_VALUE,, "Compressor state out of range");
- props->Compressor.OnOff = val;
+ props->Compressor.OnOff = val != AL_FALSE;
break;
default:
diff --git a/alc/effects/reverb.cpp b/alc/effects/reverb.cpp
index b5100a14..82a80198 100644
--- a/alc/effects/reverb.cpp
+++ b/alc/effects/reverb.cpp
@@ -1526,7 +1526,7 @@ void EAXReverb_setParami(EffectProps *props, ALCcontext *context, ALenum param,
case AL_EAXREVERB_DECAY_HFLIMIT:
if(!(val >= AL_EAXREVERB_MIN_DECAY_HFLIMIT && val <= AL_EAXREVERB_MAX_DECAY_HFLIMIT))
SETERR_RETURN(context, AL_INVALID_VALUE,, "EAX Reverb decay hflimit out of range");
- props->Reverb.DecayHFLimit = val;
+ props->Reverb.DecayHFLimit = val != AL_FALSE;
break;
default:
@@ -1863,7 +1863,7 @@ void StdReverb_setParami(EffectProps *props, ALCcontext *context, ALenum param,
case AL_REVERB_DECAY_HFLIMIT:
if(!(val >= AL_REVERB_MIN_DECAY_HFLIMIT && val <= AL_REVERB_MAX_DECAY_HFLIMIT))
SETERR_RETURN(context, AL_INVALID_VALUE,, "Reverb decay hflimit out of range");
- props->Reverb.DecayHFLimit = val;
+ props->Reverb.DecayHFLimit = val != AL_FALSE;
break;
default: