ITK  4.6.0
Insight Segmentation and Registration Toolkit
itkSmoothingRecursiveGaussianImageFilter.h
Go to the documentation of this file.
1 /*=========================================================================
2  *
3  * Copyright Insight Software Consortium
4  *
5  * Licensed under the Apache License, Version 2.0 (the "License");
6  * you may not use this file except in compliance with the License.
7  * You may obtain a copy of the License at
8  *
9  * http://www.apache.org/licenses/LICENSE-2.0.txt
10  *
11  * Unless required by applicable law or agreed to in writing, software
12  * distributed under the License is distributed on an "AS IS" BASIS,
13  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14  * See the License for the specific language governing permissions and
15  * limitations under the License.
16  *
17  *=========================================================================*/
18 #ifndef __itkSmoothingRecursiveGaussianImageFilter_h
19 #define __itkSmoothingRecursiveGaussianImageFilter_h
20 
22 #include "itkCastImageFilter.h"
23 #include "itkImage.h"
24 #include "itkPixelTraits.h"
25 #include "itkCommand.h"
26 
27 namespace itk
28 {
49 template< typename TInputImage,
50  typename TOutputImage = TInputImage >
52  public InPlaceImageFilter< TInputImage, TOutputImage >
53 {
54 public:
60 
62  typedef TInputImage InputImageType;
63  typedef TOutputImage OutputImageType;
64  typedef typename TInputImage::PixelType PixelType;
67 
71 
73  itkStaticConstMacro(ImageDimension, unsigned int,
74  TInputImage::ImageDimension);
75 
77  typedef FixedArray< ScalarRealType,
78  itkGetStaticConstMacro(ImageDimension) > SigmaArrayType;
79 
85  typedef typename InputImageType::template Rebind<InternalRealType>::Type RealImageType;
86 
92 
98 
100  typedef CastImageFilter<
104 
107 
110 
113 
115  typedef typename OutputImageType::Pointer OutputImagePointer;
116 
118  itkNewMacro(Self);
119 
124  void SetSigmaArray(const SigmaArrayType & sigmas);
125  void SetSigma(ScalarRealType sigma);
127 
129  ScalarRealType GetSigma() const;
130 
135  void SetNormalizeAcrossScale(bool normalizeInScaleSpace);
136  itkGetConstMacro(NormalizeAcrossScale, bool);
138 
139  // See super class for doxygen documentation
140  //
142 
143  // See super class for doxygen documentation
144  //
145  virtual bool CanRunInPlace( void ) const;
146 
147 #ifdef ITK_USE_CONCEPT_CHECKING
148  // Begin concept checking
149  // This concept does not work with variable length vector images
150  //itkConceptMacro( InputHasNumericTraitsCheck,
151  //( Concept::HasNumericTraits< PixelType > ) );
152  // End concept checking
153 #endif
154 
155 protected:
158  void PrintSelf(std::ostream & os, Indent indent) const;
159 
161  void GenerateData(void);
162 
168  virtual void GenerateInputRequestedRegion();
169 
170  // Override since the filter produces the entire dataset
172 
173 private:
174  SmoothingRecursiveGaussianImageFilter(const Self &); //purposely not
175  // implemented
176  void operator=(const Self &); //purposely not
177 
178  // implemented
179 
183 
186 
189 };
190 } // end namespace itk
191 
192 #ifndef ITK_MANUAL_INSTANTIATION
193 #include "itkSmoothingRecursiveGaussianImageFilter.hxx"
194 #endif
195 
196 #endif
FixedArray< ScalarRealType, itkGetStaticConstMacro(ImageDimension) > SigmaArrayType
void SetSigmaArray(const SigmaArrayType &sigmas)
InPlaceImageFilter< TInputImage, TOutputImage > Superclass
Base class for computing IIR convolution with an approximation of a Gaussian kernel.
Base class for all process objects that output image data.
Simulate a standard C array with copy semnatics.
Definition: itkFixedArray.h:50
void SetSigma(ScalarRealType sigma)
InternalGaussianFilterPointer m_SmoothingFilters[ImageDimension-1]
Computes the smoothing of an image by convolution with the Gaussian kernels implemented as IIR filter...
virtual bool CanRunInPlace(void) const
NumericTraits< PixelType >::ScalarRealType ScalarRealType
void EnlargeOutputRequestedRegion(DataObject *output)
void PrintSelf(std::ostream &os, Indent indent) const
RecursiveGaussianImageFilter< InputImageType, RealImageType > FirstGaussianFilterType
Base class for filters that take an image as input and produce an image as output.
CastImageFilter< RealImageType, OutputImageType > CastingFilterType
Control indentation during Print() invocation.
Definition: itkIndent.h:49
RecursiveGaussianImageFilter< RealImageType, RealImageType > InternalGaussianFilterType
Define additional traits for native types such as int or float.
TOutputImage OutputImageType
Base class for filters that take an image as input and overwrite that image as the output...
void SetNormalizeAcrossScale(bool normalizeInScaleSpace)
InputImageType::template Rebind< InternalRealType >::Type RealImageType
Base class for all data objects in ITK.
Casts input pixels to output pixel type.
unsigned int ThreadIdType
Definition: itkIntTypes.h:159