summaryrefslogtreecommitdiffstatshomepage
diff options
context:
space:
mode:
author Curt Coder <curtcoder@mail.com>2014-12-08 20:20:12 +0200
committer Curt Coder <curtcoder@mail.com>2014-12-08 20:20:12 +0200
commitec3981aef952c8e4c4fd2c3e2d824bc518af2b69 (patch)
tree1a791b4aec39dbdf6e113271a35c64ba4b3994a3
parentc3339567bdb2141e40d60a8cbe79358ed8854e99 (diff)
(MESS) victor9k: Implemented character attributes and intensity. (nw)
-rw-r--r--src/mess/drivers/victor9k.c15
1 files changed, 9 insertions, 6 deletions
diff --git a/src/mess/drivers/victor9k.c b/src/mess/drivers/victor9k.c
index 9c1dc48e441..4c1b174f5e0 100644
--- a/src/mess/drivers/victor9k.c
+++ b/src/mess/drivers/victor9k.c
@@ -22,7 +22,6 @@
- floppy 8048
- keyboard
- hires graphics
- - character attributes
- brightness/contrast
- MC6852
- codec sound
@@ -108,13 +107,17 @@ MC6845_UPDATE_ROW( victor9k_state::crtc_update_row )
UINT32 char_ram_addr = (BIT(ma, 12) << 16) | ((code & 0xff) << 5) | (ra << 1);
UINT16 data = program.read_word(char_ram_addr);
+ if (code & CODE_REVERSE_VIDEO) data ^= 0xffff;
+ if (code & CODE_NON_DISPLAY) data = 0;
+ if (sx == cursor_x) data = 0xffff;
+
for (int x = 0; x <= 10; x++)
{
- int color = BIT(data, x);
-
- if (sx == cursor_x) color = 1;
+ int pixel = BIT(data, x);
+ int color = palette[pixel && de];
+ if (!(code & CODE_LOW_INTENSITY) && color) color = 2;
- bitmap.pix32(vbp + y, hbp + x + sx*10) = palette[color && de];
+ bitmap.pix32(vbp + y, hbp + x + sx*10) = color;
}
video_ram_addr += 2;
@@ -441,7 +444,7 @@ static MACHINE_CONFIG_START( victor9k, victor9k_state )
MCFG_SCREEN_SIZE(640, 480)
MCFG_SCREEN_VISIBLE_AREA(0, 640-1, 0, 480-1)
- MCFG_PALETTE_ADD_MONOCHROME_GREEN("palette")
+ MCFG_PALETTE_ADD_MONOCHROME_GREEN_HIGHLIGHT("palette")
MCFG_MC6845_ADD(HD46505S_TAG, HD6845, SCREEN_TAG, 1000000) // HD6845 == HD46505S
MCFG_MC6845_SHOW_BORDER_AREA(true)