go home Home | Main Page | Modules | Namespace List | Class Hierarchy | Alphabetical List | Data Structures | File List | Namespace Members | Data Fields | Globals | Related Pages
itkLimiterFunctionBase.h
Go to the documentation of this file.
1 /*======================================================================
2 
3  This file is part of the elastix software.
4 
5  Copyright (c) University Medical Center Utrecht. All rights reserved.
6  See src/CopyrightElastix.txt or http://elastix.isi.uu.nl/legal.php for
7  details.
8 
9  This software is distributed WITHOUT ANY WARRANTY; without even
10  the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
11  PURPOSE. See the above copyright notices for more information.
12 
13 ======================================================================*/
14 #ifndef __itkLimiterFunctionBase_h
15 #define __itkLimiterFunctionBase_h
16 
17 #include "itkFunctionBase.h"
18 #include "itkExceptionObject.h"
19 
20 namespace itk
21 {
22 
45 template< class TInput, unsigned int NDimension >
47  public FunctionBase< TInput, typename NumericTraits< TInput >::RealType >
48 {
49 public:
50 
54  typedef SmartPointer< Self > Pointer;
55  typedef SmartPointer< const Self > ConstPointer;
56 
58  itkTypeMacro( LimiterFunctionBase, FunctionBase );
59 
60  itkStaticConstMacro( Dimension, unsigned int, NDimension );
61 
63  typedef typename Superclass::InputType InputType;
64  typedef typename Superclass::OutputType OutputType;
65 
67  typedef CovariantVector<
69  itkGetStaticConstMacro( Dimension ) > DerivativeType;
70 
72  virtual OutputType Evaluate( const InputType & input ) const = 0;
73 
75  virtual OutputType Evaluate( const InputType & input, DerivativeType & derivative ) const = 0;
76 
79  itkSetMacro( UpperBound, OutputType );
80  itkGetConstMacro( UpperBound, OutputType );
81 
84  itkSetMacro( LowerBound, OutputType );
85  itkGetConstMacro( LowerBound, OutputType );
86 
89  itkSetMacro( UpperThreshold, InputType );
90  itkGetConstMacro( UpperThreshold, InputType );
91 
94  itkSetMacro( LowerThreshold, InputType );
95  itkGetConstMacro( LowerThreshold, InputType );
96 
98  virtual void Initialize( void ) throw ( ExceptionObject ) {}
99 
100 protected:
101 
103  {
104  this->m_UpperBound
105  = itk::NumericTraits< OutputType >::One
106  + itk::NumericTraits< OutputType >::One;
107  this->m_LowerBound = itk::NumericTraits< OutputType >::Zero;
108  this->m_UpperThreshold = itk::NumericTraits< InputType >::One;
109  this->m_LowerThreshold = itk::NumericTraits< InputType >::One;
110  }
111 
112 
114 
119 
120 private:
121 
122  LimiterFunctionBase( const Self & ); // purposely not implemented
123  void operator=( const Self & ); // purposely not implemented
124 
125 };
126 
127 } // end namespace itk
128 
129 #endif
itkStaticConstMacro(Dimension, unsigned int, NDimension)
CovariantVector< DerivativeValueType, itkGetStaticConstMacro(Dimension) > DerivativeType
SmartPointer< Self > Pointer
virtual OutputType Evaluate(const InputType &input) const =0
FunctionBase< TInput, typename NumericTraits< TInput >::RealType > Superclass
Base class for all ITK limiter function objects.
Superclass::InputType InputType
SmartPointer< const Self > ConstPointer
Superclass::OutputType OutputType
void operator=(const Self &)


Generated on 11-03-2014 for elastix by doxygen 1.8.6 elastix logo