chip flags rewrite, part 4 - DO NOT USE

the next part is to drop systemFlagsOld completely
and then to fix the GUI
This commit is contained in:
tildearrow 2022-09-29 20:13:40 -05:00
parent ee6e0aa0e0
commit 48db9a1d0c
109 changed files with 532 additions and 377 deletions

View file

@ -761,9 +761,9 @@ void DivPlatformAY8930::poke(std::vector<DivRegWrite>& wlist) {
for (DivRegWrite& i: wlist) immWrite(i.addr,i.val);
}
void DivPlatformAY8930::setFlags(unsigned int flags) {
clockSel=(flags>>7)&1;
switch (flags&15) {
void DivPlatformAY8930::setFlags(const DivConfig& flags) {
clockSel=flags.getBool("halfClock",false);
switch (flags.getInt("clockSel",0)) {
case 1:
chipClock=COLOR_PAL*2.0/5.0;
break;
@ -809,11 +809,11 @@ void DivPlatformAY8930::setFlags(unsigned int flags) {
oscBuf[i]->rate=rate;
}
stereo=(flags>>6)&1;
stereoSep=(flags>>8)&255;
stereo=flags.getBool("stereo",false);
stereoSep=flags.getInt("stereoSep",0)&255;
}
int DivPlatformAY8930::init(DivEngine* p, int channels, int sugRate, unsigned int flags) {
int DivPlatformAY8930::init(DivEngine* p, int channels, int sugRate, const DivConfig& flags) {
parent=p;
dumpWrites=false;
skipRegisterWrites=false;