VTK
vtkMaskPointsFilter.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3  Program: Visualization Toolkit
4  Module: vtkMaskPointsFilter.h
5 
6  Copyright (c) Kitware, Inc.
7  All rights reserved.
8  See LICENSE file 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 =========================================================================*/
53 #ifndef vtkMaskPointsFilter_h
54 #define vtkMaskPointsFilter_h
55 
56 #include "vtkFiltersPointsModule.h" // For export macro
57 #include "vtkPointCloudFilter.h"
58 
59 class vtkImageData;
60 class vtkPointSet;
61 
62 
63 class VTKFILTERSPOINTS_EXPORT vtkMaskPointsFilter : public vtkPointCloudFilter
64 {
65 public:
67 
71  static vtkMaskPointsFilter *New();
73  void PrintSelf(ostream& os, vtkIndent indent) override;
75 
77 
80  void SetMaskData(vtkDataObject *source);
81  vtkDataObject *GetMask();
83 
87  void SetMaskConnection(vtkAlgorithmOutput* algOutput);
88 
90 
96  vtkSetMacro(EmptyValue,unsigned char);
97  vtkGetMacro(EmptyValue,unsigned char);
99 
100 protected:
102  ~vtkMaskPointsFilter() override;
103 
104  unsigned char EmptyValue; // what value indicates a voxel is empty
105 
106  // All derived classes must implement this method. Note that a side effect of
107  // the class is to populate the PointMap. Zero is returned if there is a failure.
108  int FilterPoints(vtkPointSet *input) override;
109 
110  // Support second input
111  int FillInputPortInformation(int port, vtkInformation *info) override;
113  vtkInformationVector *) override;
115  vtkInformationVector *) override;
117  vtkInformationVector *) override;
118  vtkImageData *Mask; //just a placeholder during execution
119 
120 private:
121  vtkMaskPointsFilter(const vtkMaskPointsFilter&) = delete;
122  void operator=(const vtkMaskPointsFilter&) = delete;
123 
124 };
125 
126 #endif
vtkPointCloudFilter.h
vtkMaskPointsFilter::EmptyValue
unsigned char EmptyValue
Definition: vtkMaskPointsFilter.h:104
vtkPointCloudFilter
abstract class for filtering a point cloud
Definition: vtkPointCloudFilter.h:66
vtkInformationVector
Store zero or more vtkInformation instances.
Definition: vtkInformationVector.h:41
vtkMaskPointsFilter::Mask
vtkImageData * Mask
Definition: vtkMaskPointsFilter.h:118
vtkPolyDataAlgorithm::RequestUpdateExtent
virtual int RequestUpdateExtent(vtkInformation *, vtkInformationVector **, vtkInformationVector *)
This is called by the superclass.
vtkPointCloudFilter::PrintSelf
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
vtkMaskPointsFilter
extract points within an image/volume mask
Definition: vtkMaskPointsFilter.h:63
source
boost::graph_traits< vtkGraph * >::vertex_descriptor source(boost::graph_traits< vtkGraph * >::edge_descriptor e, vtkGraph *)
Definition: vtkBoostGraphAdapter.h:825
vtkX3D::port
Definition: vtkX3D.h:447
vtkImageData
topologically and geometrically regular array of data
Definition: vtkImageData.h:45
vtkIndent
a simple class to control print indentation
Definition: vtkIndent.h:39
vtkPointCloudFilter::FilterPoints
virtual int FilterPoints(vtkPointSet *input)=0
vtkInformation
Store vtkAlgorithm input/output information.
Definition: vtkInformation.h:86
vtkX3D::info
Definition: vtkX3D.h:376
vtkAlgorithmOutput
Proxy object to connect input/output ports.
Definition: vtkAlgorithmOutput.h:39
vtkPointSet
abstract class for specifying dataset behavior
Definition: vtkPointSet.h:42
vtkPointCloudFilter::FillInputPortInformation
int FillInputPortInformation(int port, vtkInformation *info) override
Fill the input port information objects for this algorithm.
vtkDataObject
general representation of visualization data
Definition: vtkDataObject.h:64
vtkPolyDataAlgorithm::New
static vtkPolyDataAlgorithm * New()
vtkPolyDataAlgorithm::RequestInformation
virtual int RequestInformation(vtkInformation *request, vtkInformationVector **inputVector, vtkInformationVector *outputVector)
vtkPointCloudFilter::RequestData
int RequestData(vtkInformation *, vtkInformationVector **, vtkInformationVector *) override
This is called by the superclass.