3 \page tui_advanced_geom_objs_page Advanced Geometrical Objects
5 \anchor tui_creation_pipetshape
6 <br><h2>Creation of PipeTShape</h2>
11 gg = salome.ImportComponentGUI("GEOM")
13 # create PipeTShape object
14 pipetshape = geompy.MakePipeTShape(80.0, 20.0, 200.0, 50.0, 20.0, 200.0)
16 # add object in the study
17 id_pipetshape = geompy.addToStudy(pipetshape[0],"PipeTShape")
18 # add groups in the study
19 for g in pipetshape[1:]:
20 geompy.addToStudyInFather(pipetshape[0], g, g.GetName())
22 # Create junction vertices
23 P1 = geompy.MakeVertex(0.0, 0.0, 0.0)
24 P2 = geompy.MakeVertex(400.0, 0.0, 0.0)
25 P3 = geompy.MakeVertex(200.0, 0.0, 200.0)
27 # create PipeTShape object with position
28 pipetshape_position = geompy.MakePipeTShape(80.0, 20.0, 200.0, 50.0, 20.0, 200.0, True, P1, P2, P3)
30 # add object in the study
31 id_pipetshape_position = geompy.addToStudy(pipetshape_position[0],"PipeTShape_position")
32 # add groups in the study
33 for g in pipetshape_position[1:]:
34 geompy.addToStudyInFather(pipetshape_position[0], g, g.GetName())
36 # create PipeTShape with chamfer object
37 pipetshapechamfer = geompy.MakePipeTShapeChamfer(80.0, 20.0, 200.0, 50.0, 20.0, 200.0, 20.0, 20.0)
39 # add object in the study
40 id_pipetshapechamfer = geompy.addToStudy(pipetshapechamfer[0],"PipeTShapeChamfer")
41 # add groups in the study
42 for g in pipetshapechamfer[1:]:
43 geompy.addToStudyInFather(pipetshapechamfer[0], g, g.GetName())
45 # create PipeTShape with chamfer object with position
46 pipetshapechamfer_position = geompy.MakePipeTShapeChamfer(80.0, 20.0, 200.0, 50.0, 20.0, 200.0, 20.0, 20.0, True, P1, P2, P3)
48 # add object in the study
49 id_pipetshapechamfer_position = geompy.addToStudy(pipetshapechamfer_position[0],"PipeTShapeChamfer_position")
50 # add groups in the study
51 for g in pipetshapechamfer_position[1:]:
52 geompy.addToStudyInFather(pipetshapechamfer_position[0], g, g.GetName())
54 # create PipeTShape with fillet object
55 pipetshapefillet = geompy.MakePipeTShapeFillet(80.0, 20.0, 200.0, 50.0, 20.0, 200.0, 5.0)
57 # add object in the study
58 id_pipetshapefillet = geompy.addToStudy(pipetshapefillet[0],"PipeTShapeFillet")
59 # add groups in the study
60 for g in pipetshapefillet[1:]:
61 geompy.addToStudyInFather(pipetshapefillet[0], g, g.GetName())
63 # create PipeTShape with fillet object with position
64 pipetshapefillet_position = geompy.MakePipeTShapeFillet(80.0, 20.0, 200.0, 50.0, 20.0, 200.0, 5.0, True, P1, P2, P3)
66 # add object in the study
67 id_pipetshapefillet_position = geompy.addToStudy(pipetshapefillet_position[0],"PipeTShapeFillet_position")
68 # add groups in the study
69 for g in pipetshapefillet_position[1:]:
70 geompy.addToStudyInFather(pipetshapefillet_position[0], g, g.GetName())
74 gg.createAndDisplayGO(id_pipetshape)
75 gg.createAndDisplayGO(id_pipetshape_position)
76 gg.createAndDisplayGO(id_pipetshapechamfer)
77 gg.createAndDisplayGO(id_pipetshapechamfer_position)
78 gg.createAndDisplayGO(id_pipetshapefillet)
79 gg.createAndDisplayGO(id_pipetshapefillet_position)
83 <!--@@ insert new functions before this line @@ do not remove this line @@-->