diff options
Diffstat (limited to 'Ryujinx.Graphics.Shader/CodeGen/Glsl/CodeGenContext.cs')
-rw-r--r-- | Ryujinx.Graphics.Shader/CodeGen/Glsl/CodeGenContext.cs | 20 |
1 files changed, 4 insertions, 16 deletions
diff --git a/Ryujinx.Graphics.Shader/CodeGen/Glsl/CodeGenContext.cs b/Ryujinx.Graphics.Shader/CodeGen/Glsl/CodeGenContext.cs index 418af6cb..9eb20f6f 100644 --- a/Ryujinx.Graphics.Shader/CodeGen/Glsl/CodeGenContext.cs +++ b/Ryujinx.Graphics.Shader/CodeGen/Glsl/CodeGenContext.cs @@ -10,12 +10,12 @@ namespace Ryujinx.Graphics.Shader.CodeGen.Glsl public StructuredFunction CurrentFunction { get; set; } + public StructuredProgramInfo Info { get; } + public ShaderConfig Config { get; } public OperandManager OperandManager { get; } - private readonly StructuredProgramInfo _info; - private readonly StringBuilder _sb; private int _level; @@ -24,7 +24,7 @@ namespace Ryujinx.Graphics.Shader.CodeGen.Glsl public CodeGenContext(StructuredProgramInfo info, ShaderConfig config) { - _info = info; + Info = info; Config = config; OperandManager = new OperandManager(); @@ -72,19 +72,7 @@ namespace Ryujinx.Graphics.Shader.CodeGen.Glsl public StructuredFunction GetFunction(int id) { - return _info.Functions[id]; - } - - public TransformFeedbackOutput GetTransformFeedbackOutput(int location, int component) - { - int index = (AttributeConsts.UserAttributeBase / 4) + location * 4 + component; - return _info.TransformFeedbackOutputs[index]; - } - - public TransformFeedbackOutput GetTransformFeedbackOutput(int location) - { - int index = location / 4; - return _info.TransformFeedbackOutputs[index]; + return Info.Functions[id]; } private void UpdateIndentation() |