VTK
vtkDataSetRegionSurfaceFilter.h
Go to the documentation of this file.
1 //=========================================================================
2 // Copyright (c) Kitware, Inc.
3 // All rights reserved.
4 // See LICENSE.txt for details.
5 //
6 // This software is distributed WITHOUT ANY WARRANTY; without even
7 // the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
8 // PURPOSE. See the above copyright notice for more information.
9 //=========================================================================
24 #ifndef vtkDataSetRegionSurfaceFilter_h
25 #define vtkDataSetRegionSurfaceFilter_h
26 
27 #include "vtkFiltersGeometryModule.h" // For export macro
28 
30 
31 class vtkCharArray;
32 
33 class VTKFILTERSGEOMETRY_EXPORT vtkDataSetRegionSurfaceFilter : public vtkDataSetSurfaceFilter
34 {
35 public:
38  void PrintSelf(ostream& os, vtkIndent indent) override;
39 
41 
45  vtkSetStringMacro(RegionArrayName);
46  vtkGetStringMacro(RegionArrayName);
48 
50  vtkPolyData *output) override;
51 
52  //make it clear we want all the recordOrigCellId signatures from our parent
54 
55  //override one of the signatures
56  void RecordOrigCellId(vtkIdType newIndex, vtkFastGeomQuad *quad) override;
57 
59 
63  vtkSetMacro(SingleSided, bool);
64  vtkGetMacro(SingleSided, bool);
66 
68 
72  vtkSetStringMacro(MaterialPropertiesName);
73  vtkGetStringMacro(MaterialPropertiesName);
75 
77 
81  vtkSetStringMacro(MaterialIDsName);
82  vtkGetStringMacro(MaterialIDsName);
84 
86 
90  vtkSetStringMacro(MaterialPIDsName);
91  vtkGetStringMacro(MaterialPIDsName);
93 
95 
99  vtkSetStringMacro(InterfaceIDsName);
100  vtkGetStringMacro(InterfaceIDsName);
102 
103 protected:
105  ~vtkDataSetRegionSurfaceFilter() override;
106 
107  int FillInputPortInformation(int port, vtkInformation *info) override;
108 
112  vtkInformationVector *) override;
113 
114  virtual void InsertQuadInHash(vtkIdType a, vtkIdType b, vtkIdType c,
115  vtkIdType d, vtkIdType sourceId, vtkIdType faceId);
117  vtkIdType d, vtkIdType sourceId) override
118  {
119  this->InsertQuadInHash(a,b,c,d,sourceId, -1); //for -Woverloaded-virtual comp warning
120  }
121 
123  vtkIdType sourceId, vtkIdType faceId) override;
125  vtkIdType sourceId)
126  {
127  this->InsertTriInHash(a,b,c,sourceId, -1); //for -Woverloaded-virtual comp warning
128  }
129 
131 
132 private:
134  void operator=(const vtkDataSetRegionSurfaceFilter&) = delete;
135 
136  char *RegionArrayName;
137  vtkIntArray *RegionArray;
138  vtkIdTypeArray *OrigCellIds;
139  vtkCharArray *CellFaceIds;
140  bool SingleSided;
141  char *MaterialPropertiesName;
142  char *MaterialIDsName;
143  char *MaterialPIDsName;
144  char *InterfaceIDsName;
145 
146  class Internals;
147  Internals *Internal;
148 };
149 
150 #endif
int FillInputPortInformation(int port, vtkInformation *info) override
Fill the input port information objects for this algorithm.
Store vtkAlgorithm input/output information.
abstract class to specify dataset behavior
Definition: vtkDataSet.h:62
virtual void InsertTriInHash(vtkIdType a, vtkIdType b, vtkIdType c, vtkIdType sourceId, vtkIdType faceId=-1)
virtual void InsertQuadInHash(vtkIdType a, vtkIdType b, vtkIdType c, vtkIdType d, vtkIdType sourceId)
virtual void InsertTriInHash(vtkIdType a, vtkIdType b, vtkIdType c, vtkIdType sourceId)
dynamic, self-adjusting array of vtkIdType
int vtkIdType
Definition: vtkType.h:347
concrete dataset represents vertices, lines, polygons, and triangle strips
Definition: vtkPolyData.h:85
dynamic, self-adjusting array of char
Definition: vtkCharArray.h:38
dynamic, self-adjusting array of int
Definition: vtkIntArray.h:45
vtkFastGeomQuad * GetNextVisibleQuadFromHash()
a simple class to control print indentation
Definition: vtkIndent.h:39
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
Extract surface of materials.
static vtkDataSetSurfaceFilter * New()
void InsertQuadInHash(vtkIdType a, vtkIdType b, vtkIdType c, vtkIdType d, vtkIdType sourceId) override
int RequestData(vtkInformation *, vtkInformationVector **, vtkInformationVector *) override
This is called by the superclass.
Store zero or more vtkInformation instances.
Extracts outer (polygonal) surface.
void RecordOrigCellId(vtkIdType newIndex, vtkIdType origId)
virtual int UnstructuredGridExecute(vtkDataSet *input, vtkPolyData *output)
Direct access methods that can be used to use the this class as an algorithm without using it as a fi...