TextureCache: Simplify XFB reconstruction

This also better handles in-memory interlaced XFB data placed by the CPU
by considering the stride from the VI.
This commit is contained in:
Stenzek
2019-03-31 14:11:53 +10:00
parent dbaba0062a
commit 708bd3d9f7
8 changed files with 228 additions and 427 deletions

View File

@ -312,14 +312,13 @@ static void BPWritten(const BPCmd& bp)
if (g_ActiveConfig.bImmediateXFB)
{
// below div two to convert from bytes to pixels - it expects width, not stride
g_renderer->Swap(destAddr, destStride / 2, destStride / 2, height, srcRect,
CoreTiming::GetTicks());
g_renderer->Swap(destAddr, destStride / 2, destStride, height, CoreTiming::GetTicks());
}
else
{
if (FifoPlayer::GetInstance().IsRunningWithFakeVideoInterfaceUpdates())
{
VideoInterface::FakeVIUpdate(destAddr, srcRect.GetWidth(), height);
VideoInterface::FakeVIUpdate(destAddr, srcRect.GetWidth(), destStride, height);
}
}
}