VTK
vtkImageThresholdConnectivity.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3  Program: Visualization Toolkit
4  Module: vtkImageThresholdConnectivity.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 =========================================================================*/
35 #ifndef __vtkImageThresholdConnectivity_h
36 #define __vtkImageThresholdConnectivity_h
37 
38 #include "vtkImageAlgorithm.h"
39 
40 class vtkPoints;
41 class vtkImageData;
43 
45  public vtkImageAlgorithm
46 {
47 public:
50  void PrintSelf(ostream& os, vtkIndent indent);
51 
53 
55  void SetSeedPoints(vtkPoints *points);
56  vtkGetObjectMacro(SeedPoints, vtkPoints);
58 
60  void ThresholdByUpper(double thresh);
61 
63  void ThresholdByLower(double thresh);
64 
67  void ThresholdBetween(double lower, double upper);
68 
70 
71  vtkSetMacro(ReplaceIn, int);
72  vtkGetMacro(ReplaceIn, int);
73  vtkBooleanMacro(ReplaceIn, int);
75 
77 
79  void SetInValue(double val);
80  vtkGetMacro(InValue, double);
82 
84 
85  vtkSetMacro(ReplaceOut, int);
86  vtkGetMacro(ReplaceOut, int);
87  vtkBooleanMacro(ReplaceOut, int);
89 
91 
93  void SetOutValue(double val);
94  vtkGetMacro(OutValue, double);
96 
98 
99  vtkGetMacro(UpperThreshold, double);
100  vtkGetMacro(LowerThreshold, double);
102 
104 
105  vtkSetVector2Macro(SliceRangeX, int);
106  vtkGetVector2Macro(SliceRangeX, int);
107  vtkSetVector2Macro(SliceRangeY, int);
108  vtkGetVector2Macro(SliceRangeY, int);
109  vtkSetVector2Macro(SliceRangeZ, int);
110  vtkGetVector2Macro(SliceRangeZ, int);
112 
114 
116  virtual void SetStencil(vtkImageStencilData *stencil);
117  vtkImageStencilData *GetStencil();
119 
121 
123  vtkSetMacro(ActiveComponent,int);
124  vtkGetMacro(ActiveComponent,int);
126 
128 
132  vtkSetVector3Macro(NeighborhoodRadius, double);
133  vtkGetVector3Macro(NeighborhoodRadius, double);
135 
137 
139  vtkSetClampMacro(NeighborhoodFraction, double, 0.0, 1.0);
140  vtkGetMacro(NeighborhoodFraction, double);
142 
144  unsigned long GetMTime();
145 
147 
149  vtkGetMacro(NumberOfInVoxels, int);
151 
152 protected:
155 
158  double InValue;
159  double OutValue;
162 
163  double NeighborhoodRadius[3];
165 
167 
168  int SliceRangeX[2];
169  int SliceRangeY[2];
170  int SliceRangeZ[2];
171 
173 
175 
177 
178  void ComputeInputUpdateExtent(int inExt[6], int outExt[6]);
179 
185 
186 private:
188  void operator=(const vtkImageThresholdConnectivity&); // Not implemented.
189 };
190 
191 #endif