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

itkGaussianImageSource.h

Go to the documentation of this file.
00001 /*=========================================================================
00002 
00003   Program:   Insight Segmentation & Registration Toolkit
00004   Module:    $RCSfile: itkGaussianImageSource.h,v $
00005   Language:  C++
00006   Date:      $Date: 2009-05-12 17:22:43 $
00007   Version:   $Revision: 1.19 $
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 __itkGaussianImageSource_h
00018 #define __itkGaussianImageSource_h
00019 
00020 #include "itkImageSource.h"
00021 #include "itkFixedArray.h"
00022 #include "itkSize.h"
00023 
00024 namespace itk
00025 {
00026 
00042 template <typename TOutputImage>
00043 class ITK_EXPORT GaussianImageSource : public ImageSource<TOutputImage>
00044 {
00045 public:
00047   typedef GaussianImageSource        Self;
00048   typedef ImageSource<TOutputImage>  Superclass;
00049   typedef SmartPointer<Self>         Pointer;
00050   typedef SmartPointer<const Self>   ConstPointer;
00051 
00053   typedef typename TOutputImage::PixelType OutputImagePixelType;
00054 
00056   typedef typename TOutputImage::RegionType OutputImageRegionType;
00057 
00060   typedef typename TOutputImage::SpacingType SpacingType;
00061 
00064   typedef typename TOutputImage::PointType PointType;
00065 
00068   typedef typename TOutputImage::DirectionType DirectionType;
00069 
00071   itkStaticConstMacro(NDimensions, unsigned int, TOutputImage::ImageDimension);
00072 
00074   typedef FixedArray<double, itkGetStaticConstMacro(NDimensions)> ArrayType;
00075 
00077   typedef Size<itkGetStaticConstMacro(NDimensions)> SizeType;
00078 
00080   itkTypeMacro(GaussianImageSource,ImageSource);
00081 
00083   itkNewMacro(Self);
00084 
00086   virtual void SetSize( const unsigned long* values);
00087 
00089   virtual void SetSize( const SizeType values);
00090 
00092   itkGetVectorMacro(Size,const unsigned long,NDimensions);
00093 
00095   itkSetMacro(Spacing, SpacingType);
00096   virtual void SetSpacing( const float* values);
00097   virtual void SetSpacing( const double* values);
00099 
00101   itkGetConstReferenceMacro(Spacing,SpacingType);
00102 
00104   itkSetMacro(Origin, PointType);
00105   virtual void SetOrigin( const float* values);
00106   virtual void SetOrigin( const double* values);
00108 
00110   itkGetConstReferenceMacro(Origin,PointType);
00111 
00113   itkSetMacro(Direction, DirectionType);
00114   itkGetConstReferenceMacro(Direction, DirectionType);
00116 
00118   itkSetMacro(Scale, double);
00119   itkGetConstReferenceMacro(Scale, double);
00120   itkSetMacro(Normalized, bool);
00121   itkGetConstReferenceMacro(Normalized, bool);
00122   itkSetMacro(Sigma, ArrayType);
00123   itkGetConstReferenceMacro(Sigma, ArrayType);
00124   itkSetMacro(Mean, ArrayType);
00125   itkGetConstReferenceMacro(Mean, ArrayType);
00127 
00128 
00129 protected:
00130   GaussianImageSource();
00131   ~GaussianImageSource();
00132   void PrintSelf(std::ostream& os, Indent indent) const;
00133   void GenerateData();
00134   virtual void GenerateOutputInformation();
00135 
00136 private:
00137   GaussianImageSource(const GaussianImageSource&); //purposely not implemented
00138   void operator=(const GaussianImageSource&); //purposely not implemented
00139 
00140   unsigned long  m_Size[NDimensions];    //size of the output image
00141   SpacingType    m_Spacing;   //spacing
00142   PointType      m_Origin;    //origin
00143   DirectionType  m_Direction; // direction
00144 
00148   ArrayType m_Sigma;
00149 
00151   ArrayType m_Mean;
00152 
00154   double m_Scale;
00155 
00157   bool m_Normalized;
00158 };
00159 
00160 } // end namespace itk
00161 
00162 #ifndef ITK_MANUAL_INSTANTIATION
00163 #include "itkGaussianImageSource.txx"
00164 #endif
00165 
00166 #endif
00167 

Generated at Thu May 28 10:01:32 2009 for ITK by doxygen 1.5.5 written by Dimitri van Heesch, © 1997-2000