3MF-Importer: remove unused variable.
authorKim Kulling <kim.kulling@googlemail.com>
Sun, 16 Oct 2016 15:14:22 +0000 (17:14 +0200)
committerKim Kulling <kim.kulling@googlemail.com>
Sun, 16 Oct 2016 15:14:22 +0000 (17:14 +0200)
code/D3MFImporter.cpp

index 32b8700..98afb7d 100644 (file)
@@ -113,7 +113,7 @@ public:
         std::vector<aiNode*> children;
 
         while(ReadToEndElement(D3MF::XmlTag::model))
-        {         
+        {
 
             if(xmlReader->getNodeName() == D3MF::XmlTag::object)
             {
@@ -123,7 +123,7 @@ public:
             {
 
             }
-        }        
+        }
 
         if(scene->mRootNode->mName.length == 0)
             scene->mRootNode->mName.Set("3MF");
@@ -143,24 +143,23 @@ public:
 
 private:
     aiNode* ReadObject(aiScene* scene)
-    {        
+    {
         ScopeGuard<aiNode> node(new aiNode());
 
         std::vector<unsigned long> meshIds;
 
-        int id = std::atoi(xmlReader->getAttributeValue(D3MF::XmlTag::id.c_str()));
         std::string name(xmlReader->getAttributeValue(D3MF::XmlTag::name.c_str()));
         std::string type(xmlReader->getAttributeValue(D3MF::XmlTag::type.c_str()));
 
         node->mParent = scene->mRootNode;
-        node->mName.Set(name);        
+        node->mName.Set(name);
 
         unsigned long meshIdx = meshes.size();
 
         while(ReadToEndElement(D3MF::XmlTag::object))
         {
             if(xmlReader->getNodeName() == D3MF::XmlTag::mesh)
-            {                
+            {
                 auto mesh = ReadMesh();
 
                 mesh->mName.Set(name);
@@ -186,7 +185,7 @@ private:
         aiMesh* mesh = new aiMesh();
 
         while(ReadToEndElement(D3MF::XmlTag::mesh))
-        {            
+        {
             if(xmlReader->getNodeName() == D3MF::XmlTag::vertices)
             {
                 ImportVertices(mesh);
@@ -204,12 +203,12 @@ private:
 
     void ImportVertices(aiMesh* mesh)
     {
-        std::vector<aiVector3D> vertices;        
+        std::vector<aiVector3D> vertices;
 
         while(ReadToEndElement(D3MF::XmlTag::vertices))
-        {                        
+        {
             if(xmlReader->getNodeName() == D3MF::XmlTag::vertex)
-            {                
+            {
                 vertices.push_back(ReadVertex());
             }
         }
@@ -220,7 +219,7 @@ private:
 
     }
     aiVector3D ReadVertex()
-    {        
+    {
         aiVector3D vertex;
         vertex.x = ai_strtof(xmlReader->getAttributeValue(D3MF::XmlTag::x.c_str()), nullptr);
         vertex.y = ai_strtof(xmlReader->getAttributeValue(D3MF::XmlTag::y.c_str()), nullptr);
@@ -231,7 +230,7 @@ private:
 
     void ImportTriangles(aiMesh* mesh)
     {
-         std::vector<aiFace> faces;         
+         std::vector<aiFace> faces;
 
 
          while(ReadToEndElement(D3MF::XmlTag::triangles))
@@ -337,7 +336,7 @@ D3MFImporter::~D3MFImporter()
 }
 
 bool D3MFImporter::CanRead(const std::string &pFile, IOSystem *pIOHandler, bool checkSig) const
-{    
+{
     const std::string extension = GetExtension(pFile);
     if(extension == "3mf") {
         return true;