RTK  1.4.0
Reconstruction Toolkit
rtkMotionCompensatedFourDConjugateGradientConeBeamReconstructionFilter.h
Go to the documentation of this file.
1 /*=========================================================================
2  *
3  * Copyright RTK Consortium
4  *
5  * Licensed under the Apache License, Version 2.0 (the "License");
6  * you may not use this file except in compliance with the License.
7  * You may obtain a copy of the License at
8  *
9  * http://www.apache.org/licenses/LICENSE-2.0.txt
10  *
11  * Unless required by applicable law or agreed to in writing, software
12  * distributed under the License is distributed on an "AS IS" BASIS,
13  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14  * See the License for the specific language governing permissions and
15  * limitations under the License.
16  *
17  *=========================================================================*/
18 
19 #ifndef rtkMotionCompensatedFourDConjugateGradientConeBeamReconstructionFilter_h
20 #define rtkMotionCompensatedFourDConjugateGradientConeBeamReconstructionFilter_h
21 
25 #ifdef RTK_USE_CUDA
28 #endif
29 
30 namespace rtk
31 {
69 template< typename VolumeSeriesType, typename ProjectionStackType>
71  public rtk::FourDConjugateGradientConeBeamReconstructionFilter<VolumeSeriesType, ProjectionStackType>
72 {
73 public:
79 
81  typedef VolumeSeriesType InputImageType;
82  typedef VolumeSeriesType OutputImageType;
83  typedef ProjectionStackType VolumeType;
84  typedef itk::CovariantVector< typename VolumeSeriesType::ValueType, VolumeSeriesType::ImageDimension - 1> VectorForDVF;
85 
88 
89 #ifdef RTK_USE_CUDA
90  typedef itk::CudaImage<VectorForDVF, VolumeSeriesType::ImageDimension> DVFSequenceImageType;
91  typedef itk::CudaImage<VectorForDVF, VolumeSeriesType::ImageDimension - 1> DVFImageType;
92 #else
94  typedef itk::Image<VectorForDVF, VolumeSeriesType::ImageDimension - 1> DVFImageType;
95 #endif
96 
100  itkNewMacro(Self)
101 
102 
104 
106  void SetForwardProjectionFilter (ForwardProjectionType itkNotUsed(_arg)) ITK_OVERRIDE {itkExceptionMacro(<< "ForwardProjection cannot be changed");}
107  void SetBackProjectionFilter (BackProjectionType itkNotUsed(_arg)) ITK_OVERRIDE {itkExceptionMacro(<< "BackProjection cannot be changed");}
109 
111  void SetDisplacementField(const DVFSequenceImageType* DVFs);
112  void SetInverseDisplacementField(const DVFSequenceImageType* DVFs);
113  typename DVFSequenceImageType::ConstPointer GetDisplacementField();
114  typename DVFSequenceImageType::ConstPointer GetInverseDisplacementField();
116 
118  void SetSignal(const std::vector<double> signal) ITK_OVERRIDE;
119 
120  // Sub filters typedefs
123 
125  itkSetMacro(UseCudaCyclicDeformation, bool)
126  itkGetMacro(UseCudaCyclicDeformation, bool)
127 
128 protected:
130  virtual ~MotionCompensatedFourDConjugateGradientConeBeamReconstructionFilter() ITK_OVERRIDE {}
131 
132  void GenerateOutputInformation() ITK_OVERRIDE;
133  void GenerateInputRequestedRegion() ITK_OVERRIDE;
134 
136 
137 private:
138  //purposely not implemented
140  void operator=(const Self&);
141 }; // end of class
142 
143 } // end namespace rtk
144 
145 #ifndef ITK_MANUAL_INSTANTIATION
146 #include "rtkMotionCompensatedFourDConjugateGradientConeBeamReconstructionFilter.hxx"
147 #endif
148 
149 #endif
rtk::WarpProjectionStackToFourDImageFilter< VolumeSeriesType, ProjectionStackType > MCProjStackToFourDType
rtk::MotionCompensatedFourDReconstructionConjugateGradientOperator< VolumeSeriesType, ProjectionStackType > MCCGOperatorType
itk::CovariantVector< typename VolumeSeriesType::ValueType, VolumeSeriesType::ImageDimension-1 > VectorForDVF
Back projection part for motion compensated iterative 4D reconstruction.
Implements part of the 4D reconstruction by conjugate gradient.
FourDConjugateGradientConeBeamReconstructionFilter< VolumeSeriesType, ProjectionStackType > Superclass
#define itkSetMacro(name, type)