OPN: fix LFO effect not working in ext ch mode

This commit is contained in:
tildearrow 2022-03-30 00:09:53 -05:00
parent 7e34c7746e
commit af6bbf9493
3 changed files with 13 additions and 0 deletions

View File

@ -159,6 +159,11 @@ int DivPlatformGenesisExt::dispatch(DivCommand c) {
opChan[ch].freqChanged=true;
break;
}
case DIV_CMD_FM_LFO: {
lfoValue=(c.value&7)|((c.value>>4)<<3);
rWrite(0x22,lfoValue);
break;
}
case DIV_CMD_FM_MULT: { // TODO
unsigned short baseAddr=chanOffs[2]|opOffs[orderedOps[c.value]];
DivInstrumentFM::Operator& op=chan[2].state.op[orderedOps[c.value]];

View File

@ -147,6 +147,10 @@ int DivPlatformYM2610BExt::dispatch(DivCommand c) {
opChan[ch].freqChanged=true;
break;
}
case DIV_CMD_FM_LFO: {
rWrite(0x22,(c.value&7)|((c.value>>4)<<3));
break;
}
case DIV_CMD_FM_MULT: { // TODO
unsigned short baseAddr=chanOffs[2]|opOffs[orderedOps[c.value]];
DivInstrument* ins=parent->getIns(opChan[ch].ins);

View File

@ -147,6 +147,10 @@ int DivPlatformYM2610Ext::dispatch(DivCommand c) {
opChan[ch].freqChanged=true;
break;
}
case DIV_CMD_FM_LFO: {
rWrite(0x22,(c.value&7)|((c.value>>4)<<3));
break;
}
case DIV_CMD_FM_MULT: { // TODO
unsigned short baseAddr=chanOffs[1]|opOffs[orderedOps[c.value]];
DivInstrument* ins=parent->getIns(opChan[ch].ins);