GPU: Synchronize CRTC on GP1(05h) command

Fixes text flashing briefly after startup PlayStation logo in King's
Field (USA).
This commit is contained in:
Albert Liu 2020-10-22 21:41:42 -07:00
parent ca7db7a2d2
commit 6bc7cf29cc
1 changed files with 9 additions and 3 deletions

View File

@ -964,10 +964,16 @@ void GPU::WriteGP1(u32 value)
case 0x05: // Set display start address
{
m_crtc_state.regs.display_address_start = param & CRTCState::Regs::DISPLAY_ADDRESS_START_MASK;
Log_DebugPrintf("Display address start <- 0x%08X", m_crtc_state.regs.display_address_start);
const u32 new_value = param & CRTCState::Regs::DISPLAY_ADDRESS_START_MASK;
Log_DebugPrintf("Display address start <- 0x%08X", new_value);
System::IncrementInternalFrameNumber();
UpdateCRTCDisplayParameters();
if (m_crtc_state.regs.display_address_start != new_value)
{
SynchronizeCRTC();
m_crtc_state.regs.display_address_start = new_value;
UpdateCRTCConfig();
}
}
break;