Salome HOME
Adding control of netgen log file
[plugins/netgenplugin.git] / src / NETGENPlugin / NETGENPlugin_NETGEN_3D_SA.cxx
index bddb65cd52f99c88f8ecbd0a17075da1bfecf4f9..6dfc1003a59579c18255f6085aca1268d48b07b4 100644 (file)
@@ -202,6 +202,11 @@ bool NETGENPlugin_NETGEN_3D_SA::Compute(TopoDS_Shape &aShape, SMESH_Mesh& aMesh,
   int endWith   = netgen::MESHCONST_OPTVOLUME;
   int Netgen_NbOfNodes=0;
 
+  // Changing netgen log_file putting it next to new_element_file
+  fs::path netgen_log_file = fs::path(new_element_file).remove_filename() / fs::path("NETGEN.out");
+
+  ngLib.setOutputFile(netgen_log_file.string());
+
   NETGENPlugin_NETGEN_3D::computeFillNgMesh(aMesh, aShape, nodeVec, ngLib, helper, Netgen_NbOfNodes);
 
   netgen::OCCGeometry occgeo;