gltfio: use the new material name feature.

To see proof that this works, use gltf_viewer with -u and examine the
node hierarchy. You will now see the correct material names instead of
the ubershader names.
This commit is contained in:
Philip Rideout
2020-05-08 11:24:38 -07:00
parent 38b9cf4fe3
commit 072d17d64f
3 changed files with 4 additions and 5 deletions
+2 -2
View File
@@ -381,9 +381,9 @@ MaterialInstance* MaterialGenerator::createMaterialInstance(MaterialKey* config,
Material* mat = createMaterial(mEngine, *config, *uvmap, label);
mCache.emplace(std::make_pair(*config, mat));
mMaterials.push_back(mat);
return mat->createInstance();
return mat->createInstance(label);
}
return iter->second->createInstance();
return iter->second->createInstance(label);
}
} // anonymous namespace