Add shader non-uniform indexing support

This PR marks ALL texture indexes as nonuniform to fix an issue with the paths in Tomodachi Life: Living the Dream on AMD cards. It should have a negligible impact on performance (and it should not have an impact at all on NVIDIA cards!)

It's caused by what is called 'implicit non-uniform sampler array indexing'. The idea is basically that some GPUs optimize texture lookups from indexed texture arrays, by assuming that you are never going to index different textures within a single workgroup. What this causes is that visual glitch where a subgroup is tasked with rendering a block of the screen, and in the boundaries some cores are indexing the wrong texture.

Co-authored-by: AsperTheDog <guillerman0000@gmail.com>
This commit is contained in:
AsperTheDog
2026-05-14 08:52:04 -05:00
committed by KeatonTheBot
co-authored by AsperTheDog
parent 55aded3a05
commit 541fa63330
11 changed files with 74 additions and 5 deletions
@@ -350,6 +350,10 @@ namespace Ryujinx.Graphics.Shader
{
return true;
}
bool QueryHostSupportsShaderNonUniformIndexing()
{
return false;
}
/// <summary>
/// Queries host GPU support for signed normalized buffer texture formats.