prepare for relative pitch macro
This commit is contained in:
parent
66f5b2117f
commit
77b4e57c58
|
@ -27,7 +27,7 @@
|
||||||
|
|
||||||
class DivPlatformAmiga: public DivDispatch {
|
class DivPlatformAmiga: public DivDispatch {
|
||||||
struct Channel {
|
struct Channel {
|
||||||
int freq, baseFreq, pitch;
|
int freq, baseFreq, pitch, pitch2;
|
||||||
unsigned int audLoc;
|
unsigned int audLoc;
|
||||||
unsigned short audLen;
|
unsigned short audLen;
|
||||||
unsigned int audPos;
|
unsigned int audPos;
|
||||||
|
@ -45,6 +45,7 @@ class DivPlatformAmiga: public DivDispatch {
|
||||||
freq(0),
|
freq(0),
|
||||||
baseFreq(0),
|
baseFreq(0),
|
||||||
pitch(0),
|
pitch(0),
|
||||||
|
pitch2(0),
|
||||||
audLoc(0),
|
audLoc(0),
|
||||||
audLen(0),
|
audLen(0),
|
||||||
audPos(0),
|
audPos(0),
|
||||||
|
|
|
@ -36,7 +36,7 @@ class DivPlatformArcade: public DivDispatch {
|
||||||
DivInstrumentFM state;
|
DivInstrumentFM state;
|
||||||
DivMacroInt std;
|
DivMacroInt std;
|
||||||
unsigned char freqH, freqL;
|
unsigned char freqH, freqL;
|
||||||
int freq, baseFreq, pitch, note;
|
int freq, baseFreq, pitch, pitch2, note;
|
||||||
int ins;
|
int ins;
|
||||||
signed char konCycles;
|
signed char konCycles;
|
||||||
bool active, insChanged, freqChanged, keyOn, keyOff, inPorta, portaPause, furnacePCM, hardReset;
|
bool active, insChanged, freqChanged, keyOn, keyOff, inPorta, portaPause, furnacePCM, hardReset;
|
||||||
|
@ -48,6 +48,7 @@ class DivPlatformArcade: public DivDispatch {
|
||||||
freq(0),
|
freq(0),
|
||||||
baseFreq(0),
|
baseFreq(0),
|
||||||
pitch(0),
|
pitch(0),
|
||||||
|
pitch2(0),
|
||||||
note(0),
|
note(0),
|
||||||
ins(-1),
|
ins(-1),
|
||||||
active(false),
|
active(false),
|
||||||
|
|
|
@ -32,7 +32,7 @@ class DivPlatformAY8910: public DivDispatch {
|
||||||
inline unsigned char regRemap(unsigned char reg) { return intellivision?AY8914RegRemap[reg&0x0f]:reg&0x0f; }
|
inline unsigned char regRemap(unsigned char reg) { return intellivision?AY8914RegRemap[reg&0x0f]:reg&0x0f; }
|
||||||
struct Channel {
|
struct Channel {
|
||||||
unsigned char freqH, freqL;
|
unsigned char freqH, freqL;
|
||||||
int freq, baseFreq, note, pitch;
|
int freq, baseFreq, note, pitch, pitch2;
|
||||||
int ins;
|
int ins;
|
||||||
unsigned char psgMode, autoEnvNum, autoEnvDen;
|
unsigned char psgMode, autoEnvNum, autoEnvDen;
|
||||||
signed char konCycles;
|
signed char konCycles;
|
||||||
|
@ -40,7 +40,7 @@ class DivPlatformAY8910: public DivDispatch {
|
||||||
int vol, outVol;
|
int vol, outVol;
|
||||||
unsigned char pan;
|
unsigned char pan;
|
||||||
DivMacroInt std;
|
DivMacroInt std;
|
||||||
Channel(): freqH(0), freqL(0), freq(0), baseFreq(0), note(0), pitch(0), ins(-1), psgMode(1), autoEnvNum(0), autoEnvDen(0), active(false), insChanged(true), freqChanged(false), keyOn(false), keyOff(false), portaPause(false), inPorta(false), vol(0), outVol(15), pan(3) {}
|
Channel(): freqH(0), freqL(0), freq(0), baseFreq(0), note(0), pitch(0), pitch2(0), ins(-1), psgMode(1), autoEnvNum(0), autoEnvDen(0), active(false), insChanged(true), freqChanged(false), keyOn(false), keyOff(false), portaPause(false), inPorta(false), vol(0), outVol(15), pan(3) {}
|
||||||
};
|
};
|
||||||
Channel chan[3];
|
Channel chan[3];
|
||||||
bool isMuted[3];
|
bool isMuted[3];
|
||||||
|
|
|
@ -28,7 +28,7 @@ class DivPlatformAY8930: public DivDispatch {
|
||||||
protected:
|
protected:
|
||||||
struct Channel {
|
struct Channel {
|
||||||
unsigned char freqH, freqL;
|
unsigned char freqH, freqL;
|
||||||
int freq, baseFreq, note, pitch;
|
int freq, baseFreq, note, pitch, pitch2;
|
||||||
int ins;
|
int ins;
|
||||||
unsigned char psgMode, autoEnvNum, autoEnvDen, duty;
|
unsigned char psgMode, autoEnvNum, autoEnvDen, duty;
|
||||||
signed char konCycles;
|
signed char konCycles;
|
||||||
|
@ -36,7 +36,7 @@ class DivPlatformAY8930: public DivDispatch {
|
||||||
int vol, outVol;
|
int vol, outVol;
|
||||||
unsigned char pan;
|
unsigned char pan;
|
||||||
DivMacroInt std;
|
DivMacroInt std;
|
||||||
Channel(): freqH(0), freqL(0), freq(0), baseFreq(0), note(0), pitch(0), ins(-1), psgMode(1), autoEnvNum(0), autoEnvDen(0), duty(4), active(false), insChanged(true), freqChanged(false), keyOn(false), keyOff(false), portaPause(false), inPorta(false), vol(0), outVol(31), pan(3) {}
|
Channel(): freqH(0), freqL(0), freq(0), baseFreq(0), note(0), pitch(0), pitch2(0), ins(-1), psgMode(1), autoEnvNum(0), autoEnvDen(0), duty(4), active(false), insChanged(true), freqChanged(false), keyOn(false), keyOff(false), portaPause(false), inPorta(false), vol(0), outVol(31), pan(3) {}
|
||||||
};
|
};
|
||||||
Channel chan[3];
|
Channel chan[3];
|
||||||
bool isMuted[3];
|
bool isMuted[3];
|
||||||
|
|
|
@ -28,7 +28,7 @@
|
||||||
|
|
||||||
class DivPlatformBubSysWSG: public DivDispatch {
|
class DivPlatformBubSysWSG: public DivDispatch {
|
||||||
struct Channel {
|
struct Channel {
|
||||||
int freq, baseFreq, pitch, note, ins;
|
int freq, baseFreq, pitch, pitch2, note, ins;
|
||||||
bool active, insChanged, freqChanged, keyOn, keyOff, inPorta;
|
bool active, insChanged, freqChanged, keyOn, keyOff, inPorta;
|
||||||
signed char vol, outVol, wave;
|
signed char vol, outVol, wave;
|
||||||
signed char waveROM[32] = {0}; // 4 bit PROM per channel on bubble system
|
signed char waveROM[32] = {0}; // 4 bit PROM per channel on bubble system
|
||||||
|
@ -38,6 +38,7 @@ class DivPlatformBubSysWSG: public DivDispatch {
|
||||||
freq(0),
|
freq(0),
|
||||||
baseFreq(0),
|
baseFreq(0),
|
||||||
pitch(0),
|
pitch(0),
|
||||||
|
pitch2(0),
|
||||||
note(0),
|
note(0),
|
||||||
ins(-1),
|
ins(-1),
|
||||||
active(false),
|
active(false),
|
||||||
|
|
|
@ -26,7 +26,7 @@
|
||||||
|
|
||||||
class DivPlatformC64: public DivDispatch {
|
class DivPlatformC64: public DivDispatch {
|
||||||
struct Channel {
|
struct Channel {
|
||||||
int freq, baseFreq, pitch, prevFreq, testWhen, note, ins;
|
int freq, baseFreq, pitch, pitch2, prevFreq, testWhen, note, ins;
|
||||||
unsigned char sweep, wave, attack, decay, sustain, release;
|
unsigned char sweep, wave, attack, decay, sustain, release;
|
||||||
short duty;
|
short duty;
|
||||||
bool active, insChanged, freqChanged, sweepChanged, keyOn, keyOff, inPorta, filter;
|
bool active, insChanged, freqChanged, sweepChanged, keyOn, keyOff, inPorta, filter;
|
||||||
|
@ -37,6 +37,7 @@ class DivPlatformC64: public DivDispatch {
|
||||||
freq(0),
|
freq(0),
|
||||||
baseFreq(0),
|
baseFreq(0),
|
||||||
pitch(0),
|
pitch(0),
|
||||||
|
pitch2(0),
|
||||||
prevFreq(65535),
|
prevFreq(65535),
|
||||||
testWhen(0),
|
testWhen(0),
|
||||||
note(0),
|
note(0),
|
||||||
|
|
|
@ -26,7 +26,7 @@
|
||||||
|
|
||||||
class DivPlatformFDS: public DivDispatch {
|
class DivPlatformFDS: public DivDispatch {
|
||||||
struct Channel {
|
struct Channel {
|
||||||
int freq, baseFreq, pitch, prevFreq, note, modFreq, ins;
|
int freq, baseFreq, pitch, pitch2, prevFreq, note, modFreq, ins;
|
||||||
unsigned char duty, sweep, modDepth, modPos;
|
unsigned char duty, sweep, modDepth, modPos;
|
||||||
bool active, insChanged, freqChanged, sweepChanged, keyOn, keyOff, inPorta, modOn;
|
bool active, insChanged, freqChanged, sweepChanged, keyOn, keyOff, inPorta, modOn;
|
||||||
signed char vol, outVol, wave;
|
signed char vol, outVol, wave;
|
||||||
|
@ -36,6 +36,7 @@ class DivPlatformFDS: public DivDispatch {
|
||||||
freq(0),
|
freq(0),
|
||||||
baseFreq(0),
|
baseFreq(0),
|
||||||
pitch(0),
|
pitch(0),
|
||||||
|
pitch2(0),
|
||||||
prevFreq(65535),
|
prevFreq(65535),
|
||||||
note(0),
|
note(0),
|
||||||
modFreq(0),
|
modFreq(0),
|
||||||
|
|
|
@ -27,7 +27,7 @@
|
||||||
|
|
||||||
class DivPlatformGB: public DivDispatch {
|
class DivPlatformGB: public DivDispatch {
|
||||||
struct Channel {
|
struct Channel {
|
||||||
int freq, baseFreq, pitch, note, ins;
|
int freq, baseFreq, pitch, pitch2, note, ins;
|
||||||
unsigned char duty, sweep;
|
unsigned char duty, sweep;
|
||||||
bool active, insChanged, freqChanged, sweepChanged, keyOn, keyOff, inPorta;
|
bool active, insChanged, freqChanged, sweepChanged, keyOn, keyOff, inPorta;
|
||||||
signed char vol, outVol, wave;
|
signed char vol, outVol, wave;
|
||||||
|
@ -36,6 +36,7 @@ class DivPlatformGB: public DivDispatch {
|
||||||
freq(0),
|
freq(0),
|
||||||
baseFreq(0),
|
baseFreq(0),
|
||||||
pitch(0),
|
pitch(0),
|
||||||
|
pitch2(0),
|
||||||
note(0),
|
note(0),
|
||||||
ins(-1),
|
ins(-1),
|
||||||
duty(0),
|
duty(0),
|
||||||
|
|
|
@ -36,7 +36,7 @@ class DivPlatformGenesis: public DivDispatch {
|
||||||
DivInstrumentFM state;
|
DivInstrumentFM state;
|
||||||
DivMacroInt std;
|
DivMacroInt std;
|
||||||
unsigned char freqH, freqL;
|
unsigned char freqH, freqL;
|
||||||
int freq, baseFreq, pitch, portaPauseFreq, note;
|
int freq, baseFreq, pitch, pitch2, portaPauseFreq, note;
|
||||||
int ins;
|
int ins;
|
||||||
bool active, insChanged, freqChanged, keyOn, keyOff, portaPause, furnaceDac, inPorta, hardReset;
|
bool active, insChanged, freqChanged, keyOn, keyOff, portaPause, furnaceDac, inPorta, hardReset;
|
||||||
int vol, outVol;
|
int vol, outVol;
|
||||||
|
@ -47,6 +47,7 @@ class DivPlatformGenesis: public DivDispatch {
|
||||||
freq(0),
|
freq(0),
|
||||||
baseFreq(0),
|
baseFreq(0),
|
||||||
pitch(0),
|
pitch(0),
|
||||||
|
pitch2(0),
|
||||||
portaPauseFreq(0),
|
portaPauseFreq(0),
|
||||||
note(0),
|
note(0),
|
||||||
ins(-1),
|
ins(-1),
|
||||||
|
|
|
@ -25,7 +25,7 @@ class DivPlatformGenesisExt: public DivPlatformGenesis {
|
||||||
struct OpChannel {
|
struct OpChannel {
|
||||||
DivMacroInt std;
|
DivMacroInt std;
|
||||||
unsigned char freqH, freqL;
|
unsigned char freqH, freqL;
|
||||||
int freq, baseFreq, pitch, portaPauseFreq, ins;
|
int freq, baseFreq, pitch, pitch2, portaPauseFreq, ins;
|
||||||
signed char konCycles;
|
signed char konCycles;
|
||||||
bool active, insChanged, freqChanged, keyOn, keyOff, portaPause;
|
bool active, insChanged, freqChanged, keyOn, keyOff, portaPause;
|
||||||
int vol;
|
int vol;
|
||||||
|
@ -36,6 +36,7 @@ class DivPlatformGenesisExt: public DivPlatformGenesis {
|
||||||
freq(0),
|
freq(0),
|
||||||
baseFreq(0),
|
baseFreq(0),
|
||||||
pitch(0),
|
pitch(0),
|
||||||
|
pitch2(0),
|
||||||
portaPauseFreq(0),
|
portaPauseFreq(0),
|
||||||
ins(-1),
|
ins(-1),
|
||||||
active(false),
|
active(false),
|
||||||
|
|
|
@ -44,7 +44,7 @@ class DivPlatformLynx: public DivDispatch {
|
||||||
DivMacroInt std;
|
DivMacroInt std;
|
||||||
MikeyFreqDiv fd;
|
MikeyFreqDiv fd;
|
||||||
MikeyDuty duty;
|
MikeyDuty duty;
|
||||||
int baseFreq, pitch, note, actualNote, lfsr, ins;
|
int baseFreq, pitch, pitch2, note, actualNote, lfsr, ins;
|
||||||
unsigned char pan;
|
unsigned char pan;
|
||||||
bool active, insChanged, freqChanged, keyOn, keyOff, inPorta;
|
bool active, insChanged, freqChanged, keyOn, keyOff, inPorta;
|
||||||
signed char vol, outVol;
|
signed char vol, outVol;
|
||||||
|
@ -54,6 +54,7 @@ class DivPlatformLynx: public DivDispatch {
|
||||||
duty(0),
|
duty(0),
|
||||||
baseFreq(0),
|
baseFreq(0),
|
||||||
pitch(0),
|
pitch(0),
|
||||||
|
pitch2(0),
|
||||||
note(0),
|
note(0),
|
||||||
actualNote(0),
|
actualNote(0),
|
||||||
lfsr(-1),
|
lfsr(-1),
|
||||||
|
|
|
@ -25,7 +25,7 @@
|
||||||
|
|
||||||
class DivPlatformMMC5: public DivDispatch {
|
class DivPlatformMMC5: public DivDispatch {
|
||||||
struct Channel {
|
struct Channel {
|
||||||
int freq, baseFreq, pitch, prevFreq, note, ins;
|
int freq, baseFreq, pitch, pitch2, prevFreq, note, ins;
|
||||||
unsigned char duty, sweep;
|
unsigned char duty, sweep;
|
||||||
bool active, insChanged, freqChanged, sweepChanged, keyOn, keyOff, inPorta, furnaceDac;
|
bool active, insChanged, freqChanged, sweepChanged, keyOn, keyOff, inPorta, furnaceDac;
|
||||||
signed char vol, outVol, wave;
|
signed char vol, outVol, wave;
|
||||||
|
@ -34,6 +34,7 @@ class DivPlatformMMC5: public DivDispatch {
|
||||||
freq(0),
|
freq(0),
|
||||||
baseFreq(0),
|
baseFreq(0),
|
||||||
pitch(0),
|
pitch(0),
|
||||||
|
pitch2(0),
|
||||||
prevFreq(65535),
|
prevFreq(65535),
|
||||||
note(0),
|
note(0),
|
||||||
ins(-1),
|
ins(-1),
|
||||||
|
|
|
@ -28,7 +28,7 @@
|
||||||
|
|
||||||
class DivPlatformN163: public DivDispatch {
|
class DivPlatformN163: public DivDispatch {
|
||||||
struct Channel {
|
struct Channel {
|
||||||
int freq, baseFreq, pitch, note;
|
int freq, baseFreq, pitch, pitch2, note;
|
||||||
short ins, wave, wavePos, waveLen;
|
short ins, wave, wavePos, waveLen;
|
||||||
unsigned char waveMode;
|
unsigned char waveMode;
|
||||||
short loadWave, loadPos, loadLen;
|
short loadWave, loadPos, loadLen;
|
||||||
|
@ -41,6 +41,7 @@ class DivPlatformN163: public DivDispatch {
|
||||||
freq(0),
|
freq(0),
|
||||||
baseFreq(0),
|
baseFreq(0),
|
||||||
pitch(0),
|
pitch(0),
|
||||||
|
pitch2(0),
|
||||||
note(0),
|
note(0),
|
||||||
ins(-1),
|
ins(-1),
|
||||||
wave(-1),
|
wave(-1),
|
||||||
|
|
|
@ -25,7 +25,7 @@
|
||||||
|
|
||||||
class DivPlatformNES: public DivDispatch {
|
class DivPlatformNES: public DivDispatch {
|
||||||
struct Channel {
|
struct Channel {
|
||||||
int freq, baseFreq, pitch, prevFreq, note, ins;
|
int freq, baseFreq, pitch, pitch2, prevFreq, note, ins;
|
||||||
unsigned char duty, sweep;
|
unsigned char duty, sweep;
|
||||||
bool active, insChanged, freqChanged, sweepChanged, keyOn, keyOff, inPorta, furnaceDac;
|
bool active, insChanged, freqChanged, sweepChanged, keyOn, keyOff, inPorta, furnaceDac;
|
||||||
signed char vol, outVol, wave;
|
signed char vol, outVol, wave;
|
||||||
|
@ -34,6 +34,7 @@ class DivPlatformNES: public DivDispatch {
|
||||||
freq(0),
|
freq(0),
|
||||||
baseFreq(0),
|
baseFreq(0),
|
||||||
pitch(0),
|
pitch(0),
|
||||||
|
pitch2(0),
|
||||||
prevFreq(65535),
|
prevFreq(65535),
|
||||||
note(0),
|
note(0),
|
||||||
ins(-1),
|
ins(-1),
|
||||||
|
|
|
@ -30,7 +30,7 @@ class DivPlatformOPL: public DivDispatch {
|
||||||
DivInstrumentFM state;
|
DivInstrumentFM state;
|
||||||
DivMacroInt std;
|
DivMacroInt std;
|
||||||
unsigned char freqH, freqL;
|
unsigned char freqH, freqL;
|
||||||
int freq, baseFreq, pitch, note, ins;
|
int freq, baseFreq, pitch, pitch2, note, ins;
|
||||||
bool active, insChanged, freqChanged, keyOn, keyOff, portaPause, furnaceDac, inPorta, fourOp;
|
bool active, insChanged, freqChanged, keyOn, keyOff, portaPause, furnaceDac, inPorta, fourOp;
|
||||||
int vol, outVol;
|
int vol, outVol;
|
||||||
unsigned char pan;
|
unsigned char pan;
|
||||||
|
@ -40,6 +40,7 @@ class DivPlatformOPL: public DivDispatch {
|
||||||
freq(0),
|
freq(0),
|
||||||
baseFreq(0),
|
baseFreq(0),
|
||||||
pitch(0),
|
pitch(0),
|
||||||
|
pitch2(0),
|
||||||
note(0),
|
note(0),
|
||||||
ins(-1),
|
ins(-1),
|
||||||
active(false),
|
active(false),
|
||||||
|
|
|
@ -33,7 +33,7 @@ class DivPlatformOPLL: public DivDispatch {
|
||||||
DivInstrumentFM state;
|
DivInstrumentFM state;
|
||||||
DivMacroInt std;
|
DivMacroInt std;
|
||||||
unsigned char freqH, freqL;
|
unsigned char freqH, freqL;
|
||||||
int freq, baseFreq, pitch, note, ins;
|
int freq, baseFreq, pitch, pitch2, note, ins;
|
||||||
bool active, insChanged, freqChanged, keyOn, keyOff, portaPause, furnaceDac, inPorta;
|
bool active, insChanged, freqChanged, keyOn, keyOff, portaPause, furnaceDac, inPorta;
|
||||||
int vol, outVol;
|
int vol, outVol;
|
||||||
unsigned char pan;
|
unsigned char pan;
|
||||||
|
@ -43,6 +43,7 @@ class DivPlatformOPLL: public DivDispatch {
|
||||||
freq(0),
|
freq(0),
|
||||||
baseFreq(0),
|
baseFreq(0),
|
||||||
pitch(0),
|
pitch(0),
|
||||||
|
pitch2(0),
|
||||||
note(0),
|
note(0),
|
||||||
ins(-1),
|
ins(-1),
|
||||||
active(false),
|
active(false),
|
||||||
|
|
|
@ -28,7 +28,7 @@
|
||||||
|
|
||||||
class DivPlatformPCE: public DivDispatch {
|
class DivPlatformPCE: public DivDispatch {
|
||||||
struct Channel {
|
struct Channel {
|
||||||
int freq, baseFreq, pitch, note;
|
int freq, baseFreq, pitch, pitch2, note;
|
||||||
int dacPeriod, dacRate;
|
int dacPeriod, dacRate;
|
||||||
unsigned int dacPos;
|
unsigned int dacPos;
|
||||||
int dacSample, ins;
|
int dacSample, ins;
|
||||||
|
@ -41,6 +41,7 @@ class DivPlatformPCE: public DivDispatch {
|
||||||
freq(0),
|
freq(0),
|
||||||
baseFreq(0),
|
baseFreq(0),
|
||||||
pitch(0),
|
pitch(0),
|
||||||
|
pitch2(0),
|
||||||
note(0),
|
note(0),
|
||||||
dacPeriod(0),
|
dacPeriod(0),
|
||||||
dacRate(0),
|
dacRate(0),
|
||||||
|
|
|
@ -25,7 +25,7 @@
|
||||||
|
|
||||||
class DivPlatformPCSpeaker: public DivDispatch {
|
class DivPlatformPCSpeaker: public DivDispatch {
|
||||||
struct Channel {
|
struct Channel {
|
||||||
int freq, baseFreq, pitch, note, ins;
|
int freq, baseFreq, pitch, pitch2, note, ins;
|
||||||
unsigned char duty, sweep;
|
unsigned char duty, sweep;
|
||||||
bool active, insChanged, freqChanged, sweepChanged, keyOn, keyOff, inPorta, furnaceDac;
|
bool active, insChanged, freqChanged, sweepChanged, keyOn, keyOff, inPorta, furnaceDac;
|
||||||
signed char vol, outVol, wave;
|
signed char vol, outVol, wave;
|
||||||
|
@ -34,6 +34,7 @@ class DivPlatformPCSpeaker: public DivDispatch {
|
||||||
freq(0),
|
freq(0),
|
||||||
baseFreq(0),
|
baseFreq(0),
|
||||||
pitch(0),
|
pitch(0),
|
||||||
|
pitch2(0),
|
||||||
note(0),
|
note(0),
|
||||||
ins(-1),
|
ins(-1),
|
||||||
duty(0),
|
duty(0),
|
||||||
|
|
|
@ -25,7 +25,7 @@
|
||||||
|
|
||||||
class DivPlatformPET: public DivDispatch {
|
class DivPlatformPET: public DivDispatch {
|
||||||
struct Channel {
|
struct Channel {
|
||||||
int freq, baseFreq, pitch, note, ins;
|
int freq, baseFreq, pitch, pitch2, note, ins;
|
||||||
bool active, insChanged, freqChanged, keyOn, keyOff, inPorta;
|
bool active, insChanged, freqChanged, keyOn, keyOff, inPorta;
|
||||||
int vol, outVol, wave;
|
int vol, outVol, wave;
|
||||||
unsigned char sreg;
|
unsigned char sreg;
|
||||||
|
@ -36,6 +36,7 @@ class DivPlatformPET: public DivDispatch {
|
||||||
freq(0),
|
freq(0),
|
||||||
baseFreq(0),
|
baseFreq(0),
|
||||||
pitch(0),
|
pitch(0),
|
||||||
|
pitch2(0),
|
||||||
note(0),
|
note(0),
|
||||||
ins(-1),
|
ins(-1),
|
||||||
active(false),
|
active(false),
|
||||||
|
|
|
@ -27,7 +27,7 @@
|
||||||
|
|
||||||
class DivPlatformQSound: public DivDispatch {
|
class DivPlatformQSound: public DivDispatch {
|
||||||
struct Channel {
|
struct Channel {
|
||||||
int freq, baseFreq, pitch;
|
int freq, baseFreq, pitch, pitch2;
|
||||||
unsigned short audLen;
|
unsigned short audLen;
|
||||||
unsigned int audPos;
|
unsigned int audPos;
|
||||||
int sample, wave, ins;
|
int sample, wave, ins;
|
||||||
|
@ -40,6 +40,7 @@ class DivPlatformQSound: public DivDispatch {
|
||||||
freq(0),
|
freq(0),
|
||||||
baseFreq(0),
|
baseFreq(0),
|
||||||
pitch(0),
|
pitch(0),
|
||||||
|
pitch2(0),
|
||||||
audLen(0),
|
audLen(0),
|
||||||
audPos(0),
|
audPos(0),
|
||||||
sample(-1),
|
sample(-1),
|
||||||
|
|
|
@ -35,14 +35,14 @@ class DivPlatformSAA1099: public DivDispatch {
|
||||||
protected:
|
protected:
|
||||||
struct Channel {
|
struct Channel {
|
||||||
unsigned char freqH, freqL;
|
unsigned char freqH, freqL;
|
||||||
int freq, baseFreq, pitch, note, ins;
|
int freq, baseFreq, pitch, pitch2, note, ins;
|
||||||
unsigned char psgMode;
|
unsigned char psgMode;
|
||||||
signed char konCycles;
|
signed char konCycles;
|
||||||
bool active, insChanged, freqChanged, keyOn, keyOff, portaPause, inPorta;
|
bool active, insChanged, freqChanged, keyOn, keyOff, portaPause, inPorta;
|
||||||
int vol, outVol;
|
int vol, outVol;
|
||||||
unsigned char pan;
|
unsigned char pan;
|
||||||
DivMacroInt std;
|
DivMacroInt std;
|
||||||
Channel(): freqH(0), freqL(0), freq(0), baseFreq(0), pitch(0), note(0), ins(-1), psgMode(1), active(false), insChanged(true), freqChanged(false), keyOn(false), keyOff(false), portaPause(false), inPorta(false), vol(0), outVol(15), pan(255) {}
|
Channel(): freqH(0), freqL(0), freq(0), baseFreq(0), pitch(0), pitch2(0), note(0), ins(-1), psgMode(1), active(false), insChanged(true), freqChanged(false), keyOn(false), keyOff(false), portaPause(false), inPorta(false), vol(0), outVol(15), pan(255) {}
|
||||||
};
|
};
|
||||||
Channel chan[6];
|
Channel chan[6];
|
||||||
bool isMuted[6];
|
bool isMuted[6];
|
||||||
|
|
|
@ -29,7 +29,7 @@ class DivPlatformSegaPCM: public DivDispatch {
|
||||||
struct Channel {
|
struct Channel {
|
||||||
DivMacroInt std;
|
DivMacroInt std;
|
||||||
unsigned char freqH, freqL;
|
unsigned char freqH, freqL;
|
||||||
int freq, baseFreq, pitch, note, ins;
|
int freq, baseFreq, pitch, pitch2, note, ins;
|
||||||
signed char konCycles;
|
signed char konCycles;
|
||||||
bool active, insChanged, freqChanged, keyOn, keyOff, inPorta, portaPause, furnacePCM;
|
bool active, insChanged, freqChanged, keyOn, keyOff, inPorta, portaPause, furnacePCM;
|
||||||
int vol, outVol;
|
int vol, outVol;
|
||||||
|
@ -42,7 +42,7 @@ class DivPlatformSegaPCM: public DivDispatch {
|
||||||
unsigned char freq;
|
unsigned char freq;
|
||||||
PCMChannel(): sample(-1), pos(0), len(0), freq(0) {}
|
PCMChannel(): sample(-1), pos(0), len(0), freq(0) {}
|
||||||
} pcm;
|
} pcm;
|
||||||
Channel(): freqH(0), freqL(0), freq(0), baseFreq(0), pitch(0), note(0), ins(-1), active(false), insChanged(true), freqChanged(false), keyOn(false), keyOff(false), inPorta(false), portaPause(false), furnacePCM(false), vol(0), outVol(0), chVolL(127), chVolR(127) {}
|
Channel(): freqH(0), freqL(0), freq(0), baseFreq(0), pitch(0), pitch2(0), note(0), ins(-1), active(false), insChanged(true), freqChanged(false), keyOn(false), keyOff(false), inPorta(false), portaPause(false), furnacePCM(false), vol(0), outVol(0), chVolL(127), chVolR(127) {}
|
||||||
};
|
};
|
||||||
Channel chan[16];
|
Channel chan[16];
|
||||||
struct QueuedWrite {
|
struct QueuedWrite {
|
||||||
|
|
|
@ -26,7 +26,7 @@
|
||||||
|
|
||||||
class DivPlatformSMS: public DivDispatch {
|
class DivPlatformSMS: public DivDispatch {
|
||||||
struct Channel {
|
struct Channel {
|
||||||
int freq, baseFreq, pitch, note, actualNote, ins;
|
int freq, baseFreq, pitch, pitch2, note, actualNote, ins;
|
||||||
bool active, insChanged, freqChanged, keyOn, keyOff, inPorta;
|
bool active, insChanged, freqChanged, keyOn, keyOff, inPorta;
|
||||||
signed char vol, outVol;
|
signed char vol, outVol;
|
||||||
DivMacroInt std;
|
DivMacroInt std;
|
||||||
|
@ -34,6 +34,7 @@ class DivPlatformSMS: public DivDispatch {
|
||||||
freq(0),
|
freq(0),
|
||||||
baseFreq(0),
|
baseFreq(0),
|
||||||
pitch(0),
|
pitch(0),
|
||||||
|
pitch2(0),
|
||||||
note(0),
|
note(0),
|
||||||
actualNote(0),
|
actualNote(0),
|
||||||
ins(-1),
|
ins(-1),
|
||||||
|
|
|
@ -27,7 +27,7 @@
|
||||||
|
|
||||||
class DivPlatformSoundUnit: public DivDispatch {
|
class DivPlatformSoundUnit: public DivDispatch {
|
||||||
struct Channel {
|
struct Channel {
|
||||||
int freq, baseFreq, pitch, note;
|
int freq, baseFreq, pitch, pitch2, note;
|
||||||
int ins, cutoff, res, control;
|
int ins, cutoff, res, control;
|
||||||
signed char pan;
|
signed char pan;
|
||||||
unsigned char duty;
|
unsigned char duty;
|
||||||
|
@ -39,6 +39,7 @@ class DivPlatformSoundUnit: public DivDispatch {
|
||||||
freq(0),
|
freq(0),
|
||||||
baseFreq(0),
|
baseFreq(0),
|
||||||
pitch(0),
|
pitch(0),
|
||||||
|
pitch2(0),
|
||||||
note(0),
|
note(0),
|
||||||
ins(-1),
|
ins(-1),
|
||||||
cutoff(65535),
|
cutoff(65535),
|
||||||
|
|
|
@ -28,7 +28,7 @@
|
||||||
|
|
||||||
class DivPlatformSwan: public DivDispatch {
|
class DivPlatformSwan: public DivDispatch {
|
||||||
struct Channel {
|
struct Channel {
|
||||||
int freq, baseFreq, pitch, note, ins;
|
int freq, baseFreq, pitch, pitch2, note, ins;
|
||||||
unsigned char pan;
|
unsigned char pan;
|
||||||
bool active, insChanged, freqChanged, keyOn, keyOff, inPorta;
|
bool active, insChanged, freqChanged, keyOn, keyOff, inPorta;
|
||||||
int vol, outVol, wave;
|
int vol, outVol, wave;
|
||||||
|
@ -38,6 +38,7 @@ class DivPlatformSwan: public DivDispatch {
|
||||||
freq(0),
|
freq(0),
|
||||||
baseFreq(0),
|
baseFreq(0),
|
||||||
pitch(0),
|
pitch(0),
|
||||||
|
pitch2(0),
|
||||||
note(0),
|
note(0),
|
||||||
ins(-1),
|
ins(-1),
|
||||||
pan(255),
|
pan(255),
|
||||||
|
|
|
@ -27,13 +27,13 @@
|
||||||
class DivPlatformTIA: public DivDispatch {
|
class DivPlatformTIA: public DivDispatch {
|
||||||
protected:
|
protected:
|
||||||
struct Channel {
|
struct Channel {
|
||||||
int freq, baseFreq, pitch, note, ins;
|
int freq, baseFreq, pitch, pitch2, note, ins;
|
||||||
unsigned char shape;
|
unsigned char shape;
|
||||||
signed char konCycles;
|
signed char konCycles;
|
||||||
bool active, insChanged, freqChanged, keyOn, keyOff, portaPause, inPorta;
|
bool active, insChanged, freqChanged, keyOn, keyOff, portaPause, inPorta;
|
||||||
int vol, outVol;
|
int vol, outVol;
|
||||||
DivMacroInt std;
|
DivMacroInt std;
|
||||||
Channel(): freq(0), baseFreq(0), pitch(0), note(0), ins(-1), shape(4), active(false), insChanged(true), freqChanged(false), keyOn(false), keyOff(false), portaPause(false), inPorta(false), vol(0), outVol(15) {}
|
Channel(): freq(0), baseFreq(0), pitch(0), pitch2(0), note(0), ins(-1), shape(4), active(false), insChanged(true), freqChanged(false), keyOn(false), keyOff(false), portaPause(false), inPorta(false), vol(0), outVol(15) {}
|
||||||
};
|
};
|
||||||
Channel chan[2];
|
Channel chan[2];
|
||||||
bool isMuted[2];
|
bool isMuted[2];
|
||||||
|
|
|
@ -35,7 +35,7 @@ class DivPlatformTX81Z: public DivDispatch {
|
||||||
DivInstrumentFM state;
|
DivInstrumentFM state;
|
||||||
DivMacroInt std;
|
DivMacroInt std;
|
||||||
unsigned char freqH, freqL;
|
unsigned char freqH, freqL;
|
||||||
int freq, baseFreq, pitch, note, ins;
|
int freq, baseFreq, pitch, pitch2, note, ins;
|
||||||
signed char konCycles;
|
signed char konCycles;
|
||||||
bool active, insChanged, freqChanged, keyOn, keyOff, inPorta, portaPause, furnacePCM, hardReset;
|
bool active, insChanged, freqChanged, keyOn, keyOff, inPorta, portaPause, furnacePCM, hardReset;
|
||||||
int vol, outVol;
|
int vol, outVol;
|
||||||
|
@ -46,6 +46,7 @@ class DivPlatformTX81Z: public DivDispatch {
|
||||||
freq(0),
|
freq(0),
|
||||||
baseFreq(0),
|
baseFreq(0),
|
||||||
pitch(0),
|
pitch(0),
|
||||||
|
pitch2(0),
|
||||||
note(0),
|
note(0),
|
||||||
ins(-1),
|
ins(-1),
|
||||||
active(false),
|
active(false),
|
||||||
|
|
|
@ -29,7 +29,7 @@ struct VERA_PCM;
|
||||||
class DivPlatformVERA: public DivDispatch {
|
class DivPlatformVERA: public DivDispatch {
|
||||||
protected:
|
protected:
|
||||||
struct Channel {
|
struct Channel {
|
||||||
int freq, baseFreq, pitch, note, ins;
|
int freq, baseFreq, pitch, pitch2, note, ins;
|
||||||
unsigned char pan;
|
unsigned char pan;
|
||||||
bool active, freqChanged, inPorta;
|
bool active, freqChanged, inPorta;
|
||||||
int vol, outVol;
|
int vol, outVol;
|
||||||
|
@ -45,7 +45,8 @@ class DivPlatformVERA: public DivDispatch {
|
||||||
bool depth16;
|
bool depth16;
|
||||||
PCMChannel(): sample(-1), pos(0), len(0), freq(0), depth16(false) {}
|
PCMChannel(): sample(-1), pos(0), len(0), freq(0), depth16(false) {}
|
||||||
} pcm;
|
} pcm;
|
||||||
Channel(): freq(0), baseFreq(0), pitch(0), note(0), ins(-1), pan(0), active(false), freqChanged(false), inPorta(false), vol(0), outVol(0), accum(0), noiseval(0) {}
|
// somebody please split this into multiple lines!
|
||||||
|
Channel(): freq(0), baseFreq(0), pitch(0), pitch2(0), note(0), ins(-1), pan(0), active(false), freqChanged(false), inPorta(false), vol(0), outVol(0), accum(0), noiseval(0) {}
|
||||||
};
|
};
|
||||||
Channel chan[17];
|
Channel chan[17];
|
||||||
bool isMuted[17];
|
bool isMuted[17];
|
||||||
|
|
|
@ -27,7 +27,7 @@
|
||||||
|
|
||||||
class DivPlatformVIC20: public DivDispatch {
|
class DivPlatformVIC20: public DivDispatch {
|
||||||
struct Channel {
|
struct Channel {
|
||||||
int freq, baseFreq, pitch, note, ins;
|
int freq, baseFreq, pitch, pitch2, note, ins;
|
||||||
unsigned char pan;
|
unsigned char pan;
|
||||||
bool active, insChanged, freqChanged, keyOn, keyOff, inPorta;
|
bool active, insChanged, freqChanged, keyOn, keyOff, inPorta;
|
||||||
int vol, outVol, wave, waveWriteCycle;
|
int vol, outVol, wave, waveWriteCycle;
|
||||||
|
@ -36,6 +36,7 @@ class DivPlatformVIC20: public DivDispatch {
|
||||||
freq(0),
|
freq(0),
|
||||||
baseFreq(0),
|
baseFreq(0),
|
||||||
pitch(0),
|
pitch(0),
|
||||||
|
pitch2(0),
|
||||||
note(0),
|
note(0),
|
||||||
ins(-1),
|
ins(-1),
|
||||||
pan(255),
|
pan(255),
|
||||||
|
|
|
@ -28,7 +28,7 @@
|
||||||
|
|
||||||
class DivPlatformVRC6: public DivDispatch {
|
class DivPlatformVRC6: public DivDispatch {
|
||||||
struct Channel {
|
struct Channel {
|
||||||
int freq, baseFreq, pitch, note;
|
int freq, baseFreq, pitch, pitch2, note;
|
||||||
int dacPeriod, dacRate, dacOut;
|
int dacPeriod, dacRate, dacOut;
|
||||||
unsigned int dacPos;
|
unsigned int dacPos;
|
||||||
int dacSample, ins;
|
int dacSample, ins;
|
||||||
|
@ -40,6 +40,7 @@ class DivPlatformVRC6: public DivDispatch {
|
||||||
freq(0),
|
freq(0),
|
||||||
baseFreq(0),
|
baseFreq(0),
|
||||||
pitch(0),
|
pitch(0),
|
||||||
|
pitch2(0),
|
||||||
note(0),
|
note(0),
|
||||||
dacPeriod(0),
|
dacPeriod(0),
|
||||||
dacRate(0),
|
dacRate(0),
|
||||||
|
|
|
@ -79,7 +79,7 @@ class DivPlatformX1_010: public DivDispatch {
|
||||||
slide(0),
|
slide(0),
|
||||||
slidefrac(0) {}
|
slidefrac(0) {}
|
||||||
};
|
};
|
||||||
int freq, baseFreq, pitch, note;
|
int freq, baseFreq, pitch, pitch2, note;
|
||||||
int wave, sample, ins;
|
int wave, sample, ins;
|
||||||
unsigned char pan, autoEnvNum, autoEnvDen;
|
unsigned char pan, autoEnvNum, autoEnvDen;
|
||||||
bool active, insChanged, envChanged, freqChanged, keyOn, keyOff, inPorta, furnacePCM, pcm;
|
bool active, insChanged, envChanged, freqChanged, keyOn, keyOff, inPorta, furnacePCM, pcm;
|
||||||
|
@ -89,7 +89,7 @@ class DivPlatformX1_010: public DivDispatch {
|
||||||
DivMacroInt std;
|
DivMacroInt std;
|
||||||
DivWaveSynth ws;
|
DivWaveSynth ws;
|
||||||
void reset() {
|
void reset() {
|
||||||
freq = baseFreq = pitch = note = 0;
|
freq = baseFreq = pitch = pitch2 = note = 0;
|
||||||
wave = sample = ins = -1;
|
wave = sample = ins = -1;
|
||||||
pan = 255;
|
pan = 255;
|
||||||
autoEnvNum = autoEnvDen = 0;
|
autoEnvNum = autoEnvDen = 0;
|
||||||
|
@ -100,7 +100,7 @@ class DivPlatformX1_010: public DivDispatch {
|
||||||
waveBank = 0;
|
waveBank = 0;
|
||||||
}
|
}
|
||||||
Channel():
|
Channel():
|
||||||
freq(0), baseFreq(0), pitch(0), note(0),
|
freq(0), baseFreq(0), pitch(0), pitch2(0), note(0),
|
||||||
wave(-1), sample(-1), ins(-1),
|
wave(-1), sample(-1), ins(-1),
|
||||||
pan(255), autoEnvNum(0), autoEnvDen(0),
|
pan(255), autoEnvNum(0), autoEnvDen(0),
|
||||||
active(false), insChanged(true), envChanged(true), freqChanged(false), keyOn(false), keyOff(false), inPorta(false), furnacePCM(false), pcm(false),
|
active(false), insChanged(true), envChanged(true), freqChanged(false), keyOn(false), keyOff(false), inPorta(false), furnacePCM(false), pcm(false),
|
||||||
|
|
|
@ -43,7 +43,7 @@ class DivPlatformYM2610: public DivDispatch {
|
||||||
struct Channel {
|
struct Channel {
|
||||||
DivInstrumentFM state;
|
DivInstrumentFM state;
|
||||||
unsigned char freqH, freqL;
|
unsigned char freqH, freqL;
|
||||||
int freq, baseFreq, pitch, note, ins;
|
int freq, baseFreq, pitch, pitch2, note, ins;
|
||||||
unsigned char psgMode, autoEnvNum, autoEnvDen;
|
unsigned char psgMode, autoEnvNum, autoEnvDen;
|
||||||
signed char konCycles;
|
signed char konCycles;
|
||||||
bool active, insChanged, freqChanged, keyOn, keyOff, portaPause, inPorta, furnacePCM, hardReset;
|
bool active, insChanged, freqChanged, keyOn, keyOff, portaPause, inPorta, furnacePCM, hardReset;
|
||||||
|
@ -57,6 +57,7 @@ class DivPlatformYM2610: public DivDispatch {
|
||||||
freq(0),
|
freq(0),
|
||||||
baseFreq(0),
|
baseFreq(0),
|
||||||
pitch(0),
|
pitch(0),
|
||||||
|
pitch2(0),
|
||||||
note(0),
|
note(0),
|
||||||
ins(-1),
|
ins(-1),
|
||||||
psgMode(1),
|
psgMode(1),
|
||||||
|
|
|
@ -35,7 +35,7 @@ class DivPlatformYM2610B: public DivDispatch {
|
||||||
struct Channel {
|
struct Channel {
|
||||||
DivInstrumentFM state;
|
DivInstrumentFM state;
|
||||||
unsigned char freqH, freqL;
|
unsigned char freqH, freqL;
|
||||||
int freq, baseFreq, pitch, note, ins;
|
int freq, baseFreq, pitch, pitch2, note, ins;
|
||||||
unsigned char psgMode, autoEnvNum, autoEnvDen;
|
unsigned char psgMode, autoEnvNum, autoEnvDen;
|
||||||
signed char konCycles;
|
signed char konCycles;
|
||||||
bool active, insChanged, freqChanged, keyOn, keyOff, portaPause, inPorta, furnacePCM, hardReset;
|
bool active, insChanged, freqChanged, keyOn, keyOff, portaPause, inPorta, furnacePCM, hardReset;
|
||||||
|
@ -49,6 +49,7 @@ class DivPlatformYM2610B: public DivDispatch {
|
||||||
freq(0),
|
freq(0),
|
||||||
baseFreq(0),
|
baseFreq(0),
|
||||||
pitch(0),
|
pitch(0),
|
||||||
|
pitch2(0),
|
||||||
note(0),
|
note(0),
|
||||||
ins(-1),
|
ins(-1),
|
||||||
psgMode(1),
|
psgMode(1),
|
||||||
|
|
|
@ -25,12 +25,12 @@ class DivPlatformYM2610BExt: public DivPlatformYM2610B {
|
||||||
struct OpChannel {
|
struct OpChannel {
|
||||||
DivMacroInt std;
|
DivMacroInt std;
|
||||||
unsigned char freqH, freqL;
|
unsigned char freqH, freqL;
|
||||||
int freq, baseFreq, pitch, ins;
|
int freq, baseFreq, pitch, pitch2, ins;
|
||||||
signed char konCycles;
|
signed char konCycles;
|
||||||
bool active, insChanged, freqChanged, keyOn, keyOff, portaPause;
|
bool active, insChanged, freqChanged, keyOn, keyOff, portaPause;
|
||||||
int vol;
|
int vol;
|
||||||
unsigned char pan;
|
unsigned char pan;
|
||||||
OpChannel(): freqH(0), freqL(0), freq(0), baseFreq(0), pitch(0), ins(-1), active(false), insChanged(true), freqChanged(false), keyOn(false), keyOff(false), portaPause(false), vol(0), pan(3) {}
|
OpChannel(): freqH(0), freqL(0), freq(0), baseFreq(0), pitch(0), pitch2(0), ins(-1), active(false), insChanged(true), freqChanged(false), keyOn(false), keyOff(false), portaPause(false), vol(0), pan(3) {}
|
||||||
};
|
};
|
||||||
OpChannel opChan[4];
|
OpChannel opChan[4];
|
||||||
bool isOpMuted[4];
|
bool isOpMuted[4];
|
||||||
|
|
|
@ -25,12 +25,12 @@ class DivPlatformYM2610Ext: public DivPlatformYM2610 {
|
||||||
struct OpChannel {
|
struct OpChannel {
|
||||||
DivMacroInt std;
|
DivMacroInt std;
|
||||||
unsigned char freqH, freqL;
|
unsigned char freqH, freqL;
|
||||||
int freq, baseFreq, pitch, ins;
|
int freq, baseFreq, pitch, pitch2, ins;
|
||||||
signed char konCycles;
|
signed char konCycles;
|
||||||
bool active, insChanged, freqChanged, keyOn, keyOff, portaPause;
|
bool active, insChanged, freqChanged, keyOn, keyOff, portaPause;
|
||||||
int vol;
|
int vol;
|
||||||
unsigned char pan;
|
unsigned char pan;
|
||||||
OpChannel(): freqH(0), freqL(0), freq(0), baseFreq(0), pitch(0), ins(-1), active(false), insChanged(true), freqChanged(false), keyOn(false), keyOff(false), portaPause(false), vol(0), pan(3) {}
|
OpChannel(): freqH(0), freqL(0), freq(0), baseFreq(0), pitch(0), pitch2(0), ins(-1), active(false), insChanged(true), freqChanged(false), keyOn(false), keyOff(false), portaPause(false), vol(0), pan(3) {}
|
||||||
};
|
};
|
||||||
OpChannel opChan[4];
|
OpChannel opChan[4];
|
||||||
bool isOpMuted[4];
|
bool isOpMuted[4];
|
||||||
|
|
Loading…
Reference in a new issue