Only initialize shader outputs that are actually used on the next stage (#3054)
* Only initialize shader outputs that are actually used on the next stage * Shader cache version bump
This commit is contained in:
parent
b97ff4da5e
commit
0bcbe32367
5 changed files with 104 additions and 14 deletions
|
@ -308,7 +308,8 @@ namespace Ryujinx.Graphics.Shader.Decoders
|
|||
int attr = offset + elemIndex * 4;
|
||||
if (attr >= AttributeConsts.UserAttributeBase && attr < AttributeConsts.UserAttributeEnd)
|
||||
{
|
||||
int index = (attr - AttributeConsts.UserAttributeBase) / 16;
|
||||
int userAttr = attr - AttributeConsts.UserAttributeBase;
|
||||
int index = userAttr / 16;
|
||||
|
||||
if (isStore)
|
||||
{
|
||||
|
@ -316,7 +317,7 @@ namespace Ryujinx.Graphics.Shader.Decoders
|
|||
}
|
||||
else
|
||||
{
|
||||
config.SetInputUserAttribute(index, perPatch);
|
||||
config.SetInputUserAttribute(index, (userAttr >> 2) & 3, perPatch);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue