|
|
|
@ -289,10 +289,7 @@ namespace UnitTest
|
|
|
|
m_testMaterialSrgLayout->AddShaderInput(RHI::ShaderInputImageDescriptor{ Name{ "m_image" }, RHI::ShaderInputImageAccess::Read, RHI::ShaderInputImageType::Image2D, 1, 1 });
|
|
|
|
m_testMaterialSrgLayout->AddShaderInput(RHI::ShaderInputImageDescriptor{ Name{ "m_image" }, RHI::ShaderInputImageAccess::Read, RHI::ShaderInputImageType::Image2D, 1, 1 });
|
|
|
|
EXPECT_TRUE(m_testMaterialSrgLayout->Finalize());
|
|
|
|
EXPECT_TRUE(m_testMaterialSrgLayout->Finalize());
|
|
|
|
|
|
|
|
|
|
|
|
AZStd::vector<RPI::ShaderOptionValuePair> optionValues;
|
|
|
|
AZStd::vector<RPI::ShaderOptionValuePair> optionValues = CreateEnumShaderOptionValues({"Low", "Med", "High"});
|
|
|
|
optionValues.push_back({Name("Low"), RPI::ShaderOptionValue(0)});
|
|
|
|
|
|
|
|
optionValues.push_back({Name("Med"), RPI::ShaderOptionValue(1)});
|
|
|
|
|
|
|
|
optionValues.push_back({Name("High"), RPI::ShaderOptionValue(2)});
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Ptr<ShaderOptionGroupLayout> shaderOptions = ShaderOptionGroupLayout::Create();
|
|
|
|
Ptr<ShaderOptionGroupLayout> shaderOptions = ShaderOptionGroupLayout::Create();
|
|
|
|
uint32_t order = 0;
|
|
|
|
uint32_t order = 0;
|
|
|
|
@ -703,10 +700,7 @@ namespace UnitTest
|
|
|
|
{
|
|
|
|
{
|
|
|
|
// Set up the shaders...
|
|
|
|
// Set up the shaders...
|
|
|
|
|
|
|
|
|
|
|
|
AZStd::vector<RPI::ShaderOptionValuePair> optionValues;
|
|
|
|
AZStd::vector<RPI::ShaderOptionValuePair> optionValues = CreateEnumShaderOptionValues({"Low", "Med", "High"});
|
|
|
|
optionValues.push_back({Name("Low"), RPI::ShaderOptionValue(0)});
|
|
|
|
|
|
|
|
optionValues.push_back({Name("Med"), RPI::ShaderOptionValue(1)});
|
|
|
|
|
|
|
|
optionValues.push_back({Name("High"), RPI::ShaderOptionValue(2)});
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Ptr<ShaderOptionGroupLayout> shaderOptions = ShaderOptionGroupLayout::Create();
|
|
|
|
Ptr<ShaderOptionGroupLayout> shaderOptions = ShaderOptionGroupLayout::Create();
|
|
|
|
uint32_t order = 0;
|
|
|
|
uint32_t order = 0;
|
|
|
|
@ -1072,10 +1066,7 @@ namespace UnitTest
|
|
|
|
{
|
|
|
|
{
|
|
|
|
// Setup the shader...
|
|
|
|
// Setup the shader...
|
|
|
|
|
|
|
|
|
|
|
|
AZStd::vector<RPI::ShaderOptionValuePair> optionValues;
|
|
|
|
AZStd::vector<RPI::ShaderOptionValuePair> optionValues = CreateEnumShaderOptionValues({"Low", "Med", "High"});
|
|
|
|
optionValues.push_back({ Name("Low"), RPI::ShaderOptionValue(0) });
|
|
|
|
|
|
|
|
optionValues.push_back({ Name("Med"), RPI::ShaderOptionValue(1) });
|
|
|
|
|
|
|
|
optionValues.push_back({ Name("High"), RPI::ShaderOptionValue(2) });
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
uint32_t order = 0;
|
|
|
|
uint32_t order = 0;
|
|
|
|
|
|
|
|
|
|
|
|
@ -1402,9 +1393,7 @@ namespace UnitTest
|
|
|
|
layeredMaterialSrgLayout->AddShaderInput(RHI::ShaderInputConstantDescriptor{ Name{ "m_blendFactor" }, 4, 4, 0 });
|
|
|
|
layeredMaterialSrgLayout->AddShaderInput(RHI::ShaderInputConstantDescriptor{ Name{ "m_blendFactor" }, 4, 4, 0 });
|
|
|
|
layeredMaterialSrgLayout->Finalize();
|
|
|
|
layeredMaterialSrgLayout->Finalize();
|
|
|
|
|
|
|
|
|
|
|
|
AZStd::vector<RPI::ShaderOptionValuePair> boolOptionValues;
|
|
|
|
AZStd::vector<RPI::ShaderOptionValuePair> boolOptionValues = CreateBoolShaderOptionValues();
|
|
|
|
boolOptionValues.push_back({Name("False"), RPI::ShaderOptionValue(0)});
|
|
|
|
|
|
|
|
boolOptionValues.push_back({Name("True"), RPI::ShaderOptionValue(1)});
|
|
|
|
|
|
|
|
Ptr<ShaderOptionGroupLayout> shaderOptionsLayout = ShaderOptionGroupLayout::Create();
|
|
|
|
Ptr<ShaderOptionGroupLayout> shaderOptionsLayout = ShaderOptionGroupLayout::Create();
|
|
|
|
uint32_t order = 0;
|
|
|
|
uint32_t order = 0;
|
|
|
|
shaderOptionsLayout->AddShaderOption(ShaderOptionDescriptor{Name{"o_layer2_clearCoat_enable"}, ShaderOptionType::Boolean, 0, order++, boolOptionValues, Name{"False"}});
|
|
|
|
shaderOptionsLayout->AddShaderOption(ShaderOptionDescriptor{Name{"o_layer2_clearCoat_enable"}, ShaderOptionType::Boolean, 0, order++, boolOptionValues, Name{"False"}});
|
|
|
|
|