mirror of
https://github.com/holub/mame
synced 2025-04-23 08:49:55 +03:00
tms9927: Adjust vertical positioning of cursor by upscroll value (nw)
tv912: Add scrolling (nw)
This commit is contained in:
parent
c8c0ac7623
commit
b313a4e7bf
@ -293,22 +293,10 @@ READ_LINE_MEMBER(tms9927_device::bl_r)
|
||||
}
|
||||
|
||||
|
||||
bool tms9927_device::screen_reset()
|
||||
{
|
||||
return m_reset;
|
||||
}
|
||||
|
||||
|
||||
int tms9927_device::upscroll_offset()
|
||||
{
|
||||
return m_start_datarow;
|
||||
}
|
||||
|
||||
|
||||
bool tms9927_device::cursor_bounds(rectangle &bounds)
|
||||
bool tms9927_device::cursor_bounds(rectangle &bounds) const
|
||||
{
|
||||
int cursorx = CURSOR_CHAR_ADDRESS;
|
||||
int cursory = CURSOR_ROW_ADDRESS;
|
||||
int cursory = (CURSOR_ROW_ADDRESS + DATA_ROWS_PER_FRAME - m_start_datarow) % DATA_ROWS_PER_FRAME;
|
||||
|
||||
bounds.min_x = cursorx * m_hpixels_per_column;
|
||||
bounds.max_x = bounds.min_x + m_hpixels_per_column - 1;
|
||||
|
@ -48,9 +48,9 @@ public:
|
||||
|
||||
DECLARE_READ_LINE_MEMBER(bl_r);
|
||||
|
||||
bool screen_reset();
|
||||
int upscroll_offset();
|
||||
bool cursor_bounds(rectangle &bounds);
|
||||
bool screen_reset() const { return m_reset; }
|
||||
int upscroll_offset() const { return m_start_datarow; }
|
||||
bool cursor_bounds(rectangle &bounds) const;
|
||||
|
||||
protected:
|
||||
tms9927_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock);
|
||||
|
@ -432,7 +432,7 @@ uint32_t alphatpx_state::screen_update(screen_device &screen, bitmap_rgb32 &bitm
|
||||
{
|
||||
uint8_t code = m_vram[(vramy * 128) + x]; // helwie44 must be 128d is 080h physical display-ram step line
|
||||
// draw 12 lines of the character
|
||||
bool cursoren = cursor.contains(x * 8, vramy * 12);
|
||||
bool cursoren = cursor.contains(x * 8, y * 12);
|
||||
for (int line = 0; line < 12; line++)
|
||||
{
|
||||
uint8_t data = m_gfx[((code & 0x7f) * 16) + line];
|
||||
|
@ -294,9 +294,11 @@ u32 tv912_state::screen_update(screen_device &screen, bitmap_rgb32 &bitmap, cons
|
||||
rectangle curs;
|
||||
m_crtc->cursor_bounds(curs);
|
||||
|
||||
int scroll = m_crtc->upscroll_offset();
|
||||
|
||||
for (int y = cliprect.top(); y <= cliprect.bottom(); y++)
|
||||
{
|
||||
int row = y / 10;
|
||||
int row = ((y / 10) + scroll) % 24;
|
||||
int ra = y % 10;
|
||||
int x = 0;
|
||||
u8 *charbase = &m_p_chargen[(ra & 7) | BIT(videoctrl, 1) << 10];
|
||||
|
@ -37,7 +37,7 @@ uint32_t intv_state::screen_update_intvkbd(screen_device &screen, bitmap_ind16 &
|
||||
{
|
||||
for(int x=0;x<40;x++)
|
||||
{
|
||||
if ((cursor_row == current_row) && (cursor_col == x+1)) {
|
||||
if ((cursor_row == y) && (cursor_col == x+1)) {
|
||||
/* draw the cursor as a solid white block */
|
||||
m_gfxdecode->gfx(0)->transpen(bitmap,cliprect,
|
||||
191, /* a block */
|
||||
|
Loading…
Reference in New Issue
Block a user