Browse Source

Fixed a bug in the ADSR class when transitioning to the decay stage

tags/2021-05-28
ed 6 years ago
parent
commit
5d3854732b
1 changed files with 5 additions and 1 deletions
  1. +5
    -1
      modules/juce_audio_basics/utilities/juce_ADSR.h

+ 5
- 1
modules/juce_audio_basics/utilities/juce_ADSR.h View File

@@ -135,7 +135,11 @@ public:
if (envelopeVal >= 1.0f)
{
envelopeVal = 1.0f;
currentState = State::decay;
if (decayRate > 0.0f)
currentState = State::decay;
else
currentState = State::sustain;
}
}
else if (currentState == State::decay)


Loading…
Cancel
Save