Add manifest support for pass declarations
This commit is contained in:
@@ -81,15 +81,19 @@ int main()
|
||||
if (packageIt == packagesById.end())
|
||||
continue;
|
||||
|
||||
std::string fragmentShaderSource;
|
||||
std::string compileError;
|
||||
if (!compiler.BuildLayerFragmentShaderSource(packageIt->second, fragmentShaderSource, compileError))
|
||||
const ShaderPackage& shaderPackage = packageIt->second;
|
||||
for (const ShaderPassDefinition& pass : shaderPackage.passes)
|
||||
{
|
||||
Fail("Shader package '" + packageId + "' failed Slang validation: " + compileError);
|
||||
continue;
|
||||
std::string fragmentShaderSource;
|
||||
std::string compileError;
|
||||
if (!compiler.BuildPassFragmentShaderSource(shaderPackage, pass, fragmentShaderSource, compileError))
|
||||
{
|
||||
Fail("Shader package '" + packageId + "' pass '" + pass.id + "' failed Slang validation: " + compileError);
|
||||
continue;
|
||||
}
|
||||
if (fragmentShaderSource.find("#version 430 core") == std::string::npos)
|
||||
Fail("Shader package '" + packageId + "' pass '" + pass.id + "' generated GLSL without the expected patched GLSL version header.");
|
||||
}
|
||||
if (fragmentShaderSource.find("#version 430 core") == std::string::npos)
|
||||
Fail("Shader package '" + packageId + "' generated GLSL without the expected patched GLSL version header.");
|
||||
}
|
||||
|
||||
std::error_code removeError;
|
||||
|
||||
Reference in New Issue
Block a user