mirror of
https://github.com/holub/mame
synced 2025-10-05 00:38:58 +03:00
mc6845: only apply the interlace adjust to the apricot since it causes
issues with other systems. really need proper interlace support.
This commit is contained in:
parent
782d37b6c7
commit
5bce2574a9
@ -92,6 +92,7 @@ mc6845_device::mc6845_device(const machine_config &mconfig, device_type type, co
|
||||
: device_t(mconfig, type, name, tag, owner, clock, shortname, source),
|
||||
device_video_interface(mconfig, *this, false),
|
||||
m_show_border_area(true),
|
||||
m_interlace_adjust(0),
|
||||
m_visarea_adjust_min_x(0),
|
||||
m_visarea_adjust_max_x(0),
|
||||
m_visarea_adjust_min_y(0),
|
||||
@ -108,6 +109,7 @@ mc6845_device::mc6845_device(const machine_config &mconfig, const char *tag, dev
|
||||
: device_t(mconfig, MC6845, "MC6845 CRTC", tag, owner, clock, "mc6845", __FILE__),
|
||||
device_video_interface(mconfig, *this, false),
|
||||
m_show_border_area(true),
|
||||
m_interlace_adjust(0),
|
||||
m_visarea_adjust_min_x(0),
|
||||
m_visarea_adjust_max_x(0),
|
||||
m_visarea_adjust_min_y(0),
|
||||
@ -218,7 +220,7 @@ WRITE8_MEMBER( mc6845_device::register_w )
|
||||
case 0x06: m_vert_disp = data & 0x7f; break;
|
||||
case 0x07: m_vert_sync_pos = data & 0x7f; break;
|
||||
case 0x08: m_mode_control = data & 0xff; break;
|
||||
case 0x09: m_max_ras_addr = data & 0x1f; break;
|
||||
case 0x09: m_max_ras_addr = data & 0x1f; if (MODE_INTERLACE_AND_VIDEO) m_max_ras_addr += m_interlace_adjust; break;
|
||||
case 0x0a: m_cursor_start_ras = data & 0x7f; break;
|
||||
case 0x0b: m_cursor_end_ras = data & 0x1f; break;
|
||||
case 0x0c: m_disp_start_addr = ((data & 0x3f) << 8) | (m_disp_start_addr & 0x00ff); break;
|
||||
@ -454,10 +456,6 @@ void mc6845_device::recompute_parameters(bool postload)
|
||||
{
|
||||
UINT16 hsync_on_pos, hsync_off_pos, vsync_on_pos, vsync_off_pos;
|
||||
|
||||
// needed for the apricot, correct?
|
||||
if (MODE_INTERLACE_AND_VIDEO)
|
||||
m_max_ras_addr |= 1;
|
||||
|
||||
UINT16 video_char_height = m_max_ras_addr + 1; // fix garbage at the bottom of the screen (eg victor9k)
|
||||
// Would be useful for 'interlace and video' mode support...
|
||||
// UINT16 frame_char_height = (MODE_INTERLACE_AND_VIDEO ? m_max_ras_addr / 2 : m_max_ras_addr) + 1;
|
||||
|
@ -30,6 +30,9 @@
|
||||
#define MCFG_MC6845_SHOW_BORDER_AREA(_show) \
|
||||
mc6845_device::set_show_border_area(*device, _show);
|
||||
|
||||
#define MCFG_MC6845_INTERLACE_ADJUST(_value) \
|
||||
mc6845_device::set_interlace_adjust(*device, _value);
|
||||
|
||||
#define MCFG_MC6845_VISAREA_ADJUST(_minx, _maxx, _miny, _maxy) \
|
||||
mc6845_device::set_visarea_adjust(*device, _minx, _maxx, _miny, _maxy);
|
||||
|
||||
@ -96,6 +99,7 @@ public:
|
||||
mc6845_device(const machine_config &mconfig, device_type type, const char *name, const char *tag, device_t *owner, UINT32 clock, const char *shortname, const char *source);
|
||||
|
||||
static void set_show_border_area(device_t &device, bool show) { downcast<mc6845_device &>(device).m_show_border_area = show; }
|
||||
static void set_interlace_adjust(device_t &device, int value) { downcast<mc6845_device &>(device).m_interlace_adjust = value; }
|
||||
static void set_visarea_adjust(device_t &device, int min_x, int max_x, int min_y, int max_y)
|
||||
{
|
||||
mc6845_device &dev = downcast<mc6845_device &>(device);
|
||||
@ -272,6 +276,7 @@ protected:
|
||||
************************/
|
||||
|
||||
bool m_show_border_area; /* visible screen area (false) active display (true) active display + blanking */
|
||||
int m_interlace_adjust; /* adjust max ras in interlace mode */
|
||||
|
||||
/* visible screen area adjustment */
|
||||
int m_visarea_adjust_min_x;
|
||||
|
@ -401,6 +401,7 @@ static MACHINE_CONFIG_START( apricot, apricot_state )
|
||||
MCFG_PALETTE_ADD_MONOCHROME_GREEN_HIGHLIGHT("palette")
|
||||
|
||||
MCFG_MC6845_ADD("ic30", MC6845, "screen", XTAL_15MHz / 10)
|
||||
MCFG_MC6845_INTERLACE_ADJUST(1)
|
||||
MCFG_MC6845_SHOW_BORDER_AREA(false)
|
||||
MCFG_MC6845_CHAR_WIDTH(10)
|
||||
MCFG_MC6845_UPDATE_ROW_CB(apricot_state, crtc_update_row)
|
||||
|
Loading…
Reference in New Issue
Block a user