Merge pull request #1940 from wanadev/gltf2-mesh-names

[glTF2] Added name to nodes
pull/1921/head^2
Kim Kulling 2018-05-03 20:32:45 +02:00 committed by GitHub
commit 5eb7928ce8
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 3 additions and 1 deletions

View File

@ -759,7 +759,7 @@ void glTF2Exporter::ExportMeshes()
if (c)
p.attributes.color.push_back(c);
}
/*************** Vertices indices ****************/
if (aim->mNumFaces > 0) {
std::vector<IndicesType> indices;
@ -891,6 +891,8 @@ unsigned int glTF2Exporter::ExportNodeHierarchy(const aiNode* n)
{
Ref<Node> node = mAsset->nodes.Create(mAsset->FindUniqueID(n->mName.C_Str(), "node"));
node->name = n->mName.C_Str();
if (!n->mTransformation.IsIdentity()) {
node->matrix.isPresent = true;
CopyValue(n->mTransformation, node->matrix.value);