1 .. |axis_button.icon| image:: images/axis_button.png
6 Axis feature creates a new constructive axis line.
8 Axis is a construction object and it can be created in a part or in a partset. To create an axis:
10 #. select in the Main Menu *Construction - > Axis* item or
11 #. click |axis_button.icon| **Axis** button in the toolbar
13 There are 6 algorithms for creation of an Axis:
15 .. figure:: images/axis_dxyz_32x32.png
19 **By three dimensions** creates an axis by dimensions along X, Y, Z axes starting form existing origin.
21 .. figure:: images/by_two_points_32x32.png
25 **By two points** creates an axis using existing points.
27 .. figure:: images/axis_by_line_32x32.png
31 **By line** creates an axis using a line.
33 .. figure:: images/cylindrical_face_32x32.png
37 **As an axis of cylindrical face** creates an axis using a cylindrical face.
39 .. figure:: images/axis_by_plane_and_point_32x32.png
43 **By plane and point** creates an axis using a plane and point.
45 .. figure:: images/axis_by_two_planes_32x32.png
49 **By two planes** creates an axis as the intersection of two planes.
51 --------------------------------------------------------------------------------
56 .. figure:: images/Axis1.png
59 **By dX, dY, dZ values**
61 An axis is defined by dX, dY and dZ values of a vector.
65 .. py:function:: model.addAxis(Part_doc, 10, 10, 10)
67 :param part: The current part object.
71 :return: Result object.
76 The Result of the operation will be an axis defined by vector from origin:
78 .. figure:: images/CreatedAxis1.png
81 **Axis by three dimensions**
83 **See Also** a sample TUI Script of :ref:`tui_create_axis_xyz` operation.
89 .. figure:: images/Axis2.png
94 An axis is defined by two points or vertices.
98 .. py:function:: model.addAxis(Part_doc, model.selection("VERTEX", "Box_1_1/Back&Box_1_1/Left&Box_1_1/Top"), model.selection("VERTEX", "Box_1_1/Front&Box_1_1/Right&Box_1_1/Bottom"))
100 :param part: The current part object.
101 :param object: Vertex 1.
102 :param object: Vertex 2.
103 :return: Result object.
105 **See Also** a sample TUI Script of :ref:`tui_create_axis_points` operation.
110 The Result of the operation will be an axis based on two points:
112 .. figure:: images/CreatedAxis2.png
115 **Axis by two points**
117 **See Also** a sample TUI Script of :ref:`tui_create_axis_points` operation.
123 .. figure:: images/Axis3.png
128 An axis is defined by a linear edge.
132 .. py:function:: model.addAxis(Part_doc, model.selection("EDGE", "Box_1_1/Left&Box_1_1/Top"))
134 :param part: The current part object.
136 :return: Result object.
141 The Result of the operation will be an axis based on the selected line:
143 .. figure:: images/CreatedAxis3.png
148 **See Also** a sample TUI Script of :ref:`tui_create_axis_line` operation.
151 As an axis of cylindrical face
152 ------------------------------
154 .. figure:: images/Axis4.png
159 An axis is defined by a cylindrical face. Axis of the cylinder will be an axis object.
163 .. py:function:: model.addAxis(Part_doc, model.selection("FACE", "Cylinder_1_1/Face_1"))
165 :param part: The current part object.
166 :param object: Cylindrical face.
167 :return: Result object.
172 The Result of the operation will be an axis of the selected cylinder:
174 .. figure:: images/CreatedAxis4.png
177 **Axis cylindrical face**
179 **See Also** a sample TUI Script of :ref:`tui_create_axis_cylinder` operation.
185 .. figure:: images/Axis5.png
188 **By a plane and point**
190 An axis is defined by a point or vertex and plane (or planar face) as a normal from the point to the plane.
194 .. py:function:: model.addAxis(Part_doc, model.selection("FACE", "Box_1_1/Front"), model.selection("VERTEX", "Box_1_1/Back&Box_1_1/Right&Box_1_1/Top"))
196 :param part: The current part object.
197 :param object: Plane.
198 :param object: Point.
199 :return: Result object.
204 The Result of the operation will be an axis:
206 .. figure:: images/CreatedAxis5.png
209 **Axis by plane and point**
211 **See Also** a sample TUI Script of :ref:`tui_create_axis_plane` operation.
217 .. figure:: images/Axis6.png
222 An axis is defined by two planes. The intersection of the planes defines an axis. It is possible to define offset for axis definition from both planes.
226 .. py:function:: model.addAxis(Part_doc, model.selection("FACE", "Box_1_1/Top"), 5, False, model.selection("FACE", "Box_1_1/Front"), 3, False)
228 :param part: The current part object.
229 :param object: Plane 1.
230 :param real: Offset value.
231 :param boolean: Is reversed.
232 :param object: Plane 2.
233 :param real: Offset value.
234 :param boolean: Is reversed.
235 :return: Result object.
240 The Result of the operation will be an axis:
242 .. figure:: images/CreatedAxis6.png
245 **Axis by two planes**
247 **See Also** a sample TUI Script of :ref:`tui_create_axis_twoplanes` operation.