Salome HOME
Join modifications from BR_Dev_For_4_0 tag V4_1_1.
[plugins/netgenplugin.git] / src / NETGENPlugin / NETGENPlugin_NETGEN_2D_ONLY.hxx
1 // Copyright (C) 2005  OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
2 // CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS, L3S, LJLL, MENSI
3 //
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.
8 //
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.
13 //
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
17 //
18 // See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
19 //
20 // File      : NETGENPlugin_NETGEN_2D_ONLY.hxx
21 // Project   : SALOME
22 // Author    : Edward AGAPOV (OCC)
23
24 #ifndef _NETGENPlugin_NETGEN_2D_ONLY_HXX_
25 #define _NETGENPlugin_NETGEN_2D_ONLY_HXX_
26
27 #include "SMESH_2D_Algo.hxx"
28 #include "SMESH_Mesh.hxx"
29
30 /*#define OCCGEOMETRY
31 #include <occgeom.hpp>
32 #include <meshing.hpp>//amv*/
33
34 class StdMeshers_MaxElementArea;
35 class StdMeshers_LengthFromEdges;
36 class StdMeshers_QuadranglePreference;
37 //class NETGENPlugin_Hypothesis;
38
39 /*namespace netgen {
40   class OCCGeometry;
41 }*/
42 /*namespace netgen {
43   class OCCGeometry;
44   extern int OCCGenerateMesh (OCCGeometry&, Mesh*&, int, int, char*);
45   extern MeshingParameters mparam;
46 }*/
47
48 //using namespace netgen;
49
50 /*!
51  * \brief Mesher generating 2D elements on a geometrical face taking
52  * into account pre-existing nodes on face boundaries
53  *
54  * Historically, NETGENPlugin_NETGEN_2D is actually 1D-2D, that is why
55  * the class is named NETGENPlugin_NETGEN_2D_ONLY. Renaming is useless as
56  * algorithm field "_name" can't be changed
57  */
58 class NETGENPlugin_NETGEN_2D_ONLY: public SMESH_2D_Algo
59 {
60 public:
61   NETGENPlugin_NETGEN_2D_ONLY(int hypId, int studyId, SMESH_Gen* gen);
62   virtual ~NETGENPlugin_NETGEN_2D_ONLY();
63
64   virtual bool CheckHypothesis(SMESH_Mesh&         aMesh,
65                                const TopoDS_Shape& aShape,
66                                Hypothesis_Status&  aStatus);
67
68   virtual bool Compute(SMESH_Mesh&         aMesh,
69                        const TopoDS_Shape& aShape);
70
71   /*static TError AddSegmentsToMesh(netgen::Mesh&                    ngMesh,
72                                 OCCGeometry&                     geom,
73                                 const TSideVector&               wires,
74                                 SMESH_MesherHelper&              helper,
75                                 vector< const SMDS_MeshNode* > & nodeVec); //amv*/
76
77 protected:
78   const StdMeshers_MaxElementArea*       _hypMaxElementArea;
79   const StdMeshers_LengthFromEdges*      _hypLengthFromEdges;
80   const StdMeshers_QuadranglePreference* _hypQuadranglePreference;
81   //  const NETGENPlugin_Hypothesis* _hypothesis;
82 };
83
84 #endif