From 5acb668006b280b38b31ca184d0de193413605ef Mon Sep 17 00:00:00 2001 From: benrg Date: Fri, 30 Dec 2022 15:47:26 -0800 Subject: Remove a2_video_device::hgr_update_tk2000 (#10764) It was not referenced anywhere in the source tree, and was just a copy of hgr_update with the address of page 2 changed from $4000 to $A000. If support for this is ever needed, it could be handled by adding a parameter to hgr_update. --- src/mame/apple/apple2video.cpp | 109 ----------------------------------------- src/mame/apple/apple2video.h | 1 - 2 files changed, 110 deletions(-) diff --git a/src/mame/apple/apple2video.cpp b/src/mame/apple/apple2video.cpp index edfd0bd5a1d..d16af31d297 100644 --- a/src/mame/apple/apple2video.cpp +++ b/src/mame/apple/apple2video.cpp @@ -1002,115 +1002,6 @@ void a2_video_device::hgr_update(screen_device &screen, bitmap_ind16 &bitmap, co } } -// similar to regular A2 except page 2 is at $A000 -void a2_video_device::hgr_update_tk2000(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect, int beginrow, int endrow) -{ - int const mon_type = m_sysconfig & 0x03; - - /* sanity checks */ - if (beginrow < cliprect.top()) - beginrow = cliprect.top(); - if (endrow > cliprect.bottom()) - endrow = cliprect.bottom(); - if (endrow < beginrow) - return; - - uint8_t const *const vram = &m_ram_ptr[(m_page2 ? 0xa000 : 0x2000)]; - - uint8_t vram_row[42]; - vram_row[0] = 0; - vram_row[41] = 0; - - for (int row = beginrow; row <= endrow; row++) - { - for (int col = 0; col < 40; col++) - { - int const offset = ((((row/8) & 0x07) << 7) | (((row/8) & 0x18) * 5 + col)) | ((row & 7) << 10); - vram_row[1+col] = vram[offset]; - } - - uint16_t *p = &bitmap.pix(row); - - for (int col = 0; col < 40; col++) - { - uint32_t w = (((uint32_t) vram_row[col+0] & 0x7f) << 0) - | (((uint32_t) vram_row[col+1] & 0x7f) << 7) - | (((uint32_t) vram_row[col+2] & 0x7f) << 14); - - uint16_t const *artifact_map_ptr; - switch (mon_type) - { - case 0: - artifact_map_ptr = &m_hires_artifact_map[((vram_row[col+1] & 0x80) >> 7) * 16]; - for (int b = 0; b < 7; b++) - { - uint16_t const v = artifact_map_ptr[((w >> (b + 7-1)) & 0x07) | (((b ^ col) & 0x01) << 3)]; - *(p++) = v; - *(p++) = v; - } - break; - - case 1: - w >>= 7; - if (vram_row[col] & 0x80) - { - p--; - } - for (int b = 0; b < 7; b++) - { - uint16_t const v = (w & 1); - w >>= 1; - *(p++) = v ? WHITE : BLACK; - *(p++) = v ? WHITE : BLACK; - } - if (vram_row[col] & 0x80) - { - p++; - } - break; - - case 2: - w >>= 7; - if (vram_row[col] & 0x80) - { - p--; - } - for (int b = 0; b < 7; b++) - { - uint16_t const v = (w & 1); - w >>= 1; - *(p++) = v ? GREEN : BLACK; - *(p++) = v ? GREEN : BLACK; - } - if (vram_row[col] & 0x80) - { - p++; - } - break; - - case 3: - w >>= 7; - if (vram_row[col] & 0x80) - { - p--; - } - for (int b = 0; b < 7; b++) - { - uint16_t const v = (w & 1); - w >>= 1; - *(p++) = v ? ORANGE : BLACK; - *(p++) = v ? ORANGE : BLACK; - } - if (vram_row[col] & 0x80) - { - p++; - } - break; - } - } - } -} - void a2_video_device::dhgr_update(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect, int beginrow, int endrow) { uint16_t v; diff --git a/src/mame/apple/apple2video.h b/src/mame/apple/apple2video.h index 21a1eb8f9e0..079bd366600 100644 --- a/src/mame/apple/apple2video.h +++ b/src/mame/apple/apple2video.h @@ -60,7 +60,6 @@ public: void lores_update(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect, int beginrow, int endrow); void dlores_update(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect, int beginrow, int endrow); void hgr_update(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect, int beginrow, int endrow); - void hgr_update_tk2000(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect, int beginrow, int endrow); void dhgr_update(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect, int beginrow, int endrow); uint32_t screen_update_GS(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect); -- cgit v1.2.3