OTB  10.0.0
Orfeo Toolbox
otbAtmosphericRadiativeTerms.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 otbAtmosphericRadiativeTerms_h
22 #define otbAtmosphericRadiativeTerms_h
23 
24 #include "OTBOpticalCalibrationExport.h"
25 #include "itkDataObject.h"
26 #include "itkObjectFactory.h"
27 #include "itkMacro.h"
28 #include <vector>
29 
30 namespace otb
31 {
32 
44 class OTBOpticalCalibration_EXPORT AtmosphericRadiativeTermsSingleChannel : public itk::DataObject
45 {
46 public:
49  typedef itk::DataObject Superclass;
50  typedef itk::SmartPointer<Self> Pointer;
51  typedef itk::SmartPointer<const Self> ConstPointer;
52 
54  itkTypeMacro(AtmosphericRadiativeTermsSingleChannel, DataObject);
55 
57  itkNewMacro(Self);
58 
62  itkSetMacro(IntrinsicAtmosphericReflectance, double);
63  itkGetMacro(IntrinsicAtmosphericReflectance, double);
65 
69  itkSetMacro(SphericalAlbedo, double);
70  itkGetMacro(SphericalAlbedo, double);
71 
75  itkSetMacro(TotalGaseousTransmission, double);
76  itkGetMacro(TotalGaseousTransmission, double);
78 
82  itkSetMacro(DownwardTransmittance, double);
83  itkGetMacro(DownwardTransmittance, double);
85 
89  itkSetMacro(UpwardTransmittance, double);
90  itkGetMacro(UpwardTransmittance, double);
92 
96  itkSetMacro(UpwardDiffuseTransmittance, double);
97  itkGetMacro(UpwardDiffuseTransmittance, double);
99 
103  itkSetMacro(UpwardDirectTransmittance, double);
104  itkGetMacro(UpwardDirectTransmittance, double);
106 
110  itkSetMacro(UpwardDiffuseTransmittanceForRayleigh, double);
111  itkGetMacro(UpwardDiffuseTransmittanceForRayleigh, double);
113 
117  itkSetMacro(UpwardDiffuseTransmittanceForAerosol, double);
118  itkGetMacro(UpwardDiffuseTransmittanceForAerosol, double);
120 
124  itkSetMacro(WavelengthSpectralBand, double);
125  itkGetMacro(WavelengthSpectralBand, double);
127 
128 protected:
131 
134  {
135  }
136 
138  void PrintSelf(std::ostream& os, itk::Indent indent) const override;
139 
140 private:
142  void operator=(const Self&) = delete;
143 
146 
149 
152 
155 
158 
161 
164 
167 
170 
173 };
174 
185 class OTBOpticalCalibration_EXPORT AtmosphericRadiativeTerms : public itk::DataObject
186 {
187 public:
190  typedef itk::DataObject Superclass;
191  typedef itk::SmartPointer<Self> Pointer;
192  typedef itk::SmartPointer<const Self> ConstPointer;
193 
195  itkTypeMacro(AtmosphericRadiativeTerms, DataObject);
196 
198  itkNewMacro(Self);
199 
201  typedef std::vector<ValueType> VectorValueType;
202  typedef std::vector<double> DataVectorType;
203  typedef DataVectorType::size_type DataVectorSizeType;
207  void SetValues(const VectorValueType& val)
208  {
209  m_Values = val;
210  this->Modified();
211  }
213  {
214  return m_Values;
215  }
216  const VectorValueType& GetValues() const
217  {
218  return m_Values;
219  }
221 
231 
237 
239  void SetValueByIndex(unsigned int id, const ValueType& val);
240  void SetIntrinsicAtmosphericReflectance(unsigned int id, const double& val);
241  void SetSphericalAlbedo(unsigned int id, const double& val);
242  void SetTotalGaseousTransmission(unsigned int id, const double& val);
243  void SetDownwardTransmittance(unsigned int id, const double& val);
244  void SetUpwardTransmittance(unsigned int id, const double& val);
246 
247  void SetUpwardDiffuseTransmittance(unsigned int id, const double& val);
248  void SetUpwardDirectTransmittance(unsigned int id, const double& val);
249  void SetUpwardDiffuseTransmittanceForRayleigh(unsigned int id, const double& val);
250  void SetUpwardDiffuseTransmittanceForAerosol(unsigned int id, const double& val);
251  void SetWavelengthSpectralBand(unsigned int id, const double& val);
252 
260 
266 
268  double GetIntrinsicAtmosphericReflectance(unsigned int id) const;
269  double GetSphericalAlbedo(unsigned int id) const;
270  double GetTotalGaseousTransmission(unsigned int id) const;
271  double GetDownwardTransmittance(unsigned int id) const;
272  double GetUpwardTransmittance(unsigned int id) const;
273  double GetUpwardDiffuseTransmittance(unsigned int id) const;
274  double GetUpwardDirectTransmittance(unsigned int id) const;
275  double GetUpwardDiffuseTransmittanceForRayleigh(unsigned int id) const;
276  double GetUpwardDiffuseTransmittanceForAerosol(unsigned int id) const;
277  double GetWavelengthSpectralBand(unsigned int id) const;
279 
280  const ValueType GetValueByIndex(unsigned int id) const;
281 
284 
285 protected:
288 
291  {
292  }
293 
295  void PrintSelf(std::ostream& os, itk::Indent indent) const override;
296 
297 private:
298  AtmosphericRadiativeTerms(const Self&) = delete;
299  void operator=(const Self&) = delete;
300 
303 
306 };
307 
308 } // end namespace otb
309 
310 #endif
This class contains all atmospheric radiative terms for one channel.
AtmosphericRadiativeTermsSingleChannel Self
void PrintSelf(std::ostream &os, itk::Indent indent) const override
AtmosphericRadiativeTermsSingleChannel(const Self &)=delete
This class is a vector of AtmosphericRadiativeTermsSingleChannel, it contains all atmospheric radiati...
double GetUpwardTransmittance(unsigned int id) const
void SetUpwardDiffuseTransmittanceForAerosol(unsigned int id, const double &val)
double GetUpwardDiffuseTransmittanceForRayleigh(unsigned int id) const
void SetUpwardDiffuseTransmittancesForRayleigh(const DataVectorType &vect)
void SetWavelengthSpectralBand(const DataVectorType &vect)
double GetDownwardTransmittance(unsigned int id) const
void SetValues(const VectorValueType &val)
void SetDownwardTransmittances(const DataVectorType &vect)
DataVectorType GetWavelengthSpectralBand() const
void SetUpwardTransmittances(const DataVectorType &vect)
DataVectorType GetUpwardTransmittances() const
void SetUpwardDirectTransmittance(unsigned int id, const double &val)
void SetSphericalAlbedo(unsigned int id, const double &val)
DataVectorType GetSphericalAlbedos() const
DataVectorType::size_type DataVectorSizeType
DataVectorType GetDownwardTransmittances() const
void SetValueByIndex(unsigned int id, const ValueType &val)
void SetIntrinsicAtmosphericReflectances(const DataVectorType &vect)
double GetTotalGaseousTransmission(unsigned int id) const
double GetSphericalAlbedo(unsigned int id) const
void SetIntrinsicAtmosphericReflectance(unsigned int id, const double &val)
DataVectorType GetUpwardDiffuseTransmittancesForRayleigh() const
const ValueType GetValueByIndex(unsigned int id) const
double GetUpwardDiffuseTransmittanceForAerosol(unsigned int id) const
double GetUpwardDirectTransmittance(unsigned int id) const
void SetSphericalAlbedos(const DataVectorType &vect)
void SetDownwardTransmittance(unsigned int id, const double &val)
void SetWavelengthSpectralBand(unsigned int id, const double &val)
void ValuesInitialization(DataVectorSizeType nbChannel)
void PrintSelf(std::ostream &os, itk::Indent indent) const override
void SetUpwardTransmittance(unsigned int id, const double &val)
itk::SmartPointer< const Self > ConstPointer
double GetUpwardDiffuseTransmittance(unsigned int id) const
const VectorValueType & GetValues() const
AtmosphericRadiativeTermsSingleChannel::Pointer ValueType
DataVectorType GetUpwardDirectTransmittances() const
void SetUpwardDirectTransmittances(const DataVectorType &vect)
AtmosphericRadiativeTerms(const Self &)=delete
void SetUpwardDiffuseTransmittance(unsigned int id, const double &val)
void SetUpwardDiffuseTransmittanceForRayleigh(unsigned int id, const double &val)
void SetUpwardDiffuseTransmittancesForAerosol(const DataVectorType &vect)
void SetUpwardDiffuseTransmittances(const DataVectorType &vect)
DataVectorType GetUpwardDiffuseTransmittancesForAerosol() const
void SetTotalGaseousTransmission(unsigned int id, const double &val)
void operator=(const Self &)=delete
DataVectorType GetUpwardDiffuseTransmittances() const
DataVectorType GetIntrinsicAtmosphericReflectances() const
double GetWavelengthSpectralBand(unsigned int id) const
double GetIntrinsicAtmosphericReflectance(unsigned int id) const
DataVectorType GetTotalGaseousTransmissions() const
void SetTotalGaseousTransmissions(const DataVectorType &vect)
The "otb" namespace contains all Orfeo Toolbox (OTB) classes.