GPU: Skip zero-width or height fills

This commit is contained in:
Connor McLaughlin 2020-10-31 00:59:25 +10:00
parent 2e53bf914e
commit 61a4960380
1 changed files with 3 additions and 1 deletions

View File

@ -459,7 +459,9 @@ bool GPU::HandleFillRectangleCommand()
Log_DebugPrintf("Fill VRAM rectangle offset=(%u,%u), size=(%u,%u)", dst_x, dst_y, width, height);
FillVRAM(dst_x, dst_y, width, height, color);
if (width > 0 && height > 0)
FillVRAM(dst_x, dst_y, width, height, color);
m_stats.num_vram_fills++;
AddCommandTicks(46 + ((width / 8) + 9) * height);
EndCommand();