-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathvdp.h
53 lines (48 loc) · 1.51 KB
/
vdp.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
#ifndef _VDP_H_
#define _VDP_H_
/* Global variables */
extern uint8 sat[0x400];
extern uint8 vram[0x10000];
extern uint8 cram[0x80];
extern uint8 vsram[0x80];
extern uint8 reg[0x20];
extern uint16 status;
extern uint16 ntab;
extern uint16 ntbb;
extern uint16 ntwb;
extern uint16 satb;
extern uint16 hscb;
extern uint8 is_color_dirty;
extern uint8 color_dirty[0x40];
extern uint8 border;
extern uint8 is_border_dirty;
extern uint8 bg_name_dirty[0x800];
extern uint16 bg_name_list[0x800];
extern uint16 bg_list_index;
extern uint8 bg_pattern_cache[0x80000];
extern uint8 playfield_shift;
extern uint8 playfield_col_mask;
extern uint16 playfield_row_mask;
extern uint32 y_mask;
extern int vint_pending;
extern int hint_pending;
extern int scanline;
extern int counter;
extern int im2_flag;
extern int frame_end;
extern int v_counter, v_update;
extern void (*color_update)(int index, uint16 data);
/* Function prototypes */
void vdp_init(void);
void vdp_reset(void);
void vdp_shutdown(void);
void vdp_ctrl_w(uint16 data);
uint16 vdp_ctrl_r(void);
void vdp_data_w(uint16 data);
uint16 vdp_data_r(void);
void vdp_reg_w(uint8 r, uint8 d);
uint16 vdp_hvc_r(void);
void dma_copy(void);
void dma_vbus(void);
void vdp_test_w(uint16 value);
#endif /* _VDP_H_ */