Salome HOME
Task 3.8. Extrusion to any face
[modules/shaper.git] / src / FeaturesPlugin / doc / measurementFeature.rst
1
2 Measurement
3 ===========
4
5 The feature **Measurement** calculates dimensions of sub-elements of a geometrical object (shape).
6
7 The measured dimension is displayed in the property panel and shown in 3D OCC viewer.
8
9 The  properties of dimension text and line, such as font, color, arrow size, etc. can be defined in the Preferences  :ref:`visualization_preferences`.
10
11 **Apply** button does not generate any result and has the same effect as **Cancel** for this feature.  
12
13 To start Measurement in the active part:
14
15 #. select in the Main Menu *Part - > Measurement* item  or
16 #. click **Measurement** button in the toolbar
17
18 .. image:: images/measurement.png      
19    :align: center
20
21 .. centered::
22    **Measurement** button 
23
24 The following dimensions can be calculated:
25
26   .. image:: images/meas_length_32x32.png      
27     :align: left
28   edge length 
29
30   .. image:: images/meas_distance_32x32.png    
31     :align: left
32   distance between objects
33
34   .. image:: images/meas_radius_32x32.png    
35     :align: left
36   radius
37
38   .. image:: images/meas_angle_32x32.png    
39     :align: left
40   angle between edges  
41
42   .. image:: images/meas_angle3p_32x32.png    
43     :align: left
44   angle by 3 points  
45
46 Edge length
47 -----------
48
49 The length can be measured for straight or curved edge built on two points. 
50
51 .. image:: images/Measurement1.png
52   :align: center
53
54 .. centered::
55   Edge length
56
57 Input fields:
58
59 - **Edge**  contains  edge to be measured selected in 3D OCC viewer or object browser. 
60
61 Note, that for curved edges length is displayed only in the property panel.
62
63 **TUI Command**:  *length =model.measureLength(Part_doc, edge)*
64  
65 **Arguments**: part + edge in format *model.selection("EDGE", edge)*. 
66
67
68 Distance between objects
69 ------------------------
70
71 **Distance between objects** calculates minimal distance for any pair of shapes: vertex, edge, face, solid.
72
73  .. image:: images/Measurement2.png
74   :align: center
75
76 .. centered::
77   Distance between objects
78
79 Input fields:
80
81 - **From**, **To**  contain shapes between which distance is  measured. Shapes are selected in 3D OCC viewer or object browser. 
82
83 **TUI Command**:  *length =model.measureDistance(Part_doc, shape1, shape2)*
84  
85 **Arguments**: part +  2 shapes in format *model.selection("TYPE", shape)*.
86
87 Radius
88 ------
89
90 **Radius** calculates radius for circular edge or cylindrical face. 
91
92 .. image:: images/Measurement3.png
93   :align: center
94
95 .. centered::
96   Radius
97
98 Input fields:
99
100 - **Object**  contains shape to be measured selected in 3D OCC viewer or object browser.  
101
102
103 **TUI Command**:  *radius = model.measureRadius(Part_doc, shape)*
104  
105 **Arguments**: part +  shape in format *model.selection("TYPE", shape)*.
106
107 Angle between edges
108 -------------------
109
110 **Angle between edges** calculates angle between the selected pair of edges in the point of intersection. If there are several points of intersection, then angles are calculated in all points.
111
112 .. image:: images/Measurement4.png
113   :align: center
114
115 .. centered::
116   Angle between edges
117
118 Input fields:
119
120 - **First Edge**, **Second edge**  contain  edges between which angle is measured. Edges are selected in 3D OCC viewer or object browser. 
121
122 **TUI Command**:  *angle = model.measureAngle(Part_doc, edge1, edge2)*
123  
124 **Arguments**: part +  2 edges in format *model.selection("EDGE", edge)*.  
125
126 Angle by 3 points
127 -----------------
128
129 **Angle by 3 points** calculates angle between the selected three points. The second point is in the corner of the angle.
130
131 .. image:: images/Measurement5.png
132   :align: center
133
134 .. centered::
135   Angle by 3 points
136
137 Input fields:
138
139 - **First point**, **Second point**, **Third point**  contain  point between which angle is measured. Points are selected in 3D OCC viewer or object browser. 
140
141 **TUI Command**:  *angle = model.measureAngle(Part_doc, vertex1, vertex2, vertex3)*
142   
143 **Arguments**: part +  3 vertices in format *model.selection("VERTEX", vertex)*.  
144