Keep arpeggiated also in the release phase

This commit is contained in:
Takeshi Yokemura
2021-08-16 12:43:58 +09:00
parent ef6d94654c
commit 88dea8e989
2 changed files with 66 additions and 17 deletions

View File

@ -47,6 +47,8 @@ struct TonalVoice : public BaseVoice // The base for Pulse and Triangle
int currentArpeggioFrame = 0;
double arpeggioFrameTimer = 0;
double arpeggioFrameLength = 0; // Unit: seconds. Set non-zero value to enable arpeggio
int retireBuffer[10];
int currentNumRetireBuffer = 0;
void startNote (int midiNoteNumber, float velocity,
SynthesiserSound*, int currentPitchWheelPosition) override;
@ -74,4 +76,5 @@ struct TonalVoice : public BaseVoice // The base for Pulse and Triangle
bool isArpeggioEnabled() {
return arpeggioFrameLength > 0;
}
bool isInReleasePhase();
};