mirror of
https://github.com/tildearrow/furnace.git
synced 2024-11-16 01:35:07 +00:00
Lynx: sample improvements
This commit is contained in:
parent
1811a95e76
commit
b0c8cfc1f6
1 changed files with 9 additions and 3 deletions
|
@ -236,7 +236,8 @@ void DivPlatformLynx::tick(bool sysTick) {
|
||||||
off=(double)s->centerRate/8363.0;
|
off=(double)s->centerRate/8363.0;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
chan[i].sampleFreq=parent->calcFreq(chan[i].baseFreq,chan[i].pitch,false,2,chan[i].pitch2,off,1);
|
chan[i].sampleFreq=off*parent->calcFreq(chan[i].baseFreq,chan[i].pitch,false,2,chan[i].pitch2,1,1);
|
||||||
|
WRITE_FEEDBACK(i,0);
|
||||||
WRITE_LFSR(i,0);
|
WRITE_LFSR(i,0);
|
||||||
WRITE_OTHER(i,0);
|
WRITE_OTHER(i,0);
|
||||||
WRITE_CONTROL(i,0x18);
|
WRITE_CONTROL(i,0x18);
|
||||||
|
@ -258,11 +259,13 @@ void DivPlatformLynx::tick(bool sysTick) {
|
||||||
chan[i].freqChanged=false;
|
chan[i].freqChanged=false;
|
||||||
} else if (chan[i].std.duty.had) {
|
} else if (chan[i].std.duty.had) {
|
||||||
chan[i].duty = chan[i].std.duty.val;
|
chan[i].duty = chan[i].std.duty.val;
|
||||||
|
if (!chan[i].pcm) {
|
||||||
WRITE_FEEDBACK(i, chan[i].duty.feedback);
|
WRITE_FEEDBACK(i, chan[i].duty.feedback);
|
||||||
WRITE_CONTROL(i, (chan[i].fd.clockDivider|0x18|chan[i].duty.int_feedback7));
|
WRITE_CONTROL(i, (chan[i].fd.clockDivider|0x18|chan[i].duty.int_feedback7));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
int DivPlatformLynx::dispatch(DivCommand c) {
|
int DivPlatformLynx::dispatch(DivCommand c) {
|
||||||
switch (c.cmd) {
|
switch (c.cmd) {
|
||||||
|
@ -292,6 +295,9 @@ int DivPlatformLynx::dispatch(DivCommand c) {
|
||||||
chan[c.chan].active=false;
|
chan[c.chan].active=false;
|
||||||
WRITE_VOLUME(c.chan, 0);
|
WRITE_VOLUME(c.chan, 0);
|
||||||
chan[c.chan].macroInit(NULL);
|
chan[c.chan].macroInit(NULL);
|
||||||
|
if (chan[c.chan].pcm) {
|
||||||
|
chan[c.chan].pcm=false;
|
||||||
|
}
|
||||||
break;
|
break;
|
||||||
case DIV_CMD_LYNX_LFSR_LOAD:
|
case DIV_CMD_LYNX_LFSR_LOAD:
|
||||||
chan[c.chan].freqChanged=true;
|
chan[c.chan].freqChanged=true;
|
||||||
|
|
Loading…
Reference in a new issue