X-Git-Url: http://git.salome-platform.org/gitweb/?a=blobdiff_plain;f=src%2FSMESH_SWIG%2Fex30_tepal.py;h=f40a8284a5e3863b3c7ace63a8afa2da490db405;hb=079e65a9b152c9dec23fa91a346ac312b04eb145;hp=ef40850c874b7b9bb8383dae6cce52fcd9b6dafa;hpb=bd8f1aee7c78f7d2eb82bd4fec5e08c9e3d280ce;p=modules%2Fsmesh.git diff --git a/src/SMESH_SWIG/ex30_tepal.py b/src/SMESH_SWIG/ex30_tepal.py index ef40850c8..f40a8284a 100644 --- a/src/SMESH_SWIG/ex30_tepal.py +++ b/src/SMESH_SWIG/ex30_tepal.py @@ -1,10 +1,10 @@ # -*- coding: iso-8859-1 -*- -# Copyright (C) 2007-2013 CEA/DEN, EDF R&D, OPEN CASCADE +# Copyright (C) 2007-2014 CEA/DEN, EDF R&D, OPEN CASCADE # # This library is free software; you can redistribute it and/or # modify it under the terms of the GNU Lesser General Public # License as published by the Free Software Foundation; either -# version 2.1 of the License. +# version 2.1 of the License, or (at your option) any later version. # # This library is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the implied warranty of @@ -22,8 +22,15 @@ # import os -import geompy -import smesh +import salome +salome.salome_init() +import GEOM +from salome.geom import geomBuilder +geompy = geomBuilder.New(salome.myStudy) + +import SMESH, SALOMEDS +from salome.smesh import smeshBuilder +smesh = smeshBuilder.New(salome.myStudy) # Parameters # ---------- @@ -53,7 +60,7 @@ m = smesh.Mesh(cylinder) # 2D mesh with BLSURF # ------------------- -algo2d = m.Triangle(smesh.BLSURF) +algo2d = m.Triangle(smeshBuilder.BLSURF) algo2d.SetPhysicalMesh(1) algo2d.SetPhySize(5) @@ -63,7 +70,7 @@ algo2d.SetGeometricMesh(0) # 3D mesh with tepal # ------------------ -algo3d = m.Tetrahedron(smesh.GHS3DPRL) +algo3d = m.Tetrahedron(smeshBuilder.GHS3DPRL) algo3d.SetMEDName(results) algo3d.SetNbPart(4)