-#ifndef __FPA__IMAGE__DIJKSTRA__H__
-#define __FPA__IMAGE__DIJKSTRA__H__
+// =========================================================================
+// @author Leonardo Florez Valencia
+// @email florez-l@javeriana.edu.co
+// =========================================================================
+
+#ifndef __fpa__Image__Dijkstra__h__
+#define __fpa__Image__Dijkstra__h__
-#include <itkImage.h>
-#include <itkImageFunction.h>
-#include <itkImageToImageFilter.h>
-#include <itkIndex.h>
#include <fpa/Base/Dijkstra.h>
#include <fpa/Image/Algorithm.h>
+#include <fpa/Image/DefaultTraits.h>
+#include <fpa/Image/MinimumSpanningTree.h>
namespace fpa
{
namespace Image
{
/**
- * @param I Input image type
*/
- template< class I, class C >
+ template< class _TInputImage, class _TOutputImage, class _TFrontId = unsigned char >
class Dijkstra
- : public Algorithm< I, fpa::Base::Dijkstra< typename I::IndexType, C, typename I::PixelType, itk::Functor::IndexLexicographicCompare< I::ImageDimension >, itk::ImageToImageFilter< I, itk::Image< C, I::ImageDimension > > > >
+ : public fpa::Base::Dijkstra< fpa::Image::Algorithm< fpa::Image::DefaultTraits< _TInputImage, _TOutputImage, _TFrontId > >, fpa::Image::MinimumSpanningTree< _TInputImage::ImageDimension > >
{
public:
- // Standard class typdedefs
- typedef typename I::IndexType TVertex;
- typedef typename I::PixelType TVertexValue;
- typedef itk::Image< C, I::ImageDimension > TCostImage;
- typedef itk::ImageToImageFilter< I, TCostImage > TBaseFilter;
- typedef fpa::Base::Dijkstra< TVertex, C, TVertexValue, itk::Functor::IndexLexicographicCompare< I::ImageDimension >, TBaseFilter > TBaseAlgorithm;
-
- typedef Dijkstra Self;
- typedef Algorithm< I, TBaseAlgorithm > Superclass;
- typedef itk::SmartPointer< Self > Pointer;
- typedef itk::SmartPointer< const Self > ConstPointer;
+ typedef _TInputImage TInputImage;
+ typedef _TOutputImage TOutputImage;
+ typedef _TFrontId TFrontId;
+ typedef fpa::Image::MinimumSpanningTree< _TInputImage::ImageDimension > TMST;
+
+ typedef fpa::Image::DefaultTraits< TInputImage, TOutputImage, TFrontId > TTraits;
+ typedef fpa::Image::Algorithm< TTraits > TAlgorithm;
+ typedef fpa::Base::Dijkstra< TAlgorithm, TMST > Superclass;
+ typedef Dijkstra Self;
+ typedef itk::SmartPointer< Self > Pointer;
+ typedef itk::SmartPointer< const Self > ConstPointer;
public:
itkNewMacro( Self );
- itkTypeMacro( Dijkstra, fpaBaseDijkstra );
+ itkTypeMacro( fpa::Image::Dijkstra, fpa::Base::Dijkstra );
protected:
- Dijkstra( )
- : Superclass( )
- { }
- virtual ~Dijkstra( )
- { }
+ Dijkstra( ) : Superclass( ) { }
+ virtual ~Dijkstra( ) { }
private:
- // Purposely not implemented
- Dijkstra( const Self& );
- void operator=( const Self& );
+ // Purposely not implemented.
+ Dijkstra( const Self& other );
+ Self& operator=( const Self& other );
};
} // ecapseman
} // ecapseman
-#endif // __FPA__IMAGE__DIJKSTRA__H__
+#endif // __fpa__Image__Dijkstra__h__
// eof - $RCSfile$