diff options
author | Miodrag Milanovic <mmicko@gmail.com> | 2012-09-18 08:43:04 +0000 |
---|---|---|
committer | Miodrag Milanovic <mmicko@gmail.com> | 2012-09-18 08:43:04 +0000 |
commit | 7e40ce54f21d854327fbe56a5c989014602462ff (patch) | |
tree | 310b268b8424a7eb6b8bffd5b87e808b8c7ccb5e /src/mess/video | |
parent | 8196b6177882559f277b0688f4f210e352cce6be (diff) |
changed most of screen.machine() to machine() (no whatsnew)
Diffstat (limited to 'src/mess/video')
40 files changed, 121 insertions, 121 deletions
diff --git a/src/mess/video/ac1.c b/src/mess/video/ac1.c index e7fd46ddd62..74effeeb62c 100644 --- a/src/mess/video/ac1.c +++ b/src/mess/video/ac1.c @@ -29,14 +29,14 @@ void ac1_state::video_start() UINT32 ac1_state::screen_update_ac1(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect) { int x,y; - address_space &space = *screen.machine().device("maincpu")->memory().space(AS_PROGRAM); + address_space &space = *machine().device("maincpu")->memory().space(AS_PROGRAM); for(y = 0; y < 16; y++ ) { for(x = 0; x < 64; x++ ) { int code = space.read_byte(AC1_VIDEO_MEMORY + x + y*64); - drawgfx_opaque(bitmap, cliprect, screen.machine().gfx[0], code , 0, 0,0, 63*6-x*6,15*8-y*8); + drawgfx_opaque(bitmap, cliprect, machine().gfx[0], code , 0, 0,0, 63*6-x*6,15*8-y*8); } } return 0; @@ -45,14 +45,14 @@ UINT32 ac1_state::screen_update_ac1(screen_device &screen, bitmap_ind16 &bitmap, UINT32 ac1_state::screen_update_ac1_32(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect) { int x,y; - address_space &space = *screen.machine().device("maincpu")->memory().space(AS_PROGRAM); + address_space &space = *machine().device("maincpu")->memory().space(AS_PROGRAM); for(y = 0; y < 32; y++ ) { for(x = 0; x < 64; x++ ) { int code = space.read_byte(AC1_VIDEO_MEMORY + x + y*64); - drawgfx_opaque(bitmap, cliprect, screen.machine().gfx[0], code , 0, 0,0, 63*6-x*6,31*8-y*8); + drawgfx_opaque(bitmap, cliprect, machine().gfx[0], code , 0, 0,0, 63*6-x*6,31*8-y*8); } } return 0; diff --git a/src/mess/video/apple1.c b/src/mess/video/apple1.c index 428db6b6002..aef42f7cd9c 100644 --- a/src/mess/video/apple1.c +++ b/src/mess/video/apple1.c @@ -393,7 +393,7 @@ static void apple1_vh_cursor_blink (running_machine &machine) UINT32 apple1_state::screen_update_apple1(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect) { - apple1_vh_cursor_blink(screen.machine()); - terminal_draw(screen.machine(), bitmap, cliprect, m_terminal); + apple1_vh_cursor_blink(machine()); + terminal_draw(machine(), bitmap, cliprect, m_terminal); return 0; } diff --git a/src/mess/video/apple2.c b/src/mess/video/apple2.c index 0f5e170b6af..f40edc079df 100644 --- a/src/mess/video/apple2.c +++ b/src/mess/video/apple2.c @@ -478,7 +478,7 @@ UINT32 apple2_state::screen_update_apple2(screen_device &screen, bitmap_ind16 &b UINT32 new_a2; /* calculate the m_flash value */ - m_flash = ((screen.machine().time() * 4).seconds & 1) ? 1 : 0; + m_flash = ((machine().time() * 4).seconds & 1) ? 1 : 0; /* read out relevant softswitch variables; to see what has changed */ new_a2 = effective_a2(this); diff --git a/src/mess/video/apple3.c b/src/mess/video/apple3.c index f14c2c1cd3e..c4b0b0f6ccf 100644 --- a/src/mess/video/apple3.c +++ b/src/mess/video/apple3.c @@ -369,28 +369,28 @@ UINT32 apple3_state::screen_update_apple3(screen_device &screen, bitmap_ind16 &b { case 0: case VAR_VM0: - apple3_video_text40(screen.machine(),bitmap); + apple3_video_text40(machine(),bitmap); break; case VAR_VM1: case VAR_VM1|VAR_VM0: - apple3_video_text80(screen.machine(),bitmap); + apple3_video_text80(machine(),bitmap); break; case VAR_VM3: - apple3_video_graphics_hgr(screen.machine(),bitmap); /* hgr mode */ + apple3_video_graphics_hgr(machine(),bitmap); /* hgr mode */ break; case VAR_VM3|VAR_VM0: - apple3_video_graphics_chgr(screen.machine(),bitmap); + apple3_video_graphics_chgr(machine(),bitmap); break; case VAR_VM3|VAR_VM1: - apple3_video_graphics_shgr(screen.machine(),bitmap); + apple3_video_graphics_shgr(machine(),bitmap); break; case VAR_VM3|VAR_VM1|VAR_VM0: - apple3_video_graphics_chires(screen.machine(),bitmap); + apple3_video_graphics_chires(machine(),bitmap); break; } return 0; diff --git a/src/mess/video/b2m.c b/src/mess/video/b2m.c index f1d3b4b972f..95bf24a6f7b 100644 --- a/src/mess/video/b2m.c +++ b/src/mess/video/b2m.c @@ -21,7 +21,7 @@ UINT32 b2m_state::screen_update_b2m(screen_device &screen, bitmap_ind16 &bitmap, UINT8 code2; UINT8 col; int y, x, b; - UINT8 *ram = screen.machine().device<ram_device>(RAM_TAG)->pointer(); + UINT8 *ram = machine().device<ram_device>(RAM_TAG)->pointer(); for (x = 0; x < 48; x++) { diff --git a/src/mess/video/bbc.c b/src/mess/video/bbc.c index 7a8530fadf7..18688fc56b1 100644 --- a/src/mess/video/bbc.c +++ b/src/mess/video/bbc.c @@ -640,7 +640,7 @@ WRITE8_MEMBER(bbc_state::bbc_6845_w) UINT32 bbc_state::screen_update_bbc(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect) { - mc6845_device *mc6845 = screen.machine().device<mc6845_device>("mc6845"); + mc6845_device *mc6845 = machine().device<mc6845_device>("mc6845"); mc6845->update( bitmap, cliprect); return 0; @@ -665,7 +665,7 @@ UINT32 bbc_state::screen_update_bbc(screen_device &screen, bitmap_ind16 &bitmap, while((m_BBC_VSync)&&(c<60000)) { // Clock the 6845 - m6845_clock(screen.machine()); + m6845_clock(machine()); c++; } @@ -674,13 +674,13 @@ UINT32 bbc_state::screen_update_bbc(screen_device &screen, bitmap_ind16 &bitmap, // or until a timeout (this catches the 6845 with silly register values that would not give a VSYNC signal) while((!m_BBC_VSync)&&(c<60000)) { - if ((m_y_screen_pos>=cliprect.min_y) && (m_y_screen_pos<=cliprect.max_y)) (m_draw_function)(screen.machine()); + if ((m_y_screen_pos>=cliprect.min_y) && (m_y_screen_pos<=cliprect.max_y)) (m_draw_function)(machine()); // and check the cursor if (m_VideoULA_CR) BBC_Clock_CR(this); // Clock the 6845 - m6845_clock(screen.machine()); + m6845_clock(machine()); c++; } diff --git a/src/mess/video/cgenie.c b/src/mess/video/cgenie.c index c63085a5ef3..800838b8f5a 100644 --- a/src/mess/video/cgenie.c +++ b/src/mess/video/cgenie.c @@ -413,8 +413,8 @@ static void cgenie_refresh_tv_set(running_machine &machine, bitmap_ind16 &bitmap UINT32 cgenie_state::screen_update_cgenie(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect) { if( m_tv_mode ) - cgenie_refresh_tv_set(screen.machine(), bitmap, cliprect); + cgenie_refresh_tv_set(machine(), bitmap, cliprect); else - cgenie_refresh_monitor(screen.machine(), bitmap, cliprect); + cgenie_refresh_monitor(machine(), bitmap, cliprect); return 0; } diff --git a/src/mess/video/dai.c b/src/mess/video/dai.c index edd6e947ece..43340b568ea 100644 --- a/src/mess/video/dai.c +++ b/src/mess/video/dai.c @@ -57,7 +57,7 @@ void dai_state::video_start() UINT32 dai_state::screen_update_dai(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect) { - address_space &space = *screen.machine().device("maincpu")->memory().space(AS_PROGRAM); + address_space &space = *machine().device("maincpu")->memory().space(AS_PROGRAM); int i, j, k, l; UINT8* char_rom = memregion("gfx1")->base(); diff --git a/src/mess/video/fmtowns.c b/src/mess/video/fmtowns.c index f64385cde2c..361efeb146c 100644 --- a/src/mess/video/fmtowns.c +++ b/src/mess/video/fmtowns.c @@ -1814,36 +1814,36 @@ UINT32 towns_state::screen_update(screen_device &screen, bitmap_rgb32 &bitmap, c if(!(m_video.towns_video_reg[1] & 0x01)) { - if(!screen.machine().input().code_pressed(KEYCODE_Q)) + if(!machine().input().code_pressed(KEYCODE_Q)) { if((m_video.towns_layer_ctrl & 0x03) != 0) - towns_crtc_draw_layer(screen.machine(),bitmap,&m_video.towns_crtc_layerscr[1],1); + towns_crtc_draw_layer(machine(),bitmap,&m_video.towns_crtc_layerscr[1],1); } - if(!screen.machine().input().code_pressed(KEYCODE_W)) + if(!machine().input().code_pressed(KEYCODE_W)) { if((m_video.towns_layer_ctrl & 0x0c) != 0) - towns_crtc_draw_layer(screen.machine(),bitmap,&m_video.towns_crtc_layerscr[0],0); + towns_crtc_draw_layer(machine(),bitmap,&m_video.towns_crtc_layerscr[0],0); } } else { - if(!screen.machine().input().code_pressed(KEYCODE_Q)) + if(!machine().input().code_pressed(KEYCODE_Q)) { if((m_video.towns_layer_ctrl & 0x0c) != 0) - towns_crtc_draw_layer(screen.machine(),bitmap,&m_video.towns_crtc_layerscr[0],0); + towns_crtc_draw_layer(machine(),bitmap,&m_video.towns_crtc_layerscr[0],0); } - if(!screen.machine().input().code_pressed(KEYCODE_W)) + if(!machine().input().code_pressed(KEYCODE_W)) { if((m_video.towns_layer_ctrl & 0x03) != 0) - towns_crtc_draw_layer(screen.machine(),bitmap,&m_video.towns_crtc_layerscr[1],1); + towns_crtc_draw_layer(machine(),bitmap,&m_video.towns_crtc_layerscr[1],1); } } #if 0 #ifdef SPR_DEBUG - if(screen.machine().input().code_pressed(KEYCODE_O)) + if(machine().input().code_pressed(KEYCODE_O)) pshift+=0x80; - if(screen.machine().input().code_pressed(KEYCODE_I)) + if(machine().input().code_pressed(KEYCODE_I)) pshift-=0x80; popmessage("Pixel shift = %08x",pshift); #endif diff --git a/src/mess/video/galeb.c b/src/mess/video/galeb.c index 8ffc5362f88..c49bafacbe0 100644 --- a/src/mess/video/galeb.c +++ b/src/mess/video/galeb.c @@ -36,7 +36,7 @@ UINT32 galeb_state::screen_update_galeb(screen_device &screen, bitmap_ind16 &bit for(x = 0; x < 48; x++ ) { int code = m_video_ram[15 + x + y*64]; - drawgfx_opaque(bitmap, cliprect, screen.machine().gfx[0], code , 0, 0,0, x*8,y*8); + drawgfx_opaque(bitmap, cliprect, machine().gfx[0], code , 0, 0,0, x*8,y*8); } } return 0; diff --git a/src/mess/video/hec2video.c b/src/mess/video/hec2video.c index b1e72725bfc..c7c7e289f2e 100644 --- a/src/mess/video/hec2video.c +++ b/src/mess/video/hec2video.c @@ -125,18 +125,18 @@ UINT32 hec2hrp_state::screen_update_hec2hrp(screen_device &screen, bitmap_ind16 if (m_hector_flag_80c==0) { screen.set_visible_area(0, 243, 0, 227); - hector_hr( screen.machine(), bitmap , &videoram_HR[0], 227, 64); + hector_hr( machine(), bitmap , &videoram_HR[0], 227, 64); } else { screen.set_visible_area(0, 243*2, 0, 227); - hector_80c( screen.machine(), bitmap , &videoram_HR[0], 227, 64); + hector_80c( machine(), bitmap , &videoram_HR[0], 227, 64); } } else { screen.set_visible_area(0, 113, 0, 75); - hector_hr( screen.machine(), bitmap, videoram, 77, 32); + hector_hr( machine(), bitmap, videoram, 77, 32); } return 0; } diff --git a/src/mess/video/hp48.c b/src/mess/video/hp48.c index 195f2534e20..463cc71be11 100644 --- a/src/mess/video/hp48.c +++ b/src/mess/video/hp48.c @@ -129,8 +129,8 @@ void hp48_state::palette_init() UINT32 hp48_state::screen_update_hp48(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect) { - hp48_state *state = screen.machine().driver_data<hp48_state>(); - address_space &space = *screen.machine().device("maincpu")->memory().space(AS_PROGRAM); + hp48_state *state = machine().driver_data<hp48_state>(); + address_space &space = *machine().device("maincpu")->memory().space(AS_PROGRAM); int x, y, xp, i, addr; int display = HP48_IO_4(0) >> 3; /* 1=on, 0=off */ int left_margin = HP48_IO_4(0) & 7; /* 0..7 pixels for main bitmap */ @@ -142,7 +142,7 @@ UINT32 hp48_state::screen_update_hp48(screen_device &screen, bitmap_ind16 &bitma int menu_start = HP48_IO_20(0x30) & ~1; /* menu bitmap address */ int fg = contrast + 2; - LOG(( "%f hp48 video_update called: ", screen.machine().time().as_double())); + LOG(( "%f hp48 video_update called: ", machine().time().as_double())); if ( !display || refresh ) { diff --git a/src/mess/video/intv.c b/src/mess/video/intv.c index 993a69b45de..b8c090a9fad 100644 --- a/src/mess/video/intv.c +++ b/src/mess/video/intv.c @@ -800,7 +800,7 @@ UINT32 intv_state::screen_update_intvkbd(screen_device &screen, bitmap_ind16 &bi { offs = current_row*64+x; drawgfx_transpen(bitmap, cliprect, - screen.machine().gfx[1], + machine().gfx[1], videoram[offs], 7, /* white */ 0,0, @@ -811,7 +811,7 @@ UINT32 intv_state::screen_update_intvkbd(screen_device &screen, bitmap_ind16 &bi /* draw the cursor as a solid white block */ /* (should use a filled rect here!) */ drawgfx_transpen(bitmap, cliprect, - screen.machine().gfx[1], + machine().gfx[1], 191, /* a block */ 7, /* white */ 0,0, diff --git a/src/mess/video/kramermc.c b/src/mess/video/kramermc.c index a059c141f8f..0335a26b3a2 100644 --- a/src/mess/video/kramermc.c +++ b/src/mess/video/kramermc.c @@ -30,14 +30,14 @@ void kramermc_state::video_start() UINT32 kramermc_state::screen_update_kramermc(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect) { int x,y; - address_space &space = *screen.machine().device("maincpu")->memory().space(AS_PROGRAM); + address_space &space = *machine().device("maincpu")->memory().space(AS_PROGRAM); for(y = 0; y < 16; y++ ) { for(x = 0; x < 64; x++ ) { int code = space.read_byte(KRAMERMC_VIDEO_MEMORY + x + y*64); - drawgfx_opaque(bitmap, cliprect, screen.machine().gfx[0], code , 0, 0,0, x*8,y*8); + drawgfx_opaque(bitmap, cliprect, machine().gfx[0], code , 0, 0,0, x*8,y*8); } } return 0; diff --git a/src/mess/video/mac.c b/src/mess/video/mac.c index 0f973e1b3c8..67d860e7890 100644 --- a/src/mess/video/mac.c +++ b/src/mess/video/mac.c @@ -86,8 +86,8 @@ UINT32 mac_state::screen_update_mac(screen_device &screen, bitmap_ind16 &bitmap, UINT16 *line; int y, x, b; - video_base = screen.machine().device<ram_device>(RAM_TAG)->size() - (m_screen_buffer ? MAC_MAIN_SCREEN_BUF_OFFSET : MAC_ALT_SCREEN_BUF_OFFSET); - video_ram = (const UINT16 *) (screen.machine().device<ram_device>(RAM_TAG)->pointer() + video_base); + video_base = machine().device<ram_device>(RAM_TAG)->size() - (m_screen_buffer ? MAC_MAIN_SCREEN_BUF_OFFSET : MAC_ALT_SCREEN_BUF_OFFSET); + video_ram = (const UINT16 *) (machine().device<ram_device>(RAM_TAG)->pointer() + video_base); for (y = 0; y < MAC_V_VIS; y++) { @@ -373,7 +373,7 @@ UINT32 mac_state::screen_update_macrbv(screen_device &screen, bitmap_rgb32 &bitm { UINT32 *scanline; int x, y, hres, vres; - UINT8 *vram8 = (UINT8 *)screen.machine().device<ram_device>(RAM_TAG)->pointer(); + UINT8 *vram8 = (UINT8 *)machine().device<ram_device>(RAM_TAG)->pointer(); switch (m_rbv_montype) { diff --git a/src/mess/video/mz700.c b/src/mess/video/mz700.c index e10b1dbd201..00ee041cd32 100644 --- a/src/mess/video/mz700.c +++ b/src/mess/video/mz700.c @@ -51,7 +51,7 @@ UINT32 mz_state::screen_update_mz700(screen_device &screen, bitmap_ind16 &bitmap UINT8 *videoram = m_videoram; int offs; - bitmap.fill(get_black_pen(screen.machine()), cliprect); + bitmap.fill(get_black_pen(machine()), cliprect); for(offs = 0; offs < 40*25; offs++) { @@ -63,7 +63,7 @@ UINT32 mz_state::screen_update_mz700(screen_device &screen, bitmap_ind16 &bitmap color = m_colorram[offs]; code = videoram[offs] | (color & 0x80) << 1; - drawgfx_opaque(bitmap, cliprect, screen.machine().gfx[0], code, color, 0, 0, sx, sy); + drawgfx_opaque(bitmap, cliprect, machine().gfx[0], code, color, 0, 0, sx, sy); } return 0; @@ -83,7 +83,7 @@ UINT32 mz_state::screen_update_mz800(screen_device &screen, bitmap_ind16 &bitmap { UINT8 *videoram = m_videoram; - bitmap.fill(get_black_pen(screen.machine()), cliprect); + bitmap.fill(get_black_pen(machine()), cliprect); if (m_mz700_mode) return SCREEN_UPDATE16_CALL_MEMBER(mz700); diff --git a/src/mess/video/nascom1.c b/src/mess/video/nascom1.c index 27e6e8e3662..7dba521bcfa 100644 --- a/src/mess/video/nascom1.c +++ b/src/mess/video/nascom1.c @@ -17,7 +17,7 @@ UINT32 nascom1_state::screen_update_nascom1(screen_device &screen, bitmap_ind16 for (sx = 0; sx < 48; sx++) { drawgfx_opaque (bitmap, cliprect, - screen.machine().gfx[0], videoram[0x03ca + sx], + machine().gfx[0], videoram[0x03ca + sx], 1, 0, 0, sx * 8, 0); } @@ -26,7 +26,7 @@ UINT32 nascom1_state::screen_update_nascom1(screen_device &screen, bitmap_ind16 for (sx = 0; sx < 48; sx++) { drawgfx_opaque (bitmap, cliprect, - screen.machine().gfx[0], videoram[0x000a + (sy * 64) + sx], + machine().gfx[0], videoram[0x000a + (sy * 64) + sx], 1, 0, 0, sx * 8, (sy + 1) * 16); } } @@ -41,7 +41,7 @@ UINT32 nascom1_state::screen_update_nascom2(screen_device &screen, bitmap_ind16 for (sx = 0; sx < 48; sx++) { drawgfx_opaque (bitmap, cliprect, - screen.machine().gfx[0], videoram[0x03ca + sx], + machine().gfx[0], videoram[0x03ca + sx], 1, 0, 0, sx * 8, 0); } @@ -50,7 +50,7 @@ UINT32 nascom1_state::screen_update_nascom2(screen_device &screen, bitmap_ind16 for (sx = 0; sx < 48; sx++) { drawgfx_opaque (bitmap, cliprect, - screen.machine().gfx[0], videoram[0x000a + (sy * 64) + sx], + machine().gfx[0], videoram[0x000a + (sy * 64) + sx], 1, 0, 0, sx * 8, (sy + 1) * 14); } } diff --git a/src/mess/video/nc.c b/src/mess/video/nc.c index e011d6dbfe0..b381e8523e6 100644 --- a/src/mess/video/nc.c +++ b/src/mess/video/nc.c @@ -90,7 +90,7 @@ UINT32 nc_state::screen_update_nc(screen_device &screen, bitmap_ind16 &bitmap, c { int by; /* 64 bytes per line */ - char *line_ptr = ((char*)screen.machine().device<ram_device>(RAM_TAG)->pointer()) + m_display_memory_start + (y<<6); + char *line_ptr = ((char*)machine().device<ram_device>(RAM_TAG)->pointer()) + m_display_memory_start + (y<<6); x = 0; for (by=0; by<width>>3; by++) diff --git a/src/mess/video/nes.c b/src/mess/video/nes.c index be9dc008668..0ff78cb5b77 100644 --- a/src/mess/video/nes.c +++ b/src/mess/video/nes.c @@ -47,7 +47,7 @@ UINT32 nes_state::screen_update_nes(screen_device &screen, bitmap_ind16 &bitmap, if (m_disk_expansion && m_pcb_id == NO_BOARD) { // latch this input so it doesn't go at warp speed - if ((screen.machine().root_device().ioport("FLIPDISK")->read() & 0x01) && (!m_last_frame_flip)) + if ((machine().root_device().ioport("FLIPDISK")->read() & 0x01) && (!m_last_frame_flip)) { m_last_frame_flip = 1; m_fds_current_side++; @@ -60,7 +60,7 @@ UINT32 nes_state::screen_update_nes(screen_device &screen, bitmap_ind16 &bitmap, popmessage("Disk set to side %d", m_fds_current_side); } - if (!(screen.machine().root_device().ioport("FLIPDISK")->read() & 0x01)) + if (!(machine().root_device().ioport("FLIPDISK")->read() & 0x01)) m_last_frame_flip = 0; } return 0; diff --git a/src/mess/video/ondra.c b/src/mess/video/ondra.c index 0e1087def14..5fd0d084526 100644 --- a/src/mess/video/ondra.c +++ b/src/mess/video/ondra.c @@ -29,8 +29,8 @@ UINT32 ondra_state::screen_update_ondra(screen_device &screen, bitmap_ind16 &bit { for (y = 127; y >=0; y--) { - code1 = screen.machine().device<ram_device>(RAM_TAG)->pointer()[0xd700 + Vaddr + 0x80]; - code2 = screen.machine().device<ram_device>(RAM_TAG)->pointer()[0xd700 + Vaddr + 0x00]; + code1 = machine().device<ram_device>(RAM_TAG)->pointer()[0xd700 + Vaddr + 0x80]; + code2 = machine().device<ram_device>(RAM_TAG)->pointer()[0xd700 + Vaddr + 0x00]; for (b = 0; b < 8; b++) { bitmap.pix16(2*y, x*8+b) = ((code1 << b) & 0x80) ? 1 : 0; diff --git a/src/mess/video/oric.c b/src/mess/video/oric.c index c0fc0678dd8..56248001860 100644 --- a/src/mess/video/oric.c +++ b/src/mess/video/oric.c @@ -182,10 +182,10 @@ UINT32 oric_state::screen_update_oric(screen_device &screen, bitmap_ind16 &bitma int x = 0; /* foreground colour white */ - oric_vh_update_attribute(screen.machine(),7); + oric_vh_update_attribute(machine(),7); /* background colour black */ - oric_vh_update_attribute(screen.machine(),(1<<3)); - oric_vh_update_attribute(screen.machine(),(1<<4)); + oric_vh_update_attribute(machine(),(1<<3)); + oric_vh_update_attribute(machine(),(1<<4)); for (byte_offset=0; byte_offset<40; byte_offset++) { @@ -213,12 +213,12 @@ UINT32 oric_state::screen_update_oric(screen_device &screen, bitmap_ind16 &bitma } /* fetch data */ - c = RAM ? RAM[read_addr] : screen.machine().device("maincpu")->memory().space(AS_PROGRAM)->read_byte(read_addr); + c = RAM ? RAM[read_addr] : machine().device("maincpu")->memory().space(AS_PROGRAM)->read_byte(read_addr); /* if bits 6 and 5 are zero, the byte contains a serial attribute */ if ((c & ((1 << 6) | (1 << 5))) == 0) { - oric_vh_update_attribute(screen.machine(), c); + oric_vh_update_attribute(machine(), c); /* display background colour when attribute has been found */ oric_vh_render_6pixels(bitmap, x, y, m_vh_state.active_foreground_colour, m_vh_state.active_background_colour, 0, (c & 0x080)); diff --git a/src/mess/video/orion.c b/src/mess/video/orion.c index 9ea7c54667a..769dca102da 100644 --- a/src/mess/video/orion.c +++ b/src/mess/video/orion.c @@ -24,7 +24,7 @@ UINT32 orion_state::screen_update_orion128(screen_device &screen, bitmap_ind16 & int part1addr = (3-((m_orion128_video_page & 3) | orionproshift)) * 0x4000; int part2addr = part1addr + 0x10000; int video_mode = m_orion128_video_mode & m_video_mode_mask; - UINT8 *ram = screen.machine().device<ram_device>(RAM_TAG)->pointer(); + UINT8 *ram = machine().device<ram_device>(RAM_TAG)->pointer(); for (x = 0; x < m_orion128_video_width; x++) { diff --git a/src/mess/video/p2000m.c b/src/mess/video/p2000m.c index 9b9c874239b..0dfab3498a9 100644 --- a/src/mess/video/p2000m.c +++ b/src/mess/video/p2000m.c @@ -41,7 +41,7 @@ UINT32 p2000t_state::screen_update_p2000m(screen_device &screen, bitmap_ind16 &b if (code < 32) code = 32; } - drawgfxzoom_opaque (bitmap, cliprect, screen.machine().gfx[0], code, + drawgfxzoom_opaque (bitmap, cliprect, machine().gfx[0], code, videoram[offs + 2048] & 0x08 ? 0 : 1, 0, 0, sx, sy, 0x20000, 0x20000); if (videoram[offs] & 0x80) diff --git a/src/mess/video/pcw.c b/src/mess/video/pcw.c index 06bc04b4495..334cf6ff05e 100644 --- a/src/mess/video/pcw.c +++ b/src/mess/video/pcw.c @@ -92,14 +92,14 @@ UINT32 pcw_state::screen_update_pcw(screen_device &screen, bitmap_ind16 &bitmap, x = PCW_BORDER_WIDTH; - roller_ram_ptr = screen.machine().device<ram_device>(RAM_TAG)->pointer() + m_roller_ram_addr + roller_ram_offs; + roller_ram_ptr = machine().device<ram_device>(RAM_TAG)->pointer() + m_roller_ram_addr + roller_ram_offs; /* get line address */ /* b16-14 control which bank the line is to be found in, b13-3 the address in the bank (in 16-byte units), and b2-0 the offset. Thus a roller RAM address bbbxxxxxxxxxxxyyy indicates bank bbb, address 00xxxxxxxxxxx0yyy. */ line_data = ((unsigned char *)roller_ram_ptr)[0] | (((unsigned char *)roller_ram_ptr)[1]<<8); /* calculate address of pixel data */ - line_ptr = screen.machine().device<ram_device>(RAM_TAG)->pointer() + ((line_data & 0x0e000)<<1) + ((line_data & 0x01ff8)<<1) + (line_data & 0x07); + line_ptr = machine().device<ram_device>(RAM_TAG)->pointer() + ((line_data & 0x0e000)<<1) + ((line_data & 0x01ff8)<<1) + (line_data & 0x07); for (by=0; by<90; by++) { diff --git a/src/mess/video/pcw16.c b/src/mess/video/pcw16.c index 19d58460a60..5afe8d05d47 100644 --- a/src/mess/video/pcw16.c +++ b/src/mess/video/pcw16.c @@ -156,7 +156,7 @@ static void pcw16_vh_decode_mode2(pcw16_state *state, bitmap_ind16 &bitmap, int ***************************************************************************/ UINT32 pcw16_state::screen_update_pcw16(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect) { - UINT8 *ram = screen.machine().device<ram_device>(RAM_TAG)->pointer(); + UINT8 *ram = machine().device<ram_device>(RAM_TAG)->pointer(); unsigned char *pScanLine = (unsigned char *)ram + 0x0fc00; //0x03c00; //0x020FC00; int y; diff --git a/src/mess/video/pdp1.c b/src/mess/video/pdp1.c index 6bce0a03b34..7591ee92aa1 100644 --- a/src/mess/video/pdp1.c +++ b/src/mess/video/pdp1.c @@ -91,7 +91,7 @@ UINT32 pdp1_state::screen_update_pdp1(screen_device &screen, bitmap_ind16 &bitma crt_update(m_crt, bitmap); pdp1_draw_lightpen(this, bitmap); - pdp1_draw_panel(screen.machine(), m_panel_bitmap); + pdp1_draw_panel(machine(), m_panel_bitmap); copybitmap(bitmap, m_panel_bitmap, 0, 0, panel_window_offset_x, panel_window_offset_y, cliprect); copybitmap(bitmap, m_typewriter_bitmap, 0, 0, typewriter_window_offset_x, typewriter_window_offset_y, cliprect); diff --git a/src/mess/video/pet.c b/src/mess/video/pet.c index ba246e9e94e..5472b1cd7d8 100644 --- a/src/mess/video/pet.c +++ b/src/mess/video/pet.c @@ -75,7 +75,7 @@ UINT32 pet_state::screen_update_pet(screen_device &screen, bitmap_ind16 &bitmap, { for (x=0;x<40;x++, i++) { - drawgfx_opaque(bitmap, cliprect,screen.machine().gfx[m_font], + drawgfx_opaque(bitmap, cliprect,machine().gfx[m_font], videoram[i], 0, 0, 0, 8*x,8*y); } } diff --git a/src/mess/video/pk8020.c b/src/mess/video/pk8020.c index 107d6436011..b573961796c 100644 --- a/src/mess/video/pk8020.c +++ b/src/mess/video/pk8020.c @@ -19,7 +19,7 @@ UINT32 pk8020_state::screen_update_pk8020(screen_device &screen, bitmap_ind16 &b { int y, x, b, j; UINT8 *gfx = memregion("gfx1")->base(); - UINT8 *ram = screen.machine().device<ram_device>(RAM_TAG)->pointer(); + UINT8 *ram = machine().device<ram_device>(RAM_TAG)->pointer(); for (y = 0; y < 16; y++) { diff --git a/src/mess/video/pp01.c b/src/mess/video/pp01.c index 90d2ee54d07..a74afaf609c 100644 --- a/src/mess/video/pp01.c +++ b/src/mess/video/pp01.c @@ -20,7 +20,7 @@ UINT32 pp01_state::screen_update_pp01(screen_device &screen, bitmap_ind16 &bitma UINT8 code_r,code_g,code_b; UINT8 col; int y, x, b; - UINT8 *ram = screen.machine().device<ram_device>(RAM_TAG)->pointer(); + UINT8 *ram = machine().device<ram_device>(RAM_TAG)->pointer(); for (y = 0; y < 256; y++) { diff --git a/src/mess/video/primo.c b/src/mess/video/primo.c index a1212ae361b..0263922ddca 100644 --- a/src/mess/video/primo.c +++ b/src/mess/video/primo.c @@ -41,6 +41,6 @@ UINT32 primo_state::screen_update_primo(screen_device &screen, bitmap_ind16 &bit int primo_scanline; for (primo_scanline=0; primo_scanline<192; primo_scanline++) - primo_draw_scanline(screen.machine(), bitmap, primo_scanline); + primo_draw_scanline(machine(), bitmap, primo_scanline); return 0; } diff --git a/src/mess/video/radio86.c b/src/mess/video/radio86.c index 5c163fbf97a..1432730d650 100644 --- a/src/mess/video/radio86.c +++ b/src/mess/video/radio86.c @@ -109,7 +109,7 @@ I8275_DISPLAY_PIXELS(partner_display_pixels) UINT32 radio86_state::screen_update_radio86(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect) { - device_t *devconf = screen.machine().device("i8275"); + device_t *devconf = machine().device("i8275"); i8275_update( devconf, bitmap, cliprect); copybitmap(bitmap, m_bitmap, 0, 0, 0, 0, cliprect); return 0; diff --git a/src/mess/video/spectrum.c b/src/mess/video/spectrum.c index 82a6936de54..96d6bcc30f9 100644 --- a/src/mess/video/spectrum.c +++ b/src/mess/video/spectrum.c @@ -74,13 +74,13 @@ void spectrum_state::screen_eof_spectrum(screen_device &screen, bool state) /* Empty event buffer for undisplayed frames noting the last border colour (in case colours are not changed in the next frame). */ - NumItems = spectrum_EventList_NumEvents(screen.machine()); + NumItems = spectrum_EventList_NumEvents(machine()); if (NumItems) { - pItem = spectrum_EventList_GetFirstItem(screen.machine()); - spectrum_border_set_last_color ( screen.machine(), pItem[NumItems-1].Event_Data ); - spectrum_EventList_Reset(screen.machine()); - spectrum_EventList_SetOffsetStartTime ( screen.machine(), screen.machine().firstcpu->attotime_to_cycles(screen.scan_period() * screen.vpos()) ); + pItem = spectrum_EventList_GetFirstItem(machine()); + spectrum_border_set_last_color ( machine(), pItem[NumItems-1].Event_Data ); + spectrum_EventList_Reset(machine()); + spectrum_EventList_SetOffsetStartTime ( machine(), machine().firstcpu->attotime_to_cycles(screen.scan_period() * screen.vpos()) ); logerror ("Event log reset in callback fn.\n"); } } @@ -159,7 +159,7 @@ UINT32 spectrum_state::screen_update_spectrum(screen_device &screen, bitmap_ind1 } } - spectrum_border_draw(screen.machine(), bitmap, full_refresh, + spectrum_border_draw(machine(), bitmap, full_refresh, SPEC_TOP_BORDER, SPEC_DISPLAY_YSIZE, SPEC_BOTTOM_BORDER, SPEC_LEFT_BORDER, SPEC_DISPLAY_XSIZE, SPEC_RIGHT_BORDER, SPEC_LEFT_BORDER_CYCLES, SPEC_DISPLAY_XSIZE_CYCLES, diff --git a/src/mess/video/ssystem3.c b/src/mess/video/ssystem3.c index 086c7ec21a5..68ca76087ac 100644 --- a/src/mess/video/ssystem3.c +++ b/src/mess/video/ssystem3.c @@ -204,7 +204,7 @@ UINT32 ssystem3_state::screen_update_ssystem3(screen_device &screen, bitmap_ind1 ssystem3_draw_led(bitmap, m_lcd.data[3]&1?1:0, ssystem3_led_pos[4].x, ssystem3_led_pos[4].y, '3'); ssystem3_draw_led(bitmap, m_lcd.data[4]&1?1:0, ssystem3_led_pos[4].x, ssystem3_led_pos[4].y, '4'); - if (screen.machine().root_device().ioport("Configuration")->read()&1) { // playfield(optional device) + if (machine().root_device().ioport("Configuration")->read()&1) { // playfield(optional device) static const int lcd_signs_on[]={ 0, // empty 1, // bauer @@ -221,7 +221,7 @@ UINT32 ssystem3_state::screen_update_ssystem3(screen_device &screen, bitmap_ind1 int figure, black; int xp=263+x*22; int yp=55+(y^7)*28; - ssystem3_playfield_getfigure(screen.machine(), x, y, &figure, &black); + ssystem3_playfield_getfigure(machine(), x, y, &figure, &black); ssystem3_draw_led(bitmap, lcd_signs_on[figure]&1?1:0, xp, yp, '6'); ssystem3_draw_led(bitmap, lcd_signs_on[figure]&2?1:0, xp, yp, '8'); ssystem3_draw_led(bitmap, lcd_signs_on[figure]&4?1:0, xp, yp, '9'); diff --git a/src/mess/video/super80.c b/src/mess/video/super80.c index 4f2d0a1c619..0e0984dbac1 100644 --- a/src/mess/video/super80.c +++ b/src/mess/video/super80.c @@ -76,15 +76,15 @@ void super80_state::screen_eof_super80m(screen_device &screen, bool state) if (state) { /* if we chose another palette or colour mode, enable it */ - UINT8 chosen_palette = (screen.machine().root_device().ioport("CONFIG")->read() & 0x60)>>5; // read colour dipswitches + UINT8 chosen_palette = (machine().root_device().ioport("CONFIG")->read() & 0x60)>>5; // read colour dipswitches if (chosen_palette != m_current_palette) // any changes? { m_current_palette = chosen_palette; // save new palette if (!m_current_palette) - palette_set_colors_rgb(screen.machine(), super80_comp_palette); // composite colour + palette_set_colors_rgb(machine(), super80_comp_palette); // composite colour else - palette_set_colors_rgb(screen.machine(), super80_rgb_palette); // rgb and b&w + palette_set_colors_rgb(machine(), super80_rgb_palette); // rgb and b&w } } } @@ -97,7 +97,7 @@ UINT32 super80_state::screen_update_super80(screen_device &screen, bitmap_ind16 output_set_value("cass_led",(m_shared & 0x20) ? 1 : 0); - if ((m_shared & 4) || (!(screen.machine().root_device().ioport("CONFIG")->read() & 4))) /* bit 2 of port F0 is high, OR user turned on config switch */ + if ((m_shared & 4) || (!(machine().root_device().ioport("CONFIG")->read() & 4))) /* bit 2 of port F0 is high, OR user turned on config switch */ screen_on++; for (y = 0; y < 16; y++) @@ -138,7 +138,7 @@ UINT32 super80_state::screen_update_super80d(screen_device &screen, bitmap_ind16 output_set_value("cass_led",(m_shared & 0x20) ? 1 : 0); - if ((m_shared & 4) || (!(screen.machine().root_device().ioport("CONFIG")->read() & 4))) /* bit 2 of port F0 is high, OR user turned on config switch */ + if ((m_shared & 4) || (!(machine().root_device().ioport("CONFIG")->read() & 4))) /* bit 2 of port F0 is high, OR user turned on config switch */ screen_on++; for (y = 0; y < 16; y++) @@ -179,7 +179,7 @@ UINT32 super80_state::screen_update_super80e(screen_device &screen, bitmap_ind16 output_set_value("cass_led",(m_shared & 0x20) ? 1 : 0); - if ((m_shared & 4) || (!(screen.machine().root_device().ioport("CONFIG")->read() & 4))) /* bit 2 of port F0 is high, OR user turned on config switch */ + if ((m_shared & 4) || (!(machine().root_device().ioport("CONFIG")->read() & 4))) /* bit 2 of port F0 is high, OR user turned on config switch */ screen_on++; for (y = 0; y < 16; y++) @@ -216,7 +216,7 @@ UINT32 super80_state::screen_update_super80m(screen_device &screen, bitmap_ind16 { UINT8 y,ra,chr=32,gfx,screen_on=0; UINT16 sy=0,ma=m_vidpg,x; - UINT8 col, bg=0, fg=0, options=screen.machine().root_device().ioport("CONFIG")->read(); + UINT8 col, bg=0, fg=0, options=machine().root_device().ioport("CONFIG")->read(); UINT8 *RAM = memregion("maincpu")->base(); /* get selected character generator */ @@ -384,7 +384,7 @@ UINT32 super80_state::screen_update_super80v(screen_device &screen, bitmap_rgb32 m_framecnt++; m_speed = m_mc6845_reg[10]&0x20, m_flash = m_mc6845_reg[10]&0x40; // cursor modes m_cursor = (m_mc6845_reg[14]<<8) | m_mc6845_reg[15]; // get cursor position - m_s_options=screen.machine().root_device().ioport("CONFIG")->read(); + m_s_options=machine().root_device().ioport("CONFIG")->read(); output_set_value("cass_led",(m_shared & 0x20) ? 1 : 0); m_6845->screen_update(screen, bitmap, cliprect); return 0; diff --git a/src/mess/video/timex.c b/src/mess/video/timex.c index ab23e138c9b..55569c0d43f 100644 --- a/src/mess/video/timex.c +++ b/src/mess/video/timex.c @@ -189,28 +189,28 @@ UINT32 spectrum_state::screen_update_ts2068(screen_device &screen, bitmap_ind16 /* 64 Column mode */ unsigned short inkcolor = (m_port_ff_data & 0x38) >> 3; for (count = 0; count < 192; count++) - ts2068_64col_scanline(screen.machine(),bitmap, count, TS2068_TOP_BORDER, inkcolor); + ts2068_64col_scanline(machine(),bitmap, count, TS2068_TOP_BORDER, inkcolor); } else if ((m_port_ff_data & 7) == 2) { /* Extended Color mode */ for (count = 0; count < 192; count++) - ts2068_hires_scanline(screen.machine(),bitmap, count, TS2068_TOP_BORDER); + ts2068_hires_scanline(machine(),bitmap, count, TS2068_TOP_BORDER); } else if ((m_port_ff_data & 7) == 1) { /* Screen 6000-7aff */ for (count = 0; count < 192; count++) - ts2068_lores_scanline(screen.machine(),bitmap, count, TS2068_TOP_BORDER, 1); + ts2068_lores_scanline(machine(),bitmap, count, TS2068_TOP_BORDER, 1); } else { /* Screen 4000-5aff */ for (count = 0; count < 192; count++) - ts2068_lores_scanline(screen.machine(),bitmap, count, TS2068_TOP_BORDER, 0); + ts2068_lores_scanline(machine(),bitmap, count, TS2068_TOP_BORDER, 0); } - spectrum_border_draw(screen.machine(), bitmap, full_refresh, + spectrum_border_draw(machine(), bitmap, full_refresh, TS2068_TOP_BORDER, SPEC_DISPLAY_YSIZE, TS2068_BOTTOM_BORDER, TS2068_LEFT_BORDER, TS2068_DISPLAY_XSIZE, TS2068_RIGHT_BORDER, SPEC_LEFT_BORDER_CYCLES, SPEC_DISPLAY_XSIZE_CYCLES, @@ -229,28 +229,28 @@ UINT32 spectrum_state::screen_update_tc2048(screen_device &screen, bitmap_ind16 /* 64 Column mode */ unsigned short inkcolor = (m_port_ff_data & 0x38) >> 3; for (count = 0; count < 192; count++) - ts2068_64col_scanline(screen.machine(),bitmap, count, SPEC_TOP_BORDER, inkcolor); + ts2068_64col_scanline(machine(),bitmap, count, SPEC_TOP_BORDER, inkcolor); } else if ((m_port_ff_data & 7) == 2) { /* Extended Color mode */ for (count = 0; count < 192; count++) - ts2068_hires_scanline(screen.machine(),bitmap, count, SPEC_TOP_BORDER); + ts2068_hires_scanline(machine(),bitmap, count, SPEC_TOP_BORDER); } else if ((m_port_ff_data & 7) == 1) { /* Screen 6000-7aff */ for (count = 0; count < 192; count++) - ts2068_lores_scanline(screen.machine(),bitmap, count, SPEC_TOP_BORDER, 1); + ts2068_lores_scanline(machine(),bitmap, count, SPEC_TOP_BORDER, 1); } else { /* Screen 4000-5aff */ for (count = 0; count < 192; count++) - ts2068_lores_scanline(screen.machine(),bitmap, count, SPEC_TOP_BORDER, 0); + ts2068_lores_scanline(machine(),bitmap, count, SPEC_TOP_BORDER, 0); } - spectrum_border_draw(screen.machine(), bitmap, full_refresh, + spectrum_border_draw(machine(), bitmap, full_refresh, SPEC_TOP_BORDER, SPEC_DISPLAY_YSIZE, SPEC_BOTTOM_BORDER, TS2068_LEFT_BORDER, TS2068_DISPLAY_XSIZE, TS2068_RIGHT_BORDER, SPEC_LEFT_BORDER_CYCLES, SPEC_DISPLAY_XSIZE_CYCLES, diff --git a/src/mess/video/tx0.c b/src/mess/video/tx0.c index d1b80896350..8796fec4e49 100644 --- a/src/mess/video/tx0.c +++ b/src/mess/video/tx0.c @@ -77,7 +77,7 @@ UINT32 tx0_state::screen_update_tx0(screen_device &screen, bitmap_ind16 &bitmap, { crt_update(m_crt, bitmap); - tx0_draw_panel(screen.machine(), m_panel_bitmap); + tx0_draw_panel(machine(), m_panel_bitmap); copybitmap(bitmap, m_panel_bitmap, 0, 0, panel_window_offset_x, panel_window_offset_y, cliprect); copybitmap(bitmap, m_typewriter_bitmap, 0, 0, typewriter_window_offset_x, typewriter_window_offset_y, cliprect); diff --git a/src/mess/video/ut88.c b/src/mess/video/ut88.c index 3526d66aca3..e7df67b38a7 100644 --- a/src/mess/video/ut88.c +++ b/src/mess/video/ut88.c @@ -35,7 +35,7 @@ UINT32 ut88_state::screen_update_ut88(screen_device &screen, bitmap_ind16 &bitma { int code = m_p_videoram[ x + y*64 ] & 0x7f; int attr = m_p_videoram[ x+1 + y*64 ] & 0x80; - drawgfx_opaque(bitmap, cliprect, screen.machine().gfx[0], code | attr, 0, 0,0, x*8,y*8); + drawgfx_opaque(bitmap, cliprect, machine().gfx[0], code | attr, 0, 0,0, x*8,y*8); } } return 0; diff --git a/src/mess/video/vector06.c b/src/mess/video/vector06.c index 2bc4e5b6c9e..98b615f3ba6 100644 --- a/src/mess/video/vector06.c +++ b/src/mess/video/vector06.c @@ -19,7 +19,7 @@ UINT32 vector06_state::screen_update_vector06(screen_device &screen, bitmap_ind1 UINT8 code1,code2,code3,code4; UINT8 col; int y, x, b,draw_y; - UINT8 *ram = screen.machine().device<ram_device>(RAM_TAG)->pointer(); + UINT8 *ram = machine().device<ram_device>(RAM_TAG)->pointer(); int width = (m_video_mode==0x00) ? 256 : 512; rectangle screen_area(0,width+64-1,0,256+64-1); diff --git a/src/mess/video/vtech2.c b/src/mess/video/vtech2.c index 5ebb2b2b2ee..e8abfc49601 100644 --- a/src/mess/video/vtech2.c +++ b/src/mess/video/vtech2.c @@ -142,7 +142,7 @@ UINT32 vtech2_state::screen_update_laser(screen_device &screen, bitmap_ind16 &bi sy = BORDER_V/2 + y; sx = BORDER_H/2 + x * 8; code = videoram[offs]; - drawgfx_opaque(bitmap,cliprect,screen.machine().gfx[2],code,color,0,0,sx,sy); + drawgfx_opaque(bitmap,cliprect,machine().gfx[2],code,color,0,0,sx,sy); } } break; @@ -162,7 +162,7 @@ UINT32 vtech2_state::screen_update_laser(screen_device &screen, bitmap_ind16 &bi sx = BORDER_H/2 + x * 16; code = videoram[offs]; color = videoram[offs+1]; - drawgfx_opaque(bitmap,cliprect,screen.machine().gfx[3],code,color,0,0,sx,sy); + drawgfx_opaque(bitmap,cliprect,machine().gfx[3],code,color,0,0,sx,sy); } } break; @@ -181,7 +181,7 @@ UINT32 vtech2_state::screen_update_laser(screen_device &screen, bitmap_ind16 &bi sy = BORDER_V/2 + y; sx = BORDER_H/2 + x * 8; code = videoram[offs]; - drawgfx_opaque(bitmap,cliprect,screen.machine().gfx[5],code,0,0,0,sx,sy); + drawgfx_opaque(bitmap,cliprect,machine().gfx[5],code,0,0,0,sx,sy); } } break; @@ -201,7 +201,7 @@ UINT32 vtech2_state::screen_update_laser(screen_device &screen, bitmap_ind16 &bi sy = BORDER_V/2 + y * 2; sx = BORDER_H/2 + x * 8; code = videoram[offs]; - drawgfx_opaque(bitmap,cliprect,screen.machine().gfx[6],code,0,0,0,sx,sy); + drawgfx_opaque(bitmap,cliprect,machine().gfx[6],code,0,0,0,sx,sy); } } break; @@ -220,7 +220,7 @@ UINT32 vtech2_state::screen_update_laser(screen_device &screen, bitmap_ind16 &bi sy = BORDER_V/2 + y; sx = BORDER_H/2 + x * 16; code = videoram[offs]; - drawgfx_opaque(bitmap,cliprect,screen.machine().gfx[3],code,color,0,0,sx,sy); + drawgfx_opaque(bitmap,cliprect,machine().gfx[3],code,color,0,0,sx,sy); } } break; @@ -240,7 +240,7 @@ UINT32 vtech2_state::screen_update_laser(screen_device &screen, bitmap_ind16 &bi sx = BORDER_H/2 + x * 32; code = videoram[offs]; color = videoram[offs+1]; - drawgfx_opaque(bitmap,cliprect,screen.machine().gfx[4],code,color,0,0,sx,sy); + drawgfx_opaque(bitmap,cliprect,machine().gfx[4],code,color,0,0,sx,sy); } } break; @@ -261,7 +261,7 @@ UINT32 vtech2_state::screen_update_laser(screen_device &screen, bitmap_ind16 &bi sy = BORDER_V/2 + y * 8; sx = BORDER_H/2 + x * 8; code = videoram[0x3800+offs]; - drawgfx_opaque(bitmap,cliprect,screen.machine().gfx[0],code,color,0,0,sx,sy); + drawgfx_opaque(bitmap,cliprect,machine().gfx[0],code,color,0,0,sx,sy); } } } @@ -278,7 +278,7 @@ UINT32 vtech2_state::screen_update_laser(screen_device &screen, bitmap_ind16 &bi sx = BORDER_H/2 + x * 16; code = videoram[0x3800+offs]; color = videoram[0x3801+offs]; - drawgfx_opaque(bitmap,cliprect,screen.machine().gfx[1],code,color,0,0,sx,sy); + drawgfx_opaque(bitmap,cliprect,machine().gfx[1],code,color,0,0,sx,sy); } } } diff --git a/src/mess/video/x68k.c b/src/mess/video/x68k.c index 507626ff2fc..0ec6cca5da6 100644 --- a/src/mess/video/x68k.c +++ b/src/mess/video/x68k.c @@ -1200,17 +1200,17 @@ UINT32 x68k_state::screen_update_x68000(screen_device &screen, bitmap_ind16 &bit rect.max_y = cliprect.max_y; // update tiles - //rom = screen.machine().root_device().memregion("user1")->base(); + //rom = machine().root_device().memregion("user1")->base(); for(x=0;x<256;x++) { if(m_video.tile16_dirty[x] != 0) { - screen.machine().gfx[1]->mark_dirty(x); + machine().gfx[1]->mark_dirty(x); m_video.tile16_dirty[x] = 0; } if(m_video.tile8_dirty[x] != 0) { - screen.machine().gfx[0]->mark_dirty(x); + machine().gfx[0]->mark_dirty(x); m_video.tile8_dirty[x] = 0; } } @@ -1219,12 +1219,12 @@ UINT32 x68k_state::screen_update_x68000(screen_device &screen, bitmap_ind16 &bit { // Graphics screen(s) if(priority == m_video.gfx_pri) - x68k_draw_gfx(screen.machine(),bitmap,rect); + x68k_draw_gfx(machine(),bitmap,rect); // Sprite / BG Tiles if(priority == m_video.sprite_pri /*&& (m_spritereg[0x404] & 0x0200)*/ && (m_video.reg[2] & 0x0040)) { - x68k_draw_sprites(screen.machine(), bitmap,1,rect); + x68k_draw_sprites(machine(), bitmap,1,rect); if((m_spritereg[0x404] & 0x0008)) { if((m_spritereg[0x404] & 0x0030) == 0x10) // BG1 TXSEL @@ -1240,7 +1240,7 @@ UINT32 x68k_state::screen_update_x68000(screen_device &screen, bitmap_ind16 &bit x68k_bg1->draw(bitmap,rect,0,0); } } - x68k_draw_sprites(screen.machine(),bitmap,2,rect); + x68k_draw_sprites(machine(),bitmap,2,rect); if((m_spritereg[0x404] & 0x0001)) { if((m_spritereg[0x404] & 0x0006) == 0x02) // BG0 TXSEL @@ -1256,7 +1256,7 @@ UINT32 x68k_state::screen_update_x68000(screen_device &screen, bitmap_ind16 &bit x68k_bg1->draw(bitmap,rect,0,0); } } - x68k_draw_sprites(screen.machine(),bitmap,3,rect); + x68k_draw_sprites(machine(),bitmap,3,rect); } // Text screen @@ -1265,24 +1265,24 @@ UINT32 x68k_state::screen_update_x68000(screen_device &screen, bitmap_ind16 &bit xscr = (m_crtc.reg[10] & 0x3ff); yscr = (m_crtc.reg[11] & 0x3ff); if(!(m_crtc.reg[20] & 0x1000)) // if text layer is set to buffer, then it's not visible - x68k_draw_text(screen.machine(),bitmap,xscr,yscr,rect); + x68k_draw_text(machine(),bitmap,xscr,yscr,rect); } } #ifdef MAME_DEBUG - if(screen.machine().input().code_pressed(KEYCODE_I)) + if(machine().input().code_pressed(KEYCODE_I)) { m_mfp.isra = 0; m_mfp.isrb = 0; // mfp_trigger_irq(MFP_IRQ_GPIP6); // machine().device("maincpu")->execute().set_input_line_and_vector(6,ASSERT_LINE,0x43); } - if(screen.machine().input().code_pressed(KEYCODE_9)) + if(machine().input().code_pressed(KEYCODE_9)) { m_sprite_shift--; popmessage("Sprite shift = %i",m_sprite_shift); } - if(screen.machine().input().code_pressed(KEYCODE_0)) + if(machine().input().code_pressed(KEYCODE_0)) { m_sprite_shift++; popmessage("Sprite shift = %i",m_sprite_shift); |