mirror of
https://github.com/holub/mame
synced 2025-05-23 22:20:01 +03:00
Fix cliffhgr. tms9928a depends on the screen parameters matching output
exactly, but for ld games it doesn't since they are externally clocked.
This commit is contained in:
parent
3d10a89945
commit
39c358476c
@ -274,7 +274,8 @@ WRITE8_MEMBER( tms9928a_device::register_write )
|
||||
|
||||
void tms9928a_device::device_timer(emu_timer &timer, device_timer_id id, int param, void *ptr)
|
||||
{
|
||||
int vpos = m_screen->vpos();
|
||||
int raw_vpos = m_screen->vpos();
|
||||
int vpos = raw_vpos * m_vertical_size / m_screen->height();
|
||||
UINT16 BackColour = m_Regs[7] & 15;
|
||||
UINT16 *p = &m_tmpbmp.pix16(vpos);
|
||||
|
||||
@ -567,7 +568,7 @@ void tms9928a_device::device_timer(emu_timer &timer, device_timer_id id, int par
|
||||
}
|
||||
|
||||
/* Schedule next callback */
|
||||
m_line_timer->adjust( m_screen->time_until_pos( ( vpos + 1 ) % m_screen->height() , 0 ) );
|
||||
m_line_timer->adjust( m_screen->time_until_pos( ( raw_vpos + 1 ) % m_screen->height() , 0 ) );
|
||||
}
|
||||
|
||||
|
||||
@ -602,6 +603,7 @@ void tms9928a_device::device_start()
|
||||
assert( m_screen != NULL );
|
||||
|
||||
m_top_border = m_50hz ? TMS9928A_VERT_DISPLAY_START_PAL : TMS9928A_VERT_DISPLAY_START_NTSC;
|
||||
m_vertical_size = m_50hz ? TMS9928A_TOTAL_VERT_PAL : TMS9928A_TOTAL_VERT_NTSC;
|
||||
|
||||
m_irq_changed.resolve( m_out_int_line, *this );
|
||||
|
||||
|
@ -153,6 +153,7 @@ private:
|
||||
|
||||
/* emulation settings */
|
||||
int m_top_border;
|
||||
int m_vertical_size;
|
||||
};
|
||||
|
||||
|
||||
|
@ -671,14 +671,6 @@ static TMS9928A_INTERFACE(cliffhgr_tms9928a_interface)
|
||||
DEVCB_LINE(vdp_interrupt)
|
||||
};
|
||||
|
||||
static SCREEN_UPDATE_IND16( cliffhgr )
|
||||
{
|
||||
tms9928a_device *tms9928a = screen.machine().device<tms9928a_device>( "tms9928a" );
|
||||
|
||||
tms9928a->screen_update( screen, bitmap, cliprect );
|
||||
return 0;
|
||||
}
|
||||
|
||||
DISCRETE_SOUND_EXTERN( cliffhgr );
|
||||
|
||||
|
||||
@ -701,7 +693,7 @@ static MACHINE_CONFIG_START( cliffhgr, cliffhgr_state )
|
||||
MCFG_NVRAM_ADD_0FILL("nvram")
|
||||
|
||||
MCFG_LASERDISC_PR8210_ADD("laserdisc")
|
||||
MCFG_LASERDISC_OVERLAY_STATIC(TMS9928A_TOTAL_HORZ, TMS9928A_TOTAL_VERT_NTSC, cliffhgr)
|
||||
MCFG_LASERDISC_OVERLAY_DEVICE(TMS9928A_TOTAL_HORZ, TMS9928A_TOTAL_VERT_NTSC, "tms9928a", tms9928a_device, screen_update)
|
||||
MCFG_LASERDISC_OVERLAY_CLIP(TMS9928A_HORZ_DISPLAY_START-12, TMS9928A_HORZ_DISPLAY_START+32*8+12-1, TMS9928A_VERT_DISPLAY_START_NTSC - 12, TMS9928A_VERT_DISPLAY_START_NTSC+24*8+12-1)
|
||||
|
||||
/* start with the TMS9928a video configuration */
|
||||
|
Loading…
Reference in New Issue
Block a user