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

itkScalarImageToListAdaptor.h

Go to the documentation of this file.
00001 /*=========================================================================
00002 
00003   Program:   Insight Segmentation & Registration Toolkit
00004   Module:    $RCSfile: itkScalarImageToListAdaptor.h,v $
00005   Language:  C++
00006   Date:      $Date: 2003/12/09 16:53:08 $
00007   Version:   $Revision: 1.5 $
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 __itkScalarImageToListAdaptor_h
00018 #define __itkScalarImageToListAdaptor_h
00019 
00020 #include <typeinfo>
00021 
00022 #include "itkImage.h"
00023 #include "itkPixelTraits.h"
00024 #include "itkImageToListAdaptor.h"
00025 #include "itkSmartPointer.h"
00026 #include "itkImageRegionIterator.h"
00027 #include "itkFixedArray.h"
00028 #include "itkMacro.h"
00029 
00030 namespace itk{ 
00031 namespace Statistics{
00032 
00062 template < class TImage >
00063 class ITK_EXPORT ScalarImageToListAdaptor 
00064   : public ImageToListAdaptor< 
00065   TImage, 
00066   FixedArray< typename TImage::PixelType, 1 > >
00067 {
00068 public:
00069   typedef FixedArray< typename TImage::PixelType, 1 > MeasurementVectorType ;
00070 
00072   typedef ScalarImageToListAdaptor Self;
00073   typedef ImageToListAdaptor< TImage, MeasurementVectorType > Superclass;
00074   typedef SmartPointer< Self > Pointer;
00075   typedef SmartPointer<const Self> ConstPointer;
00076   
00078   itkTypeMacro(ScalarImageToListAdaptor, ListSampleBase) ;
00079   
00081   itkNewMacro(Self) ;
00082   
00084   itkStaticConstMacro(MeasurementVectorSize, unsigned int, 1);
00085 
00088   typedef typename Superclass::FrequencyType FrequencyType ;
00089   typedef typename Superclass::MeasurementType MeasurementType ;
00090   typedef typename Superclass::InstanceIdentifier InstanceIdentifier ;
00091   typedef MeasurementVectorType ValueType ;
00092 
00093   const MeasurementVectorType & GetMeasurementVector(const InstanceIdentifier &id) const;
00094 
00095 protected:
00096   ScalarImageToListAdaptor() {}
00097   virtual ~ScalarImageToListAdaptor() {}
00098   void PrintSelf(std::ostream& os, Indent indent) const;  
00099 
00100 private:
00101   ScalarImageToListAdaptor(const Self&) ; //purposely not implemented
00102   void operator=(const Self&) ; //purposely not implemented
00103   mutable MeasurementVectorType m_TempVector ;
00104 } ; // end of class ScalarImageToListAdaptor
00105 
00106 } // end of namespace Statistics
00107 } // end of namespace itk
00108 
00109 #ifndef ITK_MANUAL_INSTANTIATION
00110 #include "itkScalarImageToListAdaptor.txx"
00111 #endif
00112 
00113 #endif

Generated at Wed Mar 30 00:09:35 2005 for ITK by doxygen 1.3.9.1 written by Dimitri van Heesch, © 1997-2000