From 28dd7d80af56701887dbb538b56aa58edaf39d91 Mon Sep 17 00:00:00 2001 From: gdkchan Date: Wed, 18 Oct 2023 01:47:22 -0300 Subject: [PATCH] Enable copy between MS and non-MS textures with different height (#5801) --- src/Ryujinx.Graphics.Gpu/Image/TextureCompatibility.cs | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/src/Ryujinx.Graphics.Gpu/Image/TextureCompatibility.cs b/src/Ryujinx.Graphics.Gpu/Image/TextureCompatibility.cs index eafa50b2..3a0efcdd 100644 --- a/src/Ryujinx.Graphics.Gpu/Image/TextureCompatibility.cs +++ b/src/Ryujinx.Graphics.Gpu/Image/TextureCompatibility.cs @@ -374,6 +374,13 @@ namespace Ryujinx.Graphics.Gpu.Image return stride == rhs.Stride ? TextureViewCompatibility.CopyOnly : TextureViewCompatibility.LayoutIncompatible; } + else if (lhs.Target.IsMultisample() != rhs.Target.IsMultisample() && alignedWidthMatches && lhsAlignedSize.Height == rhsAlignedSize.Height) + { + // Copy between multisample and non-multisample textures with mismatching size is allowed, + // as long aligned size matches. + + return TextureViewCompatibility.CopyOnly; + } else { return TextureViewCompatibility.LayoutIncompatible;