Skip to content

Commit

Permalink
Fix enums in ADSR
Browse files Browse the repository at this point in the history
  • Loading branch information
AndrewBelt committed May 29, 2018
1 parent 45f6f7e commit 5b9345f
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/ADSR.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -41,10 +41,10 @@ struct ADSR : Module {


void ADSR::step() {
float attack = clamp(params[ATTACK_INPUT].value + inputs[ATTACK_INPUT].value / 10.0f, 0.0f, 1.0f);
float attack = clamp(params[ATTACK_PARAM].value + inputs[ATTACK_INPUT].value / 10.0f, 0.0f, 1.0f);
float decay = clamp(params[DECAY_PARAM].value + inputs[DECAY_INPUT].value / 10.0f, 0.0f, 1.0f);
float sustain = clamp(params[SUSTAIN_PARAM].value + inputs[SUSTAIN_INPUT].value / 10.0f, 0.0f, 1.0f);
float release = clamp(params[RELEASE_PARAM].value + inputs[RELEASE_PARAM].value / 10.0f, 0.0f, 1.0f);
float release = clamp(params[RELEASE_PARAM].value + inputs[RELEASE_INPUT].value / 10.0f, 0.0f, 1.0f);

// Gate and trigger
bool gated = inputs[GATE_INPUT].value >= 1.0f;
Expand Down

0 comments on commit 5b9345f

Please sign in to comment.