RTK  2.7.0
Reconstruction Toolkit
rtkFDKVarianceReconstructionFilter.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  * https://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 rtkFDKVarianceReconstructionFilter_h
20 #define rtkFDKVarianceReconstructionFilter_h
21 
25 #include "rtkConfiguration.h"
26 
27 #include <itkExtractImageFilter.h>
28 
29 namespace rtk
30 {
31 
54 template <class TInputImage, class TOutputImage = TInputImage, class TFFTPrecision = double>
55 class ITK_TEMPLATE_EXPORT FDKVarianceReconstructionFilter : public itk::InPlaceImageFilter<TInputImage, TOutputImage>
56 {
57 public:
58  ITK_DISALLOW_COPY_AND_MOVE(FDKVarianceReconstructionFilter);
59 
65 
67  using InputImageType = TInputImage;
68  using OutputImageType = TOutputImage;
69 
76 
78  itkNewMacro(Self);
79 
81  itkOverrideGetNameOfClassMacro(FDKVarianceReconstructionFilter);
82 
84  itkGetModifiableObjectMacro(Geometry, ThreeDCircularProjectionGeometry);
85  itkSetObjectMacro(Geometry, ThreeDCircularProjectionGeometry);
87 
91  {
92  return m_VarianceRampFilter;
93  }
94 
97  itkGetMacro(ProjectionSubsetSize, unsigned int);
98  itkSetMacro(ProjectionSubsetSize, unsigned int);
100 
104  itkGetMacro(BackProjectionFilter, BackProjectionFilterPointer);
105  virtual void
106  SetBackProjectionFilter(const BackProjectionFilterPointer _arg);
108 
109 protected:
111  ~FDKVarianceReconstructionFilter() override = default;
112 
114  void
115  VerifyPreconditions() const override;
116 
117  void
118  GenerateInputRequestedRegion() override;
119 
120  void
121  GenerateOutputInformation() override;
122 
123  void
124  GenerateData() override;
125 
128  void
129  VerifyInputInformation() const override
130  {}
131 
138 
139 private:
141  unsigned int m_ProjectionSubsetSize{ 16 };
142 
145 }; // end of class
146 
147 } // end namespace rtk
148 
149 #ifndef ITK_MANUAL_INSTANTIATION
150 # include "rtkFDKVarianceReconstructionFilter.hxx"
151 #endif
152 
153 #endif
VarianceRampFilterType::Pointer GetVarianceRampFilter()
Weighting of projections to correct for the divergence in filtered backprojection reconstruction algo...
Implements the variance image filter of the filtered backprojection algorithm.
Implements reconstruction of the variance map of images reconstructed with FDK.
ThreeDCircularProjectionGeometry::Pointer m_Geometry
Projection geometry for a source and a 2-D flat panel.
#define itkSetMacro(name, type)
typename BackProjectionFilterType::Pointer BackProjectionFilterPointer
CPU version of the backprojection of the FDK algorithm.