Blob Blame History Raw
diff -rupN gmsh-2.8.5-source/Mesh/meshGRegion.cpp gmsh-2.8.5-source-new/Mesh/meshGRegion.cpp
--- gmsh-2.8.5-source/Mesh/meshGRegion.cpp	2014-07-09 10:52:24.000000000 +0200
+++ gmsh-2.8.5-source-new/Mesh/meshGRegion.cpp	2014-07-23 15:58:11.811862790 +0200
@@ -1156,8 +1156,10 @@ bool CreateAnEmptyVolumeMesh(GRegion *gr
   sprintf(opts, "-Ype%c",
 	  (Msg::GetVerbosity() < 3) ? 'Q':
 	  (Msg::GetVerbosity() > 6) ? 'V': '\0');
+  tetgenbehavior behaviour;
+  behaviour.parse_commandline(opts);
   try{
-    tetrahedralize(opts, &in, &out);
+    tetrahedralize(&behaviour, &in, &out);
   }
   catch (int error){
     Msg::Error("Self intersecting surface mesh");
@@ -1210,6 +1212,7 @@ void MeshDelaunayVolumeTetgen(std::vecto
   // this in block, so in/out are destroyed before we refine the mesh)
   splitQuadRecovery sqr;
   {
+    tetgenbehavior behaviour;
     tetgenio in, out;
     std::vector<MVertex*> numberedV;
     char opts[128];
@@ -1237,15 +1240,19 @@ void MeshDelaunayVolumeTetgen(std::vecto
       // sprintf(opts, "-q3.5Ype%c", (Msg::GetVerbosity() < 3) ? 'Q':
       //        (Msg::GetVerbosity() > 6) ? 'V': '\0');*/
     }
+    behaviour = tetgenbehavior();
+    behaviour.parse_commandline(opts);
     try{
-      tetrahedralize(opts, &in, &out);
+      tetrahedralize(&behaviour, &in, &out);
     }
     catch (int error){
       Msg::Error("Self intersecting surface mesh, computing intersections "
                  "(this could take a while)");
       sprintf(opts, "dV");
       try{
-        tetrahedralize(opts, &in, &out);
+        behaviour = tetgenbehavior();
+        behaviour.parse_commandline(opts);
+        tetrahedralize(&behaviour, &in, &out);
         Msg::Info("%d intersecting faces have been saved into 'intersect.pos'",
                   out.numberoftrifaces);
         FILE *fp = Fopen("intersect.pos", "w");