Salome HOME
Update comments.
[modules/gui.git] / src / VTKViewer / VTKViewer_ShrinkFilter.h
1 #ifndef VTKVIEWER_SHRINKFILTER_H
2 #define VTKVIEWER_SHRINKFILTER_H
3
4 #include "VTKViewer.h"
5
6 #include <vtkShrinkFilter.h>
7
8 #include <vector>
9
10 /*!Shrink cells composing an arbitrary data set.
11  *\warning It is possible to turn cells inside out or cause self intersection in special cases.
12  */
13 class VTKVIEWER_EXPORT VTKViewer_ShrinkFilter : public vtkShrinkFilter 
14 {
15 public:
16   /*!Create new instance of VTKViewer_ShrinkFilter.*/
17   static VTKViewer_ShrinkFilter *New();
18   vtkTypeRevisionMacro(VTKViewer_ShrinkFilter, vtkShrinkFilter);
19
20   void SetStoreMapping(int theStoreMapping);
21   /*!Gets store mapping flag.*/
22   int GetStoreMapping(){ return myStoreMapping;}
23
24   virtual vtkIdType GetNodeObjId(int theVtkID);
25   /*!Return element id by vtk id.*/
26   virtual vtkIdType GetElemObjId(int theVtkID) { return theVtkID;}
27
28 protected:
29   VTKViewer_ShrinkFilter();
30   ~VTKViewer_ShrinkFilter();
31   
32   void Execute();
33   /*!Not implemented.*/
34   void UnstructuredGridExecute();
35     
36 private:
37   int myStoreMapping;   
38   typedef std::vector<vtkIdType> TVectorId;
39   TVectorId myVTK2ObjIds;
40 };
41
42 #endif