mirror of
https://github.com/holub/mame
synced 2025-04-23 00:39:36 +03:00
saturn.cpp: Worked around VDP1 timings in Sega Saturn, fixes regression with Batman Forever gameplay speed [Angelo Salese]
This commit is contained in:
parent
846dfa8ffd
commit
5387680831
@ -1752,6 +1752,8 @@ TIMER_CALLBACK_MEMBER(saturn_state::vdp1_draw_end )
|
||||
/* set CEF to 1*/
|
||||
CEF_1;
|
||||
|
||||
// TODO: temporary for Batman Forever, presumably anonymous timer not behaving well.
|
||||
#if 0
|
||||
if(!(m_scu.ism & IRQ_VDP1_END))
|
||||
{
|
||||
m_maincpu->set_input_line_and_vector(0x2, HOLD_LINE, 0x4d);
|
||||
@ -1759,6 +1761,7 @@ TIMER_CALLBACK_MEMBER(saturn_state::vdp1_draw_end )
|
||||
}
|
||||
else
|
||||
m_scu.ist |= (IRQ_VDP1_END);
|
||||
#endif
|
||||
}
|
||||
|
||||
|
||||
|
@ -647,7 +647,6 @@ MACHINE_START_MEMBER(sat_console_state, saturn)
|
||||
|
||||
if (machine().debug_flags & DEBUG_FLAG_ENABLED)
|
||||
{
|
||||
//printf("HI!\n");
|
||||
using namespace std::placeholders;
|
||||
machine().debugger().console().register_command("saturn", CMDFLAG_NONE, 0, 1, 4, std::bind(&saturn_state::debug_commands, this, _1, _2, _3));
|
||||
}
|
||||
|
@ -862,6 +862,18 @@ TIMER_DEVICE_CALLBACK_MEMBER(saturn_state::saturn_scanline)
|
||||
m_vdp1.framebuffer_clear_on_next_frame = 1;
|
||||
}
|
||||
|
||||
// TODO: temporary for Batman Forever, presumably anonymous timer not behaving well.
|
||||
// VDP1 timing needs some HW work anyway so I'm currently firing VDP1 after 8 scanlines for now, will de-anon the timers in a later stage.
|
||||
if(scanline == (vblank_line+8)*y_step)
|
||||
{
|
||||
if(!(m_scu.ism & IRQ_VDP1_END))
|
||||
{
|
||||
m_maincpu->set_input_line_and_vector(0x2, HOLD_LINE, 0x4d);
|
||||
scu_do_transfer(6);
|
||||
}
|
||||
else
|
||||
m_scu.ist |= (IRQ_VDP1_END);
|
||||
}
|
||||
|
||||
if(scanline == (m_scu_regs[36] & 0x3ff)*y_step)
|
||||
{
|
||||
|
Loading…
Reference in New Issue
Block a user