Salome HOME
Documentation: use 'figure' instead of 'image'; improve caption layout; fix warnings.
[modules/shaper.git] / src / FeaturesPlugin / doc / symmetryFeature.rst
1 .. |symmetry.icon|    image:: images/symmetry.png
2
3 Symmetry
4 ========
5
6 **Symmetry** feature makes a symmetrical copy of the selected shape.
7
8 To create a Symmetry in the active part:
9
10 #. select in the Main Menu *Part - > Symmetry* item  or
11 #. click |symmetry.icon| **Symmetry** button in the toolbar
12
13 Symmetrical copy of an Object can be mirrored in three different ways:
14
15 .. figure:: images/symmetry_point_32x32.png    
16    :align: left
17    :height: 24px
18
19 through a Point of symmetry 
20
21 .. figure:: images/symmetry_axis_32x32.png      
22    :align: left
23    :height: 24px
24
25 through an Axis of symmetry  
26
27 .. figure:: images/symmetry_plane_32x32.png    
28    :align: left
29    :height: 24px
30
31 through a Plane of symmetry 
32
33 --------------------------------------------------------------------------------
34
35 Symmetry through a Point of symmetry
36 ------------------------------------
37
38 .. figure:: images/symmetryPoint.png
39    :align: center
40
41    Symmetry through a Point of symmetry property panel
42
43 Input fields:
44
45 - **Main objects** panel contains shapes to be translated. Shapes are selected in 3D OCC viewer or object browser;
46 - **Point**  defines a point of symmetry selected in 3D OCC viewer or object browser;
47 - **Create a copy** checkbox preserves/removes the initial object.
48
49 **TUI Command**:
50
51 .. py:function:: model.addSymmetry(Part_doc, [shape], point, copy)
52
53     :param part: The current part object.
54     :param list: A list of shapes in format *model.selection(TYPE, shape)*.
55     :param object: A point in format *model.selection(TYPE, shape)*.
56     :param boolean: A flag to create a copy.
57     :return: Result object.
58
59 Result
60 """"""
61
62 The result of operation is a mirrored initial shape with **Create a copy** = *True*.
63
64 .. figure:: images/symmetryPointres.png
65    :align: center
66
67    Symmetry through a Point of symmetry
68
69 **See Also** a sample TUI Script of :ref:`tui_symmetry_point` operation.
70
71 Symmetry through an Axis of symmetry
72 ------------------------------------
73
74 .. figure:: images/symmetryAxis.png
75    :align: center
76
77    Symmetry through an Axis of symmetry property panel
78
79 Input fields:
80
81 - **Main objects** panel contains shapes to be translated. Shapes are selected in 3D OCC viewer or object browser;
82 - **Axis**  defines an axis of symmetry selected in 3D OCC viewer or object browser;
83 - **Create a copy** checkbox preserves/removes the initial object.
84
85 **TUI Command**:
86
87 .. py:function:: model.addSymmetry(Part_doc, [shape], axis, copy)
88
89     :param part: The current part object.
90     :param list: A list of shapes in format *model.selection(TYPE, shape)*.
91     :param object: An axis in format *model.selection(TYPE, shape)*.
92     :param boolean: A flag to create a copy.
93     :return: Result object.
94
95 Result
96 """"""
97
98 The result of operation is a mirrored initial shape with **Create a copy** = *False*.
99
100 .. figure:: images/symmetryAxisres.png
101    :align: center
102
103    Symmetry through an Axis of symmetry
104
105 **See Also** a sample TUI Script of :ref:`tui_symmetry_axis` operation.  
106
107 Symmetry through a Plane of symmetry
108 ------------------------------------
109
110 .. figure:: images/symmetryPlane.png
111    :align: center
112
113    Symmetry through a Plane of symmetry property panel
114
115 Input fields:
116
117 - **Main objects** panel contains shapes to be translated. Shapes are selected in 3D OCC viewer or object browser;
118 - **Plane**  defines a plane of symmetry selected in 3D OCC viewer or object browser;
119 - **Create a copy** checkbox preserves/removes the initial object.
120
121 **TUI Command**:
122
123 .. py:function:: model.addSymmetry(Part_doc, [shape], plane, copy)
124
125     :param part: The current part object.
126     :param list: A list of shapes in format *model.selection(TYPE, shape)*.
127     :param object: A plane in format *model.selection(TYPE, shape)*.
128     :param boolean: A flag to create a copy.
129     :return: Result object.
130
131 Result
132 """"""
133
134 The result of operation is a mirrored initial shape with **Create a copy** = *False*.
135
136 .. figure:: images/symmetryPlaneres.png
137    :align: center
138
139    Symmetry through a Plane of symmetry
140
141 **See Also** a sample TUI Script of :ref:`tui_symmetry_plane` operation.