OTB  10.0.0
Orfeo Toolbox
otbDrawPathListFilter.h
Go to the documentation of this file.
1 /*
2  * Copyright (C) 2005-2024 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 otbDrawPathListFilter_h
22 #define otbDrawPathListFilter_h
23 
24 #include "itkImageToImageFilter.h"
25 #include "otbObjectList.h"
26 
27 namespace otb
28 {
49 template <class TInputImage, class TInputPath, class TOutputImage>
50 class ITK_EXPORT DrawPathListFilter : public itk::ImageToImageFilter<TInputImage, TOutputImage>
51 {
52 public:
55  typedef itk::ImageToImageFilter<TInputImage, TOutputImage> Superclass;
56  typedef itk::SmartPointer<Self> Pointer;
57  typedef itk::SmartPointer<const Self> ConstPointer;
58 
60  itkNewMacro(Self);
61 
63  itkTypeMacro(DrawPathListFilter, ImageToImageFilter);
64 
66  typedef TInputImage InputImageType;
67  typedef typename InputImageType::Pointer InputImagePointerType;
68  typedef typename InputImageType::ConstPointer InputImageConstPointerType;
69  typedef typename InputImageType::RegionType InputImageRegionType;
70  typedef typename InputImageType::PixelType InputImagePixelType;
71  typedef typename InputImageType::SizeType InputImageSizeType;
72  typedef typename InputImageType::ValueType InputImageValueType;
73 
74  typedef TInputPath InputPathType;
75  typedef typename InputPathType::Pointer InputPathPointerType;
79 
80  typedef TOutputImage OutputImageType;
81  typedef typename OutputImageType::Pointer OutputImagePointerType;
82  typedef typename OutputImageType::ConstPointer OutputImageConstPointerType;
83  typedef typename OutputImageType::RegionType OutputImageRegionType;
84  typedef typename OutputImageType::PixelType OutputImagePixelType;
85  typedef typename OutputImageType::SizeType OutputImageSizeType;
86  typedef typename OutputImageType::ValueType OutputImageValueType;
87  typedef typename OutputImageType::IndexType OutputImageIndexType;
88 
89  typedef itk::ProcessObject ProcessObjectType;
90 
91  itkGetMacro(UseInternalPathValue, bool);
92  itkSetMacro(UseInternalPathValue, bool);
93  itkBooleanMacro(UseInternalPathValue);
94 
95  itkGetMacro(AddValue, bool);
96  itkSetMacro(AddValue, bool);
97  itkBooleanMacro(AddValue);
98 
99  itkSetMacro(PathValue, OutputImagePixelType);
100  itkGetMacro(PathValue, OutputImagePixelType);
101 
103  itkStaticConstMacro(InputImageDimension, unsigned int, TInputImage::ImageDimension);
104 
106  virtual void SetInputPath(InputPathListType* path);
107  const InputPathListType* GetInputPath(void);
109 
110 protected:
113 
116  {
117  }
118 
120  void PrintSelf(std::ostream& os, itk::Indent indent) const override;
121 
123  void GenerateData() override;
124 
125 private:
126  DrawPathListFilter(const Self&) = delete;
127  void operator=(const Self&) = delete;
128 
131 
134 
136 };
137 
138 } // end namespace otb
139 
140 #ifndef OTB_MANUAL_INSTANTIATION
141 #include "otbDrawPathListFilter.hxx"
142 #endif
143 
144 #endif
This class can be used to draw a list of path on an image.
OutputImageType::RegionType OutputImageRegionType
OutputImageType::PixelType OutputImagePixelType
InputImageType::ConstPointer InputImageConstPointerType
OutputImageType::SizeType OutputImageSizeType
InputImageType::RegionType InputImageRegionType
OutputImageType::ConstPointer OutputImageConstPointerType
InputImageType::Pointer InputImagePointerType
itk::ImageToImageFilter< TInputImage, TOutputImage > Superclass
InputImageType::ValueType InputImageValueType
DrawPathListFilter(const Self &)=delete
InputImageType::SizeType InputImageSizeType
OutputImageType::Pointer OutputImagePointerType
OutputImagePixelType m_PathValue
OutputImageType::IndexType OutputImageIndexType
InputPathListType::ConstPointer InputPathListConstPointerType
OutputImageType::ValueType OutputImageValueType
InputPathType::Pointer InputPathPointerType
InputPathListType::Pointer InputPathListPointerType
void operator=(const Self &)=delete
itk::SmartPointer< const Self > ConstPointer
otb::ObjectList< InputPathType > InputPathListType
itk::SmartPointer< Self > Pointer
itk::ProcessObject ProcessObjectType
InputImageType::PixelType InputImagePixelType
This class is a generic all-purpose wrapping around an std::vector<itk::SmartPointer<ObjectType> >.
Definition: otbObjectList.h:41
itk::SmartPointer< const Self > ConstPointer
Definition: otbObjectList.h:47
itk::SmartPointer< Self > Pointer
Definition: otbObjectList.h:46
The "otb" namespace contains all Orfeo Toolbox (OTB) classes.