Fix SSBO array

This commit is contained in:
gdkchan 2018-03-23 22:23:41 -03:00
parent 8ed55be9c5
commit 63243d16ad
2 changed files with 5 additions and 6 deletions

View file

@ -77,7 +77,9 @@ namespace Ryujinx.Graphics.Gal.Shader
StringBuilder SB = new StringBuilder();
PrintDeclUBOs(SB);
SB.AppendLine("#version 430");
PrintDeclSSBOs(SB);
PrintDeclInAttributes(SB);
PrintDeclOutAttributes(SB);
@ -94,12 +96,12 @@ namespace Ryujinx.Graphics.Gal.Shader
return SB.ToString();
}
private void PrintDeclUBOs(StringBuilder SB)
private void PrintDeclSSBOs(StringBuilder SB)
{
foreach (int Cbuf in UsedCbufs)
{
SB.AppendLine($"layout(std430, binding = {Cbuf}) buffer {CbufBuffPrefix}{Cbuf} {{");
SB.AppendLine($"{IdentationStr}float[] {CbufDataName};");
SB.AppendLine($"{IdentationStr}float {CbufDataName}[];");
SB.AppendLine("};");
SB.AppendLine(string.Empty);
}

View file

@ -1,6 +1,3 @@
using System;
using System.Collections.Generic;
namespace Ryujinx.Graphics.Gal.Shader
{
public static class ShaderTest