ITK  4.2.0
Insight Segmentation and Registration Toolkit
itkGradientRecursiveGaussianImageFilter.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 __itkGradientRecursiveGaussianImageFilter_h
19 #define __itkGradientRecursiveGaussianImageFilter_h
20 
23 #include "itkImage.h"
24 #include "itkCovariantVector.h"
25 #include "itkPixelTraits.h"
26 #include "itkProgressAccumulator.h"
27 #include <vector>
28 
29 namespace itk
30 {
46 // NOTE that the typename macro has to be used here in lieu
47 // of "typename" because VC++ doesn't like the typename keyword
48 // on the defaults of template parameters
49 template< typename TInputImage,
50  typename TOutputImage = Image< CovariantVector<
51  typename NumericTraits< typename TInputImage::PixelType >::RealType,
55  public ImageToImageFilter< TInputImage, TOutputImage >
56 {
57 public:
63 
65  typedef TInputImage InputImageType;
66  typedef typename TInputImage::PixelType PixelType;
68 
70  itkStaticConstMacro(ImageDimension, unsigned int,
71  TInputImage::ImageDimension);
72 
77  typedef float InternalRealType;
78  typedef Image< InternalRealType,
79  itkGetStaticConstMacro(ImageDimension) > RealImageType;
80 
85  typedef NthElementImageAdaptor< TOutputImage,
87 
89 
95 
101 
104 
107 
109  typedef typename TOutputImage::Pointer OutputImagePointer;
110 
112  typedef TOutputImage OutputImageType;
113  typedef typename OutputImageType::PixelType OutputPixelType;
115 
117  itkNewMacro(Self);
118 
122 
124  void SetSigma(RealType sigma);
125 
129  void SetNormalizeAcrossScale(bool normalizeInScaleSpace);
130  itkGetConstMacro(NormalizeAcrossScale, bool);
132 
138  virtual void GenerateInputRequestedRegion()
140 
151  itkSetMacro(UseImageDirection, bool);
152  itkGetConstMacro(UseImageDirection, bool);
153  itkBooleanMacro(UseImageDirection);
155 
156 #ifdef ITK_USE_CONCEPT_CHECKING
157 
158  itkConceptMacro( InputHasNumericTraitsCheck,
160  itkConceptMacro( OutputHasPixelTraitsCheck,
162 
164 #endif
165 protected:
168  void PrintSelf(std::ostream & os, Indent indent) const;
170 
172  void GenerateData(void);
173 
174  // Override since the filter produces the entire dataset
175  void EnlargeOutputRequestedRegion(DataObject *output);
176 
177 private:
178  GradientRecursiveGaussianImageFilter(const Self &); //purposely not
179  // implemented
180  void operator=(const Self &); //purposely not
181 
182  // implemented
183 
184  std::vector< GaussianFilterPointer > m_SmoothingFilters;
187 
190 
193 };
194 } // end namespace itk
195 
196 #ifndef ITK_MANUAL_INSTANTIATION
197 #include "itkGradientRecursiveGaussianImageFilter.hxx"
198 #endif
199 
200 #endif
201