Main Page   Groups   Namespace List   Class Hierarchy   Alphabetical List   Compound List   File List   Namespace Members   Compound Members   File Members   Concepts

itkCovarianceImageFunction.h

Go to the documentation of this file.
00001 /*========================================================================= 00002 00003 Program: Insight Segmentation & Registration Toolkit 00004 Module: $RCSfile: itkCovarianceImageFunction.h,v $ 00005 Language: C++ 00006 Date: $Date: 2003/09/10 14:29:05 $ 00007 Version: $Revision: 1.2 $ 00008 00009 Copyright (c) Insight Software Consortium. All rights reserved. 00010 See ITKCopyright.txt or http://www.itk.org/HTML/Copyright.htm for details. 00011 00012 This software is distributed WITHOUT ANY WARRANTY; without even 00013 the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR 00014 PURPOSE. See the above copyright notices for more information. 00015 00016 =========================================================================*/ 00017 #ifndef _itkCovarianceImageFunction_h 00018 #define _itkCovarianceImageFunction_h 00019 00020 #include "itkImageFunction.h" 00021 #include "itkNumericTraits.h" 00022 00023 namespace itk 00024 { 00025 00043 template <class TInputImage, class TCoordRep = float > 00044 class ITK_EXPORT CovarianceImageFunction : 00045 public ImageFunction< TInputImage, 00046 vnl_matrix< 00047 ITK_TYPENAME NumericTraits<typename TInputImage::PixelType::ValueType>::RealType >, 00048 TCoordRep > 00049 { 00050 public: 00052 typedef CovarianceImageFunction Self; 00053 typedef ImageFunction<TInputImage, 00054 vnl_matrix< 00055 ITK_TYPENAME NumericTraits<typename TInputImage::PixelType::ValueType>::RealType >, 00056 TCoordRep > Superclass; 00057 typedef SmartPointer<Self> Pointer; 00058 typedef SmartPointer<const Self> ConstPointer; 00059 00061 itkTypeMacro(CovarianceImageFunction, ImageFunction); 00062 00064 itkNewMacro(Self); 00065 00067 typedef TInputImage InputImageType; 00068 00070 typedef typename Superclass::OutputType OutputType; 00071 00073 typedef typename Superclass::IndexType IndexType; 00074 00076 typedef typename Superclass::ContinuousIndexType ContinuousIndexType; 00077 00079 typedef typename Superclass::PointType PointType; 00080 00082 itkStaticConstMacro(ImageDimension, unsigned int, 00083 InputImageType::ImageDimension); 00084 00086 typedef vnl_matrix< 00087 typename NumericTraits<typename InputImageType::PixelType::ValueType>::RealType > 00088 RealType; 00089 00091 virtual RealType EvaluateAtIndex( const IndexType& index ) const; 00092 00094 virtual RealType Evaluate( const PointType& point ) const 00095 { 00096 IndexType index; 00097 this->ConvertPointToNearestIndex( point, index ); 00098 return this->EvaluateAtIndex( index ); 00099 } 00100 virtual RealType EvaluateAtContinuousIndex( 00101 const ContinuousIndexType& cindex ) const 00102 { 00103 IndexType index; 00104 this->ConvertContinuousIndexToNearestIndex( cindex, index ); 00105 return this->EvaluateAtIndex( index ) ; 00106 } 00107 00110 itkSetMacro( NeighborhoodRadius, unsigned int ); 00111 itkGetConstReferenceMacro( NeighborhoodRadius, unsigned int ); 00112 00113 protected: 00114 CovarianceImageFunction(); 00115 ~CovarianceImageFunction(){}; 00116 void PrintSelf(std::ostream& os, Indent indent) const; 00117 00118 private: 00119 CovarianceImageFunction( const Self& ); //purposely not implemented 00120 void operator=( const Self& ); //purposely not implemented 00121 00122 unsigned int m_NeighborhoodRadius; 00123 00124 }; 00125 00126 } // namespace itk 00127 00128 #ifndef ITK_MANUAL_INSTANTIATION 00129 #include "itkCovarianceImageFunction.txx" 00130 #endif 00131 00132 #endif 00133

Generated at Sat Mar 31 02:16:27 2007 for ITK by doxygen 1.3.8 written by Dimitri van Heesch, © 1997-2000