Salome HOME
#16822 EDF 19295 - Advanced options for meshgems
[plugins/hybridplugin.git] / doc / salome / examples / hybriddemo.py
1 import salome
2 salome.salome_init()
3 import GEOM
4 from salome.geom import geomBuilder
5 geompy = geomBuilder.New()
6
7 import SMESH, SALOMEDS
8 from salome.smesh import smeshBuilder
9 smesh =  smeshBuilder.New()
10
11 # create a box
12 box = geompy.MakeBoxDXDYDZ(200., 200., 200.)
13 geompy.addToStudy(box, "box")
14
15 # create a mesh on the box
16 hybridMesh = smesh.Mesh(box,"box: MG-Hybrid and BLSurf mesh")
17
18 # create a BLSurf algorithm for faces
19 BLSURF = hybridMesh.Triangle(algo=smeshBuilder.BLSURF)
20 HYBRID = hybridMesh.Tetrahedron(algo=smeshBuilder.HYBRID)
21
22 # compute the mesh
23 hybridMesh.Compute()
24
25 # End of script
26