VTK  9.2.6
vtkExtractPolyDataGeometry.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3  Program: Visualization Toolkit
4  Module: vtkExtractPolyDataGeometry.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 =========================================================================*/
47 #ifndef vtkExtractPolyDataGeometry_h
48 #define vtkExtractPolyDataGeometry_h
49 
50 #include "vtkFiltersExtractionModule.h" // For export macro
51 #include "vtkPolyDataAlgorithm.h"
52 
54 
55 class VTKFILTERSEXTRACTION_EXPORT vtkExtractPolyDataGeometry : public vtkPolyDataAlgorithm
56 {
57 public:
59  void PrintSelf(ostream& os, vtkIndent indent) override;
60 
65 
69  vtkMTimeType GetMTime() override;
70 
72 
75  virtual void SetImplicitFunction(vtkImplicitFunction*);
76  vtkGetObjectMacro(ImplicitFunction, vtkImplicitFunction);
78 
80 
85  vtkSetMacro(ExtractInside, vtkTypeBool);
86  vtkGetMacro(ExtractInside, vtkTypeBool);
87  vtkBooleanMacro(ExtractInside, vtkTypeBool);
89 
91 
95  vtkSetMacro(ExtractBoundaryCells, vtkTypeBool);
96  vtkGetMacro(ExtractBoundaryCells, vtkTypeBool);
97  vtkBooleanMacro(ExtractBoundaryCells, vtkTypeBool);
99 
101 
105  vtkSetMacro(PassPoints, vtkTypeBool);
106  vtkGetMacro(PassPoints, vtkTypeBool);
107  vtkBooleanMacro(PassPoints, vtkTypeBool);
109 
110 protected:
112  ~vtkExtractPolyDataGeometry() override;
113 
114  // Usual data generation method
116 
121 
122  vtkIdType InsertPointInMap(vtkIdType i, vtkPoints* inPts, vtkPoints* newPts, vtkIdType* pointMap);
123 
124 private:
126  void operator=(const vtkExtractPolyDataGeometry&) = delete;
127 };
128 
130 
134  vtkIdType i, vtkPoints* inPts, vtkPoints* newPts, vtkIdType* pointMap)
135 {
136  double x[3];
137  inPts->GetPoint(i, x);
138  pointMap[i] = newPts->InsertNextPoint(x);
139  return pointMap[i];
140 }
142 
143 #endif
abstract interface for implicit functions
Store vtkAlgorithm input/output information.
vtkTypeUInt32 vtkMTimeType
Definition: vtkType.h:287
virtual int RequestData(vtkInformation *request, vtkInformationVector **inputVector, vtkInformationVector *outputVector)
This is called by the superclass.
vtkIdType InsertPointInMap(vtkIdType i, vtkPoints *inPts, vtkPoints *newPts, vtkIdType *pointMap)
When not passing points, have to use a point map to keep track of things.
vtkIdType InsertNextPoint(const float x[3])
Insert point into next available slot.
Definition: vtkPoints.h:211
int vtkIdType
Definition: vtkType.h:332
static vtkPolyDataAlgorithm * New()
int vtkTypeBool
Definition: vtkABI.h:69
Superclass for algorithms that produce only polydata as output.
a simple class to control print indentation
Definition: vtkIndent.h:39
virtual vtkMTimeType GetMTime()
Return this object's modified time.
double * GetPoint(vtkIdType id)
Return a pointer to a double point x[3] for a specific id.
Definition: vtkPoints.h:140
Store zero or more vtkInformation instances.
extract vtkPolyData cells that lies either entirely inside or outside of a specified implicit functio...
represent and manipulate 3D points
Definition: vtkPoints.h:39
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.