summaryrefslogtreecommitdiffstatshomepage
path: root/src/mame/includes/taitojc.h
blob: 260ac39d99a392441c096717369c0d6cecd395c6 (plain) (blame)
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
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
#include "video/poly.h"

class taitojc_state : public driver_device
{
public:
	taitojc_state(const machine_config &mconfig, device_type type, const char *tag)
		: driver_device(mconfig, type, tag) { }

	int m_texture_x;
	int m_texture_y;

	UINT32 m_dsp_rom_pos;
	UINT16 m_dsp_tex_address;
	UINT16 m_dsp_tex_offset;


	int m_first_dsp_reset;
	int m_viewport_data[3];

	INT32 m_projected_point_x;
	INT32 m_projected_point_y;
	INT32 m_projection_data[3];

	INT32 m_intersection_data[3];

	UINT8 *m_texture;
	bitmap_t *m_framebuffer;
	bitmap_t *m_zbuffer;

	UINT32 *m_vram;
	UINT32 *m_objlist;

	//int debug_tex_pal;

	int m_gfx_index;

	UINT32 *m_char_ram;
	UINT32 *m_tile_ram;
	tilemap_t *m_tilemap;

	poly_manager *m_poly;

	UINT32 *m_f3_shared_ram;
	UINT32 *m_main_ram;
	UINT16 *m_dsp_shared_ram;
	UINT32 *m_palette_ram;

	UINT16 *m_polygon_fifo;
	int m_polygon_fifo_ptr;

	UINT8 m_mcu_comm_main;
	UINT8 m_mcu_comm_hc11;
	UINT8 m_mcu_data_main;
	UINT8 m_mcu_data_hc11;

	UINT16 m_debug_dsp_ram[0x8000];

	UINT8 m_has_dsp_hack;

	double m_speed_meter;
	UINT16 m_break_meter;
};


/*----------- defined in video/taitojc.c -----------*/

READ32_HANDLER(taitojc_tile_r);
WRITE32_HANDLER(taitojc_tile_w);
READ32_HANDLER(taitojc_char_r);
WRITE32_HANDLER(taitojc_char_w);
void taitojc_clear_frame(running_machine &machine);
void taitojc_render_polygons(running_machine &machine, UINT16 *polygon_fifo, int length);

VIDEO_START(taitojc);
SCREEN_UPDATE(taitojc);