summaryrefslogtreecommitdiffstatshomepage
path: root/src/mame/includes/nitedrvr.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/mame/includes/nitedrvr.h')
-rw-r--r--src/mame/includes/nitedrvr.h54
1 files changed, 32 insertions, 22 deletions
diff --git a/src/mame/includes/nitedrvr.h b/src/mame/includes/nitedrvr.h
index 8e18e2d2330..c10615ad9a3 100644
--- a/src/mame/includes/nitedrvr.h
+++ b/src/mame/includes/nitedrvr.h
@@ -5,6 +5,10 @@
Atari Night Driver hardware
*************************************************************************/
+#ifndef MAME_INCLUDES_NITEDRVR_H
+#define MAME_INCLUDES_NITEDRVR_H
+
+#pragma once
#include "machine/timer.h"
#include "sound/discrete.h"
@@ -21,15 +25,38 @@
class nitedrvr_state : public driver_device
{
public:
- nitedrvr_state(const machine_config &mconfig, device_type type, const char *tag)
- : driver_device(mconfig, type, tag),
+ nitedrvr_state(const machine_config &mconfig, device_type type, const char *tag) :
+ driver_device(mconfig, type, tag),
m_videoram(*this, "videoram"),
m_hvc(*this, "hvc"),
m_maincpu(*this, "maincpu"),
m_discrete(*this, "discrete"),
m_gfxdecode(*this, "gfxdecode"),
- m_palette(*this, "palette"){ }
+ m_palette(*this, "palette")
+ { }
+
+ void nitedrvr(machine_config &config);
+
+protected:
+ DECLARE_READ8_MEMBER(nitedrvr_steering_reset_r);
+ DECLARE_WRITE8_MEMBER(nitedrvr_steering_reset_w);
+ DECLARE_READ8_MEMBER(nitedrvr_in0_r);
+ DECLARE_READ8_MEMBER(nitedrvr_in1_r);
+ DECLARE_WRITE8_MEMBER(nitedrvr_out0_w);
+ DECLARE_WRITE8_MEMBER(nitedrvr_out1_w);
+ DECLARE_WRITE8_MEMBER(nitedrvr_videoram_w);
+ TILE_GET_INFO_MEMBER(get_bg_tile_info);
+ virtual void machine_start() override;
+ virtual void machine_reset() override;
+ virtual void video_start() override;
+ uint32_t screen_update_nitedrvr(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
+ TIMER_DEVICE_CALLBACK_MEMBER(nitedrvr_crash_toggle_callback);
+ void draw_box(bitmap_ind16 &bitmap, const rectangle &cliprect, int bx, int by, int ex, int ey);
+ void draw_roadway(bitmap_ind16 &bitmap, const rectangle &cliprect);
+ int nitedrvr_steering();
+ void nitedrvr_map(address_map &map);
+private:
/* memory pointers */
required_shared_ptr<uint8_t> m_videoram;
required_shared_ptr<uint8_t> m_hvc;
@@ -53,26 +80,9 @@ public:
required_device<discrete_device> m_discrete;
required_device<gfxdecode_device> m_gfxdecode;
required_device<palette_device> m_palette;
-
- DECLARE_READ8_MEMBER(nitedrvr_steering_reset_r);
- DECLARE_WRITE8_MEMBER(nitedrvr_steering_reset_w);
- DECLARE_READ8_MEMBER(nitedrvr_in0_r);
- DECLARE_READ8_MEMBER(nitedrvr_in1_r);
- DECLARE_WRITE8_MEMBER(nitedrvr_out0_w);
- DECLARE_WRITE8_MEMBER(nitedrvr_out1_w);
- DECLARE_WRITE8_MEMBER(nitedrvr_videoram_w);
- TILE_GET_INFO_MEMBER(get_bg_tile_info);
- virtual void machine_start() override;
- virtual void machine_reset() override;
- virtual void video_start() override;
- uint32_t screen_update_nitedrvr(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
- TIMER_DEVICE_CALLBACK_MEMBER(nitedrvr_crash_toggle_callback);
- void draw_box(bitmap_ind16 &bitmap, const rectangle &cliprect, int bx, int by, int ex, int ey);
- void draw_roadway(bitmap_ind16 &bitmap, const rectangle &cliprect);
- int nitedrvr_steering();
- void nitedrvr(machine_config &config);
- void nitedrvr_map(address_map &map);
};
/*----------- defined in audio/nitedrvr.c -----------*/
DISCRETE_SOUND_EXTERN( nitedrvr );
+
+#endif // MAME_INCLUDES_NITEDRVR_H