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

itkNormalizedCorrelationImageFilter.h

Go to the documentation of this file.
00001 /*=========================================================================
00002 
00003   Program:   Insight Segmentation & Registration Toolkit
00004   Module:    $RCSfile: itkNormalizedCorrelationImageFilter.h,v $
00005   Language:  C++
00006   Date:      $Date: 2008-10-16 19:33:45 $
00007   Version:   $Revision: 1.6 $
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 __itkNormalizedCorrelationImageFilter_h
00018 #define __itkNormalizedCorrelationImageFilter_h
00019 
00020 #include "itkNeighborhoodOperatorImageFilter.h"
00021 
00022 namespace itk
00023 {
00043 template <class TInputImage, class TMaskImage, class TOutputImage, class TOperatorValueType=ITK_TYPENAME TOutputImage::PixelType>
00044 class ITK_EXPORT NormalizedCorrelationImageFilter :
00045     public NeighborhoodOperatorImageFilter< TInputImage, TOutputImage, TOperatorValueType > 
00046 {
00047 public:
00049   typedef NormalizedCorrelationImageFilter          Self;
00050   typedef NeighborhoodOperatorImageFilter<
00051     TInputImage, TOutputImage, TOperatorValueType > Superclass;
00052   typedef SmartPointer<Self>                        Pointer;
00053   typedef SmartPointer<const Self>                  ConstPointer;
00054 
00056   itkNewMacro(Self);
00057 
00059   itkTypeMacro(NormalizedCorrelationImageFilter, NeighborhoodOperatorImageFilter);
00060 
00063   typedef typename TOutputImage::PixelType         OutputPixelType;
00064   typedef typename TOutputImage::InternalPixelType OutputInternalPixelType;
00065   typedef typename  TInputImage::PixelType         InputPixelType;
00066   typedef typename  TInputImage::InternalPixelType InputInternalPixelType;
00067   typedef typename   TMaskImage::PixelType         MaskPixelType;
00068   typedef typename   TMaskImage::InternalPixelType MaskInternalPixelType;
00069 
00072   itkStaticConstMacro(InputImageDimension, unsigned int,
00073                       TInputImage::ImageDimension);
00074   itkStaticConstMacro(ImageDimension, unsigned int,
00075                       TOutputImage::ImageDimension);
00076   itkStaticConstMacro(MaskImageDimension, unsigned int,
00077                       TMaskImage::ImageDimension);
00079 
00081   typedef TInputImage                      InputImageType;
00082   typedef TMaskImage                       MaskImageType;
00083   typedef TOutputImage                     OutputImageType;
00084   typedef typename InputImageType::Pointer InputImagePointer;
00085   typedef typename MaskImageType::Pointer  MaskImagePointer;
00086 
00088   typedef ImageBoundaryCondition<OutputImageType> *ImageBoundaryConditionPointerType;
00089 
00091   typedef typename Superclass::OutputImageRegionType OutputImageRegionType;
00092   typedef typename Superclass::OperatorValueType     OperatorValueType;
00093 
00095   typedef typename Superclass::OutputNeighborhoodType OutputNeighborhoodType;
00096 
00100   void SetMaskImage( const TMaskImage* mask);
00101 
00105   const TMaskImage* GetMaskImage() const;
00106 
00110   void SetTemplate(const OutputNeighborhoodType &t)
00111     {
00112     this->SetOperator(t);
00113     }
00114 
00115 #ifdef ITK_USE_CONCEPT_CHECKING
00116 
00117   itkConceptMacro(SameDimensionCheck,
00118     (Concept::SameDimension<InputImageDimension, MaskImageDimension>));
00119   itkConceptMacro(OutputHasNumericTraitsCheck,
00120     (Concept::HasNumericTraits<OutputPixelType>));
00121   itkConceptMacro(OperatorHasNumericTraitsCheck,
00122     (Concept::HasNumericTraits<OperatorValueType>));
00123 
00125 #endif
00126 
00127 protected:
00128   NormalizedCorrelationImageFilter() {}
00129   virtual ~NormalizedCorrelationImageFilter() {}
00130     
00136   void GenerateInputRequestedRegion() throw (InvalidRequestedRegionError);
00137 
00149   void ThreadedGenerateData(const OutputImageRegionType& outputRegionForThread,
00150                             int threadId );
00151 
00153   void PrintSelf(std::ostream& os, Indent indent) const
00154     {  Superclass::PrintSelf(os, indent); }
00155 
00156 private:
00157   NormalizedCorrelationImageFilter(const Self&); //purposely not implemented
00158   void operator=(const Self&); //purposely not implemented
00159 
00160 };
00161   
00162 } // end namespace itk
00163 
00164 #ifndef ITK_MANUAL_INSTANTIATION
00165 #include "itkNormalizedCorrelationImageFilter.txx"
00166 #endif
00167 
00168 #endif
00169 

Generated at Wed Nov 5 23:13:16 2008 for ITK by doxygen 1.5.1 written by Dimitri van Heesch, © 1997-2000