00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017 #ifndef __itkMultiResolutionPyramidImageFilter_h
00018 #define __itkMultiResolutionPyramidImageFilter_h
00019
00020 #include "itkImageToImageFilter.h"
00021 #include "itkArray2D.h"
00022
00023 namespace itk
00024 {
00025
00103 template <
00104 class TInputImage,
00105 class TOutputImage
00106 >
00107 class ITK_EXPORT MultiResolutionPyramidImageFilter :
00108 public ImageToImageFilter< TInputImage, TOutputImage >
00109 {
00110 public:
00112 typedef MultiResolutionPyramidImageFilter Self;
00113 typedef ImageToImageFilter<TInputImage,TOutputImage> Superclass;
00114 typedef SmartPointer<Self> Pointer;
00115 typedef SmartPointer<const Self> ConstPointer;
00116
00118 itkNewMacro(Self);
00119
00121 itkTypeMacro(MultiResolutionPyramidImageFilter, ImageToImageFilter);
00122
00124 typedef Array2D<unsigned int> ScheduleType;
00125
00127 itkStaticConstMacro(ImageDimension, unsigned int,
00128 TInputImage::ImageDimension);
00129
00131 typedef typename Superclass::InputImageType InputImageType;
00132 typedef typename Superclass::OutputImageType OutputImageType;
00133 typedef typename Superclass::InputImagePointer InputImagePointer;
00134 typedef typename Superclass::OutputImagePointer OutputImagePointer;
00135 typedef typename Superclass::InputImageConstPointer InputImageConstPointer;
00136
00143 void SetNumberOfLevels(unsigned int num);
00144
00146 itkGetMacro(NumberOfLevels, unsigned int);
00147
00154 void SetSchedule( const ScheduleType& schedule );
00155
00157 itkGetConstReferenceMacro(Schedule, ScheduleType);
00158
00163 void SetStartingShrinkFactors( unsigned int factor );
00164 void SetStartingShrinkFactors( unsigned int* factors );
00165
00167 const unsigned int * GetStartingShrinkFactors() const;
00168
00172 static bool IsScheduleDownwardDivisible( const ScheduleType& schedule );
00173
00180 virtual void GenerateOutputInformation();
00181
00186 virtual void GenerateOutputRequestedRegion(DataObject *output);
00187
00194 virtual void GenerateInputRequestedRegion();
00195
00196 itkSetMacro(MaximumError,double);
00197 itkGetConstReferenceMacro(MaximumError,double);
00198
00199 protected:
00200 MultiResolutionPyramidImageFilter();
00201 ~MultiResolutionPyramidImageFilter() {};
00202 void PrintSelf(std::ostream&os, Indent indent) const;
00203
00205 void GenerateData();
00206
00207 double m_MaximumError;
00208 unsigned int m_NumberOfLevels;
00209 ScheduleType m_Schedule;
00210
00211 private:
00212 MultiResolutionPyramidImageFilter(const Self&);
00213 void operator=(const Self&);
00214
00215 };
00216
00217
00218 }
00219
00220 #ifndef ITK_MANUAL_INSTANTIATION
00221 #include "itkMultiResolutionPyramidImageFilter.txx"
00222 #endif
00223
00224 #endif
00225
00226