Salome HOME
21c09a2ece635a04f10b9ca1cbac71559c8cf43b
[plugins/ghs3dplugin.git] / src / GHS3DPlugin / GHS3DPlugin_Optimizer.hxx
1 // Copyright (C) 2004-2020  CEA/DEN, EDF R&D
2 //
3 // This library is free software; you can redistribute it and/or
4 // modify it under the terms of the GNU Lesser General Public
5 // License as published by the Free Software Foundation; either
6 // version 2.1 of the License, or (at your option) any later version.
7 //
8 // This library is distributed in the hope that it will be useful,
9 // but WITHOUT ANY WARRANTY; without even the implied warranty of
10 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
11 // Lesser General Public License for more details.
12 //
13 // You should have received a copy of the GNU Lesser General Public
14 // License along with this library; if not, write to the Free Software
15 // Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307 USA
16 //
17 // See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
18 //
19 // File      : GHS3DPlugin_Optimizer.hxx
20 // Created   : Mon Oct 31 19:58:02 2016
21
22
23 #ifndef __GHS3DPlugin_Optimizer_HXX__
24 #define __GHS3DPlugin_Optimizer_HXX__
25
26 #include <SMESH_Algo.hxx>
27
28 class GHS3DPlugin_OptimizerHypothesis;
29
30 class GHS3DPlugin_Optimizer: public SMESH_3D_Algo
31 {
32 public:
33   GHS3DPlugin_Optimizer(int hypId, SMESH_Gen* gen);
34
35   virtual bool CheckHypothesis(SMESH_Mesh&         aMesh,
36                                const TopoDS_Shape& aShape,
37                                Hypothesis_Status&  aStatus);
38
39   virtual void CancelCompute();
40   bool         computeCanceled() { return _computeCanceled; }
41
42   virtual bool Evaluate(SMESH_Mesh& aMesh, const TopoDS_Shape& aShape,
43                         MapShapeNbElems& aResMap);
44
45   virtual bool Compute(SMESH_Mesh&         theMesh,
46                        SMESH_MesherHelper* theHelper);
47   virtual bool Compute(SMESH_Mesh &         aMesh,
48                        const TopoDS_Shape & aShape);
49
50   static const char* Name() { return "MG-Tetra Optimization"; }
51
52   //virtual double GetProgress() const;
53
54 private:
55
56   const GHS3DPlugin_OptimizerHypothesis* _hyp;
57 };
58
59
60 #endif