Salome HOME
Task #3016: 3.2 To add a mode «through all» for features RevolutionCut and RevolutionFuse
[modules/shaper.git] / src / FeaturesPlugin / doc / extrusionFeature.rst
1 .. |extrusion_btn.icon|    image:: images/extrusion_btn.png
2
3 Extrusion
4 =========
5
6 Extrusion feature extrudes selected objects along their normals or the selected axis.
7
8 To perform Extrusion in the active part:
9
10 #. select in the Main Menu *Features - > Extrusion* item  or
11 #. click |extrusion_btn.icon| **Extrusion** button in the toolbar
12
13 The following property panel will be opened:
14
15 .. image:: images/StartSketch.png
16   :align: center
17
18 .. centered::
19   Start sketch
20
21 There are two variants of the property panel for Extrusion depending on the chosen option:
22
23 .. image:: images/extrusion_by_sizes.png
24    :align: left
25 **By Sizes** extrudes objects by specifying sizes.
26
27 .. image:: images/extrusion_by_bounding_planes.png
28    :align: left
29 **By Bounding Faces** extrudes objects by specifying bounding faces/planes and offsets.
30
31
32 By sizes
33 --------
34
35 .. image:: images/Extrusion1.png
36   :align: center
37
38 .. centered::
39   Extrusion: definition by sizes
40
41 - **Base objects** - contains a list of objects selected in the Object Browser or in the Viewer, which will be extruded.
42 - **Axis** - if selected, it will be the direction of extrusion, otherwise objects normals will be used.
43 - **To size** - size for extrusion in the direction.
44 - **From size** - size for extrusion in the opposite direction.
45
46 **TUI Commands**:
47
48 .. py:function:: model.addExtrusion(part, objects, size)
49
50     :param part: The current part object.
51     :param list: A list of objects for extrusion.
52     :param number: Size of extrucion.
53     :return: Created object.
54
55 .. py:function:: model.addExtrusion(part, objects, direction, size)
56
57     :param part: The current part object.
58     :param list: A list of objects for extrusion.
59     :param object: A direction of extrusion
60     :param number: Size of extrucion.
61     :return: Created object.
62
63 .. py:function:: model.addExtrusion(part, objects, toSize, fromSize)
64
65     :param part: The current part object.
66     :param list: A list of objects for extrusion.
67     :param number: "Size to" value.
68     :param number: "Size from" value.
69     :return: Created object.
70
71 .. py:function:: model.addExtrusion(part, objects, direction, toSize, fromSize)
72
73     :param part: The current part object.
74     :param list: A list of objects for extrusion.
75     :param object: A direction of extrusion
76     :param number: "Size to" value.
77     :param number: "Size from" value.
78     :return: Created object.
79
80 Result
81 """"""
82
83 The Result of the operation will be an extruded shape:
84
85 .. image:: images/extrusion_by_sizes_result.png
86            :align: center
87
88 .. centered::
89    **Created Extrusion**
90
91 **See Also** a sample TUI Script of :ref:`tui_create_extrusion_by_sizes` operation.
92
93 By bounding faces
94 ------------------
95
96 .. image:: images/Extrusion2.png
97   :align: center
98
99 .. centered::
100   Extrusion: definition by bounding faces
101
102 - **Base objects** - contains a list of objects selected in the Object Browser or in the Viewer, which will be extruded.
103 - **Axis** if selected, it will be direction of extrusion, otherwise objects normals will be used.
104 - **To face** - a face can be selected to bound extrusion from one side.
105 - **To offset** - offset for extrusion or for bounding plane, if selected.
106 - **From face** - a face can be selected to bound extrusion from the other side.
107 - **From offset** - offset for extrusion or for bounding plane, if selected.
108
109 Planar face selected as a boundary of extrusion will be enlarged infinitely. As a result, extrusion bounded only by planar faces will be completed always.
110 On the other hand, if the boundary face is not planar, extrusion may fail, for example, in case of the base object cannot be projected to this face along given direction.
111
112 **TUI Commands**:
113
114 .. py:function:: model.addExtrusion(part, objects, toObject, toOffset, fromObject, fromOffset)
115
116     :param part: The current part object.
117     :param list: A list of objects for extrusion.
118     :param object: "To object"
119     :param number: "To offset".
120     :param object: "From object"
121     :param number: "From offset".
122     :return: Created object.
123
124 .. py:function:: model.addExtrusion(part, objects, direction, toObject, toOffset, fromObject, fromOffset)
125
126     :param part: The current part object.
127     :param list: A list of objects for extrusion.
128     :param object: A direction of extrusion
129     :param object: "To object"
130     :param number: "To offset".
131     :param object: "From object"
132     :param number: "From offset".
133     :return: Created object.
134
135 Result
136 """"""
137
138 The Result of the operation will be an extruded shape:
139
140 .. image:: images/extrusion_by_bounding_planes_result.png
141            :align: center
142
143 .. centered::
144    **Created Extrusion**
145
146 **See Also** a sample TUI Script of :ref:`tui_create_extrusion_by_bounding_planes` operation.