X-Git-Url: http://git.salome-platform.org/gitweb/?a=blobdiff_plain;f=doc%2Fsalome%2Fgui%2FGEOM%2Fbuilding_by_blocks.htm;h=e2cb299ad8b0242d076c1e9317660297c51fed6d;hb=c6a0df686bae87821d7acf929b4bb8f4ae3b1d78;hp=246c6f4366ed77d089d6947e8c1d93d2a2b3a0a7;hpb=3e9d56c09b4bb1f34cf25c95613ef7e12890a8cd;p=modules%2Fgeom.git diff --git a/doc/salome/gui/GEOM/building_by_blocks.htm b/doc/salome/gui/GEOM/building_by_blocks.htm index 246c6f436..e2cb299ad 100755 --- a/doc/salome/gui/GEOM/building_by_blocks.htm +++ b/doc/salome/gui/GEOM/building_by_blocks.htm @@ -15,6 +15,7 @@ if (navigator.appName !="Netscape") - -
+ +-
# create quadrangle face from four edges
+# create a quadrangle face from four edges
qface1 = geompy.MakeQuad(edge1, edge2, edge3, edge4)
-
# create quadrangle face on two edges
+# create a quadrangle face from two edges
qface2 = geompy.MakeQuad2Edges(edge1, edge3)
-
# create quadrangle with specified corners
+# create a quadrangle from four points in its corners
qface3 = geompy.MakeQuad4Vertices(p1, p2, p3, p4)
-
# add objects in study
+# add objects in the study
id_p1 = geompy.addToStudy(p1,"Point1")
@@ -164,7 +170,7 @@ else-
# display vertices, edges and quadrangle faces
+# display the vertices, the edges and the quadrangle faces
gg.createAndDisplayGO(id_p1)
@@ -195,8 +201,6 @@ elsegg.setDisplayMode(id_qface3,1)
-import geompy
@@ -205,120 +209,141 @@ elsegg = salome.ImportComponentGUI("GEOM")
-+
-
# create vertices
+# create vertices
-p1 = geompy.MakeVertex( - 0., 0., +
p0 = + geompy.MakeVertex( 0., + 0., 0.)
-p2 = geompy.MakeVertex(150., - 30., 0.)
+p1 = + geompy.MakeVertex( 0., + 0., + 40.)
-p3 = geompy.MakeVertex( - 0., 120., - 50.)
+p2 = + geompy.MakeVertex( 70., -15., 0.)
-p4 = geompy.MakeVertex( - 0., 40., - 70.)
+p3 = + geompy.MakeVertex( 70., -15., 70.)
-p5 = geompy.MakeVertex(100., - 20., 45.)
+-
p6 = geompy.MakeVertex( - 0., 70., - 40.)
+p4 = + geompy.MakeVertex( 0., + 70., 0.)
-p7 = geompy.MakeVertex( - 70., 70., 70.)
+p5 = + geompy.MakeVertex( 0., + 70., 40.)
-p8 = geompy.MakeVertex( - 70.,-15., 70.)
+p6 = + geompy.MakeVertex( 70., 70., + 0.)
-p9 = geompy.MakeVertex( - 0., 0., - 40.)
+p7 = + geompy.MakeVertex( 70., 70., + 70.)
+ ++ +
p8 = + geompy.MakeVertex( 0., + -50., 0.)
+ +p9 = + geompy.MakeVertex( 0., + -50., 40.)
p10 = geompy.MakeVertex( - 0., 70., - 0.)
+ 70., -35., 0.)p11 = geompy.MakeVertex( - 70., 70., 0.)
+ 70., -35., 70.) -p12 = geompy.MakeVertex( - 70., -15., 0.)
+-
p13 = geompy.MakeVertex( - 0., 0., - 0.)
+# create faces
-+
qface1 = geompy.MakeQuad4Vertices(p0, + p1, p2, p3)
-# create faces
+qface2 = geompy.MakeQuad4Vertices(p4, + p5, p6, p7)
-qface1 = geompy.MakeQuad4Vertices(p1, - p2, p3, p4)
+qface3 = geompy.MakeQuad4Vertices(p0, + p1, p4, p5)
-qface2 = geompy.MakeQuad4Vertices(p1, - p2, p5, p4)
+qface4 = geompy.MakeQuad4Vertices(p2, + p3, p6, p7)
-qface3 = geompy.MakeQuad4Vertices(p13, - p12, p11, p10)
+qface5 = geompy.MakeQuad4Vertices(p0, + p2, p4, p6)
-qface4 = geompy.MakeQuad4Vertices(p9, - p8, p7, p6)
+qface6 = geompy.MakeQuad4Vertices(p1, + p3, p5, p7)
-qface5 = geompy.MakeQuad4Vertices(p13, - p9, p6, p10)
+-
qface6 = geompy.MakeQuad4Vertices(p13, - p9, p8, p12)
+qface7 = geompy.MakeQuad4Vertices(p8, + p9, p10, p11)
-qface7 = geompy.MakeQuad4Vertices(p12, - p8, p7, p11)
+-
qface8 = geompy.MakeQuad4Vertices(p11, - p7, p6, p10)
+# create a hexahedral + solid between two given faces
-+
solid1 = geompy.MakeHexa2Faces(qface1, + qface7)
-# create hexahedral solid between two given faces
+-
solid1 = geompy.MakeHexa2Faces(qface1, - qface2)
+# create a hexahedral + solid, bounded by six given faces
-+
solid2 = geompy.MakeHexa(qface1, + qface2, qface3, qface4, qface5, qface6)
-# create hexahedral solids, bounded by the six given faces
+-
solid2 = geompy.MakeHexa(qface3, - qface4, qface5, qface6, qface7, qface8)
+# add objects in the + study
-+
geompy.addToStudy(qface1,"qface1")
+ +geompy.addToStudy(qface2,"qface2")
+ +geompy.addToStudy(qface3,"qface3")
+ +geompy.addToStudy(qface4,"qface4")
+ +geompy.addToStudy(qface5,"qface5")
-# add objects in study
+geompy.addToStudy(qface6,"qface6")
+ +geompy.addToStudy(qface7,"qface7")
+ +
id_solid1 = geompy.addToStudy(solid1,"Solid1")
id_solid2 = geompy.addToStudy(solid2,"Solid2")
-+
-
# display solids
+# display solids
gg.createAndDisplayGO(id_solid1)
-gg.setDisplayMode(id_solid1,1)
+gg.setDisplayMode(id_solid1, + 1)
gg.createAndDisplayGO(id_solid2)
-gg.setDisplayMode(id_solid2,1) -
- -+
gg.setDisplayMode(id_solid2, + 1)