1 // Copyright (C) 2003 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
2 // CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
4 // This library is free software; you can redistribute it and/or
5 // modify it under the terms of the GNU Lesser General Public
6 // License as published by the Free Software Foundation; either
7 // version 2.1 of the License.
9 // This library is distributed in the hope that it will be useful,
10 // but WITHOUT ANY WARRANTY; without even the implied warranty of
11 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
12 // Lesser General Public License for more details.
14 // You should have received a copy of the GNU Lesser General Public
15 // License along with this library; if not, write to the Free Software
16 // Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
18 // See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
22 // File : SMESH_BasicHypothesis.idl
23 // Author : Paul RASCLE, EDF
25 #ifndef _SMESH_BASICHYPOTHESIS_IDL_
26 #define _SMESH_BASICHYPOTHESIS_IDL_
28 #include "SALOME_Exception.idl"
29 #include "SMESH_Hypothesis.idl"
30 #include "SMESH_Mesh.idl"
34 * StdMeshers: interfaces to standard hypotheses and algorithms
39 * StdMeshers_LocalLength: interface of "Average length" hypothesis
41 interface StdMeshers_LocalLength : SMESH::SMESH_Hypothesis
44 * Sets <length> parameter value
46 void SetLength(in double length)
47 raises (SALOME::SALOME_Exception);
50 * Returns <length> parameter value
56 * StdMeshers_AutomaticLength: interface of "Automatic length" hypothesis
58 interface StdMeshers_AutomaticLength : SMESH::SMESH_Hypothesis
61 * Sets Fineness parameter value
63 void SetFineness(in double theFineness)
64 raises (SALOME::SALOME_Exception);
67 * Returns <Fineness> parameter value
73 * StdMeshers_NumberOfSegments: interface of "Nb. Segments" hypothesis
75 interface StdMeshers_NumberOfSegments : SMESH::SMESH_Hypothesis
78 * Builds and returns point distribution according to passed density function
80 SMESH::double_array BuildDistributionExpr( in string func, in long nbSeg, in long conv )
81 raises (SALOME::SALOME_Exception);
82 SMESH::double_array BuildDistributionTab( in SMESH::double_array func, in long nbSeg, in long conv )
83 raises (SALOME::SALOME_Exception);
86 * Sets <number of segments> parameter value
88 void SetNumberOfSegments(in long segmentsNumber)
89 raises (SALOME::SALOME_Exception);
92 * Returns <number of segments> parameter value
94 long GetNumberOfSegments();
97 * Sets <distribution type> parameter value
99 void SetDistrType(in long typ)
100 raises (SALOME::SALOME_Exception);
103 * Returns <distribution type> parameter value
108 * Sets <scale factor> parameter value
110 void SetScaleFactor(in double scaleFactor)
111 raises (SALOME::SALOME_Exception);
114 * Returns <scale factor> parameter value
116 double GetScaleFactor()
117 raises (SALOME::SALOME_Exception);
120 * Sets <table function> parameter value for distribution DT_TabFunc
122 void SetTableFunction(in SMESH::double_array table)
123 raises (SALOME::SALOME_Exception);
126 * Returns <table function> parameter value for distribution DT_TabFunc
128 SMESH::double_array GetTableFunction()
129 raises (SALOME::SALOME_Exception);
132 * Sets <expression function> parameter value for distribution DT_ExprFunc
134 void SetExpressionFunction(in string expr)
135 raises (SALOME::SALOME_Exception);
138 * Returns <expression function> parameter value for distribution DT_ExprFunc
140 string GetExpressionFunction()
141 raises (SALOME::SALOME_Exception);
144 * Sets <conversion mode> parameter value for functional distributions
146 void SetConversionMode(in long conv )
147 raises (SALOME::SALOME_Exception);
150 * Returns <conversion mode> parameter value for functional distributions
152 long ConversionMode()
153 raises (SALOME::SALOME_Exception);
157 * StdMeshers_Arithmetic1D: interface of "Arithmetic 1D" hypothesis
159 interface StdMeshers_Arithmetic1D : SMESH::SMESH_Hypothesis
162 * Sets <start segment length> or <end segment length> parameter value
164 void SetLength(in double length, in boolean isStartLength)
165 raises (SALOME::SALOME_Exception);
168 * Returns <start segment length> or <end segment length> parameter value
170 double GetLength(in boolean isStartLength);
174 * StdMeshers_MaxElementArea: interface of "Max. Triangle Area" hypothesis
176 interface StdMeshers_MaxElementArea : SMESH::SMESH_Hypothesis
179 * Sets <maximum element area> parameter value
181 void SetMaxElementArea(in double area)
182 raises (SALOME::SALOME_Exception);
185 * Returns <maximum element area> parameter value
187 double GetMaxElementArea();
191 * StdMeshers_LengthFromEdges: interface of "Length From Edges (2D Hyp. for Triangulator)" hypothesis
193 interface StdMeshers_LengthFromEdges : SMESH::SMESH_Hypothesis
196 * Sets <mode> parameter value
198 void SetMode(in long mode)
199 raises (SALOME::SALOME_Exception);
202 * Returns <mode> parameter value
208 * StdMeshers_StartEndLength: interface of "Start and End Length" hypothesis
210 interface StdMeshers_StartEndLength : SMESH::SMESH_Hypothesis
213 * Sets <start segment length> or <end segment length> parameter value
215 void SetLength(in double length, in boolean isStartLength)
216 raises (SALOME::SALOME_Exception);
219 * Returns <start segment length> or <end segment length> parameter value
221 double GetLength(in boolean isStartLength);
226 * StdMeshers_Deflection1D: interface of "Deflection 1D" hypothesis
228 interface StdMeshers_Deflection1D : SMESH::SMESH_Hypothesis
231 * Sets <deflection> parameter value
233 void SetDeflection(in double deflection)
234 raises (SALOME::SALOME_Exception);
237 * Returns <deflection> parameter value
239 double GetDeflection();
244 * StdMeshers_MaxElementVolume: interface of "Max. Hexahedron or Tetrahedron Volume" hypothesis
246 interface StdMeshers_MaxElementVolume : SMESH::SMESH_Hypothesis
249 * Sets <maximum element volume> parameter value
251 void SetMaxElementVolume(in double volume)
252 raises (SALOME::SALOME_Exception);
255 * Returns <maximum element volume> parameter value
257 double GetMaxElementVolume();
261 * StdMeshers_NotConformAllowed: interface of "Not Conform Mesh Allowed" hypothesis.
262 * Presence of this hypothesis permits to algorithm generation of not conform mesh.
264 interface StdMeshers_NotConformAllowed : SMESH::SMESH_Hypothesis
269 * StdMeshers_Propagation: interface of "Propagation" hypothesis.
270 * Presence of this hypothesis on any edge propagates any other 1D
271 * hypothesis from this edge on all edges, opposite to it.
272 * It concerns only edges of quadrangle faces.
274 interface StdMeshers_Propagation : SMESH::SMESH_Hypothesis
279 * StdMeshers_QuadranglePreference: interface of "QuadranglePreference" hypothesis.
280 * This hypothesis is used by StdMeshers_Quadrangle_2D algorithm.
281 * Presence of this hypothesis forces construction of quadrangles if the number
282 * of nodes on opposite edges is not the same in the case where the global number
283 * of nodes on edges is even
285 interface StdMeshers_QuadranglePreference : SMESH::SMESH_Hypothesis
290 * StdMeshers_QuadraticMesh: interface of "QuadraticMesh" hypothesis.
291 * This is an auxiliary 1D hypothesis whose presence forces construction
292 * of quadratic edges.
293 * If the 2D mesher sees that all boundary edges are quadratic ones,
294 * it generates quadratic faces, else it generates linear faces using
295 * medium nodes as if they were vertex ones.
296 * The 3D mesher generates quadratic volumes only if all boundary faces
297 * are quadratic ones, else it fails.
299 interface StdMeshers_QuadraticMesh : SMESH::SMESH_Hypothesis
305 * StdMeshers_NumberOfLayers: interface of "Nb. Layers" hypothesis.
306 * This hypothesis is used by "Radial prism" algorithm.
307 * It specifies number of segments between the internal
308 * and the external surfaces.
310 interface StdMeshers_NumberOfLayers : SMESH::SMESH_Hypothesis
313 * Sets <number of segments> parameter value
315 void SetNumberOfLayers(in long numberOfLayers)
316 raises (SALOME::SALOME_Exception);
319 * Returns <number of layers> parameter value
321 long GetNumberOfLayers();
326 * StdMeshers_LayerDistribution: interface of "Distribution of Layers" hypothesis.
327 * This hypothesis is used by "Radial prism" algorithm.
328 * It specifies 1D hypothesis defining distribution of segments between the internal
329 * and the external surfaces.
331 interface StdMeshers_LayerDistribution : SMESH::SMESH_Hypothesis
334 * Sets 1D hypothesis specifying distribution of layers
336 void SetLayerDistribution(in SMESH::SMESH_Hypothesis distributionHyp)
337 raises (SALOME::SALOME_Exception);
340 * Returns 1D hypothesis specifying distribution of layers
342 SMESH::SMESH_Hypothesis GetLayerDistribution();
347 * interface of "ProjectionSource1D" hypothesis.
348 * This hypothesis specifies a meshed edge to take a mesh pattern from
349 * and optionally association of vertices between the source edge and a
350 * target one (where a hipothesis is assigned to)
352 interface StdMeshers_ProjectionSource1D : SMESH::SMESH_Hypothesis
355 * Sets source <edge> to take a mesh pattern from
357 void SetSourceEdge(in GEOM::GEOM_Object edge)
358 raises (SALOME::SALOME_Exception);
361 * Returns the source edge
363 GEOM::GEOM_Object GetSourceEdge();
366 * Sets source <mesh> to take a mesh pattern from
368 void SetSourceMesh(in SMESH::SMESH_Mesh mesh);
373 SMESH::SMESH_Mesh GetSourceMesh();
376 * Sets vertex association between the source edge and the target one.
377 * This parameter is optional
379 void SetVertexAssociation(in GEOM::GEOM_Object sourceVertex,
380 in GEOM::GEOM_Object targetVertex)
381 raises (SALOME::SALOME_Exception);
384 * Returns the vertex associated with the target vertex.
385 * Result may be nil if association not set
387 GEOM::GEOM_Object GetSourceVertex();
390 * Returns the vertex associated with the source vertex.
391 * Result may be nil if association not set
393 GEOM::GEOM_Object GetTargetVertex();
397 * interface of "ProjectionSource2D" hypothesis.
398 * This hypothesis specifies a meshed face to take a mesh pattern from
399 * and optionally association of vertices between the source face and a
400 * target one (where a hipothesis is assigned to)
402 interface StdMeshers_ProjectionSource2D : SMESH::SMESH_Hypothesis
405 * Sets a source <face> to take a mesh pattern from
407 void SetSourceFace(in GEOM::GEOM_Object face)
408 raises (SALOME::SALOME_Exception);
411 * Returns the source face
413 GEOM::GEOM_Object GetSourceFace();
416 * Sets source <mesh> to take a mesh pattern from
418 void SetSourceMesh(in SMESH::SMESH_Mesh mesh);
423 SMESH::SMESH_Mesh GetSourceMesh();
426 * Sets vertex association between the source face and the target one.
427 * This parameter is optional.
428 * Two vertices must belong to one edge of a face
430 void SetVertexAssociation(in GEOM::GEOM_Object sourceVertex1,
431 in GEOM::GEOM_Object sourceVertex2,
432 in GEOM::GEOM_Object targetVertex1,
433 in GEOM::GEOM_Object targetVertex2)
434 raises (SALOME::SALOME_Exception);
437 * Returns the <i>-th source vertex associated with the <i>-th target vertex.
438 * Result may be nil if association not set.
439 * Valid indices are 1 and 2
441 GEOM::GEOM_Object GetSourceVertex(in long i)
442 raises (SALOME::SALOME_Exception);
445 * Returns the <i>-th target vertex associated with the <i>-th source vertex.
446 * Result may be nil if association not set.
447 * Valid indices are 1 and 2
449 GEOM::GEOM_Object GetTargetVertex(in long i)
450 raises (SALOME::SALOME_Exception);
454 * interface of "ProjectionSource3D" hypothesis.
455 * This hypothesis specifies a meshed shell or solid to take a mesh pattern from
456 * and optionally association of vertices between the source shape and a
457 * target one (where a hipothesis is assigned to)
459 interface StdMeshers_ProjectionSource3D : SMESH::SMESH_Hypothesis
462 * Sets a source <shape> to take a mesh pattern from
464 void SetSource3DShape(in GEOM::GEOM_Object shape)
465 raises (SALOME::SALOME_Exception);
468 * Returns the source shape
470 GEOM::GEOM_Object GetSource3DShape();
473 * Sets source <mesh> to take a mesh pattern from
475 void SetSourceMesh(in SMESH::SMESH_Mesh mesh);
480 SMESH::SMESH_Mesh GetSourceMesh();
483 * Sets vertex association between the source shape and the target one.
484 * This parameter is optional.
485 * Two vertices must belong to one edge of a shape
487 void SetVertexAssociation(in GEOM::GEOM_Object sourceVertex1,
488 in GEOM::GEOM_Object sourceVertex2,
489 in GEOM::GEOM_Object targetVertex1,
490 in GEOM::GEOM_Object targetVertex2)
491 raises (SALOME::SALOME_Exception);
494 * Returns the <i>-th source vertex associated with the <i>-th target vertex.
495 * Result may be nil if association not set.
496 * Valid indices are 1 and 2
498 GEOM::GEOM_Object GetSourceVertex(in long i)
499 raises (SALOME::SALOME_Exception);
502 * Returns the <i>-th target vertex associated with the <i>-th source vertex.
503 * Result may be nil if association not set.
504 * Valid indices are 1 and 2
506 GEOM::GEOM_Object GetTargetVertex(in long i)
507 raises (SALOME::SALOME_Exception);
511 * interface of "SegmentLengthAroundVertex" hypothesis.
512 * This hypothesis specifies length of segments adjacent to the vertex the
513 * hypothesis is assigned to
515 interface StdMeshers_SegmentLengthAroundVertex : SMESH::SMESH_Hypothesis
518 * Sets <length> parameter value
520 void SetLength(in double length)
521 raises (SALOME::SALOME_Exception);
524 * Returns <length> parameter value
530 * StdMeshers_SegmentAroundVertex_0D: interface of "SegmentAroundVertex" algorithm
532 interface StdMeshers_SegmentAroundVertex_0D : SMESH::SMESH_0D_Algo
537 * StdMeshers_Regular_1D: interface of "Wire discretisation" algorithm
539 interface StdMeshers_Regular_1D : SMESH::SMESH_1D_Algo
544 * StdMeshers_CompositeSegment_1D: interface of "Composite side discretisation" algorithm
546 interface StdMeshers_CompositeSegment_1D : SMESH::SMESH_1D_Algo
551 * StdMeshers_MEFISTO_2D: interface of "Triangle (Mefisto)" algorithm
553 interface StdMeshers_MEFISTO_2D : SMESH::SMESH_2D_Algo
558 * StdMeshers_Quadrangle_2D: interface of "Quadrangle (Mapping)" algorithm
560 interface StdMeshers_Quadrangle_2D : SMESH::SMESH_2D_Algo
565 * StdMeshers_Hexa_3D: interface of "Hexahedron (i,j,k)" algorithm
567 interface StdMeshers_Hexa_3D : SMESH::SMESH_3D_Algo
572 * StdMeshers_Prism_3D: interface of "3D extrusion" algorithm
574 interface StdMeshers_Prism_3D : SMESH::SMESH_3D_Algo
579 * StdMeshers_RadialPrism_3D: interface of "Radial Prism" algorithm
581 interface StdMeshers_RadialPrism_3D : SMESH::SMESH_3D_Algo
586 * StdMeshers_Projection_3D: interface of "Projection 3D" algorithm
588 interface StdMeshers_Projection_3D : SMESH::SMESH_3D_Algo
593 * StdMeshers_Projection_2D: interface of "Projection 2D" algorithm
595 interface StdMeshers_Projection_2D : SMESH::SMESH_2D_Algo
600 * StdMeshers_Projection_1D: interface of "Projection 1D" algorithm
602 interface StdMeshers_Projection_1D : SMESH::SMESH_1D_Algo