VTK  9.2.5
vtkImageIslandRemoval2D.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3  Program: Visualization Toolkit
4  Module: vtkImageIslandRemoval2D.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 vtkImageIslandRemoval2D_h
48 #define vtkImageIslandRemoval2D_h
49 
50 #include "vtkImageAlgorithm.h"
51 #include "vtkImagingMorphologicalModule.h" // For export macro
52 
54 {
55  void* inPtr;
56  void* outPtr;
57  int idx0;
58  int idx1;
59 };
61 
62 class VTKIMAGINGMORPHOLOGICAL_EXPORT vtkImageIslandRemoval2D : public vtkImageAlgorithm
63 {
64 public:
66 
71  void PrintSelf(ostream& os, vtkIndent indent) override;
73 
75 
78  vtkSetMacro(AreaThreshold, int);
79  vtkGetMacro(AreaThreshold, int);
81 
83 
86  vtkSetMacro(SquareNeighborhood, vtkTypeBool);
87  vtkGetMacro(SquareNeighborhood, vtkTypeBool);
88  vtkBooleanMacro(SquareNeighborhood, vtkTypeBool);
90 
92 
95  vtkSetMacro(IslandValue, double);
96  vtkGetMacro(IslandValue, double);
98 
100 
103  vtkSetMacro(ReplaceValue, double);
104  vtkGetMacro(ReplaceValue, double);
106 
107 protected:
109  ~vtkImageIslandRemoval2D() override = default;
110 
113  double IslandValue;
114  double ReplaceValue;
115 
117 
118 private:
120  void operator=(const vtkImageIslandRemoval2D&) = delete;
121 };
122 
123 #endif
Generic algorithm superclass for image algs.
Removes small clusters in masks.
void PrintSelf(ostream &os, vtkIndent indent) override
Constructor: Sets default filter to be identity.
~vtkImageIslandRemoval2D() override=default
int RequestData(vtkInformation *, vtkInformationVector **, vtkInformationVector *) override
This is called in response to a REQUEST_DATA request from the executive.
static vtkImageIslandRemoval2D * New()
Constructor: Sets default filter to be identity.
a simple class to control print indentation
Definition: vtkIndent.h:119
Store zero or more vtkInformation instances.
Store vtkAlgorithm input/output information.
int vtkTypeBool
Definition: vtkABI.h:69