RTK  2.4.1
Reconstruction Toolkit
rtkZengBackProjectionImageFilter.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 rtkZengBackProjectionImageFilter_h
20 #define rtkZengBackProjectionImageFilter_h
21 
22 #include "rtkConfiguration.h"
24 #include "rtkMacro.h"
25 #include <itkPixelTraits.h>
26 
27 #include <itkMultiplyImageFilter.h>
28 #include <itkAddImageFilter.h>
30 #include <itkPasteImageFilter.h>
31 #include <itkResampleImageFilter.h>
32 #include <itkVector.h>
35 #include <itkExtractImageFilter.h>
39 
40 #include "rtkConstantImageSource.h"
41 
42 #include <itkVectorImage.h>
43 namespace rtk
44 {
45 
63 template <class TInputImage, class TOutputImage>
64 class ITK_TEMPLATE_EXPORT ZengBackProjectionImageFilter : public BackProjectionImageFilter<TInputImage, TOutputImage>
65 {
66 public:
69  using InputPixelType = typename TInputImage::PixelType;
70  using OutputPixelType = typename TOutputImage::PixelType;
71  using OutputImageRegionType = typename TOutputImage::RegionType;
75 
80  using AddImageFilterType = itk::AddImageFilter<InputCPUImageType, InputCPUImageType>;
81  using AddImageFilterPointerType = typename AddImageFilterType::Pointer;
102 
104  static constexpr unsigned int InputImageDimension = TInputImage::ImageDimension;
105 
108 
110  itkNewMacro(Self);
111 
114 
116  itkGetMacro(SigmaZero, double);
117  itkSetMacro(SigmaZero, double);
119 
121  itkGetMacro(Alpha, double);
122  itkSetMacro(Alpha, double);
124 
125 
126 protected:
128  ~ZengBackProjectionImageFilter() override = default;
129 
131  void
132  GenerateInputRequestedRegion() override;
133 
134  void
135  GenerateOutputInformation() override;
136 
137  void
138  GenerateData() override;
139 
142  void
143  VerifyInputInformation() const override;
144 
161 
162 private:
163  ZengBackProjectionImageFilter(const Self &) = delete; // purposely not implemented
164  void
165  operator=(const Self &) = delete; // purposely not implemented
166 
167  double m_SigmaZero{ 1.5417233052142099 };
168  double m_Alpha{ 0.016241189545787734 };
169  VectorType m_VectorOrthogonalDetector{ 0. };
170  PointType m_centerVolume{ 0 };
171 };
172 
173 } // end namespace rtk
174 
175 #ifndef ITK_MANUAL_INSTANTIATION
176 # include "rtkZengBackProjectionImageFilter.hxx"
177 #endif
178 
179 #endif
typename ExtractImageFilterType::Pointer ExtractImageFilterPointerType
ConstantVolumeSourcePointerType m_ConstantVolumeSource
typename OuputCPUImageType::PointType PointType
typename PasteImageFilterType::Pointer PasteImageFilterPointerType
Generate an n-dimensional image with constant pixel values.
itk::AddImageFilter< InputCPUImageType, InputCPUImageType > AddImageFilterType
typename CustomUnaryFilterType::Pointer CustomUnaryFilterPointerType
typename TInputImage::PixelType InputPixelType
typename TOutputImage::PixelType OutputPixelType
#define itkSetMacro(name, type)
typename ConstantVolumeSourceType::Pointer ConstantVolumeSourcePointerType
typename RegionOfInterestFilterType::Pointer RegionOfInterestPointerType
DiscreteGaussianFilterPointeurType m_DiscreteGaussianFilter
typename OutputImageType::RegionType OutputImageRegionType
ChangeInformationPointerType m_AttenuationMapChangeInformation
typename ResampleImageFilterType::Pointer ResampleImageFilterPointerType
MultpiplyImageFilterPointerType m_MultiplyImageFilter
RegionOfInterestPointerType m_AttenuationMapRegionOfInterest
typename MultiplyImageFilterType::Pointer MultpiplyImageFilterPointerType
typename DiscreteGaussianFilterType::Pointer DiscreteGaussianFilterPointeurType
ResampleImageFilterPointerType m_ResampleImageFilter
typename ChangeInformationFilterType::Pointer ChangeInformationPointerType
ResampleImageFilterPointerType m_AttenuationMapResampleImageFilter
typename TransformType::Pointer TransformPointerType
typename AddImageFilterType::Pointer AddImageFilterPointerType
MultpiplyImageFilterPointerType m_AttenuationMapMultiplyImageFilter