prepare new dispatch
will allow for more than 2 outputs
This commit is contained in:
parent
565e8cc314
commit
08d2f12dbd
|
@ -33,4 +33,7 @@
|
|||
// sample related
|
||||
#define DIV_MAX_SAMPLE_TYPE 4
|
||||
|
||||
// dispatch
|
||||
#define DIV_MAX_OUTPUTS 16
|
||||
|
||||
#endif
|
||||
|
|
|
@ -322,12 +322,10 @@ class DivDispatch {
|
|||
|
||||
/**
|
||||
* fill a buffer with sound data.
|
||||
* @param bufL the left or mono channel buffer.
|
||||
* @param bufR the right channel buffer.
|
||||
* @param start the start offset.
|
||||
* @param buf pointers to output buffers.
|
||||
* @param len the amount of samples to fill.
|
||||
*/
|
||||
virtual void acquire(short* bufL, short* bufR, size_t start, size_t len);
|
||||
virtual void acquire(short** buf, size_t len);
|
||||
|
||||
/**
|
||||
* fill a write stream with data (e.g. for software-mixed PCM).
|
||||
|
@ -413,10 +411,10 @@ class DivDispatch {
|
|||
virtual void muteChannel(int ch, bool mute);
|
||||
|
||||
/**
|
||||
* test whether this dispatch outputs audio in two channels.
|
||||
* @return whether it does.
|
||||
* get the number of outputs this dispatch provides.
|
||||
* @return number of outputs (usually 1 or 2 but may be more). SHALL NOT be less than one.
|
||||
*/
|
||||
virtual bool isStereo();
|
||||
virtual int getOutputCount();
|
||||
|
||||
/**
|
||||
* test whether sending a key off command to a channel should reset arp too.
|
||||
|
|
|
@ -89,7 +89,11 @@ void DivDispatchContainer::setQuality(bool lowQual) {
|
|||
}
|
||||
|
||||
void DivDispatchContainer::acquire(size_t offset, size_t count) {
|
||||
dispatch->acquire(bbIn[0],bbIn[1],offset,count);
|
||||
int outs=dispatch->getOutputCount();
|
||||
for (int i=0; i<outs; i++) {
|
||||
bbInMapped[i]=&bbIn[i][offset];
|
||||
}
|
||||
dispatch->acquire(bbInMapped,count);
|
||||
}
|
||||
|
||||
void DivDispatchContainer::flush(size_t count) {
|
||||
|
@ -166,26 +170,10 @@ void DivDispatchContainer::clear() {
|
|||
}
|
||||
|
||||
void DivDispatchContainer::init(DivSystem sys, DivEngine* eng, int chanCount, double gotRate, const DivConfig& flags) {
|
||||
// quit if we already initialized
|
||||
if (dispatch!=NULL) return;
|
||||
|
||||
bb[0]=blip_new(32768);
|
||||
if (bb[0]==NULL) {
|
||||
logE("not enough memory!");
|
||||
return;
|
||||
}
|
||||
|
||||
bb[1]=blip_new(32768);
|
||||
if (bb[1]==NULL) {
|
||||
logE("not enough memory!");
|
||||
return;
|
||||
}
|
||||
|
||||
bbOut[0]=new short[32768];
|
||||
bbOut[1]=new short[32768];
|
||||
bbIn[0]=new short[32768];
|
||||
bbIn[1]=new short[32768];
|
||||
bbInLen=32768;
|
||||
|
||||
// initialize chip
|
||||
switch (sys) {
|
||||
case DIV_SYSTEM_YMU759:
|
||||
dispatch=new DivPlatformOPL;
|
||||
|
@ -461,6 +449,23 @@ void DivDispatchContainer::init(DivSystem sys, DivEngine* eng, int chanCount, do
|
|||
break;
|
||||
}
|
||||
dispatch->init(eng,chanCount,gotRate,flags);
|
||||
|
||||
// initialize output buffers
|
||||
int outs=dispatch->getOutputCount();
|
||||
bbInLen=32768;
|
||||
|
||||
for (int i=0; i<outs; i++) {
|
||||
bb[i]=blip_new(bbInLen);
|
||||
if (bb[i]==NULL) {
|
||||
logE("not enough memory!");
|
||||
return;
|
||||
}
|
||||
|
||||
bbIn[i]=new short[bbInLen];
|
||||
bbOut[i]=new short[bbInLen];
|
||||
memset(bbIn,0,bbInLen*sizeof(short));
|
||||
memset(bbOut,0,bbInLen*sizeof(short));
|
||||
}
|
||||
}
|
||||
|
||||
void DivDispatchContainer::quit() {
|
||||
|
@ -469,11 +474,19 @@ void DivDispatchContainer::quit() {
|
|||
delete dispatch;
|
||||
dispatch=NULL;
|
||||
|
||||
delete[] bbOut[0];
|
||||
delete[] bbOut[1];
|
||||
delete[] bbIn[0];
|
||||
delete[] bbIn[1];
|
||||
bbInLen=0;
|
||||
blip_delete(bb[0]);
|
||||
blip_delete(bb[1]);
|
||||
for (int i=0; i<DIV_MAX_OUTPUTS; i++) {
|
||||
if (bbOut[i]!=NULL) {
|
||||
delete[] bbOut[i];
|
||||
bbOut[i]=NULL;
|
||||
}
|
||||
if (bbIn[i]!=NULL) {
|
||||
delete[] bbIn[i];
|
||||
bbIn[i]=NULL;
|
||||
}
|
||||
if (bb[i]!=NULL) {
|
||||
blip_delete(bb[i]);
|
||||
bb[i]=NULL;
|
||||
}
|
||||
}
|
||||
bbInLen=0;
|
||||
}
|
||||
|
|
|
@ -170,11 +170,12 @@ struct DivNoteEvent {
|
|||
|
||||
struct DivDispatchContainer {
|
||||
DivDispatch* dispatch;
|
||||
blip_buffer_t* bb[2];
|
||||
blip_buffer_t* bb[DIV_MAX_OUTPUTS];
|
||||
size_t bbInLen, runtotal, runLeft, runPos, lastAvail;
|
||||
int temp[2], prevSample[2];
|
||||
short* bbIn[2];
|
||||
short* bbOut[2];
|
||||
int temp[DIV_MAX_OUTPUTS], prevSample[DIV_MAX_OUTPUTS];
|
||||
short* bbInMapped[DIV_MAX_OUTPUTS];
|
||||
short* bbIn[DIV_MAX_OUTPUTS];
|
||||
short* bbOut[DIV_MAX_OUTPUTS];
|
||||
bool lowQuality, dcOffCompensation;
|
||||
|
||||
void setRates(double gotRate);
|
||||
|
@ -187,18 +188,20 @@ struct DivDispatchContainer {
|
|||
void quit();
|
||||
DivDispatchContainer():
|
||||
dispatch(NULL),
|
||||
bb{NULL,NULL},
|
||||
bbInLen(0),
|
||||
runtotal(0),
|
||||
runLeft(0),
|
||||
runPos(0),
|
||||
lastAvail(0),
|
||||
temp{0,0},
|
||||
prevSample{0,0},
|
||||
bbIn{NULL,NULL},
|
||||
bbOut{NULL,NULL},
|
||||
lowQuality(false),
|
||||
dcOffCompensation(false) {}
|
||||
dcOffCompensation(false) {
|
||||
memset(bb,0,DIV_MAX_OUTPUTS*sizeof(void*));
|
||||
memset(temp,0,DIV_MAX_OUTPUTS*sizeof(int));
|
||||
memset(prevSample,0,DIV_MAX_OUTPUTS*sizeof(int));
|
||||
memset(bbIn,0,DIV_MAX_OUTPUTS*sizeof(void*));
|
||||
memset(bbInMapped,0,DIV_MAX_OUTPUTS*sizeof(void*));
|
||||
memset(bbOut,0,DIV_MAX_OUTPUTS*sizeof(void*));
|
||||
}
|
||||
};
|
||||
|
||||
typedef int EffectValConversion(unsigned char,unsigned char);
|
||||
|
|
|
@ -19,7 +19,7 @@
|
|||
|
||||
#include "../dispatch.h"
|
||||
|
||||
void DivDispatch::acquire(short* bufL, short* bufR, size_t start, size_t len) {
|
||||
void DivDispatch::acquire(short** buf, size_t len) {
|
||||
}
|
||||
|
||||
void DivDispatch::fillStream(std::vector<DivDelayedWrite>& stream, int sRate, size_t len) {
|
||||
|
@ -69,8 +69,8 @@ int DivDispatch::dispatch(DivCommand c) {
|
|||
void DivDispatch::reset() {
|
||||
}
|
||||
|
||||
bool DivDispatch::isStereo() {
|
||||
return false;
|
||||
int DivDispatch::getOutputCount() {
|
||||
return 1;
|
||||
}
|
||||
|
||||
bool DivDispatch::keyOffAffectsArp(int ch) {
|
||||
|
|
|
@ -401,8 +401,8 @@ void DivPlatformAmiga::reset() {
|
|||
filtConst=filterOn?filtConstOn:filtConstOff;
|
||||
}
|
||||
|
||||
bool DivPlatformAmiga::isStereo() {
|
||||
return true;
|
||||
int DivPlatformAmiga::getOutputCount() {
|
||||
return 2;
|
||||
}
|
||||
|
||||
bool DivPlatformAmiga::keyOffAffectsArp(int ch) {
|
||||
|
|
|
@ -75,7 +75,7 @@ class DivPlatformAmiga: public DivDispatch {
|
|||
void forceIns();
|
||||
void tick(bool sysTick=true);
|
||||
void muteChannel(int ch, bool mute);
|
||||
bool isStereo();
|
||||
int getOutputCount();
|
||||
bool keyOffAffectsArp(int ch);
|
||||
DivMacroInt* getChanMacroInt(int ch);
|
||||
void setFlags(const DivConfig& flags);
|
||||
|
|
|
@ -885,8 +885,8 @@ void DivPlatformArcade::setFlags(const DivConfig& flags) {
|
|||
}
|
||||
}
|
||||
|
||||
bool DivPlatformArcade::isStereo() {
|
||||
return true;
|
||||
int DivPlatformArcade::getOutputCount() {
|
||||
return 2;
|
||||
}
|
||||
|
||||
void DivPlatformArcade::setYMFM(bool use) {
|
||||
|
|
|
@ -77,7 +77,7 @@ class DivPlatformArcade: public DivPlatformOPM {
|
|||
DivMacroInt* getChanMacroInt(int ch);
|
||||
void notifyInsChange(int ins);
|
||||
void setFlags(const DivConfig& flags);
|
||||
bool isStereo();
|
||||
int getOutputCount();
|
||||
void setYMFM(bool use);
|
||||
void poke(unsigned int addr, unsigned short val);
|
||||
void poke(std::vector<DivRegWrite>& wlist);
|
||||
|
|
|
@ -751,8 +751,8 @@ void DivPlatformAY8910::reset() {
|
|||
portBVal=0;
|
||||
}
|
||||
|
||||
bool DivPlatformAY8910::isStereo() {
|
||||
return true;
|
||||
int DivPlatformAY8910::getOutputCount() {
|
||||
return 2;
|
||||
}
|
||||
|
||||
bool DivPlatformAY8910::keyOffAffectsArp(int ch) {
|
||||
|
|
|
@ -140,7 +140,7 @@ class DivPlatformAY8910: public DivDispatch {
|
|||
void tick(bool sysTick=true);
|
||||
void muteChannel(int ch, bool mute);
|
||||
void setFlags(const DivConfig& flags);
|
||||
bool isStereo();
|
||||
int getOutputCount();
|
||||
bool keyOffAffectsArp(int ch);
|
||||
DivMacroInt* getChanMacroInt(int ch);
|
||||
bool getDCOffRequired();
|
||||
|
|
|
@ -747,8 +747,8 @@ void DivPlatformAY8930::reset() {
|
|||
immWrite(0x1a,0x00); // or mask
|
||||
}
|
||||
|
||||
bool DivPlatformAY8930::isStereo() {
|
||||
return true;
|
||||
int DivPlatformAY8930::getOutputCount() {
|
||||
return 2;
|
||||
}
|
||||
|
||||
bool DivPlatformAY8930::keyOffAffectsArp(int ch) {
|
||||
|
|
|
@ -142,7 +142,7 @@ class DivPlatformAY8930: public DivDispatch {
|
|||
void tick(bool sysTick=true);
|
||||
void muteChannel(int ch, bool mute);
|
||||
void setFlags(const DivConfig& flags);
|
||||
bool isStereo();
|
||||
int getOutputCount();
|
||||
bool keyOffAffectsArp(int ch);
|
||||
DivMacroInt* getChanMacroInt(int ch);
|
||||
void notifyInsDeletion(void* ins);
|
||||
|
|
|
@ -306,8 +306,8 @@ void DivPlatformBubSysWSG::reset() {
|
|||
k005289.reset();
|
||||
}
|
||||
|
||||
bool DivPlatformBubSysWSG::isStereo() {
|
||||
return false;
|
||||
int DivPlatformBubSysWSG::getOutputCount() {
|
||||
return 1;
|
||||
}
|
||||
|
||||
bool DivPlatformBubSysWSG::keyOffAffectsArp(int ch) {
|
||||
|
|
|
@ -56,7 +56,7 @@ class DivPlatformBubSysWSG: public DivDispatch {
|
|||
void forceIns();
|
||||
void tick(bool sysTick=true);
|
||||
void muteChannel(int ch, bool mute);
|
||||
bool isStereo();
|
||||
int getOutputCount();
|
||||
bool keyOffAffectsArp(int ch);
|
||||
DivMacroInt* getChanMacroInt(int ch);
|
||||
void setFlags(const DivConfig& flags);
|
||||
|
|
|
@ -361,8 +361,8 @@ void DivPlatformGA20::reset() {
|
|||
}
|
||||
}
|
||||
|
||||
bool DivPlatformGA20::isStereo() {
|
||||
return false;
|
||||
int DivPlatformGA20::getOutputCount() {
|
||||
return 1;
|
||||
}
|
||||
|
||||
void DivPlatformGA20::notifyInsChange(int ins) {
|
||||
|
|
|
@ -85,7 +85,7 @@ class DivPlatformGA20: public DivDispatch, public iremga20_intf {
|
|||
virtual void forceIns() override;
|
||||
virtual void tick(bool sysTick=true) override;
|
||||
virtual void muteChannel(int ch, bool mute) override;
|
||||
virtual bool isStereo() override;
|
||||
virtual int getOutputCount() override;
|
||||
virtual void notifyInsChange(int ins) override;
|
||||
virtual void notifyWaveChange(int wave) override;
|
||||
virtual void notifyInsDeletion(void* ins) override;
|
||||
|
|
|
@ -604,8 +604,8 @@ int DivPlatformGB::getPortaFloor(int ch) {
|
|||
return 24;
|
||||
}
|
||||
|
||||
bool DivPlatformGB::isStereo() {
|
||||
return true;
|
||||
int DivPlatformGB::getOutputCount() {
|
||||
return 2;
|
||||
}
|
||||
|
||||
bool DivPlatformGB::getDCOffRequired() {
|
||||
|
|
|
@ -90,7 +90,7 @@ class DivPlatformGB: public DivDispatch {
|
|||
void tick(bool sysTick=true);
|
||||
void muteChannel(int ch, bool mute);
|
||||
int getPortaFloor(int ch);
|
||||
bool isStereo();
|
||||
int getOutputCount();
|
||||
bool getDCOffRequired();
|
||||
void notifyInsChange(int ins);
|
||||
void notifyWaveChange(int wave);
|
||||
|
|
|
@ -1193,8 +1193,8 @@ void DivPlatformGenesis::reset() {
|
|||
delay=0;
|
||||
}
|
||||
|
||||
bool DivPlatformGenesis::isStereo() {
|
||||
return true;
|
||||
int DivPlatformGenesis::getOutputCount() {
|
||||
return 2;
|
||||
}
|
||||
|
||||
bool DivPlatformGenesis::keyOffAffectsArp(int ch) {
|
||||
|
|
|
@ -110,7 +110,7 @@ class DivPlatformGenesis: public DivPlatformOPN {
|
|||
void forceIns();
|
||||
void tick(bool sysTick=true);
|
||||
void muteChannel(int ch, bool mute);
|
||||
bool isStereo();
|
||||
int getOutputCount();
|
||||
void setYMFM(bool use);
|
||||
bool keyOffAffectsArp(int ch);
|
||||
bool keyOffAffectsPorta(int ch);
|
||||
|
|
|
@ -448,8 +448,8 @@ void DivPlatformK007232::reset() {
|
|||
}
|
||||
}
|
||||
|
||||
bool DivPlatformK007232::isStereo() {
|
||||
return stereo;
|
||||
int DivPlatformK007232::getOutputCount() {
|
||||
return stereo?2:1;
|
||||
}
|
||||
|
||||
void DivPlatformK007232::notifyInsChange(int ins) {
|
||||
|
|
|
@ -91,7 +91,7 @@ class DivPlatformK007232: public DivDispatch, public k007232_intf {
|
|||
void forceIns();
|
||||
void tick(bool sysTick=true);
|
||||
void muteChannel(int ch, bool mute);
|
||||
bool isStereo();
|
||||
int getOutputCount();
|
||||
void notifyInsChange(int ins);
|
||||
void notifyWaveChange(int wave);
|
||||
void notifyInsDeletion(void* ins);
|
||||
|
|
|
@ -393,8 +393,8 @@ void DivPlatformLynx::muteChannel(int ch, bool mute) {
|
|||
if (chan[ch].active) WRITE_VOLUME(ch,(isMuted[ch]?0:(chan[ch].outVol&127)));
|
||||
}
|
||||
|
||||
bool DivPlatformLynx::isStereo() {
|
||||
return true;
|
||||
int DivPlatformLynx::getOutputCount() {
|
||||
return 2;
|
||||
}
|
||||
|
||||
void DivPlatformLynx::forceIns() {
|
||||
|
|
|
@ -79,7 +79,7 @@ class DivPlatformLynx: public DivDispatch {
|
|||
void forceIns();
|
||||
void tick(bool sysTick=true);
|
||||
void muteChannel(int ch, bool mute);
|
||||
bool isStereo();
|
||||
int getOutputCount();
|
||||
bool keyOffAffectsArp(int ch);
|
||||
bool keyOffAffectsPorta(int ch);
|
||||
//int getPortaFloor(int ch);
|
||||
|
|
|
@ -371,8 +371,8 @@ void DivPlatformMSM5232::reset() {
|
|||
}
|
||||
}
|
||||
|
||||
bool DivPlatformMSM5232::isStereo() {
|
||||
return false;
|
||||
int DivPlatformMSM5232::getOutputCount() {
|
||||
return 1;
|
||||
}
|
||||
|
||||
bool DivPlatformMSM5232::keyOffAffectsArp(int ch) {
|
||||
|
|
|
@ -71,7 +71,7 @@ class DivPlatformMSM5232: public DivDispatch {
|
|||
void forceIns();
|
||||
void tick(bool sysTick=true);
|
||||
void muteChannel(int ch, bool mute);
|
||||
bool isStereo();
|
||||
int getOutputCount();
|
||||
bool keyOffAffectsArp(int ch);
|
||||
void setFlags(const DivConfig& flags);
|
||||
void notifyInsDeletion(void* ins);
|
||||
|
|
|
@ -336,8 +336,8 @@ void DivPlatformMSM6258::reset() {
|
|||
delay=0;
|
||||
}
|
||||
|
||||
bool DivPlatformMSM6258::isStereo() {
|
||||
return true;
|
||||
int DivPlatformMSM6258::getOutputCount() {
|
||||
return 2;
|
||||
}
|
||||
|
||||
bool DivPlatformMSM6258::keyOffAffectsArp(int ch) {
|
||||
|
|
|
@ -69,7 +69,7 @@ class DivPlatformMSM6258: public DivDispatch {
|
|||
void forceIns();
|
||||
void tick(bool sysTick=true);
|
||||
void muteChannel(int ch, bool mute);
|
||||
bool isStereo();
|
||||
int getOutputCount();
|
||||
bool keyOffAffectsArp(int ch);
|
||||
void notifyInsChange(int ins);
|
||||
void notifyInsDeletion(void* ins);
|
||||
|
|
|
@ -494,8 +494,8 @@ void DivPlatformNamcoWSG::reset() {
|
|||
namco->device_start(NULL);
|
||||
}
|
||||
|
||||
bool DivPlatformNamcoWSG::isStereo() {
|
||||
return (devType==30);
|
||||
int DivPlatformNamcoWSG::getOutputCount() {
|
||||
return (devType==30)?2:1;
|
||||
}
|
||||
|
||||
bool DivPlatformNamcoWSG::keyOffAffectsArp(int ch) {
|
||||
|
|
|
@ -65,7 +65,7 @@ class DivPlatformNamcoWSG: public DivDispatch {
|
|||
void forceIns();
|
||||
void tick(bool sysTick=true);
|
||||
void muteChannel(int ch, bool mute);
|
||||
bool isStereo();
|
||||
int getOutputCount();
|
||||
bool keyOffAffectsArp(int ch);
|
||||
void setDeviceType(int type);
|
||||
void setFlags(const DivConfig& flags);
|
||||
|
|
|
@ -1568,8 +1568,8 @@ void DivPlatformOPL::reset() {
|
|||
immWrite(0xbd,(dam<<7)|(dvb<<6)|(properDrums<<5)|drumState);
|
||||
}
|
||||
|
||||
bool DivPlatformOPL::isStereo() {
|
||||
return (oplType==3 || oplType==759);
|
||||
int DivPlatformOPL::getOutputCount() {
|
||||
return (oplType==3 || oplType==759)?4:1;
|
||||
}
|
||||
|
||||
bool DivPlatformOPL::keyOffAffectsArp(int ch) {
|
||||
|
|
|
@ -119,7 +119,7 @@ class DivPlatformOPL: public DivDispatch {
|
|||
void forceIns();
|
||||
void tick(bool sysTick=true);
|
||||
void muteChannel(int ch, bool mute);
|
||||
bool isStereo();
|
||||
int getOutputCount();
|
||||
void setYMFM(bool use);
|
||||
void setOPLType(int type, bool drums);
|
||||
bool keyOffAffectsArp(int ch);
|
||||
|
|
|
@ -547,8 +547,8 @@ void DivPlatformPCE::reset() {
|
|||
delay=500;
|
||||
}
|
||||
|
||||
bool DivPlatformPCE::isStereo() {
|
||||
return true;
|
||||
int DivPlatformPCE::getOutputCount() {
|
||||
return 2;
|
||||
}
|
||||
|
||||
bool DivPlatformPCE::keyOffAffectsArp(int ch) {
|
||||
|
|
|
@ -87,7 +87,7 @@ class DivPlatformPCE: public DivDispatch {
|
|||
void forceIns();
|
||||
void tick(bool sysTick=true);
|
||||
void muteChannel(int ch, bool mute);
|
||||
bool isStereo();
|
||||
int getOutputCount();
|
||||
bool keyOffAffectsArp(int ch);
|
||||
void setFlags(const DivConfig& flags);
|
||||
void notifyWaveChange(int wave);
|
||||
|
|
|
@ -410,8 +410,8 @@ void DivPlatformPCMDAC::reset() {
|
|||
chan[0].ws.init(NULL,32,255);
|
||||
}
|
||||
|
||||
bool DivPlatformPCMDAC::isStereo() {
|
||||
return true;
|
||||
int DivPlatformPCMDAC::getOutputCount() {
|
||||
return 2;
|
||||
}
|
||||
|
||||
DivMacroInt* DivPlatformPCMDAC::getChanMacroInt(int ch) {
|
||||
|
|
|
@ -75,7 +75,7 @@ class DivPlatformPCMDAC: public DivDispatch {
|
|||
void forceIns();
|
||||
void tick(bool sysTick=true);
|
||||
void muteChannel(int ch, bool mute);
|
||||
bool isStereo();
|
||||
int getOutputCount();
|
||||
DivMacroInt* getChanMacroInt(int ch);
|
||||
void setFlags(const DivConfig& flags);
|
||||
void notifyInsChange(int ins);
|
||||
|
|
|
@ -287,8 +287,8 @@ void DivPlatformPET::reset() {
|
|||
chan[0].std.setEngine(parent);
|
||||
}
|
||||
|
||||
bool DivPlatformPET::isStereo() {
|
||||
return false;
|
||||
int DivPlatformPET::getOutputCount() {
|
||||
return 1;
|
||||
}
|
||||
|
||||
void DivPlatformPET::notifyInsDeletion(void* ins) {
|
||||
|
|
|
@ -57,7 +57,7 @@ class DivPlatformPET: public DivDispatch {
|
|||
void tick(bool sysTick=true);
|
||||
void muteChannel(int ch, bool mute);
|
||||
void notifyInsDeletion(void* ins);
|
||||
bool isStereo();
|
||||
int getOutputCount();
|
||||
void poke(unsigned int addr, unsigned short val);
|
||||
void poke(std::vector<DivRegWrite>& wlist);
|
||||
const char** getRegisterSheet();
|
||||
|
|
|
@ -636,8 +636,8 @@ void DivPlatformQSound::reset() {
|
|||
immWrite(Q1_ECHO_FEEDBACK, echoFeedback << 6);
|
||||
}
|
||||
|
||||
bool DivPlatformQSound::isStereo() {
|
||||
return true;
|
||||
int DivPlatformQSound::getOutputCount() {
|
||||
return 2;
|
||||
}
|
||||
|
||||
bool DivPlatformQSound::keyOffAffectsArp(int ch) {
|
||||
|
|
|
@ -74,7 +74,7 @@ class DivPlatformQSound: public DivDispatch {
|
|||
void forceIns();
|
||||
void tick(bool sysTick=true);
|
||||
void muteChannel(int ch, bool mute);
|
||||
bool isStereo();
|
||||
int getOutputCount();
|
||||
bool keyOffAffectsArp(int ch);
|
||||
void setFlags(const DivConfig& flags);
|
||||
void notifyInsChange(int ins);
|
||||
|
|
|
@ -332,8 +332,8 @@ void DivPlatformRF5C68::reset() {
|
|||
}
|
||||
}
|
||||
|
||||
bool DivPlatformRF5C68::isStereo() {
|
||||
return true;
|
||||
int DivPlatformRF5C68::getOutputCount() {
|
||||
return 2;
|
||||
}
|
||||
|
||||
void DivPlatformRF5C68::notifyInsChange(int ins) {
|
||||
|
|
|
@ -67,7 +67,7 @@ class DivPlatformRF5C68: public DivDispatch {
|
|||
void forceIns();
|
||||
void tick(bool sysTick=true);
|
||||
void muteChannel(int ch, bool mute);
|
||||
bool isStereo();
|
||||
int getOutputCount();
|
||||
void setChipModel(int type);
|
||||
void notifyInsChange(int ins);
|
||||
void notifyWaveChange(int wave);
|
||||
|
|
|
@ -419,8 +419,8 @@ void DivPlatformSAA1099::reset() {
|
|||
rWrite(0x1c,1);
|
||||
}
|
||||
|
||||
bool DivPlatformSAA1099::isStereo() {
|
||||
return true;
|
||||
int DivPlatformSAA1099::getOutputCount() {
|
||||
return 2;
|
||||
}
|
||||
|
||||
int DivPlatformSAA1099::getPortaFloor(int ch) {
|
||||
|
|
|
@ -86,7 +86,7 @@ class DivPlatformSAA1099: public DivDispatch {
|
|||
void tick(bool sysTick=true);
|
||||
void muteChannel(int ch, bool mute);
|
||||
void setFlags(const DivConfig& flags);
|
||||
bool isStereo();
|
||||
int getOutputCount();
|
||||
int getPortaFloor(int ch);
|
||||
bool keyOffAffectsArp(int ch);
|
||||
void notifyInsDeletion(void* ins);
|
||||
|
|
|
@ -335,8 +335,8 @@ void DivPlatformSCC::reset() {
|
|||
lastUpdated34=0;
|
||||
}
|
||||
|
||||
bool DivPlatformSCC::isStereo() {
|
||||
return false;
|
||||
int DivPlatformSCC::getOutputCount() {
|
||||
return 1;
|
||||
}
|
||||
|
||||
void DivPlatformSCC::notifyWaveChange(int wave) {
|
||||
|
|
|
@ -61,7 +61,7 @@ class DivPlatformSCC: public DivDispatch {
|
|||
void forceIns();
|
||||
void tick(bool sysTick=true);
|
||||
void muteChannel(int ch, bool mute);
|
||||
bool isStereo();
|
||||
int getOutputCount();
|
||||
void notifyWaveChange(int wave);
|
||||
void notifyInsDeletion(void* ins);
|
||||
void poke(unsigned int addr, unsigned short val);
|
||||
|
|
|
@ -502,8 +502,8 @@ void DivPlatformSegaPCM::setFlags(const DivConfig& flags) {
|
|||
}
|
||||
}
|
||||
|
||||
bool DivPlatformSegaPCM::isStereo() {
|
||||
return true;
|
||||
int DivPlatformSegaPCM::getOutputCount() {
|
||||
return 2;
|
||||
}
|
||||
|
||||
int DivPlatformSegaPCM::init(DivEngine* p, int channels, int sugRate, const DivConfig& flags) {
|
||||
|
|
|
@ -91,7 +91,7 @@ class DivPlatformSegaPCM: public DivDispatch {
|
|||
void notifyInsChange(int ins);
|
||||
void renderSamples(int chipID);
|
||||
void setFlags(const DivConfig& flags);
|
||||
bool isStereo();
|
||||
int getOutputCount();
|
||||
void poke(unsigned int addr, unsigned short val);
|
||||
void poke(std::vector<DivRegWrite>& wlist);
|
||||
int init(DivEngine* parent, int channels, int sugRate, const DivConfig& flags);
|
||||
|
|
|
@ -444,8 +444,8 @@ void DivPlatformSMS::reset() {
|
|||
}
|
||||
}
|
||||
|
||||
bool DivPlatformSMS::isStereo() {
|
||||
return stereo;
|
||||
int DivPlatformSMS::getOutputCount() {
|
||||
return stereo?2:1;
|
||||
}
|
||||
|
||||
bool DivPlatformSMS::keyOffAffectsArp(int ch) {
|
||||
|
|
|
@ -78,7 +78,7 @@ class DivPlatformSMS: public DivDispatch {
|
|||
void forceIns();
|
||||
void tick(bool sysTick=true);
|
||||
void muteChannel(int ch, bool mute);
|
||||
bool isStereo();
|
||||
int getOutputCount();
|
||||
bool keyOffAffectsArp(int ch);
|
||||
bool keyOffAffectsPorta(int ch);
|
||||
int getPortaFloor(int ch);
|
||||
|
|
|
@ -768,8 +768,8 @@ void DivPlatformSNES::reset() {
|
|||
initEcho();
|
||||
}
|
||||
|
||||
bool DivPlatformSNES::isStereo() {
|
||||
return true;
|
||||
int DivPlatformSNES::getOutputCount() {
|
||||
return 2;
|
||||
}
|
||||
|
||||
void DivPlatformSNES::notifyInsChange(int ins) {
|
||||
|
|
|
@ -104,7 +104,7 @@ class DivPlatformSNES: public DivDispatch {
|
|||
void forceIns();
|
||||
void tick(bool sysTick=true);
|
||||
void muteChannel(int ch, bool mute);
|
||||
bool isStereo();
|
||||
int getOutputCount();
|
||||
void notifyInsChange(int ins);
|
||||
void notifyWaveChange(int wave);
|
||||
void setFlags(const DivConfig& flags);
|
||||
|
|
|
@ -499,8 +499,8 @@ void DivPlatformSoundUnit::reset() {
|
|||
rWrite(0xbd,fil1);
|
||||
}
|
||||
|
||||
bool DivPlatformSoundUnit::isStereo() {
|
||||
return true;
|
||||
int DivPlatformSoundUnit::getOutputCount() {
|
||||
return 2;
|
||||
}
|
||||
|
||||
bool DivPlatformSoundUnit::keyOffAffectsArp(int ch) {
|
||||
|
|
|
@ -109,7 +109,7 @@ class DivPlatformSoundUnit: public DivDispatch {
|
|||
void forceIns();
|
||||
void tick(bool sysTick=true);
|
||||
void muteChannel(int ch, bool mute);
|
||||
bool isStereo();
|
||||
int getOutputCount();
|
||||
bool keyOffAffectsArp(int ch);
|
||||
void setFlags(const DivConfig& flags);
|
||||
void notifyInsDeletion(void* ins);
|
||||
|
|
|
@ -490,8 +490,8 @@ void DivPlatformSwan::reset() {
|
|||
rWrite(0x11,0x09); // enable speakers
|
||||
}
|
||||
|
||||
bool DivPlatformSwan::isStereo() {
|
||||
return true;
|
||||
int DivPlatformSwan::getOutputCount() {
|
||||
return 2;
|
||||
}
|
||||
|
||||
void DivPlatformSwan::notifyWaveChange(int wave) {
|
||||
|
|
|
@ -69,7 +69,7 @@ class DivPlatformSwan: public DivDispatch {
|
|||
void muteChannel(int ch, bool mute);
|
||||
void notifyWaveChange(int wave);
|
||||
void notifyInsDeletion(void* ins);
|
||||
bool isStereo();
|
||||
int getOutputCount();
|
||||
void poke(unsigned int addr, unsigned short val);
|
||||
void poke(std::vector<DivRegWrite>& wlist);
|
||||
const char** getRegisterSheet();
|
||||
|
|
|
@ -335,8 +335,8 @@ void DivPlatformT6W28::reset() {
|
|||
rWrite(1,0xe7);
|
||||
}
|
||||
|
||||
bool DivPlatformT6W28::isStereo() {
|
||||
return true;
|
||||
int DivPlatformT6W28::getOutputCount() {
|
||||
return 2;
|
||||
}
|
||||
|
||||
bool DivPlatformT6W28::keyOffAffectsArp(int ch) {
|
||||
|
|
|
@ -70,7 +70,7 @@ class DivPlatformT6W28: public DivDispatch {
|
|||
void forceIns();
|
||||
void tick(bool sysTick=true);
|
||||
void muteChannel(int ch, bool mute);
|
||||
bool isStereo();
|
||||
int getOutputCount();
|
||||
bool keyOffAffectsArp(int ch);
|
||||
void setFlags(const DivConfig& flags);
|
||||
void notifyInsDeletion(void* ins);
|
||||
|
|
|
@ -342,8 +342,8 @@ float DivPlatformTIA::getPostAmp() {
|
|||
return 0.5f;
|
||||
}
|
||||
|
||||
bool DivPlatformTIA::isStereo() {
|
||||
return (mixingType==2);
|
||||
int DivPlatformTIA::getOutputCount() {
|
||||
return (mixingType==2)?2:1;
|
||||
}
|
||||
|
||||
bool DivPlatformTIA::keyOffAffectsArp(int ch) {
|
||||
|
|
|
@ -58,7 +58,7 @@ class DivPlatformTIA: public DivDispatch {
|
|||
void muteChannel(int ch, bool mute);
|
||||
void setFlags(const DivConfig& flags);
|
||||
float getPostAmp();
|
||||
bool isStereo();
|
||||
int getOutputCount();
|
||||
bool keyOffAffectsArp(int ch);
|
||||
void notifyInsDeletion(void* ins);
|
||||
void poke(unsigned int addr, unsigned short val);
|
||||
|
|
|
@ -947,8 +947,8 @@ void DivPlatformTX81Z::setFlags(const DivConfig& flags) {
|
|||
}
|
||||
}
|
||||
|
||||
bool DivPlatformTX81Z::isStereo() {
|
||||
return true;
|
||||
int DivPlatformTX81Z::getOutputCount() {
|
||||
return 2;
|
||||
}
|
||||
|
||||
int DivPlatformTX81Z::init(DivEngine* p, int channels, int sugRate, const DivConfig& flags) {
|
||||
|
|
|
@ -73,7 +73,7 @@ class DivPlatformTX81Z: public DivPlatformOPM {
|
|||
void muteChannel(int ch, bool mute);
|
||||
void notifyInsChange(int ins);
|
||||
void setFlags(const DivConfig& flags);
|
||||
bool isStereo();
|
||||
int getOutputCount();
|
||||
void poke(unsigned int addr, unsigned short val);
|
||||
void poke(std::vector<DivRegWrite>& wlist);
|
||||
const char** getRegisterSheet();
|
||||
|
|
|
@ -465,8 +465,8 @@ void DivPlatformVB::reset() {
|
|||
delay=500;
|
||||
}
|
||||
|
||||
bool DivPlatformVB::isStereo() {
|
||||
return true;
|
||||
int DivPlatformVB::getOutputCount() {
|
||||
return 2;
|
||||
}
|
||||
|
||||
bool DivPlatformVB::keyOffAffectsArp(int ch) {
|
||||
|
|
|
@ -76,7 +76,7 @@ class DivPlatformVB: public DivDispatch {
|
|||
void forceIns();
|
||||
void tick(bool sysTick=true);
|
||||
void muteChannel(int ch, bool mute);
|
||||
bool isStereo();
|
||||
int getOutputCount();
|
||||
bool keyOffAffectsArp(int ch);
|
||||
float getPostAmp();
|
||||
void setFlags(const DivConfig& flags);
|
||||
|
|
|
@ -406,8 +406,8 @@ float DivPlatformVERA::getPostAmp() {
|
|||
return 4.0f;
|
||||
}
|
||||
|
||||
bool DivPlatformVERA::isStereo() {
|
||||
return true;
|
||||
int DivPlatformVERA::getOutputCount() {
|
||||
return 2;
|
||||
}
|
||||
|
||||
void DivPlatformVERA::notifyInsDeletion(void* ins) {
|
||||
|
|
|
@ -72,7 +72,7 @@ class DivPlatformVERA: public DivDispatch {
|
|||
void muteChannel(int ch, bool mute);
|
||||
void notifyInsDeletion(void* ins);
|
||||
float getPostAmp();
|
||||
bool isStereo();
|
||||
int getOutputCount();
|
||||
void poke(unsigned int addr, unsigned short val);
|
||||
void poke(std::vector<DivRegWrite>& wlist);
|
||||
const char** getRegisterSheet();
|
||||
|
|
|
@ -299,8 +299,8 @@ void DivPlatformVIC20::reset() {
|
|||
vic_sound_clock(vic,4);
|
||||
}
|
||||
|
||||
bool DivPlatformVIC20::isStereo() {
|
||||
return false;
|
||||
int DivPlatformVIC20::getOutputCount() {
|
||||
return 1;
|
||||
}
|
||||
|
||||
void DivPlatformVIC20::notifyInsDeletion(void* ins) {
|
||||
|
|
|
@ -56,7 +56,7 @@ class DivPlatformVIC20: public DivDispatch {
|
|||
void muteChannel(int ch, bool mute);
|
||||
void setFlags(const DivConfig& flags);
|
||||
void notifyInsDeletion(void* ins);
|
||||
bool isStereo();
|
||||
int getOutputCount();
|
||||
void poke(unsigned int addr, unsigned short val);
|
||||
void poke(std::vector<DivRegWrite>& wlist);
|
||||
const char** getRegisterSheet();
|
||||
|
|
|
@ -894,8 +894,8 @@ void DivPlatformX1_010::reset() {
|
|||
}
|
||||
}
|
||||
|
||||
bool DivPlatformX1_010::isStereo() {
|
||||
return stereo;
|
||||
int DivPlatformX1_010::getOutputCount() {
|
||||
return stereo?2:1;
|
||||
}
|
||||
|
||||
bool DivPlatformX1_010::keyOffAffectsArp(int ch) {
|
||||
|
|
|
@ -138,7 +138,7 @@ class DivPlatformX1_010: public DivDispatch, public vgsound_emu_mem_intf {
|
|||
void forceIns();
|
||||
void tick(bool sysTick=true);
|
||||
void muteChannel(int ch, bool mute);
|
||||
bool isStereo();
|
||||
int getOutputCount();
|
||||
bool keyOffAffectsArp(int ch);
|
||||
void setFlags(const DivConfig& flags);
|
||||
void notifyWaveChange(int wave);
|
||||
|
|
|
@ -967,8 +967,8 @@ void DivPlatformYM2203::reset() {
|
|||
ay->flushWrites();
|
||||
}
|
||||
|
||||
bool DivPlatformYM2203::isStereo() {
|
||||
return false;
|
||||
int DivPlatformYM2203::getOutputCount() {
|
||||
return 1;
|
||||
}
|
||||
|
||||
bool DivPlatformYM2203::keyOffAffectsArp(int ch) {
|
||||
|
|
|
@ -70,7 +70,7 @@ class DivPlatformYM2203: public DivPlatformOPN {
|
|||
void forceIns();
|
||||
void tick(bool sysTick=true);
|
||||
void muteChannel(int ch, bool mute);
|
||||
bool isStereo();
|
||||
int getOutputCount();
|
||||
bool keyOffAffectsArp(int ch);
|
||||
void notifyInsChange(int ins);
|
||||
void notifyInsDeletion(void* ins);
|
||||
|
|
|
@ -1424,8 +1424,8 @@ void DivPlatformYM2608::reset() {
|
|||
ay->flushWrites();
|
||||
}
|
||||
|
||||
bool DivPlatformYM2608::isStereo() {
|
||||
return true;
|
||||
int DivPlatformYM2608::getOutputCount() {
|
||||
return 2;
|
||||
}
|
||||
|
||||
bool DivPlatformYM2608::keyOffAffectsArp(int ch) {
|
||||
|
|
|
@ -85,7 +85,7 @@ class DivPlatformYM2608: public DivPlatformOPN {
|
|||
void forceIns();
|
||||
void tick(bool sysTick=true);
|
||||
void muteChannel(int ch, bool mute);
|
||||
bool isStereo();
|
||||
int getOutputCount();
|
||||
bool keyOffAffectsArp(int ch);
|
||||
void notifyInsChange(int ins);
|
||||
void notifyInsDeletion(void* ins);
|
||||
|
|
|
@ -1372,8 +1372,8 @@ void DivPlatformYM2610::reset() {
|
|||
immWrite(0x1b,0xff); // B
|
||||
}
|
||||
|
||||
bool DivPlatformYM2610::isStereo() {
|
||||
return true;
|
||||
int DivPlatformYM2610::getOutputCount() {
|
||||
return 2;
|
||||
}
|
||||
|
||||
bool DivPlatformYM2610::keyOffAffectsArp(int ch) {
|
||||
|
|
|
@ -53,7 +53,7 @@ class DivPlatformYM2610: public DivPlatformYM2610Base {
|
|||
void forceIns();
|
||||
void tick(bool sysTick=true);
|
||||
void muteChannel(int ch, bool mute);
|
||||
bool isStereo();
|
||||
int getOutputCount();
|
||||
bool keyOffAffectsArp(int ch);
|
||||
void notifyInsChange(int ins);
|
||||
void notifyInsDeletion(void* ins);
|
||||
|
|
|
@ -1443,8 +1443,8 @@ void DivPlatformYM2610B::reset() {
|
|||
ay->flushWrites();
|
||||
}
|
||||
|
||||
bool DivPlatformYM2610B::isStereo() {
|
||||
return true;
|
||||
int DivPlatformYM2610B::getOutputCount() {
|
||||
return 2;
|
||||
}
|
||||
|
||||
bool DivPlatformYM2610B::keyOffAffectsArp(int ch) {
|
||||
|
|
|
@ -49,7 +49,7 @@ class DivPlatformYM2610B: public DivPlatformYM2610Base {
|
|||
void forceIns();
|
||||
void tick(bool sysTick=true);
|
||||
void muteChannel(int ch, bool mute);
|
||||
bool isStereo();
|
||||
int getOutputCount();
|
||||
bool keyOffAffectsArp(int ch);
|
||||
void notifyInsChange(int ins);
|
||||
void notifyInsDeletion(void* ins);
|
||||
|
|
|
@ -119,8 +119,8 @@ class DivPlatformYM2610Base: public DivPlatformOPN {
|
|||
}
|
||||
}
|
||||
|
||||
bool isStereo() {
|
||||
return true;
|
||||
int getOutputCount() {
|
||||
return 2;
|
||||
}
|
||||
|
||||
const void* getSampleMem(int index) {
|
||||
|
|
|
@ -372,8 +372,8 @@ void DivPlatformYMZ280B::reset() {
|
|||
}
|
||||
}
|
||||
|
||||
bool DivPlatformYMZ280B::isStereo() {
|
||||
return true;
|
||||
int DivPlatformYMZ280B::getOutputCount() {
|
||||
return 2;
|
||||
}
|
||||
|
||||
void DivPlatformYMZ280B::notifyInsChange(int ins) {
|
||||
|
|
|
@ -68,7 +68,7 @@ class DivPlatformYMZ280B: public DivDispatch {
|
|||
void tick(bool sysTick=true);
|
||||
void muteChannel(int ch, bool mute);
|
||||
float getPostAmp();
|
||||
bool isStereo();
|
||||
int getOutputCount();
|
||||
void setChipModel(int type);
|
||||
void notifyInsChange(int ins);
|
||||
void notifyWaveChange(int wave);
|
||||
|
|
Loading…
Reference in a new issue