MaterialX: split standard_surface into basic nodes #26

Merged
Bogdan Nagirniak merged 11 commits from matx-principlebsdf-split into matx-export-material 2023-09-21 10:58:14 +02:00
Showing only changes of commit d7e53b9d7e - Show all commits

View File

@ -650,40 +650,40 @@ NODE_SHADER_MATERIALX_BEGIN
NodeItem rotation = b_inputs.find("specular_rotation")->second; NodeItem rotation = b_inputs.find("specular_rotation")->second;
res = create_node("standard_surface", res = create_node("standard_surface",
NodeItem::Type::SurfaceShader, NodeItem::Type::SurfaceShader,
{ {
{"base", val(1.0f)}, {"base", val(1.0f)},
{"base_color", base_color}, {"base_color", base_color},
{"diffuse_roughness", roughness}, {"diffuse_roughness", roughness},
{"metalness", b_inputs.find("metalness")->second}, {"metalness", b_inputs.find("metalness")->second},
{"specular", b_inputs.find("specular")->second}, {"specular", b_inputs.find("specular")->second},
{"specular_color", base_color}, {"specular_color", base_color},
{"specular_roughness", roughness}, {"specular_roughness", roughness},
{"specular_IOR", ior}, {"specular_IOR", ior},
{"specular_anisotropy", anisotropic}, {"specular_anisotropy", anisotropic},
{"specular_rotation", rotation}, {"specular_rotation", rotation},
{"transmission", b_inputs.find("transmission")->second}, {"transmission", b_inputs.find("transmission")->second},
{"transmission_color", base_color}, {"transmission_color", base_color},
{"transmission_extra_roughness", roughness}, {"transmission_extra_roughness", roughness},
{"subsurface", b_inputs.find("subsurface")->second}, {"subsurface", b_inputs.find("subsurface")->second},
{"subsurface_color", base_color}, {"subsurface_color", base_color},
{"subsurface_radius", b_inputs.find("subsurface_radius")->second}, {"subsurface_radius", b_inputs.find("subsurface_radius")->second},
{"subsurface_anisotropy", anisotropic}, {"subsurface_anisotropy", anisotropic},
{"sheen", b_inputs.find("sheen")->second}, {"sheen", b_inputs.find("sheen")->second},
{"sheen_color", base_color}, {"sheen_color", base_color},
{"sheen_roughness", roughness}, {"sheen_roughness", roughness},
{"coat", b_inputs.find("coat")->second}, {"coat", b_inputs.find("coat")->second},
{"coat_color", base_color}, {"coat_color", base_color},
{"coat_roughness", b_inputs.find("coat_roughness")->second}, {"coat_roughness", b_inputs.find("coat_roughness")->second},
{"coat_IOR", ior}, {"coat_IOR", ior},
{"coat_anisotropy", anisotropic}, {"coat_anisotropy", anisotropic},
{"coat_rotation", rotation}, {"coat_rotation", rotation},
{"coat_normal", b_inputs.find("coat_normal")->second}, {"coat_normal", b_inputs.find("coat_normal")->second},
{"emission", e_inputs.find("emission")->second}, {"emission", e_inputs.find("emission")->second},
{"emission_color", e_inputs.find("emission_color")->second}, {"emission_color", e_inputs.find("emission_color")->second},
{"normal", b_inputs.find("normal")->second}, {"normal", b_inputs.find("normal")->second},
{"tangent", b_inputs.find("tangent")->second}, {"tangent", b_inputs.find("tangent")->second},
}); });
} }
return res; return res;