diff options
-rw-r--r-- | src/mame/drivers/pgm2.cpp | 11 | ||||
-rw-r--r-- | src/mame/includes/pgm2.h | 2 | ||||
-rw-r--r-- | src/mame/video/pgm2.cpp | 9 |
3 files changed, 20 insertions, 2 deletions
diff --git a/src/mame/drivers/pgm2.cpp b/src/mame/drivers/pgm2.cpp index f7b2cdd139d..311f3dc9897 100644 --- a/src/mame/drivers/pgm2.cpp +++ b/src/mame/drivers/pgm2.cpp @@ -356,6 +356,7 @@ static ADDRESS_MAP_START( pgm2_map, AS_PROGRAM, 32, pgm2_state ) AM_RANGE(0x30120000, 0x30120003) AM_RAM AM_SHARE("bgscroll") // scroll AM_RANGE(0x30120008, 0x3012000b) AM_RAM AM_SHARE("fgscroll") + AM_RANGE(0x3012000c, 0x3012000f) AM_RAM AM_SHARE("vidmode") AM_RANGE(0x30120030, 0x30120033) AM_WRITE16(share_bank_w, 0xffff0000) AM_RANGE(0x30120038, 0x3012003b) AM_WRITE(sprite_encryption_w) // there are other 0x301200xx regs @@ -570,10 +571,16 @@ static MACHINE_CONFIG_START( pgm2 ) MCFG_PGM2_MEMCARD_ADD("memcard_p2") MCFG_PGM2_MEMCARD_ADD("memcard_p3") MCFG_PGM2_MEMCARD_ADD("memcard_p4") +MACHINE_CONFIG_END - +// not strictly needed as the video code supports changing on the fly, but makes recording easier etc. +static MACHINE_CONFIG_DERIVED( pgm2_lores, pgm2 ) + MCFG_SCREEN_MODIFY("screen") + // note, +8 to y position too, could be a sprite reg to move sprites intead + MCFG_SCREEN_VISIBLE_AREA(0, 320-1, 0+8, 224+8-1) MACHINE_CONFIG_END + /* using macros for the video / sound roms because the locations never change between sets, and we're going to have a LOT of clones to cover all the internal rom regions and external rom revision combinations, so it keeps things readable */ @@ -1119,7 +1126,7 @@ GAME( 2011, kov3_102, kov3, pgm2, pgm2, pgm2_state, kov3_102, ROT0, GAME( 2011, kov3_100, kov3, pgm2, pgm2, pgm2_state, kov3_100, ROT0, "IGS", "Knights of Valour 3 (V100, China)", MACHINE_NOT_WORKING ) // King of Fighters '98: Ultimate Match Hero -GAME( 2009, kof98umh, 0, pgm2, pgm2, pgm2_state, kof98umh, ROT0, "IGS / SNK Playmore / NewChannel", "The King of Fighters '98: Ultimate Match HERO (China, V100, 09-08-23)", MACHINE_NOT_WORKING ) +GAME( 2009, kof98umh, 0, pgm2_lores, pgm2, pgm2_state, kof98umh, ROT0, "IGS / SNK Playmore / NewChannel", "The King of Fighters '98: Ultimate Match HERO (China, V100, 09-08-23)", MACHINE_NOT_WORKING ) // Jigsaw World Arena diff --git a/src/mame/includes/pgm2.h b/src/mame/includes/pgm2.h index 6964760ee8c..d3052a22b3f 100644 --- a/src/mame/includes/pgm2.h +++ b/src/mame/includes/pgm2.h @@ -33,6 +33,7 @@ public: m_sp_videoram(*this, "sp_videoram"), m_bgscroll(*this, "bgscroll"), m_fgscroll(*this, "fgscroll"), + m_vidmode(*this, "vidmode"), m_gfxdecode2(*this, "gfxdecode2"), m_gfxdecode3(*this, "gfxdecode3"), m_arm_aic(*this, "arm_aic"), @@ -133,6 +134,7 @@ private: required_shared_ptr<uint32_t> m_sp_videoram; required_shared_ptr<uint32_t> m_bgscroll; required_shared_ptr<uint32_t> m_fgscroll; + required_shared_ptr<uint32_t> m_vidmode; required_device<gfxdecode_device> m_gfxdecode2; required_device<gfxdecode_device> m_gfxdecode3; required_device<arm_aic_device> m_arm_aic; diff --git a/src/mame/video/pgm2.cpp b/src/mame/video/pgm2.cpp index 88fa0c838fc..1e52296232b 100644 --- a/src/mame/video/pgm2.cpp +++ b/src/mame/video/pgm2.cpp @@ -258,6 +258,15 @@ void pgm2_state::copy_sprites_from_bitmap(screen_device &screen, bitmap_rgb32 &b uint32_t pgm2_state::screen_update_pgm2(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect) { + + int mode = m_vidmode[0] & 0x00010000; // other bits not used? + + if (mode) + m_screen->set_visible_area(0, 448 - 1, 0, 224 - 1); + else // note, +8 to y position too, could be a sprite reg to move sprites intead + m_screen->set_visible_area(0, 320 - 1, 8, 224 + 8 - 1); + + m_fg_tilemap->set_scrollx(0, m_fgscroll[0] & 0xffff); m_fg_tilemap->set_scrolly(0, m_fgscroll[0] >> 16); m_bg_tilemap->set_scrolly(0, (m_bgscroll[0x0/4] & 0xffff0000)>>16 ); |