GS/HW: Fix incorrect resizing of Ico move target

This commit is contained in:
Stenzek 2024-01-09 22:37:16 +10:00 committed by refractionpcsx2
parent 01842a3c6b
commit c469b17350
1 changed files with 4 additions and 1 deletions

View File

@ -1416,9 +1416,12 @@ bool GSHwHack::MV_Ico(GSRendererHW& r)
if (dst->GetUnscaledWidth() < static_cast<int>(RWIDTH) || dst->GetUnscaledHeight() < static_cast<int>(RHEIGHT))
{
if (!dst->ResizeTexture(dst->GetUnscaledWidth(), static_cast<int>(RWIDTH), std::max(dst->GetUnscaledHeight(), static_cast<int>(RHEIGHT))))
if (!dst->ResizeTexture(std::max(dst->GetUnscaledWidth(), static_cast<int>(RWIDTH)),
std::max(dst->GetUnscaledHeight(), static_cast<int>(RHEIGHT))))
{
return false;
}
}
const GSVector4i draw_rc = GSVector4i(0, 0, RWIDTH, RHEIGHT).rintersect(dst->GetUnscaledRect());
dst->UpdateValidChannels(PSMCT32, 0);