From c138e20a060975b1b21b7ed07bb6c69d3a95c8a2 Mon Sep 17 00:00:00 2001 From: Sour Date: Sat, 2 Mar 2019 21:37:32 -0500 Subject: [PATCH] PPU: Fixed hi-res display for modes other than 5/6 --- Core/Ppu.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Core/Ppu.cpp b/Core/Ppu.cpp index 5ab4702..8a67299 100644 --- a/Core/Ppu.cpp +++ b/Core/Ppu.cpp @@ -537,7 +537,7 @@ void Ppu::RenderTilemap() uint16_t baseOffset = tilemapAddr + addrVerticalScrollingOffset + ((row & 0x1F) << 5); uint16_t vScroll = config.VScroll; - uint16_t hScroll = IsDoubleWidth() ? (config.HScroll << 1) : config.HScroll; + uint16_t hScroll = hiResMode ? (config.HScroll << 1) : config.HScroll; //"Offset per tile" mode (modes 2, 4 and 6 support this) bool offsetPerTileMode = (_bgMode & 0x03) == 2; @@ -1590,7 +1590,7 @@ void Ppu::RenderTilemap() template void Ppu::RenderTilemap() { - if(IsDoubleWidth()) { + if(_bgMode == 5 || _bgMode == 6) { RenderTilemap(); } else { RenderTilemap();