add a little visual to channel names

This commit is contained in:
tildearrow 2022-02-10 03:15:39 -05:00
parent 73dd66b439
commit d1e166a34e
5 changed files with 24 additions and 2 deletions

View file

@ -4911,6 +4911,9 @@ void DivEngine::play() {
} else {
stepPlay=0;
}
for (int i=0; i<DIV_MAX_CHANS; i++) {
keyHit[i]=false;
}
isBusy.unlock();
}
@ -4921,6 +4924,9 @@ void DivEngine::playToRow(int row) {
sPreview.pos=0;
freelance=false;
playSub(false,row);
for (int i=0; i<DIV_MAX_CHANS; i++) {
keyHit[i]=false;
}
isBusy.unlock();
}
@ -4929,6 +4935,9 @@ void DivEngine::stepOne(int row) {
if (!isPlaying()) {
freelance=false;
playSub(false,row);
for (int i=0; i<DIV_MAX_CHANS; i++) {
keyHit[i]=false;
}
}
stepPlay=2;
ticks=1;
@ -6322,6 +6331,7 @@ bool DivEngine::init() {
for (int i=0; i<DIV_MAX_CHANS; i++) {
isMuted[i]=0;
keyHit[i]=false;
}
oscBuf[0]=new float[32768];

View file

@ -223,6 +223,7 @@ class DivEngine {
DivSystem sysOfChan[DIV_MAX_CHANS];
int dispatchOfChan[DIV_MAX_CHANS];
int dispatchChanOfChan[DIV_MAX_CHANS];
bool keyHit[DIV_MAX_CHANS];
float* oscBuf[2];
float oscSize;

View file

@ -731,6 +731,7 @@ void DivEngine::processRow(int i, bool afterDelay) {
chan[i].portaNote=chan[i].note;
} else if (!chan[i].noteOnInhibit) {
dispatchCmd(DivCommand(DIV_CMD_NOTE_ON,i,chan[i].note,chan[i].volume>>8));
keyHit[i]=true;
}
}
chan[i].doNote=false;
@ -871,6 +872,7 @@ bool DivEngine::nextTick(bool noAccum) {
if (note.on) {
dispatchCmd(DivCommand(DIV_CMD_INSTRUMENT,note.channel,note.ins,1));
dispatchCmd(DivCommand(DIV_CMD_NOTE_ON,note.channel,note.note));
keyHit[note.channel]=true;
chan[note.channel].noteOnInhibit=true;
} else {
dispatchCmd(DivCommand(DIV_CMD_NOTE_OFF,note.channel));
@ -901,6 +903,7 @@ bool DivEngine::nextTick(bool noAccum) {
if (--chan[i].retrigTick<0) {
chan[i].retrigTick=chan[i].retrigSpeed-1;
dispatchCmd(DivCommand(DIV_CMD_NOTE_ON,i,DIV_NOTE_NULL));
keyHit[i]=true;
}
}
if (chan[i].volSpeed!=0) {