mirror of
https://github.com/holub/mame
synced 2025-07-06 10:29:38 +03:00
nec/pc9801_v.cpp: reverse attribute will draw opaque on Y char limit
* fix daremo intro
This commit is contained in:
parent
5f4e3730d9
commit
e05e355a12
@ -96,6 +96,8 @@ void pc9801_state::draw_text(bitmap_rgb32 &bitmap, uint32_t addr, int y, int wd,
|
|||||||
int scroll_end = scroll_start + m_txt_scroll_reg[5];
|
int scroll_end = scroll_start + m_txt_scroll_reg[5];
|
||||||
int scroll = m_txt_scroll_reg[3] % 20;
|
int scroll = m_txt_scroll_reg[3] % 20;
|
||||||
int line = y / lr;
|
int line = y / lr;
|
||||||
|
// TODO: accurate blink rate
|
||||||
|
const bool is_blink_rate = m_screen->frame_number() & 0x10;
|
||||||
|
|
||||||
for(int x=0;x<pitch;x+=x_step)
|
for(int x=0;x<pitch;x+=x_step)
|
||||||
{
|
{
|
||||||
@ -223,18 +225,19 @@ void pc9801_state::draw_text(bitmap_rgb32 &bitmap, uint32_t addr, int y, int wd,
|
|||||||
}
|
}
|
||||||
if(v_line) { tile_data|=8; }
|
if(v_line) { tile_data|=8; }
|
||||||
|
|
||||||
/* TODO: proper blink rate for these two */
|
if(cursor_on && cursor_addr == tile_addr && is_blink_rate)
|
||||||
if(cursor_on && cursor_addr == tile_addr && m_screen->frame_number() & 0x10)
|
|
||||||
tile_data^=0xff;
|
tile_data^=0xff;
|
||||||
|
|
||||||
if(blink && m_screen->frame_number() & 0x10)
|
if(blink && is_blink_rate)
|
||||||
tile_data = 0;
|
tile_data = 0;
|
||||||
|
|
||||||
if(reverse) { tile_data^=0xff; }
|
if(reverse) { tile_data^=0xff; }
|
||||||
|
|
||||||
int pen;
|
int pen;
|
||||||
|
// daremo wants to mask during intro with reverse attribute only
|
||||||
|
// using color is a guess: may just be black.
|
||||||
if(yi >= char_size)
|
if(yi >= char_size)
|
||||||
pen = -1;
|
pen = reverse ? color : -1;
|
||||||
else
|
else
|
||||||
pen = (tile_data >> (7-xi) & 1) ? color : -1;
|
pen = (tile_data >> (7-xi) & 1) ? color : -1;
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user