diff options
author | RĂ©mi Verschelde <rverschelde@gmail.com> | 2018-01-31 17:24:50 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2018-01-31 17:24:50 +0100 |
commit | 1ad0b463da436208136a8e7c55ba45857bf492a3 (patch) | |
tree | da88bcc521ebfdb4a7a1c122ed24a440cf0e2ff7 | |
parent | da187c875d4e1a94b3f6ccb0ca30924a67800383 (diff) | |
parent | 5a26e0786c518f9056e9eec4e1594e39815084d4 (diff) |
Merge pull request #16200 from Noshyaar/master
AudioEffectReverb: max predelay_feedback to 0.98
-rw-r--r-- | servers/audio/effects/audio_effect_reverb.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/servers/audio/effects/audio_effect_reverb.cpp b/servers/audio/effects/audio_effect_reverb.cpp index 204b11746c..162c0a1445 100644 --- a/servers/audio/effects/audio_effect_reverb.cpp +++ b/servers/audio/effects/audio_effect_reverb.cpp @@ -96,7 +96,7 @@ void AudioEffectReverb::set_predelay_msec(float p_msec) { void AudioEffectReverb::set_predelay_feedback(float p_feedback) { - predelay_fb = p_feedback; + predelay_fb = CLAMP(p_feedback, 0, 0.98); } void AudioEffectReverb::set_room_size(float p_size) { @@ -185,7 +185,7 @@ void AudioEffectReverb::_bind_methods() { ADD_GROUP("Predelay", "predelay_"); ADD_PROPERTY(PropertyInfo(Variant::REAL, "predelay_msec", PROPERTY_HINT_RANGE, "20,500,1"), "set_predelay_msec", "get_predelay_msec"); - ADD_PROPERTY(PropertyInfo(Variant::REAL, "predelay_feedback", PROPERTY_HINT_RANGE, "0,1,0.01"), "set_predelay_feedback", "get_predelay_feedback"); + ADD_PROPERTY(PropertyInfo(Variant::REAL, "predelay_feedback", PROPERTY_HINT_RANGE, "0,0.98,0.01"), "set_predelay_feedback", "get_predelay_feedback"); ADD_GROUP("", ""); ADD_PROPERTY(PropertyInfo(Variant::REAL, "room_size", PROPERTY_HINT_RANGE, "0,1,0.01"), "set_room_size", "get_room_size"); ADD_PROPERTY(PropertyInfo(Variant::REAL, "damping", PROPERTY_HINT_RANGE, "0,1,0.01"), "set_damping", "get_damping"); |