mirror of
https://git.salome-platform.org/gitpub/modules/geom.git
synced 2024-11-14 09:38:34 +05:00
17 lines
416 B
Python
17 lines
416 B
Python
|
# --- salome initialization
|
||
|
import salome
|
||
|
salome.salome_init()
|
||
|
|
||
|
# --- geom Python interface
|
||
|
import GEOM
|
||
|
from salome.geom import geomBuilder
|
||
|
geompy = geomBuilder.New(salome.myStudy)
|
||
|
|
||
|
# --- Create a box and publish it into the salome study
|
||
|
Box_1 = geompy.MakeBoxDXDYDZ(200, 200, 200)
|
||
|
geompy.addToStudy( Box_1, 'Box_1' )
|
||
|
|
||
|
# --- update the study object browser
|
||
|
if salome.sg.hasDesktop():
|
||
|
salome.sg.updateObjBrowser(1)
|