itkTobogganImageFilter.h
Go to the documentation of this file.00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017 #ifndef __itkTobogganImageFilter_h
00018 #define __itkTobogganImageFilter_h
00019
00020 #include "itkImageToImageFilter.h"
00021 #include "itkConstNeighborhoodIterator.h"
00022
00023 namespace itk {
00024
00036 template<class TInputImage>
00037 class ITK_EXPORT TobogganImageFilter :
00038 public ImageToImageFilter<
00039 TInputImage,
00040 Image<unsigned long, ::itk::GetImageDimension<TInputImage>::ImageDimension> >
00041 {
00042 public:
00044 typedef TobogganImageFilter Self;
00045
00047 typedef TInputImage InputImageType;
00048
00050 itkStaticConstMacro(NDimensions, unsigned int, TInputImage::ImageDimension);
00051
00053 typedef Image<unsigned long, itkGetStaticConstMacro(NDimensions)> OutputImageType;
00054
00056 typedef typename OutputImageType::PixelType OutputImagePixelType;
00057
00059 typedef typename InputImageType::PixelType InputImagePixelType;
00060
00062 enum {ImageDimension = InputImageType::ImageDimension };
00063
00065 typedef typename InputImageType::RegionType RegionType;
00066 typedef typename InputImageType::SizeType SizeType;
00067 typedef typename InputImageType::IndexType IndexType;
00068 typedef typename InputImageType::Pointer InputImagePointer;
00069 typedef typename InputImageType::ConstPointer InputImageConstPointer;
00070 typedef typename OutputImageType::Pointer OutputImagePointer;
00071
00073 typedef ImageToImageFilter< InputImageType, OutputImageType > Superclass;
00074
00076 typedef typename InputImageType::PixelType ScalarType;
00077
00079 typedef SmartPointer<Self> Pointer;
00080
00082 itkTypeMacro(TobogganImageFilter, ImageToImageFilter);
00083
00085 itkNewMacro(Self);
00086
00088 void GenerateData();
00089 void GenerateInputRequestedRegion();
00090 void EnlargeOutputRequestedRegion ( DataObject* );
00091
00093 typedef ConstNeighborhoodIterator<TInputImage>
00094 NeighborhoodIteratorType;
00095
00096 #ifdef ITK_USE_CONCEPT_CHECKING
00097
00098 itkConceptMacro(LessThanComparableCheck,
00099 (Concept::LessThanComparable<InputImagePixelType>));
00100 itkConceptMacro(OStreamWritableCheck,
00101 (Concept::OStreamWritable<InputImagePixelType>));
00102
00104 #endif
00105
00106 protected:
00107 TobogganImageFilter();
00108 ~TobogganImageFilter() {};
00109 void PrintSelf(std::ostream& os, Indent indent) const;
00110
00111 private:
00112 TobogganImageFilter(const Self&);
00113 void operator=(const Self&);
00114
00115 };
00116
00117 }
00118
00119 #ifndef ITK_MANUAL_INSTANTIATION
00120 #include "itkTobogganImageFilter.txx"
00121 #endif
00122
00123 #endif
00124