VTK  9.3.1
vtkPointCloudFilter.h
Go to the documentation of this file.
1 // SPDX-FileCopyrightText: Copyright (c) Ken Martin, Will Schroeder, Bill Lorensen
2 // SPDX-License-Identifier: BSD-3-CLAUSE
45 #ifndef vtkPointCloudFilter_h
46 #define vtkPointCloudFilter_h
47 
48 #include "vtkFiltersPointsModule.h" // For export macro
49 #include "vtkPolyDataAlgorithm.h"
50 
51 VTK_ABI_NAMESPACE_BEGIN
52 class vtkPointSet;
53 class vtkPolyData;
54 
55 class VTKFILTERSPOINTS_EXPORT vtkPointCloudFilter : public vtkPolyDataAlgorithm
56 {
57 public:
59 
63  void PrintSelf(ostream& os, vtkIndent indent) override;
65 
74  const vtkIdType* GetPointMap();
75 
80  vtkIdType GetNumberOfPointsRemoved();
81 
83 
90  vtkSetMacro(GenerateOutliers, bool);
91  vtkGetMacro(GenerateOutliers, bool);
92  vtkBooleanMacro(GenerateOutliers, bool);
94 
96 
102  vtkSetMacro(GenerateVertices, bool);
103  vtkGetMacro(GenerateVertices, bool);
104  vtkBooleanMacro(GenerateVertices, bool);
106 
107 protected:
109  ~vtkPointCloudFilter() override;
110 
111  // All derived classes must implement this method. Note that a side effect of
112  // the class is to populate the PointMap. Zero is returned on error.
113  virtual int FilterPoints(vtkPointSet* input) = 0;
114 
115  // Keep track of which points are removed through the point map
118 
119  // Does a second output need to be created?
121 
122  // Should output vertex cells be created?
124 
126  int FillInputPortInformation(int port, vtkInformation* info) override;
127 
128  void GenerateVerticesIfRequested(vtkPolyData* output);
129 
130 private:
131  vtkPointCloudFilter(const vtkPointCloudFilter&) = delete;
132  void operator=(const vtkPointCloudFilter&) = delete;
133 };
134 
135 VTK_ABI_NAMESPACE_END
136 #endif
Store vtkAlgorithm input/output information.
virtual int RequestData(vtkInformation *request, vtkInformationVector **inputVector, vtkInformationVector *outputVector)
This is called by the superclass.
concrete class for storing a set of points
Definition: vtkPointSet.h:58
int vtkIdType
Definition: vtkType.h:315
concrete dataset represents vertices, lines, polygons, and triangle strips
Definition: vtkPolyData.h:79
Superclass for algorithms that produce only polydata as output.
a simple class to control print indentation
Definition: vtkIndent.h:28
int FillInputPortInformation(int port, vtkInformation *info) override
Fill the input port information objects for this algorithm.
Store zero or more vtkInformation instances.
abstract class for filtering a point cloud
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.