mirror of
https://github.com/dolphin-emu/dolphin.git
synced 2025-07-21 21:30:19 -06:00
VideoCommon: Fix upper and lower depth bytes being switched when performing Z16L EFB copies (EFB to texture only).
Fixes issue 4989. Fixes issue 5056.
This commit is contained in:
@ -472,8 +472,10 @@ void TextureCache::CopyRenderTargetToTexture(u32 dstAddr, unsigned int dstFormat
|
|||||||
cbufid = 5;
|
cbufid = 5;
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case 12: // Z16L
|
case 12: // Z16L - copy lower 16 depth bits
|
||||||
colmat[2] = colmat[6] = colmat[10] = colmat[13] = 1.0f;
|
// expected to be used as an IA8 texture (upper 8 bits stored as intensity, lower 8 bits stored as alpha)
|
||||||
|
// Used e.g. in Zelda: Skyward Sword
|
||||||
|
colmat[1] = colmat[5] = colmat[9] = colmat[14] = 1.0f;
|
||||||
cbufid = 6;
|
cbufid = 6;
|
||||||
break;
|
break;
|
||||||
|
|
||||||
@ -483,7 +485,6 @@ void TextureCache::CopyRenderTargetToTexture(u32 dstAddr, unsigned int dstFormat
|
|||||||
cbufid = 7;
|
cbufid = 7;
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
else if (isIntensity)
|
else if (isIntensity)
|
||||||
{
|
{
|
||||||
|
Reference in New Issue
Block a user