From c08215621d1d7655f219cb18df787cb09ebebee6 Mon Sep 17 00:00:00 2001 From: mpa Date: Tue, 19 Nov 2013 11:32:06 +0000 Subject: [PATCH] - Modifing Geometry and Mesh Python scripts from SALOME 6 and before --- src/NETGENPlugin/NETGENPluginBuilder.py | 2 +- src/NETGENPlugin/NETGENPlugin_Mesher.cxx | 10 +++++++--- 2 files changed, 8 insertions(+), 4 deletions(-) diff --git a/src/NETGENPlugin/NETGENPluginBuilder.py b/src/NETGENPlugin/NETGENPluginBuilder.py index 11369c7..66e897f 100644 --- a/src/NETGENPlugin/NETGENPluginBuilder.py +++ b/src/NETGENPlugin/NETGENPluginBuilder.py @@ -27,7 +27,7 @@ from salome.smesh.smeshBuilder import AssureGeomPublished, ParseParameters, IsEq # import NETGENPlugin module if possible noNETGENPlugin = 0 try: - import NETGENPlugin + from salome.NETGENPlugin import NETGENPluginBuilder except ImportError: noNETGENPlugin = 1 pass diff --git a/src/NETGENPlugin/NETGENPlugin_Mesher.cxx b/src/NETGENPlugin/NETGENPlugin_Mesher.cxx index 6b4310c..0514939 100644 --- a/src/NETGENPlugin/NETGENPlugin_Mesher.cxx +++ b/src/NETGENPlugin/NETGENPlugin_Mesher.cxx @@ -1283,8 +1283,10 @@ void NETGENPlugin_Mesher::AddIntVerticesInSolids(const netgen::OCCGeometry& #ifdef DUMP_TRIANGLES_SCRIPT // create a python script making a mesh containing triangles added for internal vertices ofstream py(DUMP_TRIANGLES_SCRIPT); - py << "from smesh import * "<< endl - << "m = Mesh(name='triangles')" << endl; + py << "import SMESH"<< endl + << "from salome.smesh import smeshBuilder"<