OTB  9.0.0
Orfeo Toolbox
otbTwoNRIBandsImageToNComplexBandsImage.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 otbTwoNRIBandsImageToNComplexBandsImage_h
22 #define otbTwoNRIBandsImageToNComplexBandsImage_h
23 
24 #include "itkImageToImageFilter.h"
25 #include "itkImage.h"
26 #include "itkNumericTraits.h"
27 
28 /*
29  * Inputs : one single image made of 2N real bands
30  * Output : one single image made of N complex bands
31  *
32  * */
33 
34 
35 namespace otb
36 {
37 
38 
39 template <class TInputImage, class TOutputImage>
40 class ITK_EXPORT TwoNRIBandsImageToNComplexBandsImage : public itk::ImageToImageFilter<TInputImage, TOutputImage>
41 {
42 public:
44  itkStaticConstMacro(InputImageDimension, unsigned int, TInputImage::ImageDimension);
45  itkStaticConstMacro(OutputImageDimension, unsigned int, TOutputImage::ImageDimension);
47 
48  typedef TInputImage InputImageType;
49  typedef TOutputImage OutputImageType;
50 
53  typedef itk::ImageToImageFilter<InputImageType, OutputImageType> Superclass;
54  typedef itk::SmartPointer<Self> Pointer;
55  typedef itk::SmartPointer<const Self> ConstPointer;
56 
58  itkNewMacro(Self);
59 
61  itkTypeMacro(TwoNRIBandsImageToNComplexBandsImage, ImageToImageFilter);
62 
63  typedef typename InputImageType::PixelType InputPixelType;
64  typedef typename OutputImageType::PixelType OutputPixelType;
65  typedef typename itk::NumericTraits<InputPixelType>::RealType InputRealType;
66  typedef typename InputImageType::RegionType InputImageRegionType;
67  typedef typename OutputImageType::RegionType OutputImageRegionType;
68 
69 
70 protected:
73  {
74  }
75  void PrintSelf(std::ostream& os, itk::Indent indent) const override;
76 
77  void GenerateOutputInformation(void) override;
78  void BeforeThreadedGenerateData(void) override;
79  void ThreadedGenerateData(const OutputImageRegionType& outputRegionForThread, itk::ThreadIdType threadId) override;
80 
81 private:
82  TwoNRIBandsImageToNComplexBandsImage(const Self&) = delete;
83  void operator=(const Self&) = delete;
84 };
85 } // end namespace otb
86 
87 #ifndef OTB_MANUAL_INSTANTIATION
89 #endif
90 
91 #endif
otb::TwoNRIBandsImageToNComplexBandsImage::InputImageType
TInputImage InputImageType
Definition: otbTwoNRIBandsImageToNComplexBandsImage.h:48
otbTwoNRIBandsImageToNComplexBandsImage.hxx
otb::TwoNRIBandsImageToNComplexBandsImage::InputPixelType
InputImageType::PixelType InputPixelType
Definition: otbTwoNRIBandsImageToNComplexBandsImage.h:61
otb
The "otb" namespace contains all Orfeo Toolbox (OTB) classes.
Definition: otbJoinContainer.h:32
otb::TwoNRIBandsImageToNComplexBandsImage::InputImageRegionType
InputImageType::RegionType InputImageRegionType
Definition: otbTwoNRIBandsImageToNComplexBandsImage.h:66
otb::TwoNRIBandsImageToNComplexBandsImage::OutputImageType
TOutputImage OutputImageType
Definition: otbTwoNRIBandsImageToNComplexBandsImage.h:49
otb::TwoNRIBandsImageToNComplexBandsImage::Pointer
itk::SmartPointer< Self > Pointer
Definition: otbTwoNRIBandsImageToNComplexBandsImage.h:54
otb::TwoNRIBandsImageToNComplexBandsImage::OutputImageRegionType
OutputImageType::RegionType OutputImageRegionType
Definition: otbTwoNRIBandsImageToNComplexBandsImage.h:67
otb::TwoNRIBandsImageToNComplexBandsImage::~TwoNRIBandsImageToNComplexBandsImage
~TwoNRIBandsImageToNComplexBandsImage() override
Definition: otbTwoNRIBandsImageToNComplexBandsImage.h:72
otb::TwoNRIBandsImageToNComplexBandsImage::OutputPixelType
OutputImageType::PixelType OutputPixelType
Definition: otbTwoNRIBandsImageToNComplexBandsImage.h:64
otb::TwoNRIBandsImageToNComplexBandsImage::ConstPointer
itk::SmartPointer< const Self > ConstPointer
Definition: otbTwoNRIBandsImageToNComplexBandsImage.h:55
otb::TwoNRIBandsImageToNComplexBandsImage
Definition: otbTwoNRIBandsImageToNComplexBandsImage.h:40
otb::TwoNRIBandsImageToNComplexBandsImage::Self
TwoNRIBandsImageToNComplexBandsImage Self
Definition: otbTwoNRIBandsImageToNComplexBandsImage.h:52
otb::TwoNRIBandsImageToNComplexBandsImage::InputRealType
itk::NumericTraits< InputPixelType >::RealType InputRealType
Definition: otbTwoNRIBandsImageToNComplexBandsImage.h:65
otb::TwoNRIBandsImageToNComplexBandsImage::Superclass
itk::ImageToImageFilter< InputImageType, OutputImageType > Superclass
Definition: otbTwoNRIBandsImageToNComplexBandsImage.h:53