more command stream playback work
This commit is contained in:
parent
84e13cc91e
commit
da7d67fa85
4 changed files with 158 additions and 29 deletions
|
|
@ -29,14 +29,41 @@ struct DivCSChannelState {
|
|||
unsigned int readPos;
|
||||
int waitTicks;
|
||||
|
||||
int note, pitch;
|
||||
int volume, volMax, volSpeed;
|
||||
int vibratoDepth, vibratoRate, vibratoPos;
|
||||
int portaTarget, portaSpeed;
|
||||
unsigned char arp, arpStage, arpTicks;
|
||||
|
||||
unsigned int callStack[8];
|
||||
unsigned char callStackPos;
|
||||
|
||||
struct TraceEntry {
|
||||
unsigned int addr;
|
||||
unsigned char length;
|
||||
unsigned char data[11];
|
||||
} trace[32];
|
||||
unsigned char tracePos;
|
||||
|
||||
bool doCall(unsigned int addr);
|
||||
|
||||
DivCSChannelState():
|
||||
readPos(0),
|
||||
waitTicks(0),
|
||||
note(-1),
|
||||
pitch(0),
|
||||
volume(0x7f00),
|
||||
volMax(0),
|
||||
volSpeed(0) {}
|
||||
volSpeed(0),
|
||||
vibratoDepth(0),
|
||||
vibratoRate(0),
|
||||
vibratoPos(0),
|
||||
portaTarget(0),
|
||||
portaSpeed(0),
|
||||
arp(0),
|
||||
arpStage(0),
|
||||
arpTicks(0),
|
||||
callStackPos(0) {}
|
||||
};
|
||||
|
||||
class DivCSPlayer {
|
||||
|
|
@ -46,6 +73,8 @@ class DivCSPlayer {
|
|||
DivCSChannelState chan[DIV_MAX_CHANS];
|
||||
unsigned char fastDelays[16];
|
||||
unsigned char fastCmds[16];
|
||||
|
||||
short vibTable[64];
|
||||
public:
|
||||
void cleanup();
|
||||
bool tick();
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue