From b85136826199e468bae43145d739aa6131c236b8 Mon Sep 17 00:00:00 2001 From: Sven Schnelle Date: Thu, 8 Nov 2018 00:19:07 +0100 Subject: [PATCH] topcat: fix window move (nw) Plane bitmap check was missing, so a window move was always started on all planes. This was mostly visible in Pascal workstation, where text color was brown instead of white, and HP VUE also showed broken colors. --- src/devices/video/topcat.cpp | 14 ++++++++------ 1 file changed, 8 insertions(+), 6 deletions(-) diff --git a/src/devices/video/topcat.cpp b/src/devices/video/topcat.cpp index 87bb60cb1d7..da368d10339 100644 --- a/src/devices/video/topcat.cpp +++ b/src/devices/video/topcat.cpp @@ -75,10 +75,10 @@ READ16_MEMBER(topcat_device::vram_r) uint16_t ret = 0; if (mem_mask & m_plane_mask) - ret |= m_vram[offset*2+1] ? m_plane_mask : 0; + ret |= m_vram[offset*2+1] & m_plane_mask; if (mem_mask & m_plane_mask << 8) - ret |= m_vram[offset*2] ? m_plane_mask << 8 : 0; + ret |= (m_vram[offset*2] & m_plane_mask) << 8; //LOG("%s: %04X: %04X (mask %04X)\n", __FUNCTION__, offset, ret, mem_mask); return ret; } @@ -386,10 +386,12 @@ WRITE16_MEMBER(topcat_device::ctrl_w) update_int(); break; case TOPCAT_REG_START_WMOVE: - window_move(); - if (m_unknown_reg4a) { - m_wmove_intrq = m_plane_mask << 8; - update_int(); + if (data & (m_plane_mask << 8)) { + window_move(); + if (m_unknown_reg4a) { + m_wmove_intrq = m_plane_mask << 8; + update_int(); + } } break; case TOPCAT_REG_ENABLE_BLINK_PLANES: