ITK  4.9.0
Insight Segmentation and Registration Toolkit
itkFiniteDifferenceFunction.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 itkFiniteDifferenceFunction_h
19 #define itkFiniteDifferenceFunction_h
20 
21 #include "itkLightObject.h"
23 #include "itkVector.h"
24 
25 namespace itk
26 {
65 template< typename TImageType >
67 {
68 public:
69 
75 
78 
80  typedef TImageType ImageType;
81  typedef typename ImageType::PixelType PixelType;
82  typedef double PixelRealType;
83 
85  itkStaticConstMacro(ImageDimension, unsigned int, ImageType::ImageDimension);
86 
88  typedef double TimeStepType;
89 
94 
97 
101 
105 
109 
119  virtual void InitializeIteration() {}
120 
134  virtual PixelType ComputeUpdate( const NeighborhoodType & neighborhood,
135  void *globalData,
136  const FloatOffsetType & offset = FloatOffsetType(0.0) ) = 0;
137 
138 
141  void SetRadius(const RadiusType & r);
142 
145  const RadiusType & GetRadius() const;
146 
151 
154 
159 
166  virtual TimeStepType ComputeGlobalTimeStep(void *GlobalData) const = 0;
167 
175  virtual void * GetGlobalDataPointer() const = 0;
176 
182  virtual void ReleaseGlobalDataPointer(void *GlobalData) const = 0;
183 
184 protected:
187 
188  virtual void PrintSelf(std::ostream & os, Indent indent) const ITK_OVERRIDE;
189 
192 
193 private:
194  FiniteDifferenceFunction(const Self &) ITK_DELETE_FUNCTION;
195  void operator=(const Self &) ITK_DELETE_FUNCTION;
196 };
197 } // end namespace itk
198 
199 #ifndef ITK_MANUAL_INSTANTIATION
200 #include "itkFiniteDifferenceFunction.hxx"
201 #endif
202 
203 #endif
Light weight base class for most itk classes.
void GetScaleCoefficients(PixelRealType vals[ImageDimension]) const
static const unsigned int ImageDimension
const NeighborhoodScalesType ComputeNeighborhoodScales() const
Vector< PixelRealType, itkGetStaticConstMacro(ImageDimension) > NeighborhoodScalesType
ConstNeighborhoodIterator< TImageType >::RadiusType RadiusType
virtual void PrintSelf(std::ostream &os, Indent indent) const override
Const version of NeighborhoodIterator, defining iteration of a local N-dimensional neighborhood of pi...
const RadiusType & GetRadius() const
ConstNeighborhoodIterator< TImageType, DefaultBoundaryConditionType > NeighborhoodType
A templated class holding a n-Dimensional vector.
Definition: itkVector.h:62
PixelRealType m_ScaleCoefficients[ImageDimension]
void SetRadius(const RadiusType &r)
Vector< float, itkGetStaticConstMacro(ImageDimension) > FloatOffsetType
void SetScaleCoefficients(PixelRealType vals[ImageDimension])
virtual void * GetGlobalDataPointer() const =0
virtual TimeStepType ComputeGlobalTimeStep(void *GlobalData) const =0
virtual PixelType ComputeUpdate(const NeighborhoodType &neighborhood, void *globalData, const FloatOffsetType &offset=FloatOffsetType(0.0))=0
Control indentation during Print() invocation.
Definition: itkIndent.h:49
ZeroFluxNeumannBoundaryCondition< ImageType > DefaultBoundaryConditionType
SmartPointer< const Self > ConstPointer
virtual void ReleaseGlobalDataPointer(void *GlobalData) const =0