Merge branch 'master' of https://github.com/tildearrow/furnace into opn_volbalance
This commit is contained in:
commit
a8e388091a
149 changed files with 2925 additions and 1761 deletions
|
|
@ -232,15 +232,15 @@ const char** DivPlatformYM2610::getRegisterSheet() {
|
|||
return regCheatSheetYM2610;
|
||||
}
|
||||
|
||||
void DivPlatformYM2610::acquire(short* bufL, short* bufR, size_t start, size_t len) {
|
||||
void DivPlatformYM2610::acquire(short** buf, size_t len) {
|
||||
if (useCombo) {
|
||||
acquire_combo(bufL,bufR,start,len);
|
||||
acquire_combo(buf,len);
|
||||
} else {
|
||||
acquire_ymfm(bufL,bufR,start,len);
|
||||
acquire_ymfm(buf,len);
|
||||
}
|
||||
}
|
||||
|
||||
void DivPlatformYM2610::acquire_combo(short* bufL, short* bufR, size_t start, size_t len) {
|
||||
void DivPlatformYM2610::acquire_combo(short** buf, size_t len) {
|
||||
static int os[2];
|
||||
static short ignored[2];
|
||||
|
||||
|
|
@ -255,7 +255,7 @@ void DivPlatformYM2610::acquire_combo(short* bufL, short* bufR, size_t start, si
|
|||
adpcmAChan[i]=aae->debug_channel(i);
|
||||
}
|
||||
|
||||
for (size_t h=start; h<start+len; h++) {
|
||||
for (size_t h=0; h<len; h++) {
|
||||
os[0]=0; os[1]=0;
|
||||
// Nuked part
|
||||
for (int i=0; i<24; i++) {
|
||||
|
|
@ -319,8 +319,8 @@ void DivPlatformYM2610::acquire_combo(short* bufL, short* bufR, size_t start, si
|
|||
if (os[1]<-32768) os[1]=-32768;
|
||||
if (os[1]>32767) os[1]=32767;
|
||||
|
||||
bufL[h]=os[0];
|
||||
bufR[h]=os[1];
|
||||
buf[0][h]=os[0];
|
||||
buf[1][h]=os[1];
|
||||
|
||||
|
||||
for (int i=0; i<psgChanOffs; i++) {
|
||||
|
|
@ -340,7 +340,7 @@ void DivPlatformYM2610::acquire_combo(short* bufL, short* bufR, size_t start, si
|
|||
}
|
||||
}
|
||||
|
||||
void DivPlatformYM2610::acquire_ymfm(short* bufL, short* bufR, size_t start, size_t len) {
|
||||
void DivPlatformYM2610::acquire_ymfm(short** buf, size_t len) {
|
||||
static int os[2];
|
||||
|
||||
ymfm::ym2610::fm_engine* fme=fm->debug_fm_engine();
|
||||
|
|
@ -359,7 +359,7 @@ void DivPlatformYM2610::acquire_ymfm(short* bufL, short* bufR, size_t start, siz
|
|||
adpcmAChan[i]=aae->debug_channel(i);
|
||||
}
|
||||
|
||||
for (size_t h=start; h<start+len; h++) {
|
||||
for (size_t h=0; h<len; h++) {
|
||||
os[0]=0; os[1]=0;
|
||||
if (!writes.empty()) {
|
||||
if (--delay<1 && !(fm->read(0)&0x80)) {
|
||||
|
|
@ -382,8 +382,8 @@ void DivPlatformYM2610::acquire_ymfm(short* bufL, short* bufR, size_t start, siz
|
|||
if (os[1]<-32768) os[1]=-32768;
|
||||
if (os[1]>32767) os[1]=32767;
|
||||
|
||||
bufL[h]=os[0];
|
||||
bufR[h]=os[1];
|
||||
buf[0][h]=os[0];
|
||||
buf[1][h]=os[1];
|
||||
|
||||
for (int i=0; i<psgChanOffs; i++) {
|
||||
oscBuf[i]->data[oscBuf[i]->needle++]=(fmChan[i]->debug_output(0)+fmChan[i]->debug_output(1));
|
||||
|
|
@ -652,6 +652,17 @@ void DivPlatformYM2610::tick(bool sysTick) {
|
|||
}
|
||||
chan[adpcmBChanOffs].freqChanged=true;
|
||||
}
|
||||
|
||||
if (chan[adpcmBChanOffs].std.pitch.had) {
|
||||
if (chan[adpcmBChanOffs].std.pitch.mode) {
|
||||
chan[adpcmBChanOffs].pitch2+=chan[adpcmBChanOffs].std.pitch.val;
|
||||
CLAMP_VAR(chan[adpcmBChanOffs].pitch2,-65535,65535);
|
||||
} else {
|
||||
chan[adpcmBChanOffs].pitch2=chan[adpcmBChanOffs].std.pitch.val;
|
||||
}
|
||||
chan[adpcmBChanOffs].freqChanged=true;
|
||||
}
|
||||
|
||||
if (chan[adpcmBChanOffs].std.panL.had) {
|
||||
if (chan[adpcmBChanOffs].pan!=(chan[adpcmBChanOffs].std.panL.val&3)) {
|
||||
chan[adpcmBChanOffs].pan=chan[adpcmBChanOffs].std.panL.val&3;
|
||||
|
|
@ -1374,8 +1385,8 @@ void DivPlatformYM2610::reset() {
|
|||
immWrite(0x1b,0xff); // B
|
||||
}
|
||||
|
||||
bool DivPlatformYM2610::isStereo() {
|
||||
return true;
|
||||
int DivPlatformYM2610::getOutputCount() {
|
||||
return 2;
|
||||
}
|
||||
|
||||
bool DivPlatformYM2610::keyOffAffectsArp(int ch) {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue