Salome HOME
Debug algorithms and hypotheses assignment
[modules/smesh.git] / src / OBJECT / SMESH_ExtractGeometry.h
1 //  Copyright (C) 2003  OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
2 //  CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS 
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.opencascade.org/SALOME/ or email : webmaster.salome@opencascade.org 
19
20 #ifndef SALOME_ExtractGeometry_HeaderFile
21 #define SALOME_ExtractGeometry_HeaderFile
22
23 #include <vtkExtractGeometry.h>
24 #include <vector>
25
26
27 class SMESH_ExtractGeometry : public vtkExtractGeometry{
28 public:
29   vtkTypeMacro(SMESH_ExtractGeometry,vtkExtractGeometry);
30
31   static SMESH_ExtractGeometry *New();
32
33   void SetStoreMapping(bool theStoreMapping){
34     myStoreMapping = theStoreMapping;
35     Modified();
36   }
37   bool GetStoreMapping(){ return myStoreMapping;}
38
39   virtual vtkIdType GetNodeObjId(int theVtkID);
40   virtual vtkIdType GetElemObjId(int theVtkID);
41
42 protected:
43   SMESH_ExtractGeometry();
44   ~SMESH_ExtractGeometry();
45
46   void Execute();
47
48 private:
49   bool myStoreMapping;   
50   typedef std::vector<vtkIdType> TVectorId;
51   TVectorId myElemVTK2ObjIds;
52   TVectorId myNodeVTK2ObjIds;
53
54   SMESH_ExtractGeometry(const SMESH_ExtractGeometry&);  // Not implemented.
55   void operator=(const SMESH_ExtractGeometry&);  // Not implemented.
56 };
57
58
59 #endif
60
61