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

itkConnectedComponentFunctorImageFilter.h

Go to the documentation of this file.
00001 /*=========================================================================
00002 
00003   Program:   Insight Segmentation & Registration Toolkit
00004   Module:    $RCSfile: itkConnectedComponentFunctorImageFilter.h,v $
00005   Language:  C++
00006   Date:      $Date: 2005/10/06 19:57:21 $
00007   Version:   $Revision: 1.1 $
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 __itkConnectedComponentFunctorImageFilter_h
00018 #define __itkConnectedComponentFunctorImageFilter_h
00019 
00020 #include "itkConnectedComponentImageFilter.h"
00021 #include "itkImage.h"
00022 
00023 namespace itk
00024 {
00025 
00053 template <class TInputImage, class TOutputImage, class TFunctor, class TMaskImage=TInputImage>
00054 class ITK_EXPORT ConnectedComponentFunctorImageFilter : 
00055     public ConnectedComponentImageFilter< TInputImage, TOutputImage, TMaskImage > 
00056 {
00057 public:
00061   typedef ConnectedComponentFunctorImageFilter Self;
00062   typedef ConnectedComponentImageFilter< TInputImage, TOutputImage, TMaskImage > Superclass;
00063 
00067   typedef typename Superclass::InputImagePointer InputImagePointer;
00068 
00073   typedef typename TOutputImage::PixelType OutputPixelType;
00074   typedef typename TOutputImage::InternalPixelType OutputInternalPixelType;
00075   typedef typename TInputImage::PixelType InputPixelType;
00076   typedef typename TInputImage::InternalPixelType InputInternalPixelType;
00077   itkStaticConstMacro(ImageDimension, unsigned int,
00078                       TOutputImage::ImageDimension);
00079   
00083   typedef TFunctor    FunctorType;
00084   typedef TInputImage  InputImageType;
00085   typedef TMaskImage   MaskImageType;
00086   typedef TOutputImage OutputImageType;
00087   typedef   typename TInputImage::IndexType       IndexType;
00088   typedef   typename TInputImage::SizeType        SizeType;
00089   typedef   typename TOutputImage::RegionType     RegionType;
00090   typedef   std::list<IndexType>                  ListType;
00091 
00092   typedef typename MaskImageType::Pointer MaskImagePointer;
00093 
00097   typedef SmartPointer<Self> Pointer;
00098   typedef SmartPointer<const Self>  ConstPointer;
00099   
00103   itkTypeMacro(ConnectedComponentFunctorImageFilter, ImageToImageFilter);
00104   
00108   itkNewMacro(Self);
00109 
00114   FunctorType& GetFunctor() { return m_Functor; };
00115   const FunctorType& GetFunctor() const { return m_Functor; };
00116 
00123   void SetFunctor(const FunctorType& functor)
00124   {
00125     m_Functor = functor;
00126     this->Modified();
00127   }
00128   
00129 protected:
00130   ConnectedComponentFunctorImageFilter() {}
00131   virtual ~ConnectedComponentFunctorImageFilter() {}
00132   ConnectedComponentFunctorImageFilter(const Self&) {}
00133 
00134   FunctorType m_Functor;
00135 
00139   void GenerateData();
00140 
00141 };
00142   
00143 } // end namespace itk
00144 
00145 #ifndef ITK_MANUAL_INSTANTIATION
00146 #include "itkConnectedComponentFunctorImageFilter.txx"
00147 #endif
00148 
00149 #endif

Generated at Wed May 24 22:58:08 2006 for ITK by doxygen 1.3.5 written by Dimitri van Heesch, © 1997-2000