summaryrefslogtreecommitdiffstatshomepage
diff options
context:
space:
mode:
author cracyc <cracyc@users.noreply.github.com>2021-06-26 14:20:33 -0500
committer cracyc <cracyc@users.noreply.github.com>2021-06-26 14:20:33 -0500
commitcd8d2a8050446282a1af95d02075cfe6b7059e6e (patch)
tree8c42f22d163212d8cdac3dfdaa76819bb3043522
parent499399bdcde9277ad3349c63326e8f41e7a06735 (diff)
x68k: color 0 is only transparent if the crtc is not set for 16bit color mode
-rw-r--r--src/mame/video/x68k.cpp2
-rw-r--r--src/mame/video/x68k_crtc.h1
2 files changed, 2 insertions, 1 deletions
diff --git a/src/mame/video/x68k.cpp b/src/mame/video/x68k.cpp
index bf8a03f73d9..bcfe47c6f15 100644
--- a/src/mame/video/x68k.cpp
+++ b/src/mame/video/x68k.cpp
@@ -212,7 +212,7 @@ void x68k_state::draw_text(bitmap_rgb32 &bitmap, int xscr, int yscr, rectangle r
+ (((m_tvram[loc+0x20000] >> bit) & 0x01) ? 4 : 0)
+ (((m_tvram[loc+0x30000] >> bit) & 0x01) ? 8 : 0);
// Colour 0 is displayable if the text layer is at the priority level 2
- if((colour && (m_pcgpalette->pen(colour) & 0xffffff)) || ((m_video.reg[1] & 0x0c00) == 0x0800))
+ if(((colour || (m_crtc->gfx_color_mode() == 3)) && (m_pcgpalette->pen(colour) & 0xffffff)) || ((m_video.reg[1] & 0x0c00) == 0x0800))
bitmap.pix(line, pixel) = m_pcgpalette->pen(colour);
bit--;
if(bit < 0)
diff --git a/src/mame/video/x68k_crtc.h b/src/mame/video/x68k_crtc.h
index bc9f81bae0b..fd8bb2a4a01 100644
--- a/src/mame/video/x68k_crtc.h
+++ b/src/mame/video/x68k_crtc.h
@@ -41,6 +41,7 @@ public:
bool is_1024x1024() const { return BIT(m_reg[20], 10); }
bool gfx_double_scan() const { return (m_reg[20] & 0x1e) == 0x10; }
bool gfx_layer_buffer() const { return BIT(m_reg[20], 11); }
+ u8 gfx_color_mode() const { return (m_reg[20] >> 8) & 3; }
bool text_layer_buffer() const { return BIT(m_reg[20], 12); }
u16 hbegin() const { return m_hbegin; }
u16 vbegin() const { return m_vbegin; }