From 36dfd20c879967fc67721ed46ac773d341aa80d9 Mon Sep 17 00:00:00 2001 From: gdkchan Date: Sun, 8 Apr 2018 17:09:41 -0300 Subject: Use correct pitch value when decoding linear swizzle textures --- Ryujinx.Graphics/Gpu/TextureFactory.cs | 3 +++ 1 file changed, 3 insertions(+) (limited to 'Ryujinx.Graphics/Gpu/TextureFactory.cs') diff --git a/Ryujinx.Graphics/Gpu/TextureFactory.cs b/Ryujinx.Graphics/Gpu/TextureFactory.cs index 0a0497f3..7f8580d9 100644 --- a/Ryujinx.Graphics/Gpu/TextureFactory.cs +++ b/Ryujinx.Graphics/Gpu/TextureFactory.cs @@ -20,6 +20,8 @@ namespace Ryujinx.Graphics.Gpu TextureSwizzle Swizzle = (TextureSwizzle)((Tic[2] >> 21) & 7); + int Pitch = (Tic[3] & 0xffff) << 5; + int BlockHeightLog2 = (Tic[3] >> 3) & 7; int BlockHeight = 1 << BlockHeightLog2; @@ -31,6 +33,7 @@ namespace Ryujinx.Graphics.Gpu TextureAddress, Width, Height, + Pitch, BlockHeight, Swizzle, Format); -- cgit v1.2.3