Add initial support for shader binding sets (WIP)

This commit is contained in:
Jérôme Leclercq
2021-06-14 22:35:05 +02:00
parent 815a7b0c62
commit f22b501e25
53 changed files with 885 additions and 511 deletions

View File

@@ -29,6 +29,7 @@ namespace Nz
Layout, //< Struct layout (struct only) - has argument style
Location, //< Location (struct member only) - has argument index
Option, //< Conditional compilation option - has argument expr
Set, //< Binding set (external var only) - has argument index
};
enum class BinaryType

View File

@@ -83,7 +83,7 @@ namespace Nz::ShaderAst
struct StructMember
{
std::optional<BuiltinEntry> builtin;
std::optional<unsigned int> locationIndex;
std::optional<UInt32> locationIndex;
std::string name;
ExpressionType type;
};

View File

@@ -252,7 +252,8 @@ namespace Nz::ShaderAst
struct ExternalVar
{
std::optional<unsigned int> bindingIndex;
std::optional<UInt32> bindingIndex;
std::optional<UInt32> bindingSet;
std::string name;
ExpressionType type;
};