KWStyle - itkBackwardDifferenceOperator.h
 
Matrix View
Description

1 /*=========================================================================
2
3   Program:   Insight Segmentation & Registration Toolkit
4   Module:    $RCSfile: itkBackwardDifferenceOperator.h.html,v $
5   Language:  C++
6   Date:      $Date: 2006/01/17 19:15:33 $
7   Version:   $Revision: 1.4 $
8
9   Copyright (c) Insight Software Consortium. All rights reserved.
10   See ITKCopyright.txt or http://www.itk.org/HTML/Copyright.htm for details.
11
12      This software is distributed WITHOUT ANY WARRANTY; without even 
13      the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR 
14      PURPOSE.  See the above copyright notices for more information.
15
16 =========================================================================*/
17 #ifndef __itkBackwardDifferenceOperator_h
18 #define __itkBackwardDifferenceOperator_h
19
20 #include "itkNeighborhoodOperator.h"
21 #include "itkExceptionObject.h"
22
23 namespace itk {
24
25 /**
26  * \class BackwardDifferenceOperator
27  * \brief Operator whose inner product with a neighborhood returns
28  * a "half" derivative at the center of the neighborhood.
29  *
30  * BackwardDifferenceOperator uses backward differences
31  * i.e. F(x) - F(x-1) to calculate a "half" derivative useful, among
32  * other things, in solving differential equations. It is a directional
33  * NeighborhoodOperator that should be applied to a Neighborhood using the
34  * inner product. 
35  *
36  * \ingroup Operators
37  *
38  */
39 template<class TPixel, unsigned int VDimension=2,
40   class TAllocator = NeighborhoodAllocator<TPixel> >
41 class ITK_EXPORT BackwardDifferenceOperator
42 IND **: public NeighborhoodOperator<TPixel, VDimension, TAllocator>
43 {
44 public:
45   /** Standard class typedefs. */
46   typedef BackwardDifferenceOperator Self;
47 TDA   typedef NeighborhoodOperator<TPixel, VDimension, TAllocator> Superclass;
48     
49   /** From Superclass */
50   typedef typename Superclass::PixelType PixelType;
51
52   /** Constructor. */
53   BackwardDifferenceOperator() {}
54
55 protected:
56   /** Necessary to work around a compiler bug in VC++. */
57   typedef typename Superclass::CoefficientVector CoefficientVector;
58
59   /** Calculates operator coefficients. */
60   CoefficientVector GenerateCoefficients();
61
62   /** Arranges coefficients spatially in the memory buffer. */
63   void Fill(const CoefficientVector &coeff)
64     { this->FillCenteredDirectional(coeff); }
65
66 private:
67   BackwardDifferenceOperator(const Self& other); //purposely not implemented
68   Self &operator=(const Self& other); //purposely not implemented
69   
70 };
71
72 // namespace itk
73
74 #ifndef ITK_MANUAL_INSTANTIATION
75 #include "itkBackwardDifferenceOperator.txx"
76 #endif
77
78 #endif
79
80 EOF
81 EOF,EML

Generated by KWStyle 1.0b on Tuesday January,17 at 02:13:59PM
© Kitware Inc.