Salome HOME
b2d45fcd7a1df6eb20faf6ca8c7cc8f2618ae109
[plugins/netgenplugin.git] / idl / NETGENPlugin_Algorithm.idl
1 // Copyright (C) 2007-2022  CEA/DEN, EDF R&D, OPEN CASCADE
2 //
3 // Copyright (C) 2003-2007  OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
4 // CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
5 //
6 // This library is free software; you can redistribute it and/or
7 // modify it under the terms of the GNU Lesser General Public
8 // License as published by the Free Software Foundation; either
9 // version 2.1 of the License, or (at your option) any later version.
10 //
11 // This library is distributed in the hope that it will be useful,
12 // but WITHOUT ANY WARRANTY; without even the implied warranty of
13 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
14 // Lesser General Public License for more details.
15 //
16 // You should have received a copy of the GNU Lesser General Public
17 // License along with this library; if not, write to the Free Software
18 // Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307 USA
19 //
20 // See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
21 //
22
23 //  File   : NETGENPlugin_Algorithm.idl
24 //  Author : Julia DOROVSKIKH
25 //
26 #ifndef _SMESH_NETGENALGORITHM_IDL_
27 #define _SMESH_NETGENALGORITHM_IDL_
28
29 #include "SALOME_Exception.idl"
30 #include "SMESH_Hypothesis.idl"
31 #include "SMESH_Group.idl"
32 #include "GEOM_Gen.idl"
33
34 /*!
35  * NETGENPlugin: interfaces to NETGEN related hypotheses and algorithms
36  */
37 module NETGENPlugin
38 {
39   typedef sequence<string> string_array;
40   /*!
41    * NETGENPlugin_NETGEN_3D: interface of "Tetrahedron (Netgen)" algorithm
42    */
43   interface NETGENPlugin_NETGEN_3D : SMESH::SMESH_3D_Algo
44   {
45   };
46
47   /*!
48    * NETGENPlugin_NETGEN_3D: interface of "Remote Tetrahedron (Netgen)" algorithm
49    */
50   interface NETGENPlugin_NETGEN_3D_Remote : NETGENPlugin::NETGENPlugin_NETGEN_3D
51   {
52   };
53
54   /*!
55    * NETGENPlugin_NETGEN_2D: interface of "Netgen 1D-2D" algorithm
56    */
57   interface NETGENPlugin_NETGEN_2D : SMESH::SMESH_2D_Algo
58   {
59   };
60
61   /*!
62    * NETGENPlugin_NETGEN_2D3D: interface of "Netgen 1D-2D-3D" algorithm
63    */
64   interface NETGENPlugin_NETGEN_2D3D : SMESH::SMESH_3D_Algo
65   {
66   };
67
68   /*!
69    * NETGENPlugin_NETGEN_2D_ONLY: interface of "Netgen 2D" algorithm,
70    * generating 2D elements on a geometrical face taking
71    * into account pre-existing nodes on face boundaries
72    */
73   interface NETGENPlugin_NETGEN_2D_ONLY : SMESH::SMESH_2D_Algo
74   {
75   };
76
77   /*!
78    * NETGENPlugin_Remesher_2D: interface of "NETGEN Remesher" algorithm,
79    * generating 2D elements basing on an existing 2D mesh
80    */
81   interface NETGENPlugin_Remesher_2D : SMESH::SMESH_2D_Algo
82   {
83   };
84
85   /*!
86    * NETGENPlugin_Hypothesis: interface of "NETGEN parameters" hypothesis
87    */
88   interface NETGENPlugin_Hypothesis : SMESH::SMESH_Hypothesis
89   {
90     void    SetMaxSize(in double value);
91     double  GetMaxSize();
92
93     void    SetMinSize(in double value);
94     double  GetMinSize();
95
96     void    SetSecondOrder(in boolean value);
97     boolean GetSecondOrder();
98
99     void    SetOptimize(in boolean value);
100     boolean GetOptimize();
101
102     void    SetFineness(in long value);
103     long    GetFineness();
104
105     void    SetGrowthRate(in double value);
106     double  GetGrowthRate();
107
108     void    SetNbSegPerEdge(in double value);
109     double  GetNbSegPerEdge();
110
111     void    SetChordalErrorEnabled(in boolean value);
112     boolean GetChordalErrorEnabled();
113     void    SetChordalError(in double value);
114     double  GetChordalError();
115
116     void    SetNbSegPerRadius(in double value);
117     double  GetNbSegPerRadius();
118
119     void    SetQuadAllowed(in boolean value);
120     boolean GetQuadAllowed();
121
122     void    SetUseSurfaceCurvature(in boolean value);
123     boolean GetUseSurfaceCurvature();
124
125     void    SetFuseEdges(in boolean value);
126     boolean GetFuseEdges();
127
128     void    SetLocalSizeOnShape(in GEOM::GEOM_Object GeomObj, in double localSize)
129       raises (SALOME::SALOME_Exception);
130     void    SetLocalSizeOnEntry(in string entry, in double localSize);
131     double  GetLocalSizeOnEntry(in string entry);
132     string_array GetLocalSizeEntries();
133     void    UnsetLocalSizeOnEntry(in string entry);
134
135     void    SetMeshSizeFile(in string fileName);
136     string  GetMeshSizeFile();
137
138     void    SetNbSurfOptSteps(in short nb );
139     short   GetNbSurfOptSteps();
140
141     void    SetNbVolOptSteps(in short nb );
142     short   GetNbVolOptSteps();
143
144     void    SetElemSizeWeight(in double size );
145     double  GetElemSizeWeight();
146
147     void    SetWorstElemMeasure(in short val );
148     short   GetWorstElemMeasure();
149
150     void    SetNbThreads(in short val );
151     short   GetNbThreads();
152
153     void    SetUseDelauney(in boolean toUse);
154     boolean GetUseDelauney();
155
156     void    SetCheckOverlapping(in boolean toCheck );
157     boolean GetCheckOverlapping();
158
159     void    SetCheckChartBoundary(in boolean toCheck );
160     boolean GetCheckChartBoundary();
161   };
162
163   /*!
164    * NETGENPlugin_Hypothesis_2D: interface of "NETGEN 2D parameters" hypothesis
165    */
166   interface NETGENPlugin_Hypothesis_2D : NETGENPlugin_Hypothesis
167   {
168   };
169
170   /*!
171    * interface of "NETGEN 2D parameters" hypothesis used by NETGENPlugin_NETGEN_2D_ONLY algorithm
172    */
173   interface NETGENPlugin_Hypothesis_2D_ONLY : NETGENPlugin_Hypothesis_2D
174   {
175   };
176
177   /*!
178    * interface of "NETGEN 3D parameters" hypothesis used by NETGENPlugin_NETGEN_3D algorithm
179    */
180   interface NETGENPlugin_Hypothesis_3D : NETGENPlugin_Hypothesis
181   {
182   };
183
184   /*!
185    * interface of "NETGEN Remesher parameters" hypothesis used by NETGENPlugin_Remesher_2D algorithm
186    */
187   interface NETGENPlugin_RemesherHypothesis_2D : NETGENPlugin_Hypothesis_2D
188   {
189     /*!
190      * \brief Set/get ridge angle
191      */
192     void    SetRidgeAngle(in double angle );
193     double  GetRidgeAngle();
194
195     void    SetEdgeCornerAngle(in double angle );
196     double  GetEdgeCornerAngle();
197
198     void    SetChartAngle(in double angle );
199     double  GetChartAngle();
200
201     void    SetOuterChartAngle(in double angle );
202     double  GetOuterChartAngle();
203
204     void    SetRestHChartDistFactor(in double f );
205     double  GetRestHChartDistFactor();
206
207     void    SetRestHChartDistEnable(in boolean enable );
208     boolean GetRestHChartDistEnable();
209
210     void    SetRestHLineLengthFactor(in double f );
211     double  GetRestHLineLengthFactor();
212
213     void    SetRestHLineLengthEnable(in boolean enable );
214     boolean GetRestHLineLengthEnable();
215
216     void    SetRestHCloseEdgeFactor(in double f );
217     double  GetRestHCloseEdgeFactor();
218
219     void    SetRestHCloseEdgeEnable(in boolean enable );
220     boolean GetRestHCloseEdgeEnable();
221
222     void    SetRestHSurfCurvFactor(in double f );
223     double  GetRestHSurfCurvFactor();
224
225     void    SetRestHSurfCurvEnable(in boolean enable );
226     boolean GetRestHSurfCurvEnable();
227
228     void    SetRestHEdgeAngleFactor(in double f );
229     double  GetRestHEdgeAngleFactor();
230
231     void    SetRestHEdgeAngleEnable(in boolean enable );
232     boolean GetRestHEdgeAngleEnable();
233
234     void    SetRestHSurfMeshCurvFactor(in double f );
235     double  GetRestHSurfMeshCurvFactor();
236
237     void    SetRestHSurfMeshCurvEnable(in boolean enable );
238     boolean GetRestHSurfMeshCurvEnable();
239
240     void    SetKeepExistingEdges(in boolean toKeep );
241     boolean GetKeepExistingEdges();
242
243     void    SetMakeGroupsOfSurfaces(in boolean toMake );
244     boolean GetMakeGroupsOfSurfaces();
245
246     void    SetLoadMeshOnCancel(in boolean toLoad );
247     boolean GetLoadMeshOnCancel();
248
249     void SetFixedEdgeGroup( in SMESH::SMESH_GroupBase edgeGroup );
250     SMESH::SMESH_GroupBase GetFixedEdgeGroup( in SMESH::SMESH_Mesh mesh );
251   };
252
253   /*!
254    * NETGENPlugin_Hypothesis: interface of "NETGEN 2D simple parameters" hypothesis
255    */
256   interface NETGENPlugin_SimpleHypothesis_2D : SMESH::SMESH_Hypothesis
257   {
258     /*!
259      * Sets <number of segments> value
260      */
261     void SetNumberOfSegments(in long nb) raises (SALOME::SALOME_Exception);
262     /*!
263      * Returns <number of segments> value.
264      * Can be zero in case if LocalLength() has been set
265      */
266     long GetNumberOfSegments();
267
268     /*!
269      * Sets <segment length> value
270      */
271     void SetLocalLength(in double segmentLength);
272     /*!
273      * Returns <segment length> value.
274      * Can be zero in case if NumberOfSegments() has been set
275      */
276     double GetLocalLength();
277
278     /*!
279      * Sets <maximum element area> to be dependent on 1D discretization
280      */
281     void LengthFromEdges();
282     /*!
283      * Sets <maximum element area> value.
284      * Zero or negative value means same as LengthFromEdges().
285      */
286     void SetMaxElementArea(in double area);
287     /*!
288      * Returns <maximum element area> value.
289      * Can be zero in case of LengthFromEdges()
290      */
291     double GetMaxElementArea();
292
293     /*!
294      * Enables/disables generation of quadrangular faces
295      */
296     void SetAllowQuadrangles(in boolean toAllow);
297     /*!
298      * Returns true if generation of quadrangular faces is enabled
299      */
300     boolean GetAllowQuadrangles();
301   };
302
303   /*!
304    * NETGENPlugin_SimpleHypothesis_3D: interface of "NETGEN 3D simple parameters" hypothesis
305    */
306   interface NETGENPlugin_SimpleHypothesis_3D : NETGENPlugin_SimpleHypothesis_2D
307   {
308     /*!
309      * Sets <maximum element volume> to be dependent on 2D discretization
310      */
311     void LengthFromFaces();
312     /*!
313      * Sets <maximum element volume> value.
314      * Zero or negative value means same as LengthFromFaces().
315      */
316     void SetMaxElementVolume(in double volume);
317
318     /*!
319      * Returns <maximum element volume> value
320      * Can be zero in case of LengthFromFaces()
321      */
322     double GetMaxElementVolume();
323   };
324
325 };
326
327 #endif