savestate and other bugfixes
[fceu.git] / input.h
CommitLineData
c62d2810 1typedef struct {
2 uint8 FP_FASTAPASS(1) (*Read)(int w);
3 void FP_FASTAPASS(1) (*Write)(uint8 v);
4 void FP_FASTAPASS(1) (*Strobe)(int w);
5 void FP_FASTAPASS(3) (*Update)(int w, void *data, int arg);
e328100e 6 void FP_FASTAPASS(3) (*SLHook)(int w, uint8 *bg, uint8 *spr, uint32 linets, int final);
c62d2810 7 void FP_FASTAPASS(3) (*Draw)(int w, uint8 *buf, int arg);
8} INPUTC;
9
10typedef struct {
11 uint8 FP_FASTAPASS(2) (*Read)(int w, uint8 ret);
12 void FP_FASTAPASS(1) (*Write)(uint8 v);
13 void (*Strobe)(void);
14 void FP_FASTAPASS(2) (*Update)(void *data, int arg);
e328100e 15 void FP_FASTAPASS(3) (*SLHook)(uint8 *bg, uint8 *spr, uint32 linets, int final);
c62d2810 16 void FP_FASTAPASS(2) (*Draw)(uint8 *buf, int arg);
17} INPUTCFC;
18
19void DrawInput(uint8 *buf);
20void UpdateInput(void);
21void InitializeInput(void);
22extern void (*PStrobe[2])(void);
e328100e 23extern void (*InputScanlineHook)(uint8 *bg, uint8 *spr, uint32 linets, int final);
890e37ba 24
b547bda7 25#define FCEUNPCMD_RESET 0x01
26#define FCEUNPCMD_POWER 0x02
27
28#define FCEUNPCMD_VSUNICOIN 0x07
29#define FCEUNPCMD_VSUNIDIP0 0x08
30#define FCEUNPCMD_FDSINSERT 0x18
31#define FCEUNPCMD_FDSSELECT 0x1A
890e37ba 32void FCEU_DoSimpleCommand(int cmd);
33
d97315ac 34void FCEUI_FDSSelect(void);
35int FCEUI_FDSInsert(void);
36void FCEUI_VSUniToggleDIP(int w);
37void FCEUI_VSUniCoin(void);
38void FCEUI_ResetNES(void);
39void FCEUI_PowerNES(void);
40