mirror of
https://github.com/dolphin-emu/dolphin.git
synced 2025-07-22 22:00:39 -06:00
Texture Cache Base: Move PAL vertical scaling to be baked into the texture size. This saves on a number of multiplications and fixes an issue where we were multiplying the y-scaling factor by the srcRectangle's height + 1 which was causing a crash in some GC titles
This commit is contained in:
@ -252,12 +252,14 @@ static void BPWritten(const BPCmd& bp)
|
||||
|
||||
float num_xfb_lines = 1.0f + bpmem.copyTexSrcWH.y * yScale;
|
||||
|
||||
srcRect.bottom = (int)(bpmem.copyTexSrcXY.y + num_xfb_lines);
|
||||
|
||||
u32 height = static_cast<u32>(num_xfb_lines);
|
||||
|
||||
DEBUG_LOG(VIDEO, "RenderToXFB: destAddr: %08x | srcRect {%d %d %d %d} | fbWidth: %u | "
|
||||
"fbStride: %u | fbHeight: %u",
|
||||
"fbStride: %u | fbHeight: %u | yScale: %f",
|
||||
destAddr, srcRect.left, srcRect.top, srcRect.right, srcRect.bottom,
|
||||
bpmem.copyTexSrcWH.x + 1, destStride, height);
|
||||
bpmem.copyTexSrcWH.x + 1, destStride, height, yScale);
|
||||
|
||||
bool is_depth_copy = bpmem.zcontrol.pixel_format == PEControl::Z24;
|
||||
g_texture_cache->CopyRenderTargetToTexture(destAddr, EFBCopyFormat::XFB, destStride,
|
||||
|
Reference in New Issue
Block a user