mirror of
https://github.com/HifiExperiments/overte.git
synced 2025-08-16 12:20:12 +02:00
Reintroducing the use of the DiffuseFactor so both Bender and MAya looks closer to Hifi
This commit is contained in:
parent
19cc0c2282
commit
5299b06e83
1 changed files with 6 additions and 3 deletions
|
@ -183,10 +183,13 @@ void FBXReader::consolidateFBXMaterials() {
|
|||
|
||||
// Finally create the true material representation
|
||||
material._material = std::make_shared<model::Material>();
|
||||
material._material->setEmissive(material.emissiveColor * material.emissiveFactor);
|
||||
|
||||
// Do not use the Diffuse Factor from FBX at all, this simpliies the export path
|
||||
auto diffuse = material.diffuseColor;
|
||||
// Emissive color is the mix of emissiveColor with emissiveFactor
|
||||
auto emissive = material.emissiveColor * material.emissiveFactor;
|
||||
material._material->setEmissive(emissive);
|
||||
|
||||
// Final diffuse color is the mix of diffuseColor with diffuseFactor
|
||||
auto diffuse = material.diffuseColor * material.diffuseFactor;
|
||||
material._material->setAlbedo(diffuse);
|
||||
|
||||
if (material.isPBSMaterial) {
|
||||
|
|
Loading…
Reference in a new issue