smesh/doc/salome/examples/transforming_meshes_ex02.py

17 lines
286 B
Python
Raw Normal View History

2013-02-12 20:37:44 +06:00
# Rotation
import math
import SMESH_mechanic
import SMESH
2013-02-12 20:37:44 +06:00
smesh = SMESH_mechanic.smesh
mesh = SMESH_mechanic.mesh
# define rotation axis and angle
axisXYZ = SMESH.AxisStruct(0., 0., 0., 5., 5., 20.)
2013-02-12 20:37:44 +06:00
angle270 = 1.5 * math.pi
# rotate a mesh
mesh.Rotate([], axisXYZ, angle270, 1)