From fdd7ee791cd37546390856f38eab16ea78451742 Mon Sep 17 00:00:00 2001 From: gdkchan Date: Sun, 1 Sep 2024 17:58:01 -0300 Subject: Fix incorrect depth texture 3D flag (#7262) --- src/Ryujinx.Graphics.Gpu/Image/TextureCache.cs | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) (limited to 'src/Ryujinx.Graphics.Gpu/Image/TextureCache.cs') diff --git a/src/Ryujinx.Graphics.Gpu/Image/TextureCache.cs b/src/Ryujinx.Graphics.Gpu/Image/TextureCache.cs index b9ff060e..b6fa842e 100644 --- a/src/Ryujinx.Graphics.Gpu/Image/TextureCache.cs +++ b/src/Ryujinx.Graphics.Gpu/Image/TextureCache.cs @@ -468,13 +468,11 @@ namespace Ryujinx.Graphics.Gpu.Image int gobBlocksInY = dsState.MemoryLayout.UnpackGobBlocksInY(); int gobBlocksInZ = dsState.MemoryLayout.UnpackGobBlocksInZ(); + layered &= size.UnpackIsLayered(); + Target target; - if (dsState.MemoryLayout.UnpackIsTarget3D()) - { - target = Target.Texture3D; - } - else if ((samplesInX | samplesInY) != 1) + if ((samplesInX | samplesInY) != 1) { target = size.Depth > 1 && layered ? Target.Texture2DMultisampleArray -- cgit v1.2.3