VTK  9.2.6
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 =========================================================================*/
37 #ifndef vtkImageIslandRemoval2D_h
38 #define vtkImageIslandRemoval2D_h
39 
40 #include "vtkImageAlgorithm.h"
41 #include "vtkImagingMorphologicalModule.h" // For export macro
42 
44 {
45  void* inPtr;
46  void* outPtr;
47  int idx0;
48  int idx1;
49 };
51 
52 class VTKIMAGINGMORPHOLOGICAL_EXPORT vtkImageIslandRemoval2D : public vtkImageAlgorithm
53 {
54 public:
56 
61  void PrintSelf(ostream& os, vtkIndent indent) override;
63 
65 
68  vtkSetMacro(AreaThreshold, int);
69  vtkGetMacro(AreaThreshold, int);
71 
73 
76  vtkSetMacro(SquareNeighborhood, vtkTypeBool);
77  vtkGetMacro(SquareNeighborhood, vtkTypeBool);
78  vtkBooleanMacro(SquareNeighborhood, vtkTypeBool);
80 
82 
85  vtkSetMacro(IslandValue, double);
86  vtkGetMacro(IslandValue, double);
88 
90 
93  vtkSetMacro(ReplaceValue, double);
94  vtkGetMacro(ReplaceValue, double);
96 
97 protected:
99  ~vtkImageIslandRemoval2D() override = default;
100 
103  double IslandValue;
104  double ReplaceValue;
105 
107 
108 private:
110  void operator=(const vtkImageIslandRemoval2D&) = delete;
111 };
112 
113 #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:49
Store zero or more vtkInformation instances.
Store vtkAlgorithm input/output information.
int vtkTypeBool
Definition: vtkABI.h:69