diff options
author | angelosa <salese_corp_ltd@email.it> | 2016-02-08 21:36:36 +0100 |
---|---|---|
committer | angelosa <salese_corp_ltd@email.it> | 2016-02-08 21:37:11 +0100 |
commit | 7a1eb1d2add20aab3b78f9e1712af823085e715e (patch) | |
tree | 03789f61d8ece0bf36c410b28428d7ac28dde089 /src/devices/video | |
parent | 78592ed5eea2e92efe836eb22de6e2e84429620a (diff) |
Moved Night Gal to use JANGOU_BLITTER
Diffstat (limited to 'src/devices/video')
-rw-r--r-- | src/devices/video/jangou_blitter.cpp | 17 | ||||
-rw-r--r-- | src/devices/video/jangou_blitter.h | 4 |
2 files changed, 8 insertions, 13 deletions
diff --git a/src/devices/video/jangou_blitter.cpp b/src/devices/video/jangou_blitter.cpp index e7390d44a8f..be11e07b315 100644 --- a/src/devices/video/jangou_blitter.cpp +++ b/src/devices/video/jangou_blitter.cpp @@ -52,7 +52,6 @@ void jangou_blitter_device::device_start() fatalerror("JANGOU_BLITTER: \"gfx\" memory base not found"); m_gfxrommask = devregion->bytes()-1; - save_item(NAME(m_pen_data)); save_item(NAME(m_blit_data)); save_item(NAME(m_blit_buffer)); @@ -65,13 +64,8 @@ void jangou_blitter_device::device_start() void jangou_blitter_device::device_reset() { - int i; - - for (i = 0; i < 6; i++) - m_blit_data[i] = 0; - - for (i = 0; i < 16; i++) - m_pen_data[i] = 0; + memset(m_blit_data, 0, ARRAY_LENGTH(m_blit_data)); + memset(m_pen_data, 0, ARRAY_LENGTH(m_pen_data)); } @@ -80,7 +74,7 @@ void jangou_blitter_device::device_reset() //************************************************************************** // TODO: inline these -UINT8 jangou_blitter_device::gfx_nibble( UINT16 niboffset ) +UINT8 jangou_blitter_device::gfx_nibble( UINT32 niboffset ) { if (niboffset & 1) return (m_gfxrom[(niboffset >> 1) & m_gfxrommask] & 0xf0) >> 4; @@ -111,11 +105,12 @@ WRITE8_MEMBER( jangou_blitter_device::blitter_process_w ) int count = 0; int xcount, ycount; - /* printf("%02x %02x %02x %02x %02x %02x\n", m_blit_data[0], m_blit_data[1], m_blit_data[2], - m_blit_data[3], m_blit_data[4], m_blit_data[5]); */ + //printf("%02x %02x %02x %02x %02x %02x %02x\n", m_blit_data[0], m_blit_data[1], m_blit_data[2], + // m_blit_data[3], m_blit_data[4], m_blit_data[5],m_blit_data[6]); w = (m_blit_data[4] & 0xff) + 1; h = (m_blit_data[5] & 0xff) + 1; src = ((m_blit_data[1] << 8)|(m_blit_data[0] << 0)); + src |= (m_blit_data[6] & 3) << 16; x = (m_blit_data[2] & 0xff); y = (m_blit_data[3] & 0xff); diff --git a/src/devices/video/jangou_blitter.h b/src/devices/video/jangou_blitter.h index d96ff1d11f7..735fea64a73 100644 --- a/src/devices/video/jangou_blitter.h +++ b/src/devices/video/jangou_blitter.h @@ -44,9 +44,9 @@ protected: private: void plot_gfx_pixel( UINT8 pix, int x, int y ); - UINT8 gfx_nibble( UINT16 niboffset ); + UINT8 gfx_nibble( UINT32 niboffset ); UINT8 m_pen_data[0x10]; - UINT8 m_blit_data[6]; + UINT8 m_blit_data[7]; UINT8 *m_gfxrom; UINT32 m_gfxrommask; }; |