diff options
| author | riperiperi <rhy3756547@hotmail.com> | 2020-11-06 17:45:30 +0000 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2020-11-06 18:45:30 +0100 |
| commit | a16f201a6f7bd06a3a366b622a6d6c91895e2984 (patch) | |
| tree | a1bf1f3e9ccd01e9c3eae12689f28c99889aa058 | |
| parent | 24dbfc0fe6e0b98455811632dece3393e7f24851 (diff) | |
Do not align sizes for buffer texture targets. (#1671)
This should fix a random crash in Hyrule Warriors, and potentially other games that use buffer textures.
| -rw-r--r-- | Ryujinx.Graphics.Gpu/Image/TextureCompatibility.cs | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/Ryujinx.Graphics.Gpu/Image/TextureCompatibility.cs b/Ryujinx.Graphics.Gpu/Image/TextureCompatibility.cs index 6b85e49a..2507519b 100644 --- a/Ryujinx.Graphics.Gpu/Image/TextureCompatibility.cs +++ b/Ryujinx.Graphics.Gpu/Image/TextureCompatibility.cs @@ -274,7 +274,9 @@ namespace Ryujinx.Graphics.Gpu.Image return false; } - if (alignSizes) + bool isTextureBuffer = lhs.Target == Target.TextureBuffer || rhs.Target == Target.TextureBuffer; + + if (alignSizes && !isTextureBuffer) { Size size0 = GetAlignedSize(lhs); Size size1 = GetAlignedSize(rhs); |
