]> SALOME platform Git repositories - modules/shaper.git/blob - src/BuildPlugin/doc/interpolationFeature.rst
Salome HOME
Interpolation : test modification
[modules/shaper.git] / src / BuildPlugin / doc / interpolationFeature.rst
1 .. |feature_interpolation.icon|    image:: images/feature_interpolation.png
2
3 Interpolation
4 =============
5
6 Interpolation feature creates an interpolated curve (edge) based on existing points/vertices or based on analytical mathematical expression.
7
8 To create an interpolation in the active part:
9
10 #. select in the Main Menu *Build - > Interpolation* item  or
11 #. click |feature_interpolation.icon| **Interpolation** button in the toolbar
12
13 There are two creation modes of an interpolation:
14
15 .. figure:: images/feature_interpolation_by_selection.png   
16    :align: left
17    :height: 24px
18
19 Interpolation by selection
20
21 .. figure:: images/feature_interpolation_analytical.png   
22    :align: left
23    :height: 24px
24
25 Interpolation analytical
26
27 Interpolation by selection
28 """"""""""""""""""""""""""
29 The  property panel is shown below.
30
31 .. figure:: images/Interpolation.png
32   :align: center
33
34   Create an interpolation by selection
35
36 Select one or several vertices or points in the viewer.
37
38 - **Closed** makes the interpolation curve closed.
39
40 - **Reorder** reorders the selected points to minimize the length of curve.
41
42 - **Tangents** makes start and end of the curve tangent to the selected edges. The user has to select start and end edges in the corresponding fields.
43
44 **Apply** button creates an interpolation.
45
46 **Cancel** button cancels the operation. 
47
48 **TUI Commands**:
49
50 .. py:function:: model.addInterpolation(Part_doc, Points, IsClosed, IsReordered)
51
52     :param part: The current part object.
53     :param list: A list of points.
54     :param boolean: Is closed.
55     :param boolean: Is reordered.
56     :return: Result object.
57
58 .. py:function:: model.addInterpolation(Part_doc, Points, StartEdge, EndEdge, IsClosed, IsReordered)
59
60     :param part: The current part object.
61     :param list: A list of points.
62     :param object: Start point.
63     :param object: End point.
64     :param boolean: Is closed.
65     :param boolean: Is reordered.
66     :return: Result object.
67
68 Result
69 """"""
70
71 The result of the operation will be a curve created from the selected shapes:
72
73 .. figure:: images/CreateInterpolation.png
74   :align: center
75
76   Result of the operation.
77
78 **See Also** a sample TUI Script of :ref:`tui_create_interpolation_by_selection` operation.
79
80 Interpolation analytical
81 """"""""""""""""""""""""
82
83 The  property panel is shown below.
84
85 .. figure:: images/InterpolationAnalytical.png
86   :align: center
87
88   Create an interpolation analytical
89
90 Select one or several vertices or points in the viewer.
91
92 - **Curves parameters** panel allows to define the mathematical expression for creating the interpolated curve.
93    - **X(t) equation** define the expression of X with t variable.
94    - **Y(t) equation** define the expression of Y with t variable.
95    - **Z(t) equation** define the expression of Z with t variable.
96
97 - **Min t** define the minimun of t.
98
99 - **Max t** define the maximum of t.
100
101 - **Number of steps** define the number of steps.
102
103 **Apply** button creates an interpolation.
104
105 **Cancel** button cancels the operation. 
106
107 **TUI Commands**:
108
109 .. py:function:: model.addInterpolation(Part_doc, xt, yt, zt, mint, maxt, nbSteps)
110
111     :param part: The current part object.
112     :param string: Expression of x.
113     :param string: Expression of y.
114     :param string: Expression of z.
115     :param number: Minimum value of t.
116     :param number: Maximum value of t.
117     :param number: Number of steps. 
118     :return: Result object.
119
120 Result
121 """"""
122
123 The result of the operation will be a curve created from analytical expressions for x,y and z as functions of variable t:
124
125 .. figure:: images/CreateInterpolationAnalytical.png
126   :align: center
127
128   Result of the operation.
129
130 **See Also** a sample TUI Script of :ref:`tui_create_interpolation_analytical` operation.