VTK  9.0.2
vtkExtractCells.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3  Program: Visualization Toolkit
4  Module: vtkExtractCells.h
5 
6  Copyright (c) Ken Martin, Will Schroeder, Bill Lorensen
7  All rights reserved.
8  See Copyright.txt or http://www.kitware.com/Copyright.htm for details.
9 
10  This software is distributed WITHOUT ANY WARRANTY; without even
11  the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
12  PURPOSE. See the above copyright notice for more information.
13 
14 =========================================================================*/
15 /*----------------------------------------------------------------------------
16  Copyright (c) Sandia Corporation
17  See Copyright.txt or http://www.paraview.org/HTML/Copyright.html for details.
18 ----------------------------------------------------------------------------*/
19 
31 #ifndef vtkExtractCells_h
32 #define vtkExtractCells_h
33 
34 #include "vtkFiltersExtractionModule.h" // For export macro
36 
37 class vtkIdList;
38 class vtkExtractCellsSTLCloak;
39 
40 class VTKFILTERSEXTRACTION_EXPORT vtkExtractCells : public vtkUnstructuredGridAlgorithm
41 {
42 public:
44 
48  void PrintSelf(ostream& os, vtkIndent indent) override;
49  static vtkExtractCells* New();
51 
58 
64 
70 
72 
75  void SetCellIds(const vtkIdType* ptr, vtkIdType numValues);
76  void AddCellIds(const vtkIdType* ptr, vtkIdType numValues);
78 
80 
86  vtkSetMacro(ExtractAllCells, bool);
87  vtkGetMacro(ExtractAllCells, bool);
88  vtkBooleanMacro(ExtractAllCells, bool);
90 
92 
97  vtkSetMacro(AssumeSortedAndUniqueIds, bool);
98  vtkGetMacro(AssumeSortedAndUniqueIds, bool);
99  vtkBooleanMacro(AssumeSortedAndUniqueIds, bool);
101 protected:
104 
106  ~vtkExtractCells() override;
107 
108  void Copy(vtkDataSet* input, vtkUnstructuredGrid* output);
110 
113 
114  vtkExtractCellsSTLCloak* CellList = nullptr;
115  vtkIdType SubSetUGridCellArraySize = 0;
116  vtkIdType SubSetUGridFacesArraySize = 0;
117  bool InputIsUgrid = false;
118  bool ExtractAllCells = false;
119  bool AssumeSortedAndUniqueIds = false;
120 
121 private:
122  vtkExtractCells(const vtkExtractCells&) = delete;
123  void operator=(const vtkExtractCells&) = delete;
124 };
125 
126 #endif
abstract class to specify dataset behavior
Definition: vtkDataSet.h:57
subset a vtkDataSet to create a vtkUnstructuredGrid
void SetCellIds(const vtkIdType *ptr, vtkIdType numValues)
Another way to provide ids using a pointer to vtkIdType array.
void SetCellList(vtkIdList *l)
Set the list of cell IDs that the output vtkUnstructuredGrid will be composed of.
~vtkExtractCells() override
void CopyCellsUnstructuredGrid(vtkDataSet *input, vtkUnstructuredGrid *output)
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
void AddCellList(vtkIdList *l)
Add the supplied list of cell IDs to those that will be included in the output vtkUnstructuredGrid.
int RequestData(vtkInformation *, vtkInformationVector **, vtkInformationVector *) override
This is called by the superclass.
void Copy(vtkDataSet *input, vtkUnstructuredGrid *output)
void AddCellIds(const vtkIdType *ptr, vtkIdType numValues)
static vtkExtractCells * New()
void CopyCellsDataSet(vtkDataSet *input, vtkUnstructuredGrid *output)
void AddCellRange(vtkIdType from, vtkIdType to)
Add this range of cell IDs to those that will be included in the output vtkUnstructuredGrid.
vtkIdType ReMapPointIds(vtkDataSet *grid)
int FillInputPortInformation(int port, vtkInformation *info) override
Fill the input port information objects for this algorithm.
list of point or cell ids
Definition: vtkIdList.h:31
a simple class to control print indentation
Definition: vtkIndent.h:34
Store zero or more vtkInformation instances.
Store vtkAlgorithm input/output information.
Superclass for algorithms that produce only unstructured grid as output.
dataset represents arbitrary combinations of all possible cell types
@ info
Definition: vtkX3D.h:382
@ port
Definition: vtkX3D.h:453
int vtkIdType
Definition: vtkType.h:338