diff options
author | Chris Robinson <[email protected]> | 2019-03-22 16:04:13 -0700 |
---|---|---|
committer | Chris Robinson <[email protected]> | 2019-03-22 16:04:13 -0700 |
commit | ea8b02dead8f7b35f0fe2c2fa3b0aa0f8d258828 (patch) | |
tree | a25ab46a278d491291e6bb65739df75e380adfb7 /Alc/effects/distortion.cpp | |
parent | e7e585f65c43e2ccd2ae71c36c4940f4b2efa80a (diff) |
Pass ALeffectProps directly to the get/setParam* methods
Diffstat (limited to 'Alc/effects/distortion.cpp')
-rw-r--r-- | Alc/effects/distortion.cpp | 22 |
1 files changed, 10 insertions, 12 deletions
diff --git a/Alc/effects/distortion.cpp b/Alc/effects/distortion.cpp index 5c0d5cec..1bc3b626 100644 --- a/Alc/effects/distortion.cpp +++ b/Alc/effects/distortion.cpp @@ -164,13 +164,12 @@ void DistortionState::process(ALsizei samplesToDo, const ALfloat (*RESTRICT samp } -void Distortion_setParami(ALeffect *UNUSED(effect), ALCcontext *context, ALenum param, ALint UNUSED(val)) +void Distortion_setParami(ALeffectProps*, ALCcontext *context, ALenum param, ALint) { alSetError(context, AL_INVALID_ENUM, "Invalid distortion integer property 0x%04x", param); } -void Distortion_setParamiv(ALeffect *UNUSED(effect), ALCcontext *context, ALenum param, const ALint *UNUSED(vals)) +void Distortion_setParamiv(ALeffectProps*, ALCcontext *context, ALenum param, const ALint*) { alSetError(context, AL_INVALID_ENUM, "Invalid distortion integer-vector property 0x%04x", param); } -void Distortion_setParamf(ALeffect *effect, ALCcontext *context, ALenum param, ALfloat val) +void Distortion_setParamf(ALeffectProps *props, ALCcontext *context, ALenum param, ALfloat val) { - ALeffectProps *props = &effect->Props; switch(param) { case AL_DISTORTION_EDGE: @@ -208,16 +207,15 @@ void Distortion_setParamf(ALeffect *effect, ALCcontext *context, ALenum param, A param); } } -void Distortion_setParamfv(ALeffect *effect, ALCcontext *context, ALenum param, const ALfloat *vals) -{ Distortion_setParamf(effect, context, param, vals[0]); } +void Distortion_setParamfv(ALeffectProps *props, ALCcontext *context, ALenum param, const ALfloat *vals) +{ Distortion_setParamf(props, context, param, vals[0]); } -void Distortion_getParami(const ALeffect *UNUSED(effect), ALCcontext *context, ALenum param, ALint *UNUSED(val)) +void Distortion_getParami(const ALeffectProps*, ALCcontext *context, ALenum param, ALint*) { alSetError(context, AL_INVALID_ENUM, "Invalid distortion integer property 0x%04x", param); } -void Distortion_getParamiv(const ALeffect *UNUSED(effect), ALCcontext *context, ALenum param, ALint *UNUSED(vals)) +void Distortion_getParamiv(const ALeffectProps*, ALCcontext *context, ALenum param, ALint*) { alSetError(context, AL_INVALID_ENUM, "Invalid distortion integer-vector property 0x%04x", param); } -void Distortion_getParamf(const ALeffect *effect, ALCcontext *context, ALenum param, ALfloat *val) +void Distortion_getParamf(const ALeffectProps *props, ALCcontext *context, ALenum param, ALfloat *val) { - const ALeffectProps *props = &effect->Props; switch(param) { case AL_DISTORTION_EDGE: @@ -245,8 +243,8 @@ void Distortion_getParamf(const ALeffect *effect, ALCcontext *context, ALenum pa param); } } -void Distortion_getParamfv(const ALeffect *effect, ALCcontext *context, ALenum param, ALfloat *vals) -{ Distortion_getParamf(effect, context, param, vals); } +void Distortion_getParamfv(const ALeffectProps *props, ALCcontext *context, ALenum param, ALfloat *vals) +{ Distortion_getParamf(props, context, param, vals); } DEFINE_ALEFFECT_VTABLE(Distortion); |