]> https://gitweb.dealii.org/ - dealii.git/commitdiff
Add read_assimp inside GridIn<dim,spacedim>::read(std::string) 10907/head
authorBruno Turcksin <bruno.turcksin@gmail.com>
Fri, 11 Sep 2020 21:01:43 +0000 (21:01 +0000)
committerBruno Turcksin <bruno.turcksin@gmail.com>
Fri, 11 Sep 2020 21:01:43 +0000 (21:01 +0000)
source/grid/grid_in.cc

index 421e30db9c2287bc95478b86e7b72ba19d491884..84eec6bef3d221ef548b2d35b9d97bb117b50474 100644 (file)
@@ -3036,7 +3036,6 @@ GridIn<dim, spacedim>::read(const std::string &filename, Format format)
   else
     name = search.find(filename, default_suffix(format));
 
-  std::ifstream in(name.c_str());
 
   if (format == Default)
     {
@@ -3049,7 +3048,16 @@ GridIn<dim, spacedim>::read(const std::string &filename, Format format)
           format          = parse_format(ext);
         }
     }
-  read(in, format);
+
+  if (format == assimp)
+    {
+      read_assimp(name);
+    }
+  else
+    {
+      std::ifstream in(name.c_str());
+      read(in, format);
+    }
 }
 
 

In the beginning the Universe was created. This has made a lot of people very angry and has been widely regarded as a bad move.

Douglas Adams


Typeset in Trocchi and Trocchi Bold Sans Serif.