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

itkCollidingFrontsImageFilter.h

Go to the documentation of this file.
00001 /*=========================================================================
00002 
00003   Program:   Insight Segmentation & Registration Toolkit
00004   Module:    $RCSfile: itkCollidingFrontsImageFilter.h,v $
00005   Language:  C++
00006   Date:      $Date: 2005/04/17 15:51:16 $
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 
00018 #ifndef __itkCollidingFrontsImageFilter_h
00019 #define __itkCollidingFrontsImageFilter_h
00020 
00021 #include "itkFastMarchingUpwindGradientImageFilter.h"
00022 #include "itkImageToImageFilter.h"
00023 #include "itkImage.h"
00024 
00025 namespace itk
00026 {
00055 template <typename TInputImage, typename TOutputImage>
00056 class CollidingFrontsImageFilter :
00057     public ImageToImageFilter< TInputImage, TOutputImage >
00058 {
00059 public:
00061   typedef CollidingFrontsImageFilter Self;
00062   typedef ImageToImageFilter< TInputImage, TOutputImage > Superclass;
00063   typedef SmartPointer<Self> Pointer;
00064   typedef SmartPointer<const Self>  ConstPointer;
00065 
00067   itkNewMacro(Self);
00068 
00070   itkTypeMacro(CollidingFrontsImageFilter, ImageToImageFilter);
00071   
00074   typedef typename TOutputImage::PixelType OutputPixelType;
00075   typedef typename TInputImage::PixelType InputPixelType;
00076   typedef typename NumericTraits<InputPixelType>::RealType RealType;
00077 
00080   itkStaticConstMacro(ImageDimension, unsigned int,
00081                       TOutputImage::ImageDimension);
00082   
00084   typedef TInputImage  InputImageType;
00085   typedef TOutputImage OutputImageType;
00086   typedef typename InputImageType::Pointer InputImagePointer;
00087   typedef typename OutputImageType::Pointer OutputImagePointer;
00088   
00090   typedef typename Superclass::OutputImageRegionType OutputImageRegionType;
00091 
00093   typedef itk::FastMarchingUpwindGradientImageFilter<TInputImage,TOutputImage> FastMarchingUpwindGradientImageFilterType;
00094 
00096   typedef typename FastMarchingUpwindGradientImageFilterType::PixelType  PixelType;
00097   typedef typename FastMarchingUpwindGradientImageFilterType::NodeType NodeType;
00098   typedef typename FastMarchingUpwindGradientImageFilterType::NodeContainer NodeContainer;
00099   typedef typename FastMarchingUpwindGradientImageFilterType::NodeContainerPointer NodeContainerPointer;
00100   typedef typename FastMarchingUpwindGradientImageFilterType::GradientImageType GradientImageType;
00101   typedef typename FastMarchingUpwindGradientImageFilterType::IndexType  IndexType;
00102 
00105   void SetSeedPoints1( NodeContainer * points )
00106     {
00107     m_SeedPoints1 = points;
00108     this->Modified();
00109     };
00110   
00112   NodeContainerPointer GetSeedPoints1( )
00113     { return m_SeedPoints1; };
00114 
00117   void SetSeedPoints2( NodeContainer * points )
00118     {
00119     m_SeedPoints2 = points;
00120     this->Modified();
00121     };
00122   
00124   NodeContainerPointer GetSeedPoints2( )
00125     { return m_SeedPoints2; };
00126   
00127   itkSetMacro(NegativeEpsilon, double);
00128   itkGetMacro(NegativeEpsilon, double);
00129 
00130   itkSetMacro(ApplyConnectivity, bool);
00131   itkGetMacro(ApplyConnectivity, bool);
00132   itkBooleanMacro(ApplyConnectivity);
00133 
00134 protected:
00135   CollidingFrontsImageFilter();
00136   virtual ~CollidingFrontsImageFilter() {}
00137 
00138   void GenerateData();
00139 
00140   void PrintSelf(std::ostream&, Indent) const;
00141   
00142 private:
00143   CollidingFrontsImageFilter(const Self&); //purposely not implemented
00144   void operator=(const Self&); //purposely not implemented
00145 
00146   NodeContainerPointer m_SeedPoints1;
00147   NodeContainerPointer m_SeedPoints2;
00148 
00149   bool m_ApplyConnectivity;
00150 
00151   double m_NegativeEpsilon;
00152 };
00153   
00154 } // end namespace itk
00155 
00156 #ifndef ITK_MANUAL_INSTANTIATION
00157 #include "itkCollidingFrontsImageFilter.txx"
00158 #endif
00159 
00160 #endif

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