Salome HOME
Merge branch 'kw/newExtractCellType'
[modules/paravis.git] / src / Plugins / MEDReader / plugin / MEDReaderIO / vtkExtractCellType.h
1 #ifndef vtkExtractCellType_h
2 #define vtkExtractCellType_h
3
4 #include "MEDReaderIOModule.h" // for export macro
5 #include "vtkDataSetAlgorithm.h"
6 #include "vtkExtractSelection.h"
7 #include "vtkNew.h"
8
9 class vtkDataArraySelection;
10 class vtkIdTypeArray;
11
12 class MEDREADERIO_EXPORT vtkExtractCellType : public vtkExtractSelection
13 {
14 public:
15   static vtkExtractCellType* New();
16   vtkTypeMacro(vtkExtractCellType, vtkExtractSelection);
17   void PrintSelf(ostream& os, vtkIndent indent) override;
18
19   virtual int GetNumberOfGeoTypesArrays();
20   const char *GetGeoTypesArrayName(int index);
21   int GetGeoTypesArrayStatus(const char *name);
22   virtual void SetGeoTypesStatus(const char *name, int status);
23   
24   vtkSetMacro(InsideOut, bool);
25
26 protected:
27   vtkExtractCellType();
28   ~vtkExtractCellType();
29
30   int RequestInformation(vtkInformation* req, vtkInformationVector** inInfo, vtkInformationVector* outInfo) override;
31   int RequestData(vtkInformation*, vtkInformationVector**, vtkInformationVector*) override;
32
33   void AppendToGeoTypes(vtkDataSet* dataset);
34   void SelectIds(vtkDataSet* dataset, vtkIdTypeArray* selArr);
35
36 private:
37   vtkExtractCellType(const vtkExtractCellType&) = delete;
38   void operator=(const vtkExtractCellType&) = delete;
39   
40   vtkNew<vtkDataArraySelection> FieldSelection;
41   int InsideOut = false;
42 };
43
44 #endif