diff options
Diffstat (limited to 'src/mame/video/atarisy1.c')
-rw-r--r-- | src/mame/video/atarisy1.c | 22 |
1 files changed, 10 insertions, 12 deletions
diff --git a/src/mame/video/atarisy1.c b/src/mame/video/atarisy1.c index e5db4fc3702..c2d5e21ef33 100644 --- a/src/mame/video/atarisy1.c +++ b/src/mame/video/atarisy1.c @@ -92,26 +92,24 @@ static int get_bank(running_machine &machine, UINT8 prom1, UINT8 prom2, int bpp) * *************************************/ -static TILE_GET_INFO( get_alpha_tile_info ) +TILE_GET_INFO_MEMBER(atarisy1_state::get_alpha_tile_info) { - atarisy1_state *state = machine.driver_data<atarisy1_state>(); - UINT16 data = state->m_alpha[tile_index]; + UINT16 data = m_alpha[tile_index]; int code = data & 0x3ff; int color = (data >> 10) & 0x07; int opaque = data & 0x2000; - SET_TILE_INFO(0, code, color, opaque ? TILE_FORCE_LAYER0 : 0); + SET_TILE_INFO_MEMBER(0, code, color, opaque ? TILE_FORCE_LAYER0 : 0); } -static TILE_GET_INFO( get_playfield_tile_info ) +TILE_GET_INFO_MEMBER(atarisy1_state::get_playfield_tile_info) { - atarisy1_state *state = machine.driver_data<atarisy1_state>(); - UINT16 data = state->m_playfield[tile_index]; - UINT16 lookup = state->m_playfield_lookup[((data >> 8) & 0x7f) | (state->m_playfield_tile_bank << 7)]; + UINT16 data = m_playfield[tile_index]; + UINT16 lookup = m_playfield_lookup[((data >> 8) & 0x7f) | (m_playfield_tile_bank << 7)]; int gfxindex = (lookup >> 8) & 15; int code = ((lookup & 0xff) << 8) | (data & 0xff); - int color = 0x20 + (((lookup >> 12) & 15) << state->m_bank_color_shift[gfxindex]); - SET_TILE_INFO(gfxindex, code, color, (data >> 15) & 1); + int color = 0x20 + (((lookup >> 12) & 15) << m_bank_color_shift[gfxindex]); + SET_TILE_INFO_MEMBER(gfxindex, code, color, (data >> 15) & 1); } @@ -171,13 +169,13 @@ VIDEO_START( atarisy1 ) decode_gfx(machine, state->m_playfield_lookup, motable); /* initialize the playfield */ - state->m_playfield_tilemap = tilemap_create(machine, get_playfield_tile_info, TILEMAP_SCAN_ROWS, 8,8, 64,64); + state->m_playfield_tilemap = &machine.tilemap().create(tilemap_get_info_delegate(FUNC(atarisy1_state::get_playfield_tile_info),state), TILEMAP_SCAN_ROWS, 8,8, 64,64); /* initialize the motion objects */ atarimo_init(machine, 0, &modesc); /* initialize the alphanumerics */ - state->m_alpha_tilemap = tilemap_create(machine, get_alpha_tile_info, TILEMAP_SCAN_ROWS, 8,8, 64,32); + state->m_alpha_tilemap = &machine.tilemap().create(tilemap_get_info_delegate(FUNC(atarisy1_state::get_alpha_tile_info),state), TILEMAP_SCAN_ROWS, 8,8, 64,32); state->m_alpha_tilemap->set_transparent_pen(0); /* modify the motion object code lookup */ |