mirror of
https://github.com/Ryujinx/Ryujinx.git
synced 2025-08-07 04:42:33 -07:00
Fix IoMap variable names
Output struct Lazy Vertex IO Output fixes Fix output struct definition MSL Binding Model description Might need tweaks/adjustments Cleanup Typo + Format
This commit is contained in:
committed by
Isaac Marovitz
parent
d5758cb310
commit
98e2ab5a49
@@ -51,7 +51,7 @@ namespace Ryujinx.Graphics.Shader.CodeGen.Msl
|
||||
context.AppendLine(GetFunctionSignature(context, function, stage, isMainFunc));
|
||||
context.EnterScope();
|
||||
|
||||
Declarations.DeclareLocals(context, function);
|
||||
Declarations.DeclareLocals(context, function, stage);
|
||||
|
||||
PrintBlock(context, function.MainBlock, isMainFunc);
|
||||
|
||||
@@ -77,6 +77,7 @@ namespace Ryujinx.Graphics.Shader.CodeGen.Msl
|
||||
|
||||
string funcKeyword = "inline";
|
||||
string funcName = null;
|
||||
string returnType = Declarations.GetVarTypeName(context, function.ReturnType);
|
||||
|
||||
if (isMainFunc)
|
||||
{
|
||||
@@ -84,6 +85,7 @@ namespace Ryujinx.Graphics.Shader.CodeGen.Msl
|
||||
{
|
||||
funcKeyword = "vertex";
|
||||
funcName = "vertexMain";
|
||||
returnType = "VertexOutput";
|
||||
}
|
||||
else if (stage == ShaderStage.Fragment)
|
||||
{
|
||||
@@ -112,7 +114,7 @@ namespace Ryujinx.Graphics.Shader.CodeGen.Msl
|
||||
}
|
||||
}
|
||||
|
||||
return $"{funcKeyword} {Declarations.GetVarTypeName(context, function.ReturnType)} {funcName ?? function.Name}({string.Join(", ", args)})";
|
||||
return $"{funcKeyword} {returnType} {funcName ?? function.Name}({string.Join(", ", args)})";
|
||||
}
|
||||
|
||||
private static void PrintBlock(CodeGenContext context, AstBlock block, bool isMainFunction)
|
||||
|
Reference in New Issue
Block a user