Let hfm prep calculate OBJ model extents

This commit is contained in:
sabrina-shanman 2019-10-28 13:05:27 -07:00
parent 9fd76cac84
commit 993aa06301

View file

@ -675,7 +675,6 @@ HFMModel::Pointer OBJSerializer::read(const hifi::ByteArray& data, const hifi::V
_url = url;
bool combineParts = mapping.value("combineParts").toBool();
hfmModel.meshExtents.reset();
hfmModel.meshes.push_back(HFMMesh());
std::vector<QString> materialNamePerShape;
@ -826,12 +825,6 @@ HFMModel::Pointer OBJSerializer::read(const hifi::ByteArray& data, const hifi::V
}
}
}
mesh.meshExtents.reset();
foreach(const glm::vec3& vertex, mesh.vertices) {
mesh.meshExtents.addPoint(vertex);
hfmModel.meshExtents.addPoint(vertex);
}
// hfmDebugDump(hfmModel);
} catch(const std::exception& e) {