OTB  10.0.0
Orfeo Toolbox
otbTerraSarXSarImageMetadataInterface.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 
22 #ifndef otbTerraSarXSarImageMetadataInterface_h
23 #define otbTerraSarXSarImageMetadataInterface_h
24 
25 #include <string>
26 
28 #include "otbXMLMetadataSupplier.h"
29 #include "itkImageBase.h"
30 
31 namespace otb
32 {
41 {
42 public:
45  typedef itk::SmartPointer<Self> Pointer;
46  typedef itk::SmartPointer<const Self> ConstPointer;
47 
49  itkNewMacro(Self);
50 
52  itkTypeMacro(TerraSarXSarImageMetadataInterface, otbSarImageMetadataInterface);
53 
54  typedef itk::ImageBase<2> ImageType;
55  typedef ImageType::IndexType IndexType;
56  typedef std::array<int, 2> ArrayIndexType;
57  typedef std::vector<IndexType> IndexVectorType;
58  typedef itk::MetaDataDictionary MetaDataDictionaryType;
61  typedef std::vector<double> DoubleVectorType;
62  typedef std::vector<DoubleVectorType> DoubleVectorVectorType;
63  typedef std::vector<unsigned int> UIntVectorType;
64 
65  typedef Superclass::PointSetType PointSetType;
66  typedef Superclass::PointSetPointer PointSetPointer;
67  typedef double RealType;
68 
70  unsigned int GetNumberOfNoiseRecords(const MetadataSupplierInterface&, const unsigned int) const;
71 
74 
76  double GetCenterIncidenceAngle(const MetadataSupplierInterface& mds) const override;
77 
80 
83 
86 
87  PointSetPointer GetRadiometricCalibrationNoise(const MetadataSupplierInterface&, const ImageMetadata&, const std::string& b="") const override;
89 
92 
94  InfoSceneCoord GetSceneCoord(const MetadataSupplierInterface &supplier, const std::string& path);
95 
96  void ParseGdal(ImageMetadata &) override;
97 
98  void ParseGeom(ImageMetadata &) override;
99 
100  void Parse(ImageMetadata &) override;
101 
102 protected:
105 
106  void PrintSelf(std::ostream& os, itk::Indent indent) const override;
107 
109  inline double Horner(std::vector<double>& coefficients, const double tauMinusTauRef) const;
110 
112  double ConvertStringTimeUTCToJulianDay(const std::string& value) const;
113 
115  unsigned int GetNoisePolynomialDegrees(const unsigned int noiseRecord, const MetadataSupplierInterface &mds, const unsigned int polLayer) const;
116 
118  DoubleVectorType GetNoisePolynomialCoefficients(const unsigned int noiseRecord, const MetadataSupplierInterface& mds, const unsigned int polLayer) const;
119 
121  double GetNoiseTimeUTC(const unsigned int noiseRecord, const MetadataSupplierInterface& mds, const unsigned int polLayer) const;
122 
124  double GetNoiseReferencePoint(const unsigned int noiseRecord, const MetadataSupplierInterface &mds, const unsigned int polLayer) const;
125 
126 private:
128  void operator=(const Self&) = delete;
129 };
130 
131 } // end namespace otb
132 
133 #endif
Base class for captor metadata reading.
Generic class containing image metadata used in OTB.
Base class to access metadata information in files/images.
Class for SAR captor metadata reading.
Creation of an "otb" TerraSarXSarImageMetadataInterface that gets metadata.
unsigned int GetNumberOfCornerIncidenceAngles(const MetadataSupplierInterface &) const
ArrayIndexType GetRadiometricCalibrationNoisePolynomialDegree() const override
double GetNoiseTimeUTC(const unsigned int noiseRecord, const MetadataSupplierInterface &mds, const unsigned int polLayer) const
PointSetPointer GetRadiometricCalibrationNoise(const MetadataSupplierInterface &, const ImageMetadata &, const std::string &b="") const override
MetaDataKey::VariableLengthVectorType VariableLengthVectorType
void ParseGeom(ImageMetadata &) override
ArrayIndexType GetRadiometricCalibrationIncidenceAnglePolynomialDegree() const override
double ConvertStringTimeUTCToJulianDay(const std::string &value) const
TerraSarXSarImageMetadataInterface(const Self &)=delete
PointSetPointer GetRadiometricCalibrationIncidenceAngle(const MetadataSupplierInterface &) const override
~TerraSarXSarImageMetadataInterface() override=default
unsigned int GetNoisePolynomialDegrees(const unsigned int noiseRecord, const MetadataSupplierInterface &mds, const unsigned int polLayer) const
DoubleVectorType GetNoisePolynomialCoefficients(const unsigned int noiseRecord, const MetadataSupplierInterface &mds, const unsigned int polLayer) const
void PrintSelf(std::ostream &os, itk::Indent indent) const override
unsigned int GetNumberOfNoiseRecords(const MetadataSupplierInterface &, const unsigned int) const
IndexVectorType GetCornersIncidenceAnglesIndex(const MetadataSupplierInterface &) const
double GetCenterIncidenceAngle(const MetadataSupplierInterface &mds) const override
double GetNoiseReferencePoint(const unsigned int noiseRecord, const MetadataSupplierInterface &mds, const unsigned int polLayer) const
IndexType GetCenterIncidenceAngleIndex(const MetadataSupplierInterface &mds) const
void Parse(ImageMetadata &) override
double Horner(std::vector< double > &coefficients, const double tauMinusTauRef) const
void operator=(const Self &)=delete
void ParseGdal(ImageMetadata &) override
InfoSceneCoord GetSceneCoord(const MetadataSupplierInterface &supplier, const std::string &path)
DoubleVectorType GetCornersIncidenceAngles(const MetadataSupplierInterface &mds) const
std::vector< double > VectorType
itk::VariableLengthVector< double > VariableLengthVectorType
The "otb" namespace contains all Orfeo Toolbox (OTB) classes.
Represents an InfoSceneCoord.