Implement Phase Reset Timer macro for Sound Unit (#573)
* Implement Phase Reset Timer Macro * And make the macro actually work * Delete ex4Max variable
This commit is contained in:
parent
623c0efbba
commit
8011e7adc7
2 changed files with 8 additions and 0 deletions
|
|
@ -187,6 +187,13 @@ void DivPlatformSoundUnit::tick(bool sysTick) {
|
|||
chan[i].control=chan[i].std.ex3.val&15;
|
||||
writeControl(i);
|
||||
}
|
||||
if (chan[i].std.ex4.had) {
|
||||
chan[i].syncTimer=chan[i].std.ex4.val&65535;
|
||||
chan[i].timerSync=(chan[i].syncTimer>0);
|
||||
chWrite(i,0x1e,chan[i].syncTimer&0xff);
|
||||
chWrite(i,0x1f,chan[i].syncTimer>>8);
|
||||
writeControlUpper(i);
|
||||
}
|
||||
if (chan[i].freqChanged || chan[i].keyOn || chan[i].keyOff) {
|
||||
//DivInstrument* ins=parent->getIns(chan[i].ins,DIV_INS_SU);
|
||||
chan[i].freq=parent->calcFreq(chan[i].baseFreq,chan[i].pitch,false,2,chan[i].pitch2,chipClock,CHIP_FREQBASE);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue