VTK  9.3.1
vtkMaskPointsFilter.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
41 #ifndef vtkMaskPointsFilter_h
42 #define vtkMaskPointsFilter_h
43 
44 #include "vtkFiltersPointsModule.h" // For export macro
45 #include "vtkPointCloudFilter.h"
46 
47 VTK_ABI_NAMESPACE_BEGIN
48 class vtkImageData;
49 class vtkPointSet;
50 
51 class VTKFILTERSPOINTS_EXPORT vtkMaskPointsFilter : public vtkPointCloudFilter
52 {
53 public:
55 
59  static vtkMaskPointsFilter* New();
61  void PrintSelf(ostream& os, vtkIndent indent) override;
63 
65 
68  void SetMaskData(vtkDataObject* source);
69  vtkDataObject* GetMask();
71 
75  void SetMaskConnection(vtkAlgorithmOutput* algOutput);
76 
78 
84  vtkSetMacro(EmptyValue, unsigned char);
85  vtkGetMacro(EmptyValue, unsigned char);
87 
88 protected:
90  ~vtkMaskPointsFilter() override;
91 
92  unsigned char EmptyValue; // what value indicates a voxel is empty
93 
94  // All derived classes must implement this method. Note that a side effect of
95  // the class is to populate the PointMap. Zero is returned if there is a failure.
96  int FilterPoints(vtkPointSet* input) override;
97 
98  // Support second input
103  vtkImageData* Mask; // just a placeholder during execution
104 
105 private:
106  vtkMaskPointsFilter(const vtkMaskPointsFilter&) = delete;
107  void operator=(const vtkMaskPointsFilter&) = delete;
108 };
109 
110 VTK_ABI_NAMESPACE_END
111 #endif
int RequestData(vtkInformation *, vtkInformationVector **, vtkInformationVector *) override
This is called by the superclass.
Store vtkAlgorithm input/output information.
extract points within an image/volume mask
concrete class for storing a set of points
Definition: vtkPointSet.h:58
virtual int FilterPoints(vtkPointSet *input)=0
Proxy object to connect input/output ports.
static vtkPolyDataAlgorithm * New()
virtual int RequestUpdateExtent(vtkInformation *, vtkInformationVector **, vtkInformationVector *)
This is called by the superclass.
a simple class to control print indentation
Definition: vtkIndent.h:28
virtual int RequestInformation(vtkInformation *request, vtkInformationVector **inputVector, vtkInformationVector *outputVector)
topologically and geometrically regular array of data
Definition: vtkImageData.h:42
boost::graph_traits< vtkGraph * >::vertex_descriptor source(boost::graph_traits< vtkGraph * >::edge_descriptor e, vtkGraph *)
void PrintSelf(ostream &os, vtkIndent indent) override
Standard methods to obtain type information, and print information.
Store zero or more vtkInformation instances.
abstract class for filtering a point cloud
general representation of visualization data
Definition: vtkDataObject.h:54
int FillInputPortInformation(int port, vtkInformation *info) override
Fill the input port information objects for this algorithm.