OTB  10.0.0
Orfeo Toolbox
otbImageToOSMVectorDataGenerator.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 otbImageToOSMVectorDataGenerator_h
22 #define otbImageToOSMVectorDataGenerator_h
23 
25 
26 namespace otb
27 {
28 
43 template <class TImage>
45 {
46 public:
50  typedef itk::SmartPointer<Self> Pointer;
51  typedef itk::SmartPointer<const Self> ConstPointer;
52 
55 
57  itkNewMacro(Self);
58 
59  // Image typedef
60  typedef TImage ImageType;
61  typedef typename ImageType::SizeType SizeType;
62  typedef typename ImageType::IndexType IndexType;
63  typedef typename ImageType::PointType PointType;
64 
65  // VectorData
67 
68  // Struct to store the extent of the image
70  {
71  double minX;
72  double maxX;
73  double minY;
74  double maxY;
75  };
76 
78  using Superclass::SetInput;
79  void SetInput(const ImageType* input);
80 
82  const ImageType* GetInput() const;
83 
84 protected:
85  void GenerateData() override;
86 
87  // Method to compute the extent of the image
88  void EstimateImageExtent();
89 
92  {
93  }
94 
95 private:
97  void operator=(const Self&) = delete;
98 
100 
101 }; // end of class
102 
103 } // end of namespace otb
104 
105 #ifndef OTB_MANUAL_INSTANTIATION
107 #endif
108 
109 #endif
Helper class to compute the extent of the input image and use it to fill the bbox for the OSM request...
ImageToOSMVectorDataGenerator(const Self &)=delete
void operator=(const Self &)=delete
Request OSM Server using the OSM API 0.6 to get the xml file storing the vector elements available.
This class represents a hierarchy of vector data.
Definition: otbVectorData.h:62
The "otb" namespace contains all Orfeo Toolbox (OTB) classes.