Reduce duplicates of channel struct
Add/Fix custom clock limit defines (for YMF278B)
This commit is contained in:
parent
fd3f381bc3
commit
2ec4237076
69 changed files with 457 additions and 1151 deletions
|
|
@ -26,14 +26,11 @@
|
|||
#include "sound/ymz280b.h"
|
||||
|
||||
class DivPlatformYMZ280B: public DivDispatch {
|
||||
struct Channel {
|
||||
int freq, baseFreq, pitch, pitch2;
|
||||
struct Channel: public SharedChannelFreq, public SharedChannelVolume<int> {
|
||||
unsigned int audPos;
|
||||
int sample, wave, ins;
|
||||
int note;
|
||||
int sample, wave;
|
||||
int panning;
|
||||
bool active, insChanged, freqChanged, keyOn, keyOff, inPorta, setPos, isNewYMZ;
|
||||
int vol, outVol;
|
||||
bool setPos, isNewYMZ;
|
||||
int macroVolMul;
|
||||
DivMacroInt std;
|
||||
void macroInit(DivInstrument* which) {
|
||||
|
|
@ -41,25 +38,13 @@ class DivPlatformYMZ280B: public DivDispatch {
|
|||
pitch2=0;
|
||||
}
|
||||
Channel():
|
||||
freq(0),
|
||||
baseFreq(0),
|
||||
pitch(0),
|
||||
pitch2(0),
|
||||
SharedChannelFreq(),
|
||||
SharedChannelVolume<int>(255),
|
||||
audPos(0),
|
||||
sample(-1),
|
||||
ins(-1),
|
||||
note(0),
|
||||
panning(8),
|
||||
active(false),
|
||||
insChanged(true),
|
||||
freqChanged(false),
|
||||
keyOn(false),
|
||||
keyOff(false),
|
||||
inPorta(false),
|
||||
setPos(false),
|
||||
isNewYMZ(false),
|
||||
vol(255),
|
||||
outVol(255),
|
||||
macroVolMul(64) {}
|
||||
};
|
||||
Channel chan[8];
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue