Medical Imaging Interaction Toolkit  2016.11.0
Medical Imaging Interaction Toolkit
itkMergeDiffusionImagesFilter.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 Program: Tensor ToolKit - TTK
19 Module: $URL: svn://scm.gforge.inria.fr/svn/ttk/trunk/Algorithms/itkMergeDiffusionImagesFilter.h $
20 Language: C++
21 Date: $Date: 2010-06-07 13:39:13 +0200 (Mo, 07 Jun 2010) $
22 Version: $Revision: 68 $
23 
24 Copyright (c) INRIA 2010. All rights reserved.
25 See LICENSE.txt for details.
26 
27 This software is distributed WITHOUT ANY WARRANTY; without even
28 the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
29 PURPOSE. See the above copyright notices for more information.
30 
31 =========================================================================*/
32 #ifndef _itk_MergeDiffusionImagesFilter_h_
33 #define _itk_MergeDiffusionImagesFilter_h_
34 
35 #include "itkImageToImageFilter.h"
36 #include <itkDiffusionTensor3D.h>
37 #include <itkVectorImage.h>
38 #include <itkVectorContainer.h>
39 
40 namespace itk
41 {
42 
46 template <class TScalarType>
48  : public ImageSource<itk::VectorImage<TScalarType,3> >
49 {
50 
51 public:
52 
53 
55  typedef ImageSource< itk::VectorImage<TScalarType,3> > Superclass;
58 
60  itkFactorylessNewMacro(Self)
61  itkCloneMacro(Self)
62 
64  itkTypeMacro(MergeDiffusionImagesFilter, ImageSource)
65 
66  typedef itk::VectorImage<TScalarType,3> DwiImageType;
67  typedef typename DwiImageType::PixelType DwiPixelType;
68  typedef typename DwiImageType::RegionType DwiRegionType;
69  typedef typename std::vector< typename DwiImageType::Pointer > DwiImageContainerType;
70 
71  typedef vnl_vector_fixed< double, 3 > GradientType;
72  typedef itk::VectorContainer< unsigned int, GradientType > GradientListType;
73  typedef typename std::vector< GradientListType::Pointer > GradientListContainerType;
74 
75  // input
76  void SetImageVolumes(DwiImageContainerType cont);
77  void SetGradientLists(GradientListContainerType cont);
78  void SetBValues(std::vector< double > bvals);
79 
80  // output
81  GradientListType::Pointer GetOutputGradients();
82  double GetB_Value();
83 
84 protected:
85 
86  MergeDiffusionImagesFilter();
87  ~MergeDiffusionImagesFilter();
88 
89  void GenerateData();
90 
91  DwiImageContainerType m_ImageVolumes;
92  GradientListContainerType m_GradientLists;
93  std::vector< double > m_BValues;
95  GradientListType::Pointer m_OutputGradients;
96  double m_BValue;
97 };
98 
99 
100 } // end of namespace
101 
102 
103 #ifndef ITK_MANUAL_INSTANTIATION
105 #endif
106 
107 
108 #endif
GradientListType::Pointer GetOutputGradients()
gradient list of the merged output image
void SetGradientLists(GradientListContainerType cont)
gradients of all input images
void SetImageVolumes(DwiImageContainerType cont)
input DWI image volume container
void SetBValues(std::vector< double > bvals)
b-values of all input images
STL namespace.
double GetB_Value()
main b-value of the merged output image
itk::VectorImage< TScalarType, 3 > DwiImageType
std::vector< typename DwiImageType::Pointer > DwiImageContainerType
itk::VectorContainer< unsigned int, GradientType > GradientListType
ImageSource< itk::VectorImage< TScalarType, 3 > > Superclass
GradientListType::Pointer m_OutputGradients
container for output gradients
GradientListContainerType m_GradientLists
contains gradients of all input images
int m_NumGradients
number of gradients in the output image
Merges diffusion weighted images, e.g. to generate one multishell volume from several single shell vo...
unsigned short PixelType
DwiImageContainerType m_ImageVolumes
contains input images
std::vector< GradientListType::Pointer > GradientListContainerType
vnl_vector_fixed< double, 3 > GradientType
std::vector< double > m_BValues
contains b-values of all input images