RTK  1.4.0
Reconstruction Toolkit
rtkSplatWithKnownWeightsImageFilter.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 #ifndef rtkSplatWithKnownWeightsImageFilter_h
19 #define rtkSplatWithKnownWeightsImageFilter_h
20 
21 #include <itkInPlaceImageFilter.h>
22 #include <itkArray2D.h>
23 
25 
26 #include "rtkMacro.h"
27 
28 namespace rtk
29 {
66 template< typename VolumeSeriesType, typename VolumeType>
67 class SplatWithKnownWeightsImageFilter : public itk::InPlaceImageFilter< VolumeSeriesType, VolumeSeriesType >
68 {
69 public:
74  typedef typename VolumeSeriesType::RegionType OutputImageRegionType;
75 
77  itkNewMacro(Self)
78 
79 
81 
83  void SetInputVolumeSeries(const VolumeSeriesType* VolumeSeries);
84 
86  void SetInputVolume(const VolumeType* Volume);
87 
89  itkGetMacro(Weights, itk::Array2D<float>)
90  itkSetMacro(Weights, itk::Array2D<float>)
91 
92  itkGetMacro(ProjectionNumber, int)
93  void SetProjectionNumber(int n);
94 
95 protected:
96  SplatWithKnownWeightsImageFilter();
97  virtual ~SplatWithKnownWeightsImageFilter() ITK_OVERRIDE {}
98 
99  typename VolumeSeriesType::ConstPointer GetInputVolumeSeries();
100  typename VolumeType::Pointer GetInputVolume();
101 
103  void ThreadedGenerateData(const typename VolumeSeriesType::RegionType& outputRegionForThread, itk::ThreadIdType itkNotUsed(threadId)) ITK_OVERRIDE;
104 
106  const itk::ImageRegionSplitterBase* GetImageRegionSplitter(void) const ITK_OVERRIDE;
108 
111 
112 
113 private:
114  SplatWithKnownWeightsImageFilter(const Self &); //purposely not implemented
115  void operator=(const Self &); //purposely not implemented
116 };
117 } //namespace ITK
118 
119 
120 #ifndef ITK_MANUAL_INSTANTIATION
121 #include "rtkSplatWithKnownWeightsImageFilter.hxx"
122 #endif
123 
124 #endif
void SetInputVolumeSeries(const VolumeSeriesType *VolumeSeries)
Splats (linearly) a 3D volume into a 3D+t sequence of volumes.
void ThreadedGenerateData(const typename VolumeSeriesType::RegionType &outputRegionForThread, itk::ThreadIdType) override
itk::ImageToImageFilter< VolumeSeriesType, VolumeSeriesType > Superclass
VolumeSeriesType::ConstPointer GetInputVolumeSeries()
unsigned int ThreadIdType
itk::ImageRegionSplitterDirection::Pointer m_Splitter
VolumeType::Pointer GetInputVolume()
const itk::ImageRegionSplitterBase * GetImageRegionSplitter(void) const override
#define itkSetMacro(name, type)
void SetInputVolume(const VolumeType *Volume)