summaryrefslogtreecommitdiffstatshomepage
path: root/src/mame/drivers/sandscrp.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/mame/drivers/sandscrp.c')
-rw-r--r--src/mame/drivers/sandscrp.c20
1 files changed, 10 insertions, 10 deletions
diff --git a/src/mame/drivers/sandscrp.c b/src/mame/drivers/sandscrp.c
index 42e97c5a285..4d59798f675 100644
--- a/src/mame/drivers/sandscrp.c
+++ b/src/mame/drivers/sandscrp.c
@@ -109,13 +109,14 @@ public:
DECLARE_READ8_MEMBER(sandscrp_soundlatch_r);
DECLARE_WRITE8_MEMBER(sandscrp_soundlatch_w);
virtual void machine_reset();
+ UINT32 screen_update_sandscrp(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
+ void screen_eof_sandscrp(screen_device &screen, bool state);
};
-SCREEN_UPDATE_IND16( sandscrp )
+UINT32 sandscrp_state::screen_update_sandscrp(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect)
{
- sandscrp_state *state = screen.machine().driver_data<sandscrp_state>();
device_t *pandora = screen.machine().device("pandora");
bitmap.fill(0, cliprect);
@@ -123,11 +124,11 @@ SCREEN_UPDATE_IND16( sandscrp )
screen.machine().priority_bitmap.fill(0, cliprect);
- state->m_view2_0->kaneko16_prepare(bitmap, cliprect);
+ m_view2_0->kaneko16_prepare(bitmap, cliprect);
for ( i = 0; i < 8; i++ )
{
- state->m_view2_0->render_tilemap_chip(bitmap,cliprect,i);
+ m_view2_0->render_tilemap_chip(bitmap,cliprect,i);
}
// copy sprite bitmap to screen
@@ -167,14 +168,13 @@ static INTERRUPT_GEN( sandscrp_interrupt )
}
-static SCREEN_VBLANK( sandscrp )
+void sandscrp_state::screen_eof_sandscrp(screen_device &screen, bool state)
{
// rising edge
- if (vblank_on)
+ if (state)
{
- sandscrp_state *state = screen.machine().driver_data<sandscrp_state>();
device_t *pandora = screen.machine().device("pandora");
- state->m_sprite_irq = 1;
+ m_sprite_irq = 1;
update_irq_state(screen.machine());
pandora_eof(pandora);
}
@@ -515,8 +515,8 @@ static MACHINE_CONFIG_START( sandscrp, sandscrp_state )
MCFG_SCREEN_VBLANK_TIME( ATTOSECONDS_IN_USEC(2500) /* not accurate */ )
MCFG_SCREEN_SIZE(256, 256)
MCFG_SCREEN_VISIBLE_AREA(0, 256-1, 0+16, 256-16-1)
- MCFG_SCREEN_UPDATE_STATIC(sandscrp)
- MCFG_SCREEN_VBLANK_STATIC(sandscrp)
+ MCFG_SCREEN_UPDATE_DRIVER(sandscrp_state, screen_update_sandscrp)
+ MCFG_SCREEN_VBLANK_DRIVER(sandscrp_state, screen_eof_sandscrp)
MCFG_GFXDECODE(sandscrp)
MCFG_PALETTE_LENGTH(2048)