diff options
author | MooglyGuy <therealmogminer@gmail.com> | 2019-11-14 00:29:29 +0100 |
---|---|---|
committer | MooglyGuy <therealmogminer@gmail.com> | 2019-11-14 00:30:39 +0100 |
commit | 4c53d5611de42660a0d2232b6c911c7e94b6572f (patch) | |
tree | 5263083c5683b3ea39766a0acc25149f2b2650af /src/mame/machine | |
parent | 6018a48cc2875249b061a4a3e05df0cf18601266 (diff) |
-snes_ppu: Converted OAM code from bsnes ppu-fast, nw
Diffstat (limited to 'src/mame/machine')
-rw-r--r-- | src/mame/machine/snes.cpp | 11 |
1 files changed, 2 insertions, 9 deletions
diff --git a/src/mame/machine/snes.cpp b/src/mame/machine/snes.cpp index 419cb007816..a0f4281ef4d 100644 --- a/src/mame/machine/snes.cpp +++ b/src/mame/machine/snes.cpp @@ -102,15 +102,8 @@ TIMER_CALLBACK_MEMBER(snes_state::snes_hirq_tick_callback) TIMER_CALLBACK_MEMBER(snes_state::snes_reset_oam_address) { - // make sure we're in the 65816's context since we're messing with the OAM and stuff - address_space &space = m_maincpu->space(AS_PROGRAM); - if (!m_ppu->screen_disabled()) //Reset OAM address, byuu says it happens at H=10 - { - space.write_byte(OAMADDL, m_ppu->saved_oam_address_low()); /* Reset oam address */ - space.write_byte(OAMADDH, m_ppu->saved_oam_address_high()); - m_ppu->set_first_sprite(); - } + m_ppu->oam_address_reset(); } TIMER_CALLBACK_MEMBER(snes_state::snes_reset_hdma) @@ -235,7 +228,7 @@ TIMER_CALLBACK_MEMBER(snes_state::snes_hblank_tick) hdma(cpu0space); if (m_screen->vpos() > 0) - m_screen->update_partial((m_ppu->interlace() == 2) ? (m_ppu->current_vert() * m_ppu->interlace()) : m_ppu->current_vert()); + m_screen->update_partial((m_ppu->interlace() == 2) ? (m_ppu->current_vert() * m_ppu->interlace()) : m_ppu->current_vert() - 1); } // signal hblank |