12#ifndef SOSM_SPECTRALTABLE2D_HPP
13#define SOSM_SPECTRALTABLE2D_HPP
22#include "TblLookup.hpp"
37 const std::vector<float>&
DV()
const {
return mDV; }
40 std::vector<float>&
DV() {
return mDV; }
43 const TblIndVarU<float>&
IV1()
const {
return mIV1; }
49 const TblIndVarU<float>&
IV2()
const {
return mIV2; }
65 const TblLookupL<float>& aIV1_Lookup,
66 const TblLookupL<float>& aIV2_Lookup)
const;
73 void PolarLookup(TblLookupLU<float>& aAzLookup, TblLookupLU<float>& aElLookup,
float aAzimuth,
float aElevation)
const
76 float tempAzimuth = aAzimuth;
77 if ((aAzimuth < 0.0F) && (
mIV1.Get(0) >= 0.0F))
79 tempAzimuth = -aAzimuth;
81 aAzLookup.Lookup(
mIV1, tempAzimuth);
82 aElLookup.Lookup(
mIV2, aElevation);
85 void Load(
const std::string& aFileName,
const std::string& aCachePrefix);
A singleton class that manages SOSM data.
Definition SOSM_Manager.hpp:32
Definition SOSM_Selector.hpp:24
SOSM_SpectralObject()
Definition SOSM_SpectralObject.hpp:49
TblIndVarU< float > & IV2()
Return the independent variable 2 values (non-const form).
Definition SOSM_SpectralTable2D.hpp:52
const TblIndVarU< float > & IV1() const
Return the independent variable 1 values (const form).
Definition SOSM_SpectralTable2D.hpp:43
void SetDV_Info(const SOSM_TableVar &aDV_Info)
Set the name, limits and scale for the dependent variable.
Definition SOSM_SpectralTable2D.hpp:55
std::string mFileName
The name of the file from which the table was loaded.
Definition SOSM_SpectralTable2D.hpp:101
SOSM_Manager * GetManager() const
Definition SOSM_SpectralTable2D.hpp:93
std::vector< float > mDV
Definition SOSM_SpectralTable2D.hpp:111
TblIndVarU< float > mIV2
Definition SOSM_SpectralTable2D.hpp:119
TblIndVarU< float > mIV1
Definition SOSM_SpectralTable2D.hpp:115
SOSM_TableVar mIV2_Info
Independent variable 2.
Definition SOSM_SpectralTable2D.hpp:118
double mModificationTime
The modification date of the above file.
Definition SOSM_SpectralTable2D.hpp:104
void Load(const std::string &aFileName, const std::string &aCachePrefix)
Definition SOSM_SpectralTable2D.cpp:69
SOSM_SpectralTable2D(SOSM_Manager *aManagerPtr)
Definition SOSM_SpectralTable2D.cpp:25
void SaveBinaryFile(const std::string &aFileName)
Definition SOSM_SpectralTable2D.cpp:275
void SetIV2_Info(const SOSM_TableVar &aIV2_Info)
Set the name, limits and scale for independent variable 2.
Definition SOSM_SpectralTable2D.hpp:61
void Interpolate(std::vector< float > &aOutput, const SOSM_Selector &aSelector, const TblLookupL< float > &aIV1_Lookup, const TblLookupL< float > &aIV2_Lookup) const
Definition SOSM_SpectralTable2D.cpp:32
const TblIndVarU< float > & IV2() const
Return the independent variable 2 values (const form).
Definition SOSM_SpectralTable2D.hpp:49
std::vector< float > & DV()
Return the dependent variable (non-const form).
Definition SOSM_SpectralTable2D.hpp:40
const std::vector< float > & DV() const
Return the dependent variable (const form).
Definition SOSM_SpectralTable2D.hpp:37
SOSM_Manager * mManagerPtr
Definition SOSM_SpectralTable2D.hpp:98
SOSM_TableVar mDV_Info
Dependent variable ([iv1][iv2][sample].
Definition SOSM_SpectralTable2D.hpp:110
TblIndVarU< float > & IV1()
Return the independent variable 1 values (non-const form).
Definition SOSM_SpectralTable2D.hpp:46
SOSM_TableVar mIV1_Info
Independent variable 1.
Definition SOSM_SpectralTable2D.hpp:114
void LoadBinaryFile(const std::string &aFileName)
Definition SOSM_SpectralTable2D.cpp:250
void PolarLookup(TblLookupLU< float > &aAzLookup, TblLookupLU< float > &aElLookup, float aAzimuth, float aElevation) const
Definition SOSM_SpectralTable2D.hpp:73
void ValidateAndScale_IV(TblIndVarU< float > &aIV, const SOSM_TableVar &aIV_Info)
Definition SOSM_SpectralTable2D.cpp:296
void SetIV1_Info(const SOSM_TableVar &aIV1_Info)
Set the name, limits and scale for independent variable 1.
Definition SOSM_SpectralTable2D.hpp:58
void LoadTextFile(const std::string &aFileName)
Definition SOSM_SpectralTable2D.cpp:106
std::string mUserIdent[3]
The first three lines from the file.
Definition SOSM_SpectralTable2D.hpp:107
double GetModificationTime() const
Return when the source file from which the object was recreated was last modified.
Definition SOSM_SpectralTable2D.hpp:34
A helper class for specifying data to the table loaders.
Definition SOSM_TableVar.hpp:17