mirror of
https://github.com/overte-org/overte.git
synced 2025-08-10 23:32:48 +02:00
Fix MaterialBaker not including names in baked multi-materials
This commit is contained in:
parent
d00ba2a9f1
commit
b711ee8b8a
2 changed files with 2 additions and 0 deletions
|
@ -318,6 +318,7 @@ public:
|
||||||
void setTextureTransforms(const Transform& transform, MaterialMappingMode mode, bool repeat);
|
void setTextureTransforms(const Transform& transform, MaterialMappingMode mode, bool repeat);
|
||||||
|
|
||||||
const std::string& getName() const { return _name; }
|
const std::string& getName() const { return _name; }
|
||||||
|
void setName(const std::string& name) { _name = name; }
|
||||||
|
|
||||||
const std::string& getModel() const { return _model; }
|
const std::string& getModel() const { return _model; }
|
||||||
void setModel(const std::string& model) { _model = model; }
|
void setModel(const std::string& model) { _model = model; }
|
||||||
|
|
|
@ -184,6 +184,7 @@ std::pair<std::string, std::shared_ptr<NetworkMaterial>> NetworkMaterialResource
|
||||||
auto nameJSON = materialJSON.value(key);
|
auto nameJSON = materialJSON.value(key);
|
||||||
if (nameJSON.isString()) {
|
if (nameJSON.isString()) {
|
||||||
name = nameJSON.toString().toStdString();
|
name = nameJSON.toString().toStdString();
|
||||||
|
material->setName(name);
|
||||||
}
|
}
|
||||||
} else if (key == "model") {
|
} else if (key == "model") {
|
||||||
auto modelJSON = materialJSON.value(key);
|
auto modelJSON = materialJSON.value(key);
|
||||||
|
|
Loading…
Reference in a new issue