]> Creatis software - clitk.git/blob - itk/clitkInvertVFFilter.h
removed headers
[clitk.git] / itk / clitkInvertVFFilter.h
1 #ifndef __clitkInvertVFFilter_h
2 #define __clitkInvertVFFilter_h
3 #include "clitkImageCommon.h"
4
5 #include "itkImageToImageFilter.h"
6 #include "itkImage.h"
7 #include "itkImageRegionIterator.h"
8 #include "itkImageRegionIteratorWithIndex.h"
9 #include "itkNumericTraits.h"
10
11 namespace clitk
12 {
13   
14   template <class InputImageType, class OutputImageType>  
15   class ITK_EXPORT InvertVFFilter : public itk::ImageToImageFilter<InputImageType, OutputImageType>
16   
17   {
18   public:
19     typedef InvertVFFilter     Self;
20     typedef itk::ImageToImageFilter<InputImageType, OutputImageType>     Superclass;
21     typedef itk::SmartPointer<Self>            Pointer;
22     typedef itk::SmartPointer<const Self>      ConstPointer;
23    
24     /** Method for creation through the object factory. */
25     itkNewMacro(Self);  
26
27     /** Run-time type information (and related methods) */
28     itkTypeMacro( InvertVFFilter, ImageToImageFilter );
29   
30     /** Determine the image dimension. */
31     itkStaticConstMacro(ImageDimension, unsigned int,
32                         InputImageType::ImageDimension );
33     
34     //Some other typedefs
35     typedef double CoordRepType;
36     typedef itk::Image<double, ImageDimension> WeightsImageType;
37     typedef itk::Image<itk::SimpleFastMutexLock, ImageDimension> MutexImageType;
38
39     /** Point type */
40     typedef itk::Point<CoordRepType,itkGetStaticConstMacro(ImageDimension)> PointType;
41
42     /** Inherit some types from the superclass. */
43     typedef typename OutputImageType::IndexType        IndexType;
44     typedef typename OutputImageType::SizeType         SizeType;
45     typedef typename OutputImageType::PixelType        PixelType;
46     typedef typename OutputImageType::SpacingType      SpacingType;
47
48     //Set Methods(inline)
49     itkSetMacro( Verbose, bool);
50     itkSetMacro( EdgePaddingValue, PixelType );
51     void SetNumberOfThreads(unsigned int r )
52     {
53       m_NumberOfThreadsIsGiven=true;
54       m_NumberOfThreads=r;
55     }
56     itkSetMacro(ThreadSafe, bool);
57
58   
59   protected:
60     InvertVFFilter();
61     ~InvertVFFilter() {};
62     void GenerateData( );
63    
64     bool m_Verbose;
65     bool m_NumberOfThreadsIsGiven;
66     unsigned int m_NumberOfThreads;
67     PixelType m_EdgePaddingValue;
68     bool m_ThreadSafe;
69   };
70
71
72 } // end namespace clitk
73 #ifndef ITK_MANUAL_INSTANTIATION
74 #include "clitkInvertVFFilter.txx"
75 #endif
76
77 #endif // #define __clitkInvertVFFilter_h