more slide headache
This commit is contained in:
parent
ba2c4f46c6
commit
f26307f11b
|
@ -18,7 +18,7 @@ struct DivChannelState {
|
||||||
int vibratoDepth, vibratoRate, vibratoPos, vibratoDir, vibratoFine;
|
int vibratoDepth, vibratoRate, vibratoPos, vibratoDir, vibratoFine;
|
||||||
int tremoloDepth, tremoloRate, tremoloPos;
|
int tremoloDepth, tremoloRate, tremoloPos;
|
||||||
unsigned char arp, arpStage, arpTicks;
|
unsigned char arp, arpStage, arpTicks;
|
||||||
bool doNote, legato, portaStop;
|
bool doNote, legato, portaStop, keyOn;
|
||||||
|
|
||||||
DivChannelState():
|
DivChannelState():
|
||||||
note(-1),
|
note(-1),
|
||||||
|
@ -40,7 +40,7 @@ struct DivChannelState {
|
||||||
arp(0),
|
arp(0),
|
||||||
arpStage(-1),
|
arpStage(-1),
|
||||||
arpTicks(1),
|
arpTicks(1),
|
||||||
doNote(false), legato(false), portaStop(false) {}
|
doNote(false), legato(false), portaStop(false), keyOn(false) {}
|
||||||
};
|
};
|
||||||
|
|
||||||
class DivEngine {
|
class DivEngine {
|
||||||
|
|
|
@ -163,6 +163,7 @@ void DivEngine::processRow(int i, bool afterDelay) {
|
||||||
// note
|
// note
|
||||||
if (pat->data[curRow][0]==100) {
|
if (pat->data[curRow][0]==100) {
|
||||||
chan[i].note=-1;
|
chan[i].note=-1;
|
||||||
|
chan[i].keyOn=false;
|
||||||
dispatchCmd(DivCommand(DIV_CMD_NOTE_OFF,i));
|
dispatchCmd(DivCommand(DIV_CMD_NOTE_OFF,i));
|
||||||
} else if (!(pat->data[curRow][0]==0 && pat->data[curRow][1]==0)) {
|
} else if (!(pat->data[curRow][0]==0 && pat->data[curRow][1]==0)) {
|
||||||
chan[i].note=pat->data[curRow][0]+pat->data[curRow][1]*12;
|
chan[i].note=pat->data[curRow][0]+pat->data[curRow][1]*12;
|
||||||
|
@ -303,6 +304,13 @@ void DivEngine::processRow(int i, bool afterDelay) {
|
||||||
dispatchCmd(DivCommand(DIV_CMD_NOTE_ON,i,chan[i].note,chan[i].volume>>8));
|
dispatchCmd(DivCommand(DIV_CMD_NOTE_ON,i,chan[i].note,chan[i].volume>>8));
|
||||||
}
|
}
|
||||||
chan[i].doNote=false;
|
chan[i].doNote=false;
|
||||||
|
if (!chan[i].keyOn) {
|
||||||
|
if (chan[i].portaStop) {
|
||||||
|
chan[i].portaNote=-1;
|
||||||
|
chan[i].portaSpeed=-1;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
chan[i].keyOn=true;
|
||||||
}
|
}
|
||||||
|
|
||||||
// post effects
|
// post effects
|
||||||
|
|
Loading…
Reference in a new issue