Medical Imaging Interaction Toolkit  2016.11.0
Medical Imaging Interaction Toolkit
itkTensorDerivedMeasurementsFilter.h
Go to the documentation of this file.
1 /*===================================================================
2 
3 The Medical Imaging Interaction Toolkit (MITK)
4 
5 Copyright (c) German Cancer Research Center,
6 Division of Medical and Biological Informatics.
7 All rights reserved.
8 
9 This software is distributed WITHOUT ANY WARRANTY; without
10 even the implied warranty of MERCHANTABILITY or FITNESS FOR
11 A PARTICULAR PURPOSE.
12 
13 See LICENSE.txt or http://www.mitk.org for details.
14 
15 ===================================================================*/
16 
17 /*===================================================================
18 
19 This file is based heavily on a corresponding ITK filter.
20 
21 ===================================================================*/
22 #ifndef __itkTensorDerivedMeasurementsFilter_h_
23 #define __itkTensorDerivedMeasurementsFilter_h_
24 
25 #include "itkDiffusionTensor3D.h"
26 #include "itkImageToImageFilter.h"
27 
28 
29 
30 namespace itk{
34 template <class TPixel>
36  public ImageToImageFilter< itk::Image< itk::DiffusionTensor3D<TPixel>, 3 >,
37  itk::Image< TPixel, 3 > >
38 {
39 
40 public:
41 
42  enum Measure
43  {
44  FA,// Fractional anisotropy
45  RA,// Relative anisotropy
46  AD,// Axial diffusivity
47  RD,// Radial diffusivity
48  CA, // Clustering anisotropy 1-(λ2+λ3)/(2*λ1)
49  L2,
50  L3,
51  MD // mean diffusivity
52  };
53 
54  typedef itk::DiffusionTensor3D<TPixel> TensorType;
55  typedef itk::Image< TensorType, 3 > TensorImageType;
56  typedef itk::Image< TPixel, 3 > OutputImageType;
57 
61  typedef ImageToImageFilter< TensorType,
62  OutputImageType >
64 
66  itkFactorylessNewMacro(Self)
67  itkCloneMacro(Self)
68 
70  itkTypeMacro(TensorDerivedMeasurementsFilter, ImageToImageFilter);
71 
72  itkSetMacro(Measure, Measure);
73 
74 
75 protected:
76  TensorDerivedMeasurementsFilter();
77  ~TensorDerivedMeasurementsFilter() {};
78  //void PrintSelf(std::ostream& os, Indent indent) const;
79 
81 
82  void GenerateData();
83 
84 }; // end class
85 
86 } // end namespace
87 
88 #ifndef ITK_MANUAL_INSTANTIATION
90 #endif
91 
92 #endif //__itkTensorDerivedMeasurements_h_
93 
ImageToImageFilter< TensorType, OutputImageType > SuperClass