00001 
00002 
00003 
00004 
00005 
00006 
00007 
00008 
00009 
00010 
00011 
00012 
00013 
00014 
00027 #ifndef __vtkImageIslandRemoval2D_h
00028 #define __vtkImageIslandRemoval2D_h
00029 
00030 
00031 #include "vtkImageAlgorithm.h"
00032 
00033 
00034 typedef struct{
00035   void *inPtr;
00036   void *outPtr;
00037   int idx0;
00038   int idx1;
00039   } vtkImage2DIslandPixel;
00040 
00041 
00042 class VTK_IMAGING_EXPORT vtkImageIslandRemoval2D : public vtkImageAlgorithm
00043 {
00044 public:
00046 
00047   static vtkImageIslandRemoval2D *New();
00048   vtkTypeMacro(vtkImageIslandRemoval2D,vtkImageAlgorithm);
00049   void PrintSelf(ostream& os, vtkIndent indent);
00051   
00053 
00054   vtkSetMacro(AreaThreshold, int);
00055   vtkGetMacro(AreaThreshold, int);
00057 
00059 
00060   vtkSetMacro(SquareNeighborhood, int);
00061   vtkGetMacro(SquareNeighborhood, int);
00062   vtkBooleanMacro(SquareNeighborhood, int);
00064 
00066 
00067   vtkSetMacro(IslandValue, double);
00068   vtkGetMacro(IslandValue, double);
00070 
00072 
00073   vtkSetMacro(ReplaceValue, double);
00074   vtkGetMacro(ReplaceValue, double);
00076   
00077 protected:
00078   vtkImageIslandRemoval2D();
00079   ~vtkImageIslandRemoval2D() {};
00080 
00081   int AreaThreshold;
00082   int SquareNeighborhood;
00083   double IslandValue;
00084   double ReplaceValue;
00085 
00086   virtual int RequestData(vtkInformation *,
00087                           vtkInformationVector **,
00088                           vtkInformationVector *);
00089 
00090 private:
00091   vtkImageIslandRemoval2D(const vtkImageIslandRemoval2D&);  
00092   void operator=(const vtkImageIslandRemoval2D&);  
00093 };
00094 
00095 #endif
00096 
00097 
00098