Commit 8662a68a authored by Martin Schultz's avatar Martin Schultz

added postprocessing step to fix degenerates in assimp, bacuase trying

to add degenerates violates assertions
parent 240e752f
......@@ -335,9 +335,9 @@ int AssimpPlugin::loadObject(QString _filename) {
const aiScene* scene = NULL;
if (type_ == DATA_TRIANGLE_MESH)
scene = importer.ReadFile(_filename.toStdString(), aiProcess_JoinIdenticalVertices | aiProcess_Triangulate);
scene = importer.ReadFile(_filename.toStdString(), aiProcess_JoinIdenticalVertices | aiProcess_Triangulate | aiProcess_FindDegenerates);
else
scene = importer.ReadFile(_filename.toStdString(), aiProcess_JoinIdenticalVertices);
scene = importer.ReadFile(_filename.toStdString(), aiProcess_JoinIdenticalVertices | aiProcess_FindDegenerates);
if (!scene) {
emit log(LOGERR, tr(importer.GetErrorString()));
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment