# Extrusion along a Path
import math
+
import salome
+salome.salome_init()
+import GEOM
+from salome.geom import geomBuilder
+geompy = geomBuilder.New(salome.myStudy)
-# Geometry
-import geompy
+import SMESH, SALOMEDS
+from salome.smesh import smeshBuilder
+smesh = smeshBuilder.New(salome.myStudy)
# 1. Create points
points = [[0, 0], [50, 30], [50, 110], [0, 150], [-80, 150], [-130, 70], [-130, -20]]
pass
# Mesh
-import smesh
# Mesh the given shape with the given 1d hypothesis
def Mesh1D(shape1d, nbSeg, name):
# ExtrusionAlongPath
# IDsOfElements, PathMesh, PathShape, NodeStart,
# HasAngles, Angles, HasRefPoint, RefPoint
-refPoint = smesh.PointStruct(0, 0, 0)
+refPoint = SMESH.PointStruct(0, 0, 0)
a10 = 10.0*math.pi/180.0
a45 = 45.0*math.pi/180.0