3 \page tui_3dsketcher_page 3D Sketcher
8 gg = salome.ImportComponentGUI("GEOM")
10 # Create a 3D sketcher (wire) on the given points coordinates
11 sketcher1 = geompy.Make3DSketcher([ 0,0,0, 50,50,50, 0,50,0, 50,0,50, 10,20,100, 0,0,0 ])
13 # add object in the study
14 id_sketcher1 = geompy.addToStudy(sketcher1, "Sketcher1")
16 # display the sketcher
17 gg.createAndDisplayGO(id_sketcher1)
19 # Create a 3D sketcher (wire) with Sketcher3D interface
21 # get the interface instance
22 sk = geompy.Sketcher3D()
24 # add three points with absolute coordinates
25 # the first point will be the start point of sketcher
26 # two segments will be added by this command
27 sk.addPointsAbsolute(1,2,3, 7,0,0, 10,-3.5,-11)
29 # add one segment, defined by two angles in "OXY" coordinate system and length
30 sk.addPointAnglesLength("OXY", 45, 0, 100)
32 # add three points with relative coordinates
33 # three segments will be added by this command
34 sk.addPointsRelative(20,0,0, 20,0,100, -40,0,-50)
36 # set to close the sketcher
39 # obtain the sketcher result
42 # add object in the study
43 id_sketcher2 = geompy.addToStudy(sketcher2, "Sketcher2")
45 # display the sketcher
46 gg.createAndDisplayGO(id_sketcher2)