itkScalarChanAndVeseLevelSetFunction.h
Go to the documentation of this file.00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018 #ifndef __itkScalarChanAndVeseLevelSetFunction_h
00019 #define __itkScalarChanAndVeseLevelSetFunction_h
00020
00021 #include "itkScalarRegionBasedLevelSetFunction.h"
00022 #include "itkScalarChanAndVeseLevelSetFunctionData.h"
00023 #include "itkConstrainedRegionBasedLevelSetFunctionSharedData.h"
00024
00025 namespace itk {
00026
00067 template < class TInputImage,
00068 class TFeatureImage,
00069 class TSharedData=ConstrainedRegionBasedLevelSetFunctionSharedData< TInputImage, TFeatureImage,
00070 ScalarChanAndVeseLevelSetFunctionData< TInputImage, TFeatureImage > > >
00071 class ITK_EXPORT ScalarChanAndVeseLevelSetFunction
00072 : public ScalarRegionBasedLevelSetFunction< TInputImage, TFeatureImage, TSharedData >
00073 {
00074 public:
00075 typedef ScalarChanAndVeseLevelSetFunction Self;
00076 typedef ScalarRegionBasedLevelSetFunction<
00077 TInputImage, TFeatureImage, TSharedData > Superclass;
00078 typedef SmartPointer<Self> Pointer;
00079 typedef SmartPointer<const Self> ConstPointer;
00080
00082 itkNewMacro(Self);
00083
00085 itkTypeMacro( ScalarChanAndVeseLevelSetFunction, ScalarLevelSetFunction );
00086
00087 itkStaticConstMacro( ImageDimension, unsigned int, TFeatureImage::ImageDimension );
00088
00089 typedef TInputImage InputImageType;
00090 typedef typename Superclass::InputImageConstPointer InputImageConstPointer;
00091 typedef typename Superclass::InputImagePointer InputImagePointer;
00092 typedef typename Superclass::InputPixelType InputPixelType;
00093 typedef typename Superclass::InputIndexType InputIndexType;
00094 typedef typename Superclass::InputIndexValueType InputIndexValueType;
00095 typedef typename Superclass::InputSizeType InputSizeType;
00096 typedef typename Superclass::InputSizeValueType InputSizeValueType;
00097 typedef typename Superclass::InputRegionType InputRegionType;
00098 typedef typename Superclass::InputPointType InputPointType;
00099
00100 typedef TFeatureImage FeatureImageType;
00101 typedef typename FeatureImageType::ConstPointer FeatureImageConstPointer;
00102 typedef typename Superclass::FeaturePixelType FeaturePixelType;
00103 typedef typename Superclass::FeatureIndexType FeatureIndexType;
00104 typedef typename Superclass::FeatureOffsetType FeatureOffsetType;
00105
00106 typedef typename Superclass::ScalarValueType ScalarValueType;
00107 typedef typename Superclass::NeighborhoodType NeighborhoodType;
00108 typedef typename Superclass::FloatOffsetType FloatOffsetType;
00109 typedef typename Superclass::RadiusType RadiusType;
00110 typedef typename Superclass::TimeStepType TimeStepType;
00111 typedef typename Superclass::GlobalDataStruct GlobalDataStruct;
00112 typedef typename Superclass::PixelType PixelType;
00113 typedef typename Superclass::VectorType VectorType;
00114
00115 typedef typename Superclass::SharedDataType SharedDataType;
00116 typedef typename Superclass::SharedDataPointer SharedDataPointer;
00117
00118 typedef typename Superclass::ImageIteratorType ImageIteratorType;
00119 typedef typename Superclass::ConstImageIteratorType ConstImageIteratorType;
00120 typedef typename Superclass::FeatureImageIteratorType FeatureImageIteratorType;
00121 typedef typename Superclass::ConstFeatureIteratorType ConstFeatureIteratorType;
00122
00123 typedef typename Superclass::ListPixelType ListPixelType;
00124 typedef typename Superclass::ListPixelConstIterator ListPixelConstIterator;
00125 typedef typename Superclass::ListPixelIterator ListPixelIterator;
00126 typedef typename Superclass::ListImageType ListImageType;
00127
00128 protected:
00129 ScalarChanAndVeseLevelSetFunction() : Superclass() {}
00130 ~ScalarChanAndVeseLevelSetFunction(){}
00131
00132 void ComputeParameters();
00133 void UpdateSharedDataParameters();
00134
00135 ScalarValueType ComputeInternalTerm( const FeaturePixelType& iValue,
00136 const FeatureIndexType& iIdx );
00137
00138 ScalarValueType ComputeExternalTerm( const FeaturePixelType& iValue,
00139 const FeatureIndexType& iIdx );
00140
00141 void UpdateSharedDataInsideParameters( const unsigned int& iId,
00142 const FeaturePixelType& iVal, const ScalarValueType& iChange );
00143 void UpdateSharedDataOutsideParameters( const unsigned int& iId,
00144 const FeaturePixelType& iVal, const ScalarValueType& iChange );
00145
00146 private:
00147 ScalarChanAndVeseLevelSetFunction(const Self&);
00148 void operator=(const Self&);
00149 };
00150
00151 }
00152
00153 #ifndef ITK_MANUAL_INSTANTIATION
00154 #include "itkScalarChanAndVeseLevelSetFunction.txx"
00155 #endif
00156
00157 #endif
00158