]> SALOME platform Git repositories - plugins/acisplugin.git/blobdiff - doc/salome/examples/ACISPlugindemo.py
Salome HOME
Implementation of ACISPLUGIN as a GEOM plugin (added files)
[plugins/acisplugin.git] / doc / salome / examples / ACISPlugindemo.py
diff --git a/doc/salome/examples/ACISPlugindemo.py b/doc/salome/examples/ACISPlugindemo.py
new file mode 100644 (file)
index 0000000..09ee7a0
--- /dev/null
@@ -0,0 +1,23 @@
+# Import/Export ACIS
+
+import salome
+salome.salome_init()
+import GEOM
+from salome.geom import geomBuilder
+geompy = geomBuilder.New(salome.myStudy)
+
+# Example of import from ACIS
+
+# get a path to SAMPLES_SRC
+import os
+thePath = os.getenv("DATA_DIR")
+# create filenames
+theFileName = thePath + "/Shapes/Sat/Bug841_Robot01_ACIS_15_Volumique.sat"
+
+# import shape
+Shape1 = geompy.ImportACIS(theFileName)
+geompy.addToStudy(Shape1, "Robot01_1")
+
+# It is possible also to use next format of importing and publishing in study
+
+Shape2 = geompy.ImportACIS(theFileName,"Robot01_2")