ITK  4.13.0
Insight Segmentation and Registration Toolkit
itkGaussianDerivativeImageFunction.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 itkGaussianDerivativeImageFunction_h
19 #define itkGaussianDerivativeImageFunction_h
20 
24 
25 namespace itk
26 {
37 template< typename TInputImage, typename TOutput = double >
38 class ITK_TEMPLATE_EXPORT GaussianDerivativeImageFunction:
39  public ImageFunction< TInputImage,
40  Vector< TOutput, TInputImage::ImageDimension >,
41  TOutput >
42 {
43 public:
44 
47  typedef ImageFunction< TInputImage,
49  TOutput > Superclass;
52 
54  itkNewMacro(Self);
55 
58 
60  typedef TInputImage InputImageType;
61  typedef typename InputImageType::PixelType InputPixelType;
63 
65  itkStaticConstMacro(ImageDimension2, unsigned int,
66  InputImageType::ImageDimension);
67 
70 
73 
75  typedef typename Superclass::OutputType OutputType;
80 
83 
86 
88  // typedef Point< TOutput, itkGetStaticConstMacro(ImageDimension2) > PointType;
90 
92  virtual OutputType Evaluate(const PointType & point) const ITK_OVERRIDE;
93 
95  virtual OutputType EvaluateAtIndex(const IndexType & index) const ITK_OVERRIDE;
96 
98  virtual OutputType EvaluateAtContinuousIndex(
99  const ContinuousIndexType & index) const ITK_OVERRIDE;
100 
106  void SetSigma(const double *sigma);
107 
108  void SetSigma(const double sigma);
109 
110  const double * GetSigma() const { return m_Sigma; }
111 
113  void SetExtent(const double *extent);
114 
115  void SetExtent(const double extent);
116 
117  const double * GetExtent() const { return m_Extent; }
118 
123  virtual void SetInputImage(const InputImageType *ptr) ITK_OVERRIDE;
124 
125 protected:
127  GaussianDerivativeImageFunction(const Self &);
128 
130 
131  void operator=(const Self &);
132 
133  void PrintSelf(std::ostream & os, Indent indent) const ITK_OVERRIDE;
134 
137  void RecomputeGaussianKernel();
138 
141  void RecomputeContinuousGaussianKernel(
142  const double *offset) const;
143 
144 private:
145 
146  double m_Sigma[ImageDimension2];
147 
152 
155  double m_Extent[ImageDimension2];
156 
159 
163 };
164 } // namespace itk
165 
166 #ifndef ITK_MANUAL_INSTANTIATION
167 #include "itkGaussianDerivativeImageFunction.hxx"
168 #endif
169 
170 #endif
Light weight base class for most itk classes.
A light-weight container object for storing an N-dimensional neighborhood of values.
Neighborhood< TOutput, itkGetStaticConstMacro(ImageDimension2) > OperatorNeighborhoodType
ContinuousIndex< SpacePrecisionType, itkGetStaticConstMacro(ImageDimension2) > ContinuousIndexType
ImageFunction< TInputImage, Vector< TOutput, TInputImage::ImageDimension >, TOutput > Superclass
Neighborhood< InputPixelType, itkGetStaticConstMacro(ImageDimension2) > NeighborhoodType
Compute the convolution of a neighborhood operator with the image at a specific location in space...
NeighborhoodOperatorImageFunction< InputImageType, TOutput > OperatorImageFunctionType
N-dimensional Gaussian spatial function class.
A templated class holding a n-Dimensional vector.
Definition: itkVector.h:62
Vector< TOutput, itkGetStaticConstMacro(ImageDimension2) > VectorType
GaussianDerivativeSpatialFunction< TOutput, 1 > GaussianDerivativeFunctionType
N-dimensional Gaussian spatial function class.
FixedArray< OperatorNeighborhoodType, 2 *itkGetStaticConstMacro(ImageDimension2) > OperatorArrayType
GaussianSpatialFunction< TOutput, 1 > GaussianFunctionType
A templated class holding a point in n-Dimensional image space.
Control indentation during Print() invocation.
Definition: itkIndent.h:49
GaussianDerivativeFunctionType::Pointer GaussianDerivativeFunctionPointer
OperatorImageFunctionType::Pointer OperatorImageFunctionPointer
GaussianDerivativeFunctionPointer m_GaussianDerivativeFunction
Compute the gaussian derivatives of an the image at a specific location in space, i...
Evaluates a function of an image at specified position.