OTB  9.0.0
Orfeo Toolbox
otbAngularProjectionBinaryImageFilter.h
Go to the documentation of this file.
1 /*
2  * Copyright (C) 2005-2022 Centre National d'Etudes Spatiales (CNES)
3  *
4  * This file is part of Orfeo Toolbox
5  *
6  * https://www.orfeo-toolbox.org/
7  *
8  * Licensed under the Apache License, Version 2.0 (the "License");
9  * you may not use this file except in compliance with the License.
10  * You may obtain a copy of the License at
11  *
12  * http://www.apache.org/licenses/LICENSE-2.0
13  *
14  * Unless required by applicable law or agreed to in writing, software
15  * distributed under the License is distributed on an "AS IS" BASIS,
16  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
17  * See the License for the specific language governing permissions and
18  * limitations under the License.
19  */
20 
21 #ifndef otbAngularProjectionBinaryImageFilter_h
22 #define otbAngularProjectionBinaryImageFilter_h
23 
24 #include <vector>
25 
26 #include "itkImageToImageFilter.h"
27 
28 
29 namespace otb
30 {
40 template <class TInputImage, class TOutputImage, class TPrecision>
41 class ITK_EXPORT AngularProjectionBinaryImageFilter : public itk::ImageToImageFilter<TInputImage, TOutputImage>
42 {
43 public:
46  typedef itk::ImageToImageFilter<TInputImage, TOutputImage> Superclass;
47  typedef itk::SmartPointer<Self> Pointer;
48  typedef itk::SmartPointer<const Self> ConstPointer;
49 
51  itkNewMacro(Self);
52 
54  itkTypeMacro(AngularProjectionBinaryImageFilter, ImageToImageFilter);
55 
57  typedef TInputImage InputImageType;
58  typedef typename InputImageType::Pointer InputImagePointerType;
59  typedef typename InputImageType::RegionType InputImageRegionType;
60  typedef typename InputImageType::SizeType InputSizeType;
61  typedef typename InputImageType::IndexType InputIndexType;
62  typedef typename InputImageType::PixelType InputPixelType;
63 
64  typedef TOutputImage OutputImageType;
65  typedef typename OutputImageType::Pointer OutputImagePointerType;
66  typedef typename OutputImageType::RegionType OutputImageRegionType;
67  typedef typename OutputImageType::SizeType OutputSizeType;
68  typedef typename OutputImageType::IndexType OutputIndexType;
69  typedef typename OutputImageType::PixelType OutputPixelType;
70 
71  typedef TPrecision PrecisionType;
72 
74  itkStaticConstMacro(InputImageDimension, unsigned int, TInputImage::ImageDimension);
75  itkStaticConstMacro(OutputImageDimension, unsigned int, TOutputImage::ImageDimension);
77 
79  std::vector<PrecisionType> GetAngleSet() const
80  {
81  return m_AngleSet;
82  }
83  void SetAngleSet(std::vector<PrecisionType>& angle);
85 
86  void SetInput1(const InputImageType*);
87  const InputImageType* GetInput1() const;
88 
89  void SetInput2(const InputImageType*);
90  const InputImageType* GetInput2() const;
91 
92 protected:
95  {
96  }
97 
98  void GenerateOutputInformation() override;
99  void ThreadedGenerateData(const OutputImageRegionType& outputRegionForThread, itk::ThreadIdType threadID) override;
100 
101 private:
102  AngularProjectionBinaryImageFilter(const Self&); // not implemented
103  void operator=(const Self&); // not implemented
104 
105  std::vector<PrecisionType> m_AngleSet;
106 
107 }; // end of class
108 
109 } // end of namespace otb
110 
111 #ifndef OTB_MANUAL_INSTANTIATION
113 #endif
114 
115 
116 #endif
otb::AngularProjectionBinaryImageFilter::~AngularProjectionBinaryImageFilter
~AngularProjectionBinaryImageFilter() override
Definition: otbAngularProjectionBinaryImageFilter.h:94
otb::AngularProjectionBinaryImageFilter::m_AngleSet
std::vector< PrecisionType > m_AngleSet
Definition: otbAngularProjectionBinaryImageFilter.h:105
otb::AngularProjectionBinaryImageFilter::InputImageRegionType
InputImageType::RegionType InputImageRegionType
Definition: otbAngularProjectionBinaryImageFilter.h:59
otb::AngularProjectionBinaryImageFilter::PrecisionType
TPrecision PrecisionType
Definition: otbAngularProjectionBinaryImageFilter.h:71
otb::AngularProjectionBinaryImageFilter::Self
AngularProjectionBinaryImageFilter Self
Definition: otbAngularProjectionBinaryImageFilter.h:45
otb::AngularProjectionBinaryImageFilter::ConstPointer
itk::SmartPointer< const Self > ConstPointer
Definition: otbAngularProjectionBinaryImageFilter.h:48
otb::AngularProjectionBinaryImageFilter::InputImageType
TInputImage InputImageType
Definition: otbAngularProjectionBinaryImageFilter.h:54
otb
The "otb" namespace contains all Orfeo Toolbox (OTB) classes.
Definition: otbJoinContainer.h:32
otb::AngularProjectionBinaryImageFilter::OutputImageType
TOutputImage OutputImageType
Definition: otbAngularProjectionBinaryImageFilter.h:64
otbAngularProjectionBinaryImageFilter.hxx
otb::AngularProjectionBinaryImageFilter::OutputIndexType
OutputImageType::IndexType OutputIndexType
Definition: otbAngularProjectionBinaryImageFilter.h:68
otb::AngularProjectionBinaryImageFilter::InputPixelType
InputImageType::PixelType InputPixelType
Definition: otbAngularProjectionBinaryImageFilter.h:62
otb::AngularProjectionBinaryImageFilter::InputImagePointerType
InputImageType::Pointer InputImagePointerType
Definition: otbAngularProjectionBinaryImageFilter.h:58
otb::AngularProjectionBinaryImageFilter::OutputPixelType
OutputImageType::PixelType OutputPixelType
Definition: otbAngularProjectionBinaryImageFilter.h:69
otb::AngularProjectionBinaryImageFilter::Superclass
itk::ImageToImageFilter< TInputImage, TOutputImage > Superclass
Definition: otbAngularProjectionBinaryImageFilter.h:46
otb::AngularProjectionBinaryImageFilter
Performs .
Definition: otbAngularProjectionBinaryImageFilter.h:41
otb::AngularProjectionBinaryImageFilter::GetAngleSet
std::vector< PrecisionType > GetAngleSet() const
Definition: otbAngularProjectionBinaryImageFilter.h:79
otb::AngularProjectionBinaryImageFilter::OutputImageRegionType
OutputImageType::RegionType OutputImageRegionType
Definition: otbAngularProjectionBinaryImageFilter.h:66
otb::AngularProjectionBinaryImageFilter::Pointer
itk::SmartPointer< Self > Pointer
Definition: otbAngularProjectionBinaryImageFilter.h:47
otb::AngularProjectionBinaryImageFilter::OutputImagePointerType
OutputImageType::Pointer OutputImagePointerType
Definition: otbAngularProjectionBinaryImageFilter.h:65
otb::AngularProjectionBinaryImageFilter::InputSizeType
InputImageType::SizeType InputSizeType
Definition: otbAngularProjectionBinaryImageFilter.h:60
otb::AngularProjectionBinaryImageFilter::OutputSizeType
OutputImageType::SizeType OutputSizeType
Definition: otbAngularProjectionBinaryImageFilter.h:67
otb::AngularProjectionBinaryImageFilter::InputIndexType
InputImageType::IndexType InputIndexType
Definition: otbAngularProjectionBinaryImageFilter.h:61