diff --git a/Utilities/otbossim/include/ossim/imaging/EnvisatAsar/AntennaElevationPatterns.h b/Utilities/otbossim/include/ossim/imaging/EnvisatAsar/AntennaElevationPatterns.h deleted file mode 100644 index 29b27b790405ca82c96c8c4301701fdbdcb2a04b..0000000000000000000000000000000000000000 --- a/Utilities/otbossim/include/ossim/imaging/EnvisatAsar/AntennaElevationPatterns.h +++ /dev/null @@ -1,133 +0,0 @@ -#ifndef AntennaElevationPatterns_h -#define AntennaElevationPatterns_h - -#include <iostream> -#include <ossim/imaging/EnvisatAsar/EnvisatAsarRecord.h> -/** - * @ingroup AntennaElevationPatternsRecord - * @brief This class is able to read the ASAR AntennaElevationPatterns record - * @author Magellium, Pacome Dentraygues - * @version 1.0 - * @date 23-11-07 - */ -class AntennaElevationPatterns : public EnvisatAsarRecord -{ -public: - /** - * @brief Constructor - */ - AntennaElevationPatterns(); - - /** - * @brief Destructor - */ - ~AntennaElevationPatterns(); - - /** - * @brief This function writes the AntennaElevationPatterns in a stream - */ - friend std::ostream& operator<<(std::ostream& os, const AntennaElevationPatterns& data); - - /** - * @brief This function reads a AntennaElevationPatterns from a stream - */ - friend std::istream& operator>>(std::istream& is, AntennaElevationPatterns& data); - - /** - * @brief Copy constructor - */ - AntennaElevationPatterns(const AntennaElevationPatterns& rhs); - - /** - * @brief Copy operator - */ - AntennaElevationPatterns& operator=(const AntennaElevationPatterns& rhs); - - /** - * @brief This function is able to create a new instance of the class - */ - EnvisatAsarRecord* Instanciate() - { - return new AntennaElevationPatterns(); - }; - - /** - * @brief This function is able to create a new instance of the class initialised with the data of the calling instance - */ - EnvisatAsarRecord* Clone() - { - return new AntennaElevationPatterns(*this); - }; - - /** - * @brief Reads the class data from a stream - */ - void Read(std::istream& is) - { - is>>*this; - }; - - /** - * @brief Writes the class to a stream - */ - void Write(std::ostream& os) - { - os<<*this; - }; - - - /** - * @brief zero_doppler_time - */ - std::string get_zero_doppler_time() - { - return _zero_doppler_time; - }; - /** - * @brief attach_flag - */ - bool get_attach_flag() - { - return _attach_flag; - }; - /** - * @brief swath - */ - std::string get_swath() - { - return _swath; - }; - /** - * @brief Elevation Pattern - */ - float * get_elevation_pattern() - { - return _elevation_pattern; - }; - - - /** - * @brief zero_doppler_time - */ - std::string _zero_doppler_time; - /** - * @brief attach_flag - */ - bool _attach_flag; - /** - * @brief swath - */ - std::string _swath; - /** - * @brief Elevation Pattern - */ - float _elevation_pattern[33]; - - -private: - -}; - -#endif - - diff --git a/Utilities/otbossim/include/ossim/imaging/EnvisatAsar/ChirpParameters.h b/Utilities/otbossim/include/ossim/imaging/EnvisatAsar/ChirpParameters.h deleted file mode 100644 index 012d4a7bb6402e119de0120acc1a1591260d8e00..0000000000000000000000000000000000000000 --- a/Utilities/otbossim/include/ossim/imaging/EnvisatAsar/ChirpParameters.h +++ /dev/null @@ -1,242 +0,0 @@ -#ifndef ChirpParameters_h -#define ChirpParameters_h - -#include <iostream> -#include <ossim/imaging/EnvisatAsar/EnvisatAsarRecord.h> -/** - * @ingroup ChirpParametersRecord - * @brief This class is able to read the ASAR ChirpParameters record - * @author Magellium, Pacome Dentraygues - * @version 1.0 - * @date 23-11-07 - */ -class ChirpParameters : public EnvisatAsarRecord -{ -public: - /** - * @brief Constructor - */ - ChirpParameters(); - - /** - * @brief Destructor - */ - ~ChirpParameters(); - - /** - * @brief This function writes the ChirpParameters in a stream - */ - friend std::ostream& operator<<(std::ostream& os, const ChirpParameters& data); - - /** - * @brief This function reads a ChirpParameters from a stream - */ - friend std::istream& operator>>(std::istream& is, ChirpParameters& data); - - /** - * @brief Copy constructor - */ - ChirpParameters(const ChirpParameters& rhs); - - /** - * @brief Copy operator - */ - ChirpParameters& operator=(const ChirpParameters& rhs); - - /** - * @brief This function is able to create a new instance of the class - */ - EnvisatAsarRecord* Instanciate() - { - return new ChirpParameters(); - }; - - /** - * @brief This function is able to create a new instance of the class initialised with the data of the calling instance - */ - EnvisatAsarRecord* Clone() - { - return new ChirpParameters(*this); - }; - - /** - * @brief Reads the class data from a stream - */ - void Read(std::istream& is) - { - is>>*this; - }; - - /** - * @brief Writes the class to a stream - */ - void Write(std::ostream& os) - { - os<<*this; - }; - - - /** - * @brief zero_doppler_time - */ - std::string get_zero_doppler_time() - { - return _zero_doppler_time; - }; - /** - * @brief attach_flag - */ - bool get_attach_flag() - { - return _attach_flag; - }; - /** - * @brief swath - */ - std::string get_swath() - { - return _swath; - }; - /** - * @brief polar - */ - std::string get_polar() - { - return _polar; - }; - /** - * @brief chirp_width - */ - float get_chirp_width() - { - return _chirp_width; - }; - /** - * @brief chirp_sidelobe - */ - float get_chirp_sidelobe() - { - return _chirp_sidelobe; - }; - /** - * @brief chirp_islr - */ - float get_chirp_islr() - { - return _chirp_islr; - }; - /** - * @brief chirp_peak_loc - */ - float get_chirp_peak_loc() - { - return _chirp_peak_loc; - }; - /** - * @brief re_chirp_power - */ - float get_re_chirp_power() - { - return _re_chirp_power; - }; - /** - * @brief elev_chirp_power - */ - float get_elev_chirp_power() - { - return _elev_chirp_power; - }; - /** - * @brief chirp_quality_flag - */ - bool get_chirp_quality_flag() - { - return _chirp_quality_flag; - }; - /** - * @brief ref_chirp_power - */ - float get_ref_chirp_power() - { - return _ref_chirp_power; - }; - /** - * @brief normalisation_source - */ - std::string get_normalisation_source() - { - return _normalisation_source; - }; - /** - * @brief cal_pulse_info[352] - */ - float* get_cal_pulse_info() - { - return _cal_pulse_info; - }; - - - /** - * @brief zero_doppler_time - */ - std::string _zero_doppler_time; - /** - * @brief attach_flag - */ - bool _attach_flag; - /** - * @brief swath - */ - std::string _swath; - /** - * @brief polar - */ - std::string _polar; - /** - * @brief chirp_width - */ - float _chirp_width; - /** - * @brief chirp_sidelobe - */ - float _chirp_sidelobe; - /** - * @brief chirp_islr - */ - float _chirp_islr; - /** - * @brief chirp_peak_loc - */ - float _chirp_peak_loc; - /** - * @brief re_chirp_power - */ - float _re_chirp_power; - /** - * @brief elev_chirp_power - */ - float _elev_chirp_power; - /** - * @brief chirp_quality_flag - */ - bool _chirp_quality_flag; - /** - * @brief ref_chirp_power - */ - float _ref_chirp_power; - /** - * @brief normalisation_source - */ - std::string _normalisation_source; - /** - * @brief cal_pulse_info[352] - */ - float _cal_pulse_info[352]; - -private: - -}; - -#endif - - diff --git a/Utilities/otbossim/include/ossim/imaging/EnvisatAsar/DopplerCentroidParameters.h b/Utilities/otbossim/include/ossim/imaging/EnvisatAsar/DopplerCentroidParameters.h deleted file mode 100644 index 118212b184543c226976d9eaa7e45d76245201e0..0000000000000000000000000000000000000000 --- a/Utilities/otbossim/include/ossim/imaging/EnvisatAsar/DopplerCentroidParameters.h +++ /dev/null @@ -1,164 +0,0 @@ -#ifndef DopplerCentroidParameters_h -#define DopplerCentroidParameters_h - -#include <iostream> -#include <ossim/imaging/EnvisatAsar/EnvisatAsarRecord.h> -/** - * @ingroup DopplerCentroidParametersRecord - * @brief This class is able to read the ASAR DopplerCentroidParameters record - * @author Magellium, Pacome Dentraygues - * @version 1.0 - * @date 23-11-07 - */ -class DopplerCentroidParameters : public EnvisatAsarRecord -{ -public: - /** - * @brief Constructor - */ - DopplerCentroidParameters(); - - /** - * @brief Destructor - */ - ~DopplerCentroidParameters(); - - /** - * @brief This function writes the DopplerCentroidParameters in a stream - */ - friend std::ostream& operator<<(std::ostream& os, const DopplerCentroidParameters& data); - - /** - * @brief This function reads a DopplerCentroidParameters from a stream - */ - friend std::istream& operator>>(std::istream& is, DopplerCentroidParameters& data); - - /** - * @brief Copy constructor - */ - DopplerCentroidParameters(const DopplerCentroidParameters& rhs); - - /** - * @brief Copy operator - */ - DopplerCentroidParameters& operator=(const DopplerCentroidParameters& rhs); - - /** - * @brief This function is able to create a new instance of the class - */ - EnvisatAsarRecord* Instanciate() - { - return new DopplerCentroidParameters(); - }; - - /** - * @brief This function is able to create a new instance of the class initialised with the data of the calling instance - */ - EnvisatAsarRecord* Clone() - { - return new DopplerCentroidParameters(*this); - }; - - /** - * @brief Reads the class data from a stream - */ - void Read(std::istream& is) - { - is>>*this; - }; - - /** - * @brief Writes the class to a stream - */ - void Write(std::ostream& os) - { - os<<*this; - }; - - - /** - * @brief zero_doppler_time - */ - std::string get_zero_doppler_time() - { - return _zero_doppler_time; - }; - /** - * @brief attach_flag - */ - bool get_attach_flag() - { - return _attach_flag; - }; - /** - * @brief slant_range_time - */ - float get_slant_range_time() - { - return _slant_range_time; - }; - /** - * @brief dop_coef[5] - */ - float* get_dop_coef() - { - return _dop_coef; - }; - /** - * @brief dop_conf - */ - float get_dop_conf() - { - return _dop_conf; - }; - /** - * @brief dop_conf_below_thresh_flag - */ - bool get_dop_conf_below_thresh_flag() - { - return _dop_conf_below_thresh_flag; - }; - /** - * @brief delta_dopp_coeff[5] - */ - signed short * get_delta_dopp_coeff() - { - return _delta_dopp_coeff; - }; - - /** - * @brief zero_doppler_time - */ - std::string _zero_doppler_time; - /** - * @brief attach_flag - */ - bool _attach_flag; - /** - * @brief slant_range_time - */ - float _slant_range_time; - /** - * @brief dop_coef[5] - */ - float _dop_coef[5]; - /** - * @brief dop_conf - */ - float _dop_conf; - /** - * @brief dop_conf_below_thresh_flag - */ - bool _dop_conf_below_thresh_flag; - /** - * @brief delta_dopp_coeff[5] - */ - signed short _delta_dopp_coeff[5]; - -private: - -}; - -#endif - - diff --git a/Utilities/otbossim/include/ossim/imaging/EnvisatAsar/EnvisatAsarData.h b/Utilities/otbossim/include/ossim/imaging/EnvisatAsar/EnvisatAsarData.h deleted file mode 100644 index 2b3eb527ce5631d77a70bc9fb0a6bd8850d28a3c..0000000000000000000000000000000000000000 --- a/Utilities/otbossim/include/ossim/imaging/EnvisatAsar/EnvisatAsarData.h +++ /dev/null @@ -1,83 +0,0 @@ -#ifndef EnvisatAsarData_h -#define EnvisatAsarData_h - -#include <iostream> -#include "sph.h" -#include "mph.h" -#include "SQ_ADSR.h" -#include "MainProcessingParameters.h" -#include "AntennaElevationPatterns.h" -#include "DopplerCentroidParameters.h" -#include "SRGRConversionParameters.h" -#include "ChirpParameters.h" -#include "GeolocationGrid.h" -#include <map> -#include <list> -#include <vector> - - -/** - * @ingroup EnvisatAsarDataFile - * @brief This class is able to read the Envisat file structure - * @author Magellium, Pacome Dentraygues - * @version 1.0 - * @date 23-11-07 - */ -class EnvisatAsarData -{ -public: - /** - * @brief Constructor - */ - EnvisatAsarData(); - - /** - * @brief Destructor - */ - ~EnvisatAsarData(); - - /** - * @brief This function writes the EnvisatAsarData in a stream - */ - friend std::ostream& operator<<(std::ostream& os, const EnvisatAsarData& data); - - /** - * @brief This function reads a EnvisatAsarData from a stream - */ - friend std::istream& operator>>(std::istream& is, EnvisatAsarData& data); - - /** - * @brief Copy constructor - */ - EnvisatAsarData(const EnvisatAsarData& rhs); - - /** - * @brief Copy operator - */ - EnvisatAsarData& operator=(const EnvisatAsarData& rhs); - - /** - * @brief Removes all the previous records from the EnvisatAsarData - */ - void ClearRecords(); - - mph * get_mph(); - sph * get_sph(); - SQ_ADSR * get_SQ_ADSR(); - MainProcessingParameters * get_MainProcessingParameters(); - AntennaElevationPatterns * get_AntennaElevationPatterns(); - DopplerCentroidParameters * get_DopplerCentroidParameters(); - SRGRConversionParameters * get_SRGRConversionParameters(int pos = 0); - ChirpParameters * get_ChirpParameters(); - GeolocationGrid * get_GeolocationGrid(int num_ds = 0); - - int get_num_ds(EnvisatAsarRecord * record); - -protected: - std::list<EnvisatAsarRecord*> _records; - -private: - -}; - -#endif \ No newline at end of file diff --git a/Utilities/otbossim/include/ossim/imaging/EnvisatAsar/EnvisatAsarDataFactory.h b/Utilities/otbossim/include/ossim/imaging/EnvisatAsar/EnvisatAsarDataFactory.h deleted file mode 100644 index b685cabd66414e04a9e235e01b2ee675a9474c37..0000000000000000000000000000000000000000 --- a/Utilities/otbossim/include/ossim/imaging/EnvisatAsar/EnvisatAsarDataFactory.h +++ /dev/null @@ -1,33 +0,0 @@ -#ifndef EnvisatAsarDataFactory_h -#define EnvisatAsarDataFactory_h - - -#include <ossim/imaging/EnvisatAsar/EnvisatAsarRecordFactory.h> -#include <map> -/** - * @ingroup EnvisatAsarDataFile - * @brief This class is a factory able to construct Record base classes - * @author Magellium, Pacome Dentraygues - * @version 1.0 - * @date 23-11-07 - */ -class EnvisatAsarDataFactory : public EnvisatAsarRecordFactory -{ -public: - /** - * @brief Constructor - */ - EnvisatAsarDataFactory(); - /** - * @brief Destructor - */ - ~EnvisatAsarDataFactory(); - - -protected: - - -private: -}; - -#endif \ No newline at end of file diff --git a/Utilities/otbossim/include/ossim/imaging/EnvisatAsar/EnvisatAsarRecord.h b/Utilities/otbossim/include/ossim/imaging/EnvisatAsar/EnvisatAsarRecord.h deleted file mode 100644 index 8b4cf6b7c093144938cdd5965cbebd454aeb4200..0000000000000000000000000000000000000000 --- a/Utilities/otbossim/include/ossim/imaging/EnvisatAsar/EnvisatAsarRecord.h +++ /dev/null @@ -1,98 +0,0 @@ -#ifndef EnvisatAsarRecord_h -#define EnvisatAsarRecord_h - -#include <iostream> -#include <cstdlib> -#include <cstring> -#include <ossim/base/ossimCommon.h> -/** - * @ingroup EnvisatAsar - * @brief This class is the base class of all the Envisat ASAR record classes - * @author Magellium, Pacome Dentraygues - * @version 1.0 - * @date 23-11-07 - */ - - - - -class EnvisatAsarRecord -{ -public: - /** - * @brief Constructor - * @param mnemonic Name of the record - */ - EnvisatAsarRecord(std::string mnemonic); - /** - * @brief Destructor - */ - ~EnvisatAsarRecord(); - - /** - * @brief Copy constructor - */ - EnvisatAsarRecord(const EnvisatAsarRecord& rhs); - - /** - * @brief This function is able to create a new instance of the class - */ - virtual EnvisatAsarRecord* Instanciate() =0; - - /** - * @brief This function is able to create a new instance of the class initialised with the data of the calling instance - */ - virtual EnvisatAsarRecord* Clone()=0; - - /** - * @brief Reads the class data from a stream - */ - virtual void Read(std::istream& is) =0; - - /** - * @brief Writes the class to a stream - */ - virtual void Write(std::ostream& os)=0; - - /** - * @brief Returns the mnemonic of the record - */ - std::string get_mnemonic() - { - return _mnemonic; - }; - - - -protected: - /** - * @brief This function switches the LSB value and the MSB value of the parameter - */ - template<typename T> - void SwitchEndian(T &value) { - - char *buffer; - char *res; - int nb_octets = sizeof(T); - - if (ossim::byteOrder() == OSSIM_LITTLE_ENDIAN) { - buffer = (char* )malloc(nb_octets); - res = (char* )malloc(nb_octets); - - memcpy(buffer,&value,nb_octets); - - for (int i=0; i<nb_octets/2; i++) { - res[i] = buffer[nb_octets-1-i]; - res[nb_octets-1-i] = buffer[i]; - } - memcpy(&value,res,nb_octets); - } - } - - - std::string _mnemonic; - -private: -}; - -#endif \ No newline at end of file diff --git a/Utilities/otbossim/include/ossim/imaging/EnvisatAsar/EnvisatAsarRecordFactory.h b/Utilities/otbossim/include/ossim/imaging/EnvisatAsar/EnvisatAsarRecordFactory.h deleted file mode 100644 index e3d59de85da2b201d1fc9d1088b2c347507f6161..0000000000000000000000000000000000000000 --- a/Utilities/otbossim/include/ossim/imaging/EnvisatAsar/EnvisatAsarRecordFactory.h +++ /dev/null @@ -1,49 +0,0 @@ -#ifndef EnvisatAsarRecordFactory_h -#define EnvisatAsarRecordFactory_h - -#include <ossim/imaging/EnvisatAsar/EnvisatAsarRecord.h> -#include <map> -#include <string> - -/** - * @ingroup EnvisatAsar - * @brief This class is a factory able to construct Record base classes given the id of the record wanted - * @author Magellium, Pacome Dentraygues - * @version 1.0 - * @date 23-11-07 - */ -class EnvisatAsarRecordFactory -{ -public: - /** - * @brief Constructor - */ - EnvisatAsarRecordFactory(); - /** - * @brief Destructor - */ - ~EnvisatAsarRecordFactory(); - - /** - * @brief Adds a new Record type available in this factory - * @param record Record to add in the factory - * @param id Id of the new avalaible Record - */ - void RegisterRecord(std::string id, EnvisatAsarRecord * record); - - /** - * @brief Instanciatse a new Record - * @param id Id of the Record we want to instanciate - */ - EnvisatAsarRecord* Instanciate(std::string id); - -protected: - /** - * @brief Contains all the available Records for the factory - */ - std::map<std::string, EnvisatAsarRecord*> _availableRecords; - -private: -}; - -#endif \ No newline at end of file diff --git a/Utilities/otbossim/include/ossim/imaging/EnvisatAsar/GeolocationGrid.h b/Utilities/otbossim/include/ossim/imaging/EnvisatAsar/GeolocationGrid.h deleted file mode 100644 index 13f5ea0bf3d14e598842ab6039fdeb29a5e614b5..0000000000000000000000000000000000000000 --- a/Utilities/otbossim/include/ossim/imaging/EnvisatAsar/GeolocationGrid.h +++ /dev/null @@ -1,242 +0,0 @@ -#ifndef GeolocationGrid_h -#define GeolocationGrid_h - -#include <iostream> -#include <ossim/imaging/EnvisatAsar/EnvisatAsarRecord.h> -/** - * @ingroup GeolocationGridRecord - * @brief This class is able to read the ASAR GeolocationGrid record - * @author Magellium, Pacome Dentraygues - * @version 1.0 - * @date 23-11-07 - */ -class GeolocationGrid : public EnvisatAsarRecord -{ -public: - /** - * @brief Constructor - */ - GeolocationGrid(); - - /** - * @brief Destructor - */ - ~GeolocationGrid(); - - /** - * @brief This function writes the GeolocationGrid in a stream - */ - friend std::ostream& operator<<(std::ostream& os, const GeolocationGrid& data); - - /** - * @brief This function reads a GeolocationGrid from a stream - */ - friend std::istream& operator>>(std::istream& is, GeolocationGrid& data); - - /** - * @brief Copy constructor - */ - GeolocationGrid(const GeolocationGrid& rhs); - - /** - * @brief Copy operator - */ - GeolocationGrid& operator=(const GeolocationGrid& rhs); - - /** - * @brief This function is able to create a new instance of the class - */ - EnvisatAsarRecord* Instanciate() - { - return new GeolocationGrid(); - }; - - /** - * @brief This function is able to create a new instance of the class initialised with the data of the calling instance - */ - EnvisatAsarRecord* Clone() - { - return new GeolocationGrid(*this); - }; - - /** - * @brief Reads the class data from a stream - */ - void Read(std::istream& is) - { - is>>*this; - }; - - /** - * @brief Writes the class to a stream - */ - void Write(std::ostream& os) - { - os<<*this; - }; - - /** - * @brief first_zero_doppler_time day - */ - int get_first_zero_doppler_time_day() - { - return _first_zero_doppler_time_day; - }; - /** - * @brief first_zero_doppler_time second - */ - unsigned int get_first_zero_doppler_time_sec() - { - return _first_zero_doppler_time_sec; - }; - /** - * @brief first_zero_doppler_time micro sec - */ - unsigned int get_first_zero_doppler_time_microsec() - { - return _first_zero_doppler_time_microsec; - }; - /** - * @brief attach_flag - */ - bool get_attach_flag() - { - return _attach_flag; - }; - /** - * @brief line_num - */ - unsigned int get_line_num() - { - return _line_num; - }; - /** - * @brief num_lines - */ - unsigned int get_num_lines() - { - return _num_lines; - }; - /** - * @brief sub_sat_track - */ - float get_sub_sat_track() - { - return _sub_sat_track; - }; - /** - * @brief samp_numbvers - */ - unsigned int * get_samp_numbers() - { - return _samp_numbers; - }; - /** - * @brief slant_range_times - */ - float * get_slant_range_times() - { - return _slant_range_times; - }; - /** - * @brief angles - */ - float * get_angles() - { - return _angles; - }; - /** - * @brief lats - */ - int * get_lats() - { - return _lats; - }; - /** - * @brief longs - */ - int * get_longs() - { - return _longs; - }; - /** - * @brief last_zero_doppler_time - */ - std::string get_last_zero_doppler_time() - { - return _last_zero_doppler_time; - }; - /** - * @brief last_line_tie_points - */ - std::string get_last_line_tie_points() - { - return _last_line_tie_points; - }; - - - /** - * @brief first_zero_doppler_time day - */ - int _first_zero_doppler_time_day; - /** - * @brief first_zero_doppler_time sec - */ - unsigned int _first_zero_doppler_time_sec; - /** - * @brief first_zero_doppler_time microsec - */ - unsigned int _first_zero_doppler_time_microsec; - /** - * @brief attach_flag - */ - bool _attach_flag; - /** - * @brief line_num - */ - unsigned int _line_num; - /** - * @brief num_lines - */ - unsigned int _num_lines; - /** - * @brief sub_sat_track - */ - float _sub_sat_track; - /** - * @brief samp_numbers - */ - unsigned int _samp_numbers[11]; - /** - * @brief slant_range_times[11] - */ - float _slant_range_times[11]; - /** - * @brief angles[11] - */ - float _angles[11]; - /** - * @brief lats[11] - */ - int _lats[11]; - /** - * @brief longs[11] - */ - int _longs[11]; - /** - * @brief last_zero_doppler_time - */ - std::string _last_zero_doppler_time; - /** - * @brief last_line_tie_points - */ - std::string _last_line_tie_points; - - -private: - -}; - -#endif - - diff --git a/Utilities/otbossim/include/ossim/imaging/EnvisatAsar/MainProcessingParameters.h b/Utilities/otbossim/include/ossim/imaging/EnvisatAsar/MainProcessingParameters.h deleted file mode 100644 index 94707d3e9b22148b1a422e45e323f4c7180ed3ec..0000000000000000000000000000000000000000 --- a/Utilities/otbossim/include/ossim/imaging/EnvisatAsar/MainProcessingParameters.h +++ /dev/null @@ -1,1372 +0,0 @@ -#ifndef MainProcessingParameters_h -#define MainProcessingParameters_h - -#include <iostream> -#include <sstream> -#include <ossim/imaging/EnvisatAsar/EnvisatAsarRecord.h> -/** - * @ingroup MainProcessingParametersRecord - * @brief This class is able to read the ASAR MainProcessingParameters record - * @author Magellium, Pacome Dentraygues - * @version 1.0 - * @date 23-11-07 - */ -class MainProcessingParameters : public EnvisatAsarRecord -{ -public: - /** - * @brief Constructor - */ - MainProcessingParameters(); - - /** - * @brief Destructor - */ - ~MainProcessingParameters(); - - /** - * @brief This function writes the MainProcessingParameters in a stream - */ - friend std::ostream& operator<<(std::ostream& os, const MainProcessingParameters& data); - - /** - * @brief This function reads a MainProcessingParameters from a stream - */ - friend std::istream& operator>>(std::istream& is, MainProcessingParameters& data); - - /** - * @brief Copy constructor - */ - MainProcessingParameters(const MainProcessingParameters& rhs); - - /** - * @brief Copy operator - */ - MainProcessingParameters& operator=(const MainProcessingParameters& rhs); - - /** - * @brief This function is able to create a new instance of the class - */ - EnvisatAsarRecord* Instanciate() - { - return new MainProcessingParameters(); - }; - - /** - * @brief This function is able to create a new instance of the class initialised with the data of the calling instance - */ - EnvisatAsarRecord* Clone() - { - return new MainProcessingParameters(*this); - }; - - /** - * @brief Reads the class data from a stream - */ - void Read(std::istream& is) - { - is>>*this; - }; - - /** - * @brief Writes the class to a stream - */ - void Write(std::ostream& os) - { - os<<*this; - }; - - - /** - * @brief first_zero_doppler_time - */ - std::string get_first_zero_doppler_time() - { - return _first_zero_doppler_time; - }; - /** - * @brief attach_flag - */ - bool get_attach_flag() - { - return _attach_flag; - }; - /** - * @brief last_zero_doppler_time - */ - std::string get_last_zero_doppler_time() - { - return _last_zero_doppler_time; - }; - /** - * @brief work_order_id - */ - std::string get_work_order_id() - { - return _work_order_id; - }; - /** - * @brief time_diff - */ - float get_time_diff() - { - return _time_diff; - }; - /** - * @brief swath_num - */ - std::string get_swath_num() - { - return _swath_num; - }; - /** - * @brief range_spacing - */ - float get_range_spacing() - { - return _range_spacing; - }; - /** - * @brief azimut_spacing - */ - float get_azimut_spacing() - { - return _azimut_spacing; - }; - /** - * @brief line_time_interval - */ - float get_line_time_interval() - { - return _line_time_interval; - }; - /** - * @brief num_output_lines - */ - unsigned int get_num_output_lines() - { - return _num_output_lines; - }; - /** - * @brief num_samples_per_line - */ - unsigned int get_num_samples_per_line() - { - return _num_samples_per_line; - }; - /** - * @brief data_type - */ - std::string get_data_type() - { - return _data_type; - }; - /** - * @brief num_range_lines_per_burst - */ - unsigned int get_num_range_lines_per_burst() - { - return _num_range_lines_per_burst; - }; - /** - * @brief time_diff_zero_doppler - */ - float get_time_diff_zero_doppler() - { - return _time_diff_zero_doppler; - }; - /** - * @brief data_analysis_flag - */ - bool get_data_analysis_flag() - { - return _data_analysis_flag; - }; - /** - * @brief ant_elev_coor_flag - */ - bool get_ant_elev_coor_flag() - { - return _ant_elev_coor_flag; - }; - /** - * @brief chirp_extract_flag - */ - bool get_chirp_extract_flag() - { - return _chirp_extract_flag; - }; - /** - * @brief srgr_flag - */ - bool get_srgr_flag() - { - return _srgr_flag; - }; - /** - * @brief dop_cen_flag - */ - bool get_dop_cen_flag() - { - return _dop_cen_flag; - }; - /** - * @brief dop_amb_flag - */ - bool get_dop_amb_flag() - { - return _dop_amb_flag; - }; - /** - * @brief range_spread_comp_flag - */ - bool get_range_spread_comp_flag() - { - return _range_spread_comp_flag; - }; - /** - * @brief detected_flag - */ - bool get_detected_flag() - { - return _detected_flag; - }; - /** - * @brief look_sum_flag - */ - bool get_look_sum_flag() - { - return _look_sum_flag; - }; - /** - * @brief rms_equal_flag - */ - bool get_rms_equal_flag() - { - return _rms_equal_flag; - }; - /** - * @brief ant_scal_flag - */ - bool get_ant_scal_flag() - { - return _ant_scal_flag; - }; - /** - * @brief vga_com_echo_flag - */ - bool get_vga_com_echo_flag() - { - return _vga_com_echo_flag; - }; - /** - * @brief vga_com_cal_flag - */ - bool get_vga_com_cal_flag() - { - return _vga_com_cal_flag; - }; - /** - * @brief vga_com_nom_time_flag - */ - bool get_vga_com_nom_time_flag() - { - return _vga_com_nom_time_flag; - }; - /** - * @brief gm_rng_comp_inv_filter_flag - */ - bool get_gm_rng_comp_inv_filter_flag() - { - return _gm_rng_comp_inv_filter_flag; - }; - /** - * @brief raw_data_analysis - */ - std::string get_raw_data_analysis() - { - return _raw_data_analysis; - }; - /** - * @brief start_time_mds1 - */ - std::string get_start_time_mds1() - { - return _start_time_mds1; - }; - /** - * @brief start_time_mds2 - */ - std::string get_start_time_mds2() - { - return _start_time_mds2; - }; - /** - * @brief parameter_code - */ - std::string get_parameter_code() - { - return _parameter_code; - }; - /** - * @brief errors_counters - */ - std::string get_errors_counters() - { - return _errors_counters; - }; - /** - * @brief image_parameters block1 - */ - std::string get_image_parameters1() - { - return _image_parameters1; - }; - /** - * @brief prf_values[5] - */ - float* get_prf_values() - { - return _prf_values; - }; - /** - * @brief prf (i.e prf_values[0]) - */ - float get_prf() - { - return _prf_values[0]; - }; - /** - * @brief image_parameters block2 - */ - std::string get_image_parameters2() - { - return _image_parameters2; - }; - /** - * @brief first_proc_range_samp - */ - unsigned int get_first_proc_range_samp() - { - return _first_proc_range_samp; - }; - /** - * @brief range_ref - */ - float get_range_ref() - { - return _range_ref; - }; - /** - * @brief range_samp_rate - */ - float get_range_samp_rate() - { - return _range_samp_rate; - }; - /** - * @brief radar_freq - */ - float get_radar_freq() - { - return _radar_freq; - }; - /** - * @brief num_looks_range - */ - unsigned short get_num_looks_range() - { - return _num_looks_range; - }; - /** - * @brief filter_range - */ - std::string get_filter_range() - { - return _filter_range; - }; - /** - * @brief filter_coef_range - */ - float get_filter_coef_range() - { - return _filter_coef_range; - }; - /** - * @brief bandwidth - */ - std::string get_bandwidth() - { - return _bandwidth; - }; - /** - * @brief nominal_chirp - */ - std::string get_nominal_chirp() - { - return _nominal_chirp; - }; - /** - * @brief num_lines_proc - */ - unsigned int get_num_lines_proc() - { - return _num_lines_proc; - }; - /** - * @brief num_look_az - */ - unsigned short get_num_look_az() - { - return _num_look_az; - }; - /** - * @brief look_bw_az - */ - float get_look_bw_az() - { - return _look_bw_az; - }; - /** - * @brief to_bw_az - */ - float get_to_bw_az() - { - return _to_bw_az; - }; - /** - * @brief filter_az - */ - std::string get_filter_az() - { - return _filter_az; - }; - /** - * @brief filter_coef_az - */ - float get_filter_coef_az() - { - return _filter_coef_az; - }; - /** - * @brief az_fm_rate[3] - */ - float* get_az_fm_rate() - { - return _az_fm_rate; - }; - /** - * @brief ax_fm_origin - */ - float get_ax_fm_origin() - { - return _ax_fm_origin; - }; - /** - * @brief dop_amb_coef - */ - float get_dop_amb_coef() - { - return _dop_amb_coef; - }; - /** - * @brief calibration_factors - */ - std::string get_calibration_factors() - { - return _calibration_factors; - }; - /** - * @brief noise_estimation - */ - std::string get_noise_estimation() - { - return _noise_estimation; - }; - /** - * @brief output_statistics - */ - std::string get_output_statistics() - { - return _output_statistics; - }; - /** - * @brief avg_scene_height_ellpsoid - */ - float get_avg_scene_height_ellpsoid() - { - return _avg_scene_height_ellpsoid; - }; - /** - * @brief echo_comp - */ - std::string get_echo_comp() - { - return _echo_comp; - }; - /** - * @brief echo_comp_ratio - */ - std::string get_echo_comp_ratio() - { - return _echo_comp_ratio; - }; - /** - * @brief init_cal_comp - */ - std::string get_init_cal_comp() - { - return _init_cal_comp; - }; - /** - * @brief init_cal_ratio - */ - std::string get_init_cal_ratio() - { - return _init_cal_ratio; - }; - /** - * @brief per_cal_comp - */ - std::string get_per_cal_comp() - { - return _per_cal_comp; - }; - /** - * @brief per_cal_ratio - */ - std::string get_per_cal_ratio() - { - return _per_cal_ratio; - }; - /** - * @brief noise_comp - */ - std::string get_noise_comp() - { - return _noise_comp; - }; - /** - * @brief noise_comp_ratio - */ - std::string get_noise_comp_ratio() - { - return _noise_comp_ratio; - }; - /** - * @brief beam_overlap[4] - */ - unsigned int* get_beam_overlap() - { - return _beam_overlap; - }; - /** - * @brief beam_param[4] - */ - float* get_beam_param() - { - return _beam_param; - }; - /** - * @brief lines_per_burst[5] - */ - unsigned int* get_lines_per_burst() - { - return _lines_per_burst; - }; - /** - * @brief time_first_SS1_echo - */ - std::string get_time_first_SS1_echo() - { - return _time_first_SS1_echo; - }; - /** - * @brief state_vector_time_1 day - */ - int get_state_vector_time_1_day() - { - return _state_vector_time_1_day; - }; - /** - * @brief state_vector_time_1 sec - */ - unsigned int get_state_vector_time_1_sec() - { - return _state_vector_time_1_sec; - }; - /** - * @brief state_vector_time_1 microsec - */ - unsigned int get_state_vector_time_1_microsec() - { - return _state_vector_time_1_microsec; - }; - /** - * @brief x_pos_1 - */ - int get_x_pos_1() - { - return _x_pos_1; - }; - /** - * @brief y_pos_1 - */ - int get_y_pos_1() - { - return _y_pos_1; - }; - /** - * @brief z_pos_1 - */ - int get_z_pos_1() - { - return _z_pos_1; - }; - /** - * @brief x_vel_1 - */ - int get_x_vel_1() - { - return _x_vel_1; - }; - /** - * @brief y_vel_1 - */ - int get_y_vel_1() - { - return _y_vel_1; - }; - /** - * @brief z_vel_1 - */ - int get_z_vel_1() - { - return _z_vel_1; - }; - /** - * @brief state_vector_time_2 day - */ - int get_state_vector_time_2_day() - { - return _state_vector_time_2_day; - }; - /** - * @brief state_vector_time_2 sec - */ - unsigned int get_state_vector_time_2_sec() - { - return _state_vector_time_2_sec; - }; - /** - * @brief state_vector_time_1 microsec - */ - unsigned int get_state_vector_time_2_microsec() - { - return _state_vector_time_2_microsec; - }; - /** - * @brief x_pos_2 - */ - int get_x_pos_2() - { - return _x_pos_2; - }; - /** - * @brief y_pos_2 - */ - int get_y_pos_2() - { - return _y_pos_2; - }; - /** - * @brief z_pos_2 - */ - int get_z_pos_2() - { - return _z_pos_2; - }; - /** - * @brief x_vel_2 - */ - int get_x_vel_2() - { - return _x_vel_2; - }; - /** - * @brief y_vel_2 - */ - int get_y_vel_2() - { - return _y_vel_2; - }; - /** - * @brief z_vel_2 - */ - int get_z_vel_2() - { - return _z_vel_2; - }; - /** - * @brief state_vector_time_3 day - */ - int get_state_vector_time_3_day() - { - return _state_vector_time_3_day; - }; - /** - * @brief state_vector_time_3 sec - */ - unsigned int get_state_vector_time_3_sec() - { - return _state_vector_time_3_sec; - }; - /** - * @brief state_vector_time_3 microsec - */ - unsigned int get_state_vector_time_3_microsec() - { - return _state_vector_time_3_microsec; - }; - /** - * @brief x_pos_3 - */ - int get_x_pos_3() - { - return _x_pos_3; - }; - /** - * @brief y_pos_3 - */ - int get_y_pos_3() - { - return _y_pos_3; - }; - /** - * @brief z_pos_3 - */ - int get_z_pos_3() - { - return _z_pos_3; - }; - /** - * @brief x_vel_3 - */ - int get_x_vel_3() - { - return _x_vel_3; - }; - /** - * @brief y_vel_3 - */ - int get_y_vel_3() - { - return _y_vel_3; - }; - /** - * @brief z_vel_3 - */ - int get_z_vel_3() - { - return _z_vel_3; - }; - /** - * @brief state_vector_time_4 day - */ - int get_state_vector_time_4_day() - { - return _state_vector_time_4_day; - }; - /** - * @brief state_vector_time_1 sec - */ - unsigned int get_state_vector_time_4_sec() - { - return _state_vector_time_4_sec; - }; - /** - * @brief state_vector_time_4 microsec - */ - unsigned int get_state_vector_time_4_microsec() - { - return _state_vector_time_4_microsec; - }; - /** - * @brief x_pos_4 - */ - int get_x_pos_4() - { - return _x_pos_4; - }; - /** - * @brief y_pos_4 - */ - int get_y_pos_4() - { - return _y_pos_4; - }; - /** - * @brief z_pos_4 - */ - int get_z_pos_4() - { - return _z_pos_4; - }; - /** - * @brief x_vel_4 - */ - int get_x_vel_4() - { - return _x_vel_4; - }; - /** - * @brief y_vel_4 - */ - int get_y_vel_4() - { - return _y_vel_4; - }; - /** - * @brief z_vel_4 - */ - int get_z_vel_4() - { - return _z_vel_4; - }; - /** - * @brief state_vector_time_5 day - */ - int get_state_vector_time_5_day() - { - return _state_vector_time_5_day; - }; - /** - * @brief state_vector_time_5 sec - */ - unsigned int get_state_vector_time_5_sec() - { - return _state_vector_time_5_sec; - }; - /** - * @brief state_vector_time_5 microsec - */ - unsigned int get_state_vector_time_5_microsec() - { - return _state_vector_time_5_microsec; - }; - /** - * @brief x_pos_5 - */ - int get_x_pos_5() - { - return _x_pos_5; - }; - /** - * @brief y_pos_5 - */ - int get_y_pos_5() - { - return _y_pos_5; - }; - /** - * @brief z_pos_5 - */ - int get_z_pos_5() - { - return _z_pos_5; - }; - /** - * @brief x_vel_5 - */ - int get_x_vel_5() - { - return _x_vel_5; - }; - /** - * @brief y_vel_5 - */ - int get_y_vel_5() - { - return _y_vel_5; - }; - /** - * @brief z_vel_5 - */ - int get_z_vel_5() - { - return _z_vel_5; - }; - - /** - * @brief first_zero_doppler_time - */ - std::string _first_zero_doppler_time; - /** - * @brief attach_flag - */ - bool _attach_flag; - /** - * @brief last_zero_doppler_time - */ - std::string _last_zero_doppler_time; - /** - * @brief work_order_id - */ - std::string _work_order_id; - /** - * @brief time_diff - */ - float _time_diff; - /** - * @brief swath_num - */ - std::string _swath_num; - /** - * @brief range_spacing - */ - float _range_spacing; - /** - * @brief azimut_spacing - */ - float _azimut_spacing; - /** - * @brief line_time_interval - */ - float _line_time_interval; - /** - * @brief num_output_lines - */ - unsigned int _num_output_lines; - /** - * @brief num_samples_per_line - */ - unsigned int _num_samples_per_line; - /** - * @brief data_type - */ - std::string _data_type; - /** - * @brief num_range_lines_per_burst - */ - unsigned int _num_range_lines_per_burst; - /** - * @brief time_diff_zero_doppler - */ - float _time_diff_zero_doppler; - /** - * @brief data_analysis_flag - */ - bool _data_analysis_flag; - /** - * @brief ant_elev_coor_flag - */ - bool _ant_elev_coor_flag; - /** - * @brief chirp_extract_flag - */ - bool _chirp_extract_flag; - /** - * @brief srgr_flag - */ - bool _srgr_flag; - /** - * @brief dop_cen_flag - */ - bool _dop_cen_flag; - /** - * @brief dop_amb_flag - */ - bool _dop_amb_flag; - /** - * @brief range_spread_comp_flag - */ - bool _range_spread_comp_flag; - /** - * @brief detected_flag - */ - bool _detected_flag; - /** - * @brief look_sum_flag - */ - bool _look_sum_flag; - /** - * @brief rms_equal_flag - */ - bool _rms_equal_flag; - /** - * @brief ant_scal_flag - */ - bool _ant_scal_flag; - /** - * @brief vga_com_echo_flag - */ - bool _vga_com_echo_flag; - /** - * @brief vga_com_cal_flag - */ - bool _vga_com_cal_flag; - /** - * @brief vga_com_nom_time_flag - */ - bool _vga_com_nom_time_flag; - /** - * @brief gm_rng_comp_inv_filter_flag - */ - bool _gm_rng_comp_inv_filter_flag; - /** - * @brief raw_data_analysis - */ - std::string _raw_data_analysis; - /** - * @brief start_time_mds1 - */ - std::string _start_time_mds1; - /** - * @brief start_time_mds2 - */ - std::string _start_time_mds2; - /** - * @brief parameter_code - */ - std::string _parameter_code; - /** - * @brief errors_counters - */ - std::string _errors_counters; - /** - * @brief image_parameters block 1 - */ - std::string _image_parameters1; - /** - * @brief PRF - */ - float _prf_values[5]; - /** - * @brief image_parameters block 2 - */ - std::string _image_parameters2; - /** - * @brief first_proc_range_samp - */ - unsigned int _first_proc_range_samp; - /** - * @brief range_ref - */ - float _range_ref; - /** - * @brief range_samp_rate - */ - float _range_samp_rate; - /** - * @brief radar_freq - */ - float _radar_freq; - /** - * @brief num_looks_range - */ - unsigned short _num_looks_range; - /** - * @brief filter_range - */ - std::string _filter_range; - /** - * @brief filter_coef_range - */ - float _filter_coef_range; - /** - * @brief bandwidth - */ - std::string _bandwidth; - /** - * @brief nominal_chirp - */ - std::string _nominal_chirp; - /** - * @brief num_lines_proc - */ - unsigned int _num_lines_proc; - /** - * @brief num_look_az - */ - unsigned short _num_look_az; - /** - * @brief look_bw_az - */ - float _look_bw_az; - /** - * @brief to_bw_az - */ - float _to_bw_az; - /** - * @brief filter_az - */ - std::string _filter_az; - /** - * @brief filter_coef_az - */ - float _filter_coef_az; - /** - * @brief az_fm_rate[3] - */ - float _az_fm_rate[3]; - /** - * @brief ax_fm_origin - */ - float _ax_fm_origin; - /** - * @brief dop_amb_coef - */ - float _dop_amb_coef; - /** - * @brief calibration_factors - */ - std::string _calibration_factors; - /** - * @brief noise_estimation - */ - std::string _noise_estimation; - /** - * @brief output_statistics - */ - std::string _output_statistics; - /** - * @brief avg_scene_height_ellpsoid - */ - float _avg_scene_height_ellpsoid; - /** - * @brief echo_comp - */ - std::string _echo_comp; - /** - * @brief echo_comp_ratio - */ - std::string _echo_comp_ratio; - /** - * @brief init_cal_comp - */ - std::string _init_cal_comp; - /** - * @brief init_cal_ratio - */ - std::string _init_cal_ratio; - /** - * @brief per_cal_comp - */ - std::string _per_cal_comp; - /** - * @brief per_cal_ratio - */ - std::string _per_cal_ratio; - /** - * @brief noise_comp - */ - std::string _noise_comp; - /** - * @brief noise_comp_ratio - */ - std::string _noise_comp_ratio; - /** - * @brief beam_overlap[4] - */ - unsigned int _beam_overlap[4]; - /** - * @brief beam_overlap[4] - */ - float _beam_param[4]; - /** - * @brief lines_per_burst[5] - */ - unsigned int _lines_per_burst[5]; - /** - * @brief time_first_SS1_echo - */ - std::string _time_first_SS1_echo; - /** - * @brief state_vector_time_1_day - */ - int _state_vector_time_1_day; - /** - * @brief state_vector_time_1_sec - */ - unsigned int _state_vector_time_1_sec; - /** - * @brief state_vector_time_1_microsec - */ - unsigned int _state_vector_time_1_microsec; - /** - * @brief x_pos_1 - */ - int _x_pos_1; - /** - * @brief y_pos_1 - */ - int _y_pos_1; - /** - * @brief z_pos_1 - */ - int _z_pos_1; - /** - * @brief x_vel_1 - */ - int _x_vel_1; - /** - * @brief y_vel_1 - */ - int _y_vel_1; - /** - * @brief z_vel_1 - */ - int _z_vel_1; - /** - * @brief state_vector_time_2_day - */ - int _state_vector_time_2_day; - /** - * @brief state_vector_time_2_sec - */ - unsigned int _state_vector_time_2_sec; - /** - * @brief state_vector_time_2_microsec - */ - unsigned int _state_vector_time_2_microsec; - /** - * @brief x_pos_2 - */ - int _x_pos_2; - /** - * @brief y_pos_2 - */ - int _y_pos_2; - /** - * @brief z_pos_2 - */ - int _z_pos_2; - /** - * @brief x_vel_2 - */ - int _x_vel_2; - /** - * @brief y_vel_2 - */ - int _y_vel_2; - /** - * @brief z_vel_2 - */ - int _z_vel_2; - /** - * @brief state_vector_time_3_day - */ - int _state_vector_time_3_day; - /** - * @brief state_vector_time_3_sec - */ - unsigned int _state_vector_time_3_sec; - /** - * @brief state_vector_time_3_microsec - */ - unsigned int _state_vector_time_3_microsec; - /** - * @brief x_pos_3 - */ - int _x_pos_3; - /** - * @brief y_pos_3 - */ - int _y_pos_3; - /** - * @brief z_pos_3 - */ - int _z_pos_3; - /** - * @brief x_vel_3 - */ - int _x_vel_3; - /** - * @brief y_vel_3 - */ - int _y_vel_3; - /** - * @brief z_vel_3 - */ - int _z_vel_3; - /** - * @brief state_vector_time_4_day - */ - int _state_vector_time_4_day; - /** - * @brief state_vector_time_4_sec - */ - unsigned int _state_vector_time_4_sec; - /** - * @brief state_vector_time_4_microsec - */ - unsigned int _state_vector_time_4_microsec; - /** - * @brief x_pos_4 - */ - int _x_pos_4; - /** - * @brief y_pos_4 - */ - int _y_pos_4; - /** - * @brief z_pos_4 - */ - int _z_pos_4; - /** - * @brief x_vel_4 - */ - int _x_vel_4; - /** - * @brief y_vel_4 - */ - int _y_vel_4; - /** - * @brief z_vel_4 - */ - int _z_vel_4; - /** - * @brief state_vector_time_5_day - */ - int _state_vector_time_5_day; - /** - * @brief state_vector_time_5_sec - */ - unsigned int _state_vector_time_5_sec; - /** - * @brief state_vector_time_5_microsec - */ - unsigned int _state_vector_time_5_microsec; - /** - * @brief x_pos_5 - */ - int _x_pos_5; - /** - * @brief y_pos_5 - */ - int _y_pos_5; - /** - * @brief z_pos_5 - */ - int _z_pos_5; - /** - * @brief x_vel_5 - */ - int _x_vel_5; - /** - * @brief y_vel_5 - */ - int _y_vel_5; - /** - * @brief z_vel_5 - */ - int _z_vel_5; - - -private: - -}; - -#endif - - diff --git a/Utilities/otbossim/include/ossim/imaging/EnvisatAsar/SQ_ADSR.h b/Utilities/otbossim/include/ossim/imaging/EnvisatAsar/SQ_ADSR.h deleted file mode 100644 index 49c48b4fb4ca7d9dcb417e61b794ed49f9974ff3..0000000000000000000000000000000000000000 --- a/Utilities/otbossim/include/ossim/imaging/EnvisatAsar/SQ_ADSR.h +++ /dev/null @@ -1,485 +0,0 @@ -#ifndef SQ_ADSR_h -#define SQ_ADSR_h - -#include <iostream> -#include <ossim/imaging/EnvisatAsar/EnvisatAsarRecord.h> -/** - * @ingroup SQ_ADSRRecord - * @brief This class is able to read the ASAR SQ_ADSR record - * @author Magellium, Pacome Dentraygues - * @version 1.0 - * @date 23-11-07 - */ -class SQ_ADSR : public EnvisatAsarRecord -{ -public: - /** - * @brief Constructor - */ - SQ_ADSR(); - - /** - * @brief Destructor - */ - ~SQ_ADSR(); - - /** - * @brief This function write the SQ_ADSR in a stream - */ - friend std::ostream& operator<<(std::ostream& os, const SQ_ADSR& data); - - /** - * @brief This function read a SQ_ADSR from a stream - */ - friend std::istream& operator>>(std::istream& is, SQ_ADSR& data); - - /** - * @brief Copy constructor - */ - SQ_ADSR(const SQ_ADSR& rhs); - - /** - * @brief Copy operator - */ - SQ_ADSR& operator=(const SQ_ADSR& rhs); - - /** - * @brief This function is able to create a new instance of the class - */ - EnvisatAsarRecord* Instanciate() - { - return new SQ_ADSR(); - }; - - /** - * @brief This function is able to create a new instance of the class initialised with the data of the calling instance - */ - EnvisatAsarRecord* Clone() - { - return new SQ_ADSR(*this); - }; - - /** - * @brief Reads the class data from a stream - */ - void Read(std::istream& is) - { - is>>*this; - }; - - /** - * @brief Writes the class to a stream - */ - void Write(std::ostream& os) - { - os<<*this; - }; - - - /** - * @brief zero_doppler_time - */ - std::string get_zero_doppler_time() - { - return _zero_doppler_time; - }; - /** - * @brief attach_flag - */ - bool get_attach_flag() - { - return _attach_flag; - }; - /** - * @brief input_mean_flag - */ - bool get_input_mean_flag() - { - return _input_mean_flag; - }; - /** - * @brief input_std_dev_flag - */ - bool get_input_std_dev_flag() - { - return _input_std_dev_flag; - }; - /** - * @brief input_gaps_flag - */ - bool get_input_gaps_flag() - { - return _input_gaps_flag; - }; - /** - * @brief input_missing_lines_flag - */ - bool get_input_missing_lines_flag() - { - return _input_missing_lines_flag; - }; - /** - * @brief dop_cen_flag - */ - bool get_dop_cen_flag() - { - return _dop_cen_flag; - }; - /** - * @brief dop_amb_flag - */ - bool get_dop_amb_flag() - { - return _dop_amb_flag; - }; - /** - * @brief output_mean_flag - */ - bool get_output_mean_flag() - { - return _output_mean_flag; - }; - /** - * @brief output_std_dev_flag - */ - bool get_output_std_dev_flag() - { - return _output_std_dev_flag; - }; - /** - * @brief chirp_flag - */ - bool get_chirp_flag() - { - return _chirp_flag; - }; - /** - * @brief missing_data_set_flag - */ - bool get_missing_data_set_flag() - { - return _missing_data_set_flag; - }; - /** - * @brief invalid_downlink_flag - */ - bool get_invalid_downlink_flag() - { - return _invalid_downlink_flag; - }; - /** - * @brief thres_chirp_broadening - */ - float get_thres_chirp_broadening() - { - return _thres_chirp_broadening; - }; - /** - * @brief thresh_chirp_sidelobe - */ - float get_thresh_chirp_sidelobe() - { - return _thresh_chirp_sidelobe; - }; - /** - * @brief thresh_chirp_islr - */ - float get_thresh_chirp_islr() - { - return _thresh_chirp_islr; - }; - /** - * @brief thresh_input_mean - */ - float get_thresh_input_mean() - { - return _thresh_input_mean; - }; - /** - * @brief exp_input_mean - */ - float get_exp_input_mean() - { - return _exp_input_mean; - }; - /** - * @brief thresh_input_std_dev - */ - float get_thresh_input_std_dev() - { - return _thresh_input_std_dev; - }; - /** - * @brief exp_input_std_dev - */ - float get_exp_input_std_dev() - { - return _exp_input_std_dev; - }; - /** - * @brief thresh_dop_cen - */ - float get_thresh_dop_cen() - { - return _thresh_dop_cen; - }; - /** - * @brief thresh_dop_amb - */ - float get_thresh_dop_amb() - { - return _thresh_dop_amb; - }; - /** - * @brief thresh_output_mean - */ - float get_thresh_output_mean() - { - return _thresh_output_mean; - }; - /** - * @brief exp_output_mean - */ - float get_exp_output_mean() - { - return _exp_output_mean; - }; - /** - * @brief thresh_output_std_dev - */ - float get_thresh_output_std_dev() - { - return _thresh_output_std_dev; - }; - /** - * @brief exp_output_std_dev - */ - float get_exp_output_std_dev() - { - return _exp_output_std_dev; - }; - /** - * @brief thresh_input_missing_lines - */ - float get_thresh_input_missing_lines() - { - return _thresh_input_missing_lines; - }; - /** - * @brief thresh_input_gaps - */ - float get_thresh_input_gaps() - { - return _thresh_input_gaps; - }; - /** - * @brief lines_per_gaps - */ - unsigned int get_lines_per_gaps() - { - return _lines_per_gaps; - }; - /** - * @brief input_mean[2] - */ - float* get_input_mean() - { - return _input_mean; - }; - /** - * @brief input_std_dev[2] - */ - float* get_input_std_dev() - { - return _input_std_dev; - }; - /** - * @brief num_gaps - */ - float get_num_gaps() - { - return _num_gaps; - }; - /** - * @brief num_missing_lines - */ - float get_num_missing_lines() - { - return _num_missing_lines; - }; - /** - * @brief output_mean[2] - */ - float* get_output_mean() - { - return _output_mean; - }; - /** - * @brief output_std_dev[2] - */ - float* get_output_std_dev() - { - return _output_std_dev; - }; - /** - * @brief tot_errors - */ - unsigned int get_tot_errors() - { - return _tot_errors; - }; - - - /** - * @brief zero_doppler_time - */ - std::string _zero_doppler_time; - /** - * @brief attach_flag - */ - bool _attach_flag; - /** - * @brief input_mean_flag - */ - bool _input_mean_flag; - /** - * @brief input_std_dev_flag - */ - bool _input_std_dev_flag; - /** - * @brief input_gaps_flag - */ - bool _input_gaps_flag; - /** - * @brief input_missing_lines_flag - */ - bool _input_missing_lines_flag; - /** - * @brief dop_cen_flag - */ - bool _dop_cen_flag; - /** - * @brief dop_amb_flag - */ - bool _dop_amb_flag; - /** - * @brief output_mean_flag - */ - bool _output_mean_flag; - /** - * @brief output_std_dev_flag - */ - bool _output_std_dev_flag; - /** - * @brief chirp_flag - */ - bool _chirp_flag; - /** - * @brief missing_data_set_flag - */ - bool _missing_data_set_flag; - /** - * @brief invalid_downlink_flag - */ - bool _invalid_downlink_flag; - /** - * @brief thres_chirp_broadening - */ - float _thres_chirp_broadening; - /** - * @brief thresh_chirp_sidelobe - */ - float _thresh_chirp_sidelobe; - /** - * @brief thresh_chirp_islr - */ - float _thresh_chirp_islr; - /** - * @brief thresh_input_mean - */ - float _thresh_input_mean; - /** - * @brief exp_input_mean - */ - float _exp_input_mean; - /** - * @brief thresh_input_std_dev - */ - float _thresh_input_std_dev; - /** - * @brief exp_input_std_dev - */ - float _exp_input_std_dev; - /** - * @brief thresh_dop_cen - */ - float _thresh_dop_cen; - /** - * @brief thresh_dop_amb - */ - float _thresh_dop_amb; - /** - * @brief thresh_output_mean - */ - float _thresh_output_mean; - /** - * @brief exp_output_mean - */ - float _exp_output_mean; - /** - * @brief thresh_output_std_dev - */ - float _thresh_output_std_dev; - /** - * @brief exp_output_std_dev - */ - float _exp_output_std_dev; - /** - * @brief thresh_input_missing_lines - */ - float _thresh_input_missing_lines; - /** - * @brief thresh_input_gaps - */ - float _thresh_input_gaps; - /** - * @brief lines_per_gaps - */ - unsigned int _lines_per_gaps; - /** - * @brief input_mean[2] - */ - float _input_mean[2]; - /** - * @brief input_std_dev[2] - */ - float _input_std_dev[2]; - /** - * @brief num_gaps - */ - float _num_gaps; - /** - * @brief num_missing_lines - */ - float _num_missing_lines; - /** - * @brief output_mean[2] - */ - float _output_mean[2]; - /** - * @brief output_std_dev[2] - */ - float _output_std_dev[2]; - /** - * @brief tot_errors - */ - unsigned int _tot_errors; - - -private: - -}; - -#endif - - diff --git a/Utilities/otbossim/include/ossim/imaging/EnvisatAsar/SRGRConversionParameters.h b/Utilities/otbossim/include/ossim/imaging/EnvisatAsar/SRGRConversionParameters.h deleted file mode 100644 index 9511e8900ff7ea0d8939b92cfa6693fecfcbbf73..0000000000000000000000000000000000000000 --- a/Utilities/otbossim/include/ossim/imaging/EnvisatAsar/SRGRConversionParameters.h +++ /dev/null @@ -1,165 +0,0 @@ -#ifndef SRGRConversionParameters_h -#define SRGRConversionParameters_h - -#include <iostream> -#include <ossim/imaging/EnvisatAsar/EnvisatAsarRecord.h> -/** - * @ingroup SRGRConversionParametersRecord - * @brief This class is able to read the ASAR SRGRConversionParameters record - * @author Magellium, Pacome Dentraygues - * @version 1.0 - * @date 23-11-07 - */ -class SRGRConversionParameters : public EnvisatAsarRecord -{ -public: - /** - * @brief Constructor - */ - SRGRConversionParameters(); - - /** - * @brief Destructor - */ - ~SRGRConversionParameters(); - - /** - * @brief This function writes the SRGRConversionParameters in a stream - */ - friend std::ostream& operator<<(std::ostream& os, const SRGRConversionParameters& data); - - /** - * @brief This function reads a SRGRConversionParameters from a stream - */ - friend std::istream& operator>>(std::istream& is, SRGRConversionParameters& data); - - /** - * @brief Copy constructor - */ - SRGRConversionParameters(const SRGRConversionParameters& rhs); - - /** - * @brief Copy operator - */ - SRGRConversionParameters& operator=(const SRGRConversionParameters& rhs); - - /** - * @brief This function is able to create a new instance of the class - */ - EnvisatAsarRecord* Instanciate() - { - return new SRGRConversionParameters(); - }; - - /** - * @brief This function is able to create a new instance of the class initialised with the data of the calling instance - */ - EnvisatAsarRecord* Clone() - { - return new SRGRConversionParameters(*this); - }; - - /** - * @brief Reads the class data from a stream - */ - void Read(std::istream& is) - { - is>>*this; - }; - - /** - * @brief Writes the class to a stream - */ - void Write(std::ostream& os) - { - os<<*this; - }; - - - /** - * @brief first_zero_doppler_time day - */ - int get_first_zero_doppler_time_day() - { - return _first_zero_doppler_time_day; - }; - /** - * @brief first_zero_doppler_time second - */ - unsigned int get_first_zero_doppler_time_sec() - { - return _first_zero_doppler_time_sec; - }; - /** - * @brief first_zero_doppler_time micro sec - */ - unsigned int get_first_zero_doppler_time_microsec() - { - return _first_zero_doppler_time_microsec; - }; - /** - * @brief attach_flag - */ - bool get_attach_flag() - { - return _attach_flag; - }; - /** - * @brief input_mean_flag - */ - float get_slant_range_time() - { - return _slant_range_time; - }; - /** - * @brief input_std_dev_flag - */ - float get_ground_range_origin() - { - return _ground_range_origin; - }; - /** - * @brief input_gaps_flag - */ - float* get_srgr_coef() - { - return _srgr_coef; - }; - - /** - * @brief first_zero_doppler_time day - */ - int _first_zero_doppler_time_day; - /** - * @brief first_zero_doppler_time sec - */ - unsigned int _first_zero_doppler_time_sec; - /** - * @brief first_zero_doppler_time microsec - */ - unsigned int _first_zero_doppler_time_microsec; - /** - * @brief attach_flag - */ - bool _attach_flag; - /** - * @brief input_mean_flag - */ - float _slant_range_time; - /** - * @brief input_std_dev_flag - */ - float _ground_range_origin; - /** - * @brief input_gaps_flag - */ - float _srgr_coef[5]; - - -private: - -}; - -#endif - - diff --git a/Utilities/otbossim/include/ossim/imaging/EnvisatAsar/dsd.h b/Utilities/otbossim/include/ossim/imaging/EnvisatAsar/dsd.h deleted file mode 100644 index c13efa5964cd716060ddc0a474ca2c16ce917dc2..0000000000000000000000000000000000000000 --- a/Utilities/otbossim/include/ossim/imaging/EnvisatAsar/dsd.h +++ /dev/null @@ -1,164 +0,0 @@ -#ifndef dsd_h -#define dsd_h - -#include <iostream> -#include <ossim/imaging/EnvisatAsar/EnvisatAsarRecord.h> -/** - * @ingroup dsdRecord - * @brief This class is able to read the ASAR dsd record - * @author Magellium, Pacome Dentraygues - * @version 1.0 - * @date 23-11-07 - */ -class dsd : public EnvisatAsarRecord -{ -public: - /** - * @brief Constructor - */ - dsd(); - - /** - * @brief Destructor - */ - ~dsd(); - - /** - * @brief This function write the dsd in a stream - */ - friend std::ostream& operator<<(std::ostream& os, const dsd& data); - - /** - * @brief This function read a dsd from a stream - */ - friend std::istream& operator>>(std::istream& is, dsd& data); - - /** - * @brief Copy constructor - */ - dsd(const dsd& rhs); - - /** - * @brief Copy operator - */ - dsd& operator=(const dsd& rhs); - - /** - * @brief This function is able to create a new instance of the class - */ - EnvisatAsarRecord* Instanciate() - { - return new dsd(); - }; - - /** - * @brief This function is able to create a new instance of the class initialised with the data of the calling instance - */ - EnvisatAsarRecord* Clone() - { - return new dsd(*this); - }; - - /** - * @brief Read the class data from a stream - */ - void Read(std::istream& is) - { - is>>*this; - }; - - /** - * @brief Write the class to a stream - */ - void Write(std::ostream& os) - { - os<<*this; - }; - - - /** - * @brief Data set Name - */ - std::string get_ds_name() - { - return _ds_name; - } - /** - * @brief Data set Type - */ - std::string get_ds_type() - { - return _ds_type; - } - /** - * @brief Data set Filename - */ - std::string get_filename() - { - return _filename; - } - /** - * @brief Data set Offset - */ - double get_ds_offset() - { - return _ds_offset; - } - /** - * @brief Data set Size - */ - double get_ds_size() - { - return _ds_size; - } - /** - * @brief Number of data set record - */ - int get_num_dsr() - { - return _num_dsr; - } - /** - * @brief Data set record size - */ - int get_dsr_size() - { - return _dsr_size; - } - - /** - * @brief Data set Name - */ - std::string _ds_name; - /** - * @brief Data set Type - */ - std::string _ds_type; - /** - * @brief Data set Filename - */ - std::string _filename; - /** - * @brief Data set Offset - */ - double _ds_offset; - /** - * @brief Data set Size - */ - double _ds_size; - /** - * @brief Number of data set record - */ - int _num_dsr; - /** - * @brief Data set record size - */ - int _dsr_size; - -private: - -}; - -#endif - - diff --git a/Utilities/otbossim/include/ossim/imaging/EnvisatAsar/mph.h b/Utilities/otbossim/include/ossim/imaging/EnvisatAsar/mph.h deleted file mode 100644 index 61e6ed95855d6375c02082e504695bba8281421d..0000000000000000000000000000000000000000 --- a/Utilities/otbossim/include/ossim/imaging/EnvisatAsar/mph.h +++ /dev/null @@ -1,977 +0,0 @@ -#ifndef mph_h -#define mph_h - -#include <iostream> -#include <ossim/imaging/EnvisatAsar/EnvisatAsarRecord.h> -/** - * @ingroup mphRecord - * @brief This class is able to read the ASAR mph record of the leader file - * @author Magellium, Pacome Dentraygues - * @version 1.0 - * @date 23-11-07 - */ -class mph : public EnvisatAsarRecord -{ -public: - /** - * @brief Constructor - */ - mph(); - - /** - * @brief Destructor - */ - ~mph(); - - /** - * @brief This function write the mph in a stream - */ - friend std::ostream& operator<<(std::ostream& os, const mph& data); - - /** - * @brief This function read a mph from a stream - */ - friend std::istream& operator>>(std::istream& is, mph& data); - - /** - * @brief Copy constructor - */ - mph(const mph& rhs); - - /** - * @brief Copy operator - */ - mph& operator=(const mph& rhs); - - /** - * @brief This function is able to create a new instance of the class - */ - EnvisatAsarRecord* Instanciate() - { - return new mph(); - }; - - /** - * @brief This function is able to create a new instance of the class initialised with the data of the calling instance - */ - EnvisatAsarRecord* Clone() - { - return new mph(*this); - }; - - /** - * @brief Read the class data from a stream - */ - void Read(std::istream& is) - { - is>>*this; - }; - - /** - * @brief Write the class to a stream - */ - void Write(std::ostream& os) - { - os<<*this; - }; - - /** - * @brief product_name - */ - std::string get_product_name() - { - return _product_name; - }; - /** - * @brief product - */ - std::string get_product() - { - return _product; - }; - /** - * @brief proc_stage_title - */ - std::string get_proc_stage_title() - { - return _proc_stage_title; - }; - /** - * @brief proc_stage - */ - std::string get_proc_stage() - { - return _proc_stage; - }; - /** - * @brief ref_doc_title - */ - std::string get_ref_doc_title() - { - return _ref_doc_title; - }; - /** - * @brief ref_doc - */ - std::string get_ref_doc() - { - return _ref_doc; - }; - /** - * @brief acq_stat_id_title - */ - std::string get_acq_stat_id_title() - { - return _acq_stat_id_title; - }; - /** - * @brief acq_station - */ - std::string get_acq_station() - { - return _acq_station; - }; - /** - * @brief proc_center_title - */ - std::string get_proc_center_title() - { - return _proc_center_title; - }; - /** - * @brief proc_center - */ - std::string get_proc_center() - { - return _proc_center; - }; - /** - * @brief proc_time_title - */ - std::string get_proc_time_title() - { - return _proc_time_title; - }; - /** - * @brief proc_time - */ - std::string get_proc_time() - { - return _proc_time; - }; - /** - * @brief soft_version_title - */ - std::string get_soft_version_title() - { - return _soft_version_title; - }; - /** - * @brief soft_version - */ - std::string get_soft_version() - { - return _soft_version; - }; - /** - * @brief sensing_start_title - */ - std::string get_sensing_start_title() - { - return _sensing_start_title; - }; - /** - * @brief sensing_start - */ - std::string get_sensing_start() - { - return _sensing_start; - }; - /** - * @brief sensing_stop_title - */ - std::string get_sensing_stop_title() - { - return _sensing_stop_title; - }; - /** - * @brief sensing_stop - */ - std::string get_sensing_stop() - { - return _sensing_stop; - }; - /** - * @brief phase_title - */ - std::string get_phase_title() - { - return _phase_title; - }; - /** - * @brief phase - */ - std::string get_phase() - { - return _phase; - }; - /** - * @brief cycle_title - */ - std::string get_cycle_title() - { - return _cycle_title; - }; - /** - * @brief cycle - */ - std::string get_cycle() - { - return _cycle; - }; - /** - * @brief relative_orbit_title - */ - std::string get_relative_orbit_title() - { - return _relative_orbit_title; - }; - /** - * @brief rel_orbit - */ - std::string get_rel_orbit() - { - return _rel_orbit; - }; - /** - * @brief absolute_orbit_title - */ - std::string get_absolute_orbit_title() - { - return _absolute_orbit_title; - }; - /** - * @brief abs_orbit - */ - std::string get_abs_orbit() - { - return _abs_orbit; - }; - /** - * @brief state_vector_time_title - */ - std::string get_state_vector_time_title() - { - return _state_vector_time_title; - }; - /** - * @brief state_vector_time - */ - std::string get_state_vector_time() - { - return _state_vector_time; - }; - /** - * @brief delta_ut1_title - */ - std::string get_delta_ut1_title() - { - return _delta_ut1_title; - }; - /** - * @brief delta_ut1 - */ - std::string get_delta_ut1() - { - return _delta_ut1; - }; - /** - * @brief delta_ut1_units - */ - std::string get_delta_ut1_units() - { - return _delta_ut1_units; - }; - /** - * @brief x_position_title - */ - std::string get_x_position_title() - { - return _x_position_title; - }; - /** - * @brief x_position - */ - std::string get_x_position() - { - return _x_position; - }; - /** - * @brief x_position_units - */ - std::string get_x_position_units() - { - return _x_position_units; - }; - /** - * @brief y_position_title - */ - std::string get_y_position_title() - { - return _y_position_title; - }; - /** - * @brief y_position - */ - std::string get_y_position() - { - return _y_position; - }; - /** - * @brief y_position_units - */ - std::string get_y_position_units() - { - return _y_position_units; - }; - /** - * @brief z_position_title - */ - std::string get_z_position_title() - { - return _z_position_title; - }; - /** - * @brief z_position - */ - std::string get_z_position() - { - return _z_position; - }; - /** - * @brief z_position_units - */ - std::string get_z_position_units() - { - return _z_position_units; - }; - /** - * @brief x_velocity_title - */ - std::string get_x_velocity_title() - { - return _x_velocity_title; - }; - /** - * @brief x_velocity - */ - std::string get_x_velocity() - { - return _x_velocity; - }; - /** - * @brief x_velocity_units - */ - std::string get_x_velocity_units() - { - return _x_velocity_units; - }; - /** - * @brief y_velocity_title - */ - std::string get_y_velocity_title() - { - return _y_velocity_title; - }; - /** - * @brief y_velocity - */ - std::string get_y_velocity() - { - return _y_velocity; - }; - /** - * @brief y_velocity_units - */ - std::string get_y_velocity_units() - { - return _y_velocity_units; - }; - /** - * @brief z_velocity_title - */ - std::string get_z_velocity_title() - { - return _z_velocity_title; - }; - /** - * @brief z_velocity - */ - std::string get_z_velocity() - { - return _z_velocity; - }; - /** - * @brief z_velocity_units - */ - std::string get_z_velocity_units() - { - return _z_velocity_units; - }; - /** - * @brief vector_source_title - */ - std::string get_vector_source_title() - { - return _vector_source_title; - }; - /** - * @brief vector_source - */ - std::string get_vector_source() - { - return _vector_source; - }; - /** - * @brief spare_4 - */ - std::string get_spare_4() - { - return _spare_4; - }; - /** - * @brief utc_sbt_time_title - */ - std::string get_utc_sbt_time_title() - { - return _utc_sbt_time_title; - }; - /** - * @brief utc_sbt_time - */ - std::string get_utc_sbt_time() - { - return _utc_sbt_time; - }; - /** - * @brief sat_binary_time_title - */ - std::string get_sat_binary_time_title() - { - return _sat_binary_time_title; - }; - /** - * @brief sat_binary_time - */ - std::string get_sat_binary_time() - { - return _sat_binary_time; - }; - /** - * @brief clock_step_title - */ - std::string get_clock_step_title() - { - return _clock_step_title; - }; - /** - * @brief clock_step - */ - std::string get_clock_step() - { - return _clock_step; - }; - /** - * @brief clock_step_units - */ - std::string get_clock_step_units() - { - return _clock_step_units; - }; - /** - * @brief leap_utc_title - */ - std::string get_leap_utc_title() - { - return _leap_utc_title; - }; - /** - * @brief leap_utc - */ - std::string get_leap_utc() - { - return _leap_utc; - }; - /** - * @brief leap_sign_title - */ - std::string get_leap_sign_title() - { - return _leap_sign_title; - }; - /** - * @brief leap_sign - */ - std::string get_leap_sign() - { - return _leap_sign; - }; - /** - * @brief leap_err_title - */ - std::string get_leap_err_title() - { - return _leap_err_title; - }; - /** - * @brief leap_err - */ - std::string get_leap_err() - { - return _leap_err; - }; - /** - * @brief product_err_title - */ - std::string get_product_err_title() - { - return _product_err_title; - }; - /** - * @brief product_err - */ - std::string get_product_err() - { - return _product_err; - }; - /** - * @brief total_size_title - */ - std::string get_total_size_title() - { - return _total_size_title; - }; - /** - * @brief tot_size - */ - std::string get_tot_size() - { - return _tot_size; - }; - /** - * @brief total_size_units - */ - std::string get_total_size_units() - { - return _total_size_units; - }; - /** - * @brief sph_size_title - */ - std::string get_sph_size_title() - { - return _sph_size_title; - }; - /** - * @brief sph_size - */ - std::string get_sph_size() - { - return _sph_size; - }; - /** - * @brief sph_size_units - */ - std::string get_sph_size_units() - { - return _sph_size_units; - }; - /** - * @brief number_of_dsd_title - */ - std::string get_number_of_dsd_title() - { - return _number_of_dsd_title; - }; - /** - * @brief num_dsd - */ - int get_num_dsd() - { - return _num_dsd; - }; - /** - * @brief size_of_dsd_title - */ - std::string get_size_of_dsd_title() - { - return _size_of_dsd_title; - }; - /** - * @brief dsd_size - */ - int get_dsd_size() - { - return _dsd_size; - }; - /** - * @brief size_of_dsd_units - */ - std::string get_size_of_dsd_units() - { - return _size_of_dsd_units; - }; - /** - * @brief number_of_ds_att_title - */ - std::string get_number_of_ds_att_title() - { - return _number_of_ds_att_title; - }; - /** - * @brief num_data_sets - */ - int get_num_data_sets() - { - return _num_data_sets; - }; - /** - * @brief Check mph validity - */ - bool is_valid() - { - if ((_product_name.compare("PRODUCT=") == 0) && (_number_of_dsd_title.compare("NUM_DSD=") == 0)) - { - return true; - } else return false; - }; - - - /** - * @brief product_name - */ - std::string _product_name; - /** - * @brief product - */ - std::string _product; - /** - * @brief proc_stage_title - */ - std::string _proc_stage_title; - /** - * @brief proc_stage - */ - std::string _proc_stage; - /** - * @brief ref_doc_title - */ - std::string _ref_doc_title; - /** - * @brief ref_doc - */ - std::string _ref_doc; - /** - * @brief acq_stat_id_title - */ - std::string _acq_stat_id_title; - /** - * @brief acq_station - */ - std::string _acq_station; - /** - * @brief proc_center_title - */ - std::string _proc_center_title; - /** - * @brief proc_center - */ - std::string _proc_center; - /** - * @brief proc_time_title - */ - std::string _proc_time_title; - /** - * @brief proc_time - */ - std::string _proc_time; - /** - * @brief soft_version_title - */ - std::string _soft_version_title; - /** - * @brief soft_version - */ - std::string _soft_version; - /** - * @brief sensing_start_title - */ - std::string _sensing_start_title; - /** - * @brief sensing_start - */ - std::string _sensing_start; - /** - * @brief sensing_stop_title - */ - std::string _sensing_stop_title; - /** - * @brief sensing_stop - */ - std::string _sensing_stop; - /** - * @brief phase_title - */ - std::string _phase_title; - /** - * @brief phase - */ - std::string _phase; - /** - * @brief cycle_title - */ - std::string _cycle_title; - /** - * @brief cycle - */ - std::string _cycle; - /** - * @brief relative_orbit_title - */ - std::string _relative_orbit_title; - /** - * @brief rel_orbit - */ - std::string _rel_orbit; - /** - * @brief absolute_orbit_title - */ - std::string _absolute_orbit_title; - /** - * @brief abs_orbit - */ - std::string _abs_orbit; - /** - * @brief state_vector_time_title - */ - std::string _state_vector_time_title; - /** - * @brief state_vector_time - */ - std::string _state_vector_time; - /** - * @brief delta_ut1_title - */ - std::string _delta_ut1_title; - /** - * @brief delta_ut1 - */ - std::string _delta_ut1; - /** - * @brief delta_ut1_units - */ - std::string _delta_ut1_units; - /** - * @brief x_position_title - */ - std::string _x_position_title; - /** - * @brief x_position - */ - std::string _x_position; - /** - * @brief x_position_units - */ - std::string _x_position_units; - /** - * @brief y_position_title - */ - std::string _y_position_title; - /** - * @brief y_position - */ - std::string _y_position; - /** - * @brief y_position_units - */ - std::string _y_position_units; - /** - * @brief z_position_title - */ - std::string _z_position_title; - /** - * @brief z_position - */ - std::string _z_position; - /** - * @brief z_position_units - */ - std::string _z_position_units; - /** - * @brief x_velocity_title - */ - std::string _x_velocity_title; - /** - * @brief x_velocity - */ - std::string _x_velocity; - /** - * @brief x_velocity_units - */ - std::string _x_velocity_units; - /** - * @brief y_velocity_title - */ - std::string _y_velocity_title; - /** - * @brief y_velocity - */ - std::string _y_velocity; - /** - * @brief y_velocity_units - */ - std::string _y_velocity_units; - /** - * @brief z_velocity_title - */ - std::string _z_velocity_title; - /** - * @brief z_velocity - */ - std::string _z_velocity; - /** - * @brief z_velocity_units - */ - std::string _z_velocity_units; - /** - * @brief vector_source_title - */ - std::string _vector_source_title; - /** - * @brief vector_source - */ - std::string _vector_source; - /** - * @brief spare_4 - */ - std::string _spare_4; - /** - * @brief utc_sbt_time_title - */ - std::string _utc_sbt_time_title; - /** - * @brief utc_sbt_time - */ - std::string _utc_sbt_time; - /** - * @brief sat_binary_time_title - */ - std::string _sat_binary_time_title; - /** - * @brief sat_binary_time - */ - std::string _sat_binary_time; - /** - * @brief clock_step_title - */ - std::string _clock_step_title; - /** - * @brief clock_step - */ - std::string _clock_step; - /** - * @brief clock_step_units - */ - std::string _clock_step_units; - /** - * @brief leap_utc_title - */ - std::string _leap_utc_title; - /** - * @brief leap_utc - */ - std::string _leap_utc; - /** - * @brief leap_sign_title - */ - std::string _leap_sign_title; - /** - * @brief leap_sign - */ - std::string _leap_sign; - /** - * @brief leap_err_title - */ - std::string _leap_err_title; - /** - * @brief leap_err - */ - std::string _leap_err; - /** - * @brief product_err_title - */ - std::string _product_err_title; - /** - * @brief product_err - */ - std::string _product_err; - /** - * @brief total_size_title - */ - std::string _total_size_title; - /** - * @brief tot_size - */ - std::string _tot_size; - /** - * @brief total_size_units - */ - std::string _total_size_units; - /** - * @brief sph_size_title - */ - std::string _sph_size_title; - /** - * @brief sph_size - */ - std::string _sph_size; - /** - * @brief sph_size_units - */ - std::string _sph_size_units; - /** - * @brief number_of_dsd_title - */ - std::string _number_of_dsd_title; - /** - * @brief num_dsd - */ - int _num_dsd; - /** - * @brief size_of_dsd_title - */ - std::string _size_of_dsd_title; - /** - * @brief dsd_size - */ - int _dsd_size; - /** - * @brief size_of_dsd_units - */ - std::string _size_of_dsd_units; - /** - * @brief number_of_ds_att_title - */ - std::string _number_of_ds_att_title; - /** - * @brief num_data_sets - */ - int _num_data_sets; - -private: - -}; - -#endif - - diff --git a/Utilities/otbossim/include/ossim/imaging/EnvisatAsar/sph.h b/Utilities/otbossim/include/ossim/imaging/EnvisatAsar/sph.h deleted file mode 100644 index abb3955c8842841ccb603c03975196901d48bb7d..0000000000000000000000000000000000000000 --- a/Utilities/otbossim/include/ossim/imaging/EnvisatAsar/sph.h +++ /dev/null @@ -1,1006 +0,0 @@ -#ifndef sph_h -#define sph_h - -#include <iostream> -#include <vector> -#include <ossim/imaging/EnvisatAsar/EnvisatAsarRecord.h> -#include <ossim/imaging/EnvisatAsar/mph.h> -#include <ossim/imaging/EnvisatAsar/dsd.h> - -/** - * @ingroup sphRecord - * @brief This class is able to read the SAR sph record of the ASAR file - * @author Magellium, Pacome Dentraygues - * @version 1.0 - * @date 23-11-07 - */ -class sph : public EnvisatAsarRecord -{ -public: - /** - * @brief Constructor - */ - sph(); - - /** - * @brief Constructor Using an mph record to initialize num_dsd and dsd_size - */ - sph(const mph& data); - /** - * @brief Destructor - */ - ~sph(); - - /** - * @brief This function write the sph in a stream - */ - friend std::ostream& operator<<(std::ostream& os, const sph& data); - - /** - * @brief This function read a sph from a stream - */ - friend std::istream& operator>>(std::istream& is, sph& data); - - /** - * @brief Copy constructor - */ - sph(const sph& rhs); - - /** - * @brief Copy operator - */ - sph& operator=(const sph& rhs); - - /** - * @brief This function is able to create a new instance of the class - */ - EnvisatAsarRecord* Instanciate() - { - return new sph(); - }; - - /** - * @brief This function is able to create a new instance of the class initialised with the data of the calling instance - */ - EnvisatAsarRecord* Clone() - { - return new sph(*this); - }; - - /** - * @brief Read the class data from a stream - */ - void Read(std::istream& is) - { - is>>*this; - }; - - /** - * @brief Write the class to a stream - */ - void Write(std::ostream& os) - { - os<<*this; - }; - - /** - * @brief sph_desc_title - */ - std::string get_sph_desc_title() - { - return _sph_desc_title; - }; - /** - * @brief sph_desc - */ - std::string get_sph_desc() - { - return _sph_desc; - }; - /** - * @brief strip_cont_ind_title - */ - std::string get_strip_cont_ind_title() - { - return _strip_cont_ind_title; - }; - /** - * @brief strip_cont_ind - */ - std::string get_strip_cont_ind() - { - return _strip_cont_ind; - }; - /** - * @brief slice_pos_title - */ - std::string get_slice_pos_title() - { - return _slice_pos_title; - }; - /** - * @brief slice_position - */ - std::string get_slice_position() - { - return _slice_position; - }; - /** - * @brief num_slices_title - */ - std::string get_num_slices_title() - { - return _num_slices_title; - }; - /** - * @brief num_slices - */ - std::string get_num_slices() - { - return _num_slices; - }; - /** - * @brief first_line_time_title - */ - std::string get_first_line_time_title() - { - return _first_line_time_title; - }; - /** - * @brief first_line_time - */ - std::string get_first_line_time() - { - return _first_line_time; - }; - /** - * @brief last_line_time_title - */ - std::string get_last_line_time_title() - { - return _last_line_time_title; - }; - /** - * @brief last_line_time - */ - std::string get_last_line_time() - { - return _last_line_time; - }; - /** - * @brief first_near_lat_title - */ - std::string get_first_near_lat_title() - { - return _first_near_lat_title; - }; - /** - * @brief first_near_lat - */ - std::string get_first_near_lat() - { - return _first_near_lat; - }; - /** - * @brief first_near_lat_units - */ - std::string get_first_near_lat_units() - { - return _first_near_lat_units; - }; - /** - * @brief first_near_long_title - */ - std::string get_first_near_long_title() - { - return _first_near_long_title; - }; - /** - * @brief first_near_long - */ - std::string get_first_near_long() - { - return _first_near_long; - }; - /** - * @brief first_near_long_units - */ - std::string get_first_near_long_units() - { - return _first_near_long_units; - }; - /** - * @brief first_mid_lat_title - */ - std::string get_first_mid_lat_title() - { - return _first_mid_lat_title; - }; - /** - * @brief first_mid_lat - */ - std::string get_first_mid_lat() - { - return _first_mid_lat; - }; - /** - * @brief first_mid_lat_units - */ - std::string get_first_mid_lat_units() - { - return _first_mid_lat_units; - }; - /** - * @brief first_mid_long_title - */ - std::string get_first_mid_long_title() - { - return _first_mid_long_title; - }; - /** - * @brief first_mid_long - */ - std::string get_first_mid_long() - { - return _first_mid_long; - }; - /** - * @brief first_mid_long_units - */ - std::string get_first_mid_long_units() - { - return _first_mid_long_units; - }; - /** - * @brief first_far_lat_title - */ - std::string get_first_far_lat_title() - { - return _first_far_lat_title; - }; - /** - * @brief first_far_lat - */ - std::string get_first_far_lat() - { - return _first_far_lat; - }; - /** - * @brief first_far_lat_units - */ - std::string get_first_far_lat_units() - { - return _first_far_lat_units; - }; - /** - * @brief first_far_long_title - */ - std::string get_first_far_long_title() - { - return _first_far_long_title; - }; - /** - * @brief first_far_long - */ - std::string get_first_far_long() - { - return _first_far_long; - }; - /** - * @brief first_far_long_units - */ - std::string get_first_far_long_units() - { - return _first_far_long_units; - }; - /** - * @brief last_near_lat_title - */ - std::string get_last_near_lat_title() - { - return _last_near_lat_title; - }; - /** - * @brief last_near_lat - */ - std::string get_last_near_lat() - { - return _last_near_lat; - }; - /** - * @brief last_near_lat_units - */ - std::string get_last_near_lat_units() - { - return _last_near_lat_units; - }; - /** - * @brief last_near_long_title - */ - std::string get_last_near_long_title() - { - return _last_near_long_title; - }; - /** - * @brief last_near_long - */ - std::string get_last_near_long() - { - return _last_near_long; - }; - /** - * @brief last_near_long_units - */ - std::string get_last_near_long_units() - { - return _last_near_long_units; - }; - /** - * @brief last_mid_lat_title - */ - std::string get_last_mid_lat_title() - { - return _last_mid_lat_title; - }; - /** - * @brief last_mid_lat - */ - std::string get_last_mid_lat() - { - return _last_mid_lat; - }; - /** - * @brief last_mid_lat_units - */ - std::string get_last_mid_lat_units() - { - return _last_mid_lat_units; - }; - /** - * @brief last_mid_long_title - */ - std::string get_last_mid_long_title() - { - return _last_mid_long_title; - }; - /** - * @brief last_mid_long - */ - std::string get_last_mid_long() - { - return _last_mid_long; - }; - /** - * @brief last_mid_long_units - */ - std::string get_last_mid_long_units() - { - return _last_mid_long_units; - }; - /** - * @brief last_far_lat_title - */ - std::string get_last_far_lat_title() - { - return _last_far_lat_title; - }; - /** - * @brief last_far_lat - */ - std::string get_last_far_lat() - { - return _last_far_lat; - }; - /** - * @brief last_far_lat_units - */ - std::string get_last_far_lat_units() - { - return _last_far_lat_units; - }; - /** - * @brief last_far_long_title - */ - std::string get_last_far_long_title() - { - return _last_far_long_title; - }; - /** - * @brief last_far_long - */ - std::string get_last_far_long() - { - return _last_far_long; - }; - /** - * @brief last_far_long_units - */ - std::string get_last_far_long_units() - { - return _last_far_long_units; - }; - /** - * @brief swath_title - */ - std::string get_swath_title() - { - return _swath_title; - }; - /** - * @brief swath - */ - std::string get_swath() - { - return _swath; - }; - /** - * @brief pass_title - */ - std::string get_pass_title() - { - return _pass_title; - }; - /** - * @brief pass - */ - std::string get_pass() - { - return _pass; - }; - /** - * @brief sample_type_title - */ - std::string get_sample_type_title() - { - return _sample_type_title; - }; - /** - * @brief sample_type - */ - std::string get_sample_type() - { - return _sample_type; - }; - /** - * @brief algo_title - */ - std::string get_algo_title() - { - return _algo_title; - }; - /** - * @brief algorithm - */ - std::string get_algorithm() - { - return _algorithm; - }; - /** - * @brief mds1_tx_rx_polar_title - */ - std::string get_mds1_tx_rx_polar_title() - { - return _mds1_tx_rx_polar_title; - }; - /** - * @brief mds1_tx_rx_polar - */ - std::string get_mds1_tx_rx_polar() - { - return _mds1_tx_rx_polar; - }; - /** - * @brief mds2_tx_rx_polar_title - */ - std::string get_mds2_tx_rx_polar_title() - { - return _mds2_tx_rx_polar_title; - }; - /** - * @brief mds2_tx_rx_polar - */ - std::string get_mds2_tx_rx_polar() - { - return _mds2_tx_rx_polar; - }; - /** - * @brief compression_title - */ - std::string get_compression_title() - { - return _compression_title; - }; - /** - * @brief compression - */ - std::string get_compression() - { - return _compression; - }; - /** - * @brief azimut_looks_title - */ - std::string get_azimut_looks_title() - { - return _azimut_looks_title; - }; - /** - * @brief azimut_looks - */ - std::string get_azimut_looks() - { - return _azimut_looks; - }; - /** - * @brief range_looks_title - */ - std::string get_range_looks_title() - { - return _range_looks_title; - }; - /** - * @brief range_looks - */ - std::string get_range_looks() - { - return _range_looks; - }; - /** - * @brief range_spacing_title - */ - std::string get_range_spacing_title() - { - return _range_spacing_title; - }; - /** - * @brief range_spacing - */ - std::string get_range_spacing() - { - return _range_spacing; - }; - /** - * @brief range_spacing_unit - */ - std::string get_range_spacing_unit() - { - return _range_spacing_unit; - }; - /** - * @brief azimut_spacing_title - */ - std::string get_azimut_spacing_title() - { - return _azimut_spacing_title; - }; - /** - * @brief azimut_spacing - */ - std::string get_azimut_spacing() - { - return _azimut_spacing; - }; - /** - * @brief azimut_spacing_unit - */ - std::string get_azimut_spacing_unit() - { - return _azimut_spacing_unit; - }; - /** - * @brief line_time_interval_title - */ - std::string get_line_time_interval_title() - { - return _line_time_interval_title; - }; - /** - * @brief line_time_interval - */ - std::string get_line_time_interval() - { - return _line_time_interval; - }; - /** - * @brief line_time_interv_units - */ - std::string get_line_time_interv_units() - { - return _line_time_interv_units; - }; - /** - * @brief line_length_title - */ - std::string get_line_length_title() - { - return _line_length_title; - }; - /** - * @brief line_length - */ - std::string get_line_length() - { - return _line_length; - }; - /** - * @brief line_length_units - */ - std::string get_line_length_units() - { - return _line_length_units; - }; - /** - * @brief data_type_title - */ - std::string get_data_type_title() - { - return _data_type_title; - }; - /** - * @brief data_type - */ - std::string get_data_type() - { - return _data_type; - }; - /** - * @brief data_type - */ - std::vector<dsd> get_dsd_vector() - { - return _dsd_vector; - } - - /** - * @brief update DSD number and dsd size from a mph record - */ - bool update_sph_from_mph( mph& mph_rec) - { - _num_dsd = mph_rec._num_dsd; - _size_dsd = mph_rec._dsd_size; - - return 1; - }; - - -protected: - /** - * @brief Number of Data Set Descriptors (DSD) - */ - long _num_dsd; - - /** - * @brief Size of each Data Set Descriptors (DSD) - */ - long _size_dsd; - - /** - * @brief sph_desc_title - */ - std::string _sph_desc_title; - /** - * @brief sph_desc - */ - std::string _sph_desc; - /** - * @brief strip_cont_ind_title - */ - std::string _strip_cont_ind_title; - /** - * @brief strip_cont_ind - */ - std::string _strip_cont_ind; - /** - * @brief slice_pos_title - */ - std::string _slice_pos_title; - /** - * @brief slice_position - */ - std::string _slice_position; - /** - * @brief num_slices_title - */ - std::string _num_slices_title; - /** - * @brief num_slices - */ - std::string _num_slices; - /** - * @brief first_line_time_title - */ - std::string _first_line_time_title; - /** - * @brief first_line_time - */ - std::string _first_line_time; - /** - * @brief last_line_time_title - */ - std::string _last_line_time_title; - /** - * @brief last_line_time - */ - std::string _last_line_time; - /** - * @brief first_near_lat_title - */ - std::string _first_near_lat_title; - /** - * @brief first_near_lat - */ - std::string _first_near_lat; - /** - * @brief first_near_lat_units - */ - std::string _first_near_lat_units; - /** - * @brief first_near_long_title - */ - std::string _first_near_long_title; - /** - * @brief first_near_long - */ - std::string _first_near_long; - /** - * @brief first_near_long_units - */ - std::string _first_near_long_units; - /** - * @brief first_mid_lat_title - */ - std::string _first_mid_lat_title; - /** - * @brief first_mid_lat - */ - std::string _first_mid_lat; - /** - * @brief first_mid_lat_units - */ - std::string _first_mid_lat_units; - /** - * @brief first_mid_long_title - */ - std::string _first_mid_long_title; - /** - * @brief first_mid_long - */ - std::string _first_mid_long; - /** - * @brief first_mid_long_units - */ - std::string _first_mid_long_units; - /** - * @brief first_far_lat_title - */ - std::string _first_far_lat_title; - /** - * @brief first_far_lat - */ - std::string _first_far_lat; - /** - * @brief first_far_lat_units - */ - std::string _first_far_lat_units; - /** - * @brief first_far_long_title - */ - std::string _first_far_long_title; - /** - * @brief first_far_long - */ - std::string _first_far_long; - /** - * @brief first_far_long_units - */ - std::string _first_far_long_units; - /** - * @brief last_near_lat_title - */ - std::string _last_near_lat_title; - /** - * @brief last_near_lat - */ - std::string _last_near_lat; - /** - * @brief last_near_lat_units - */ - std::string _last_near_lat_units; - /** - * @brief last_near_long_title - */ - std::string _last_near_long_title; - /** - * @brief last_near_long - */ - std::string _last_near_long; - /** - * @brief last_near_long_units - */ - std::string _last_near_long_units; - /** - * @brief last_mid_lat_title - */ - std::string _last_mid_lat_title; - /** - * @brief last_mid_lat - */ - std::string _last_mid_lat; - /** - * @brief last_mid_lat_units - */ - std::string _last_mid_lat_units; - /** - * @brief last_mid_long_title - */ - std::string _last_mid_long_title; - /** - * @brief last_mid_long - */ - std::string _last_mid_long; - /** - * @brief last_mid_long_units - */ - std::string _last_mid_long_units; - /** - * @brief last_far_lat_title - */ - std::string _last_far_lat_title; - /** - * @brief last_far_lat - */ - std::string _last_far_lat; - /** - * @brief last_far_lat_units - */ - std::string _last_far_lat_units; - /** - * @brief last_far_long_title - */ - std::string _last_far_long_title; - /** - * @brief last_far_long - */ - std::string _last_far_long; - /** - * @brief last_far_long_units - */ - std::string _last_far_long_units; - /** - * @brief swath_title - */ - std::string _swath_title; - /** - * @brief swath - */ - std::string _swath; - /** - * @brief pass_title - */ - std::string _pass_title; - /** - * @brief pass - */ - std::string _pass; - /** - * @brief sample_type_title - */ - std::string _sample_type_title; - /** - * @brief sample_type - */ - std::string _sample_type; - /** - * @brief algo_title - */ - std::string _algo_title; - /** - * @brief algorithm - */ - std::string _algorithm; - /** - * @brief mds1_tx_rx_polar_title - */ - std::string _mds1_tx_rx_polar_title; - /** - * @brief mds1_tx_rx_polar - */ - std::string _mds1_tx_rx_polar; - /** - * @brief mds2_tx_rx_polar_title - */ - std::string _mds2_tx_rx_polar_title; - /** - * @brief mds2_tx_rx_polar - */ - std::string _mds2_tx_rx_polar; - /** - * @brief compression_title - */ - std::string _compression_title; - /** - * @brief compression - */ - std::string _compression; - /** - * @brief azimut_looks_title - */ - std::string _azimut_looks_title; - /** - * @brief azimut_looks - */ - std::string _azimut_looks; - /** - * @brief range_looks_title - */ - std::string _range_looks_title; - /** - * @brief range_looks - */ - std::string _range_looks; - /** - * @brief range_spacing_title - */ - std::string _range_spacing_title; - /** - * @brief range_spacing - */ - std::string _range_spacing; - /** - * @brief range_spacing_unit - */ - std::string _range_spacing_unit; - /** - * @brief azimut_spacing_title - */ - std::string _azimut_spacing_title; - /** - * @brief azimut_spacing - */ - std::string _azimut_spacing; - /** - * @brief azimut_spacing_unit - */ - std::string _azimut_spacing_unit; - /** - * @brief line_time_interval_title - */ - std::string _line_time_interval_title; - /** - * @brief line_time_interval - */ - std::string _line_time_interval; - /** - * @brief line_time_interv_units - */ - std::string _line_time_interv_units; - /** - * @brief line_length_title - */ - std::string _line_length_title; - /** - * @brief line_length - */ - std::string _line_length; - /** - * @brief line_length_units - */ - std::string _line_length_units; - /** - * @brief data_type_title - */ - std::string _data_type_title; - /** - * @brief data_type - */ - std::string _data_type; - /** - * @brief DSD records - */ - std::vector<dsd> _dsd_vector; - -private: - -}; - -#endif \ No newline at end of file diff --git a/Utilities/otbossim/include/ossim/imaging/RadarSat/Data/Data.h b/Utilities/otbossim/include/ossim/imaging/RadarSat/Data/Data.h deleted file mode 100644 index 0955a9fa41b5a5259544e908949cfb00dc05802f..0000000000000000000000000000000000000000 --- a/Utilities/otbossim/include/ossim/imaging/RadarSat/Data/Data.h +++ /dev/null @@ -1,73 +0,0 @@ -#ifndef Data_h -#define Data_h - -#include <iostream> -#include <map> -#include <ossim/imaging/RadarSat/RadarSatRecord.h> - -class ImageOptionsFileDescriptor; -class ProcessedDataRecord; - -/** - * @ingroup DataFile - * @brief This class is able to read the data file of the RadarSat file structure - * @author Magellium, Pacome Dentraygues - * @version 1.0 - * @date 23-11-07 - */ -class Data -{ -public: - /** - * @brief Constructor - */ - Data(); - - /** - * @brief Destructor - */ - ~Data(); - - /** - * @brief This function writes the Data in a stream - */ - friend std::ostream& operator<<(std::ostream& os, const Data& data); - - /** - * @brief This function reads a Data from a stream - */ - friend std::istream& operator>>(std::istream& is, Data& data); - - /** - * @brief Copy constructor - */ - Data(const Data& rhs); - - /** - * @brief Copy operator - */ - Data& operator=(const Data& rhs); - - /** - * @brief Removes all the previous records from the Data - */ - void ClearRecords(); - - /** - * @brief Inserts an existing record in the Data - */ - void InsertRecord(int id, RadarSatRecord* record); - - ImageOptionsFileDescriptor* get_ImageOptionsFileDescriptor(); - ProcessedDataRecord* get_FirstProcessedDataRecord(); - ProcessedDataRecord* get_LastProcessedDataRecord(); -protected: - std::map<int, RadarSatRecord*> _records; - static const int ImageOptionsFileDescriptorID; - static const int FirstProcessedDataRecordID; - static const int LastProcessedDataRecordID; -private: - -}; - -#endif \ No newline at end of file diff --git a/Utilities/otbossim/include/ossim/imaging/RadarSat/Data/DataFactory.h b/Utilities/otbossim/include/ossim/imaging/RadarSat/Data/DataFactory.h deleted file mode 100644 index 0204405d3f031963fcdad9180daae4c3be2d87c1..0000000000000000000000000000000000000000 --- a/Utilities/otbossim/include/ossim/imaging/RadarSat/Data/DataFactory.h +++ /dev/null @@ -1,29 +0,0 @@ -#ifndef DataFactory_h -#define DataFactory_h - -#include <ossim/imaging/RadarSat/RadarSatRecordFactory.h> -#include <map> -/** - * @ingroup DataFile - * @brief This class is a factory able to construct Record base classes - * @author Magellium, Pacome Dentraygues - * @version 1.0 - * @date 03-12-07 - */ -class DataFactory : public RadarSatRecordFactory -{ -public: - /** - * @brief Contstructor - */ - DataFactory(); - /** - * @brief Destructor - */ - ~DataFactory(); - -protected: -private: -}; - -#endif \ No newline at end of file diff --git a/Utilities/otbossim/include/ossim/imaging/RadarSat/Data/ImageOptionsFileDescriptor.h b/Utilities/otbossim/include/ossim/imaging/RadarSat/Data/ImageOptionsFileDescriptor.h deleted file mode 100644 index ee1d7ea6158cb2e92160dd061d0348fbb0d068dd..0000000000000000000000000000000000000000 --- a/Utilities/otbossim/include/ossim/imaging/RadarSat/Data/ImageOptionsFileDescriptor.h +++ /dev/null @@ -1,645 +0,0 @@ -#ifndef ImageOptionsFileDescriptor_h -#define ImageOptionsFileDescriptor_h - -#include <iostream> - -#include <ossim/imaging/RadarSat/RadarSatRecord.h> -#include <ossim/imaging/RadarSat/RadarSatRecordHeader.h> - -/** - * @ingroup ImageOptionsFileDescriptionRecord - * @brief This class is able to read an Image options file descriptor record - * @author Magellium, Pacome Dentraygues - * @version 1.0 - * @date 03-12-07 - */ -class ImageOptionsFileDescriptor : public RadarSatRecord -{ -public: - /** - * @brief Constructor - */ - ImageOptionsFileDescriptor(); - - /** - * @brief Destructor - */ - ~ImageOptionsFileDescriptor(); - - /** - * @brief Copy constructor - */ - ImageOptionsFileDescriptor(const ImageOptionsFileDescriptor& rhs); - - /** - * @brief Copy operator - */ - ImageOptionsFileDescriptor& operator=(const ImageOptionsFileDescriptor& rhs); - /** - * @brief This function writes the ImageOptionsFileDescriptor in a stream - */ - friend std::ostream& operator<<(std::ostream& os, const ImageOptionsFileDescriptor& data); - - /** - * @brief This function reads a ImageOptionsFileDescriptor from a stream - */ - friend std::istream& operator>>(std::istream& is, ImageOptionsFileDescriptor& data); - - /** - * @brief This function is able to create a new instance of the class - */ - RadarSatRecord* Instanciate() - { - return new ImageOptionsFileDescriptor(); - }; - - /** - * @brief This function is able to create a new instance of the class initialised with the data of the calling instance - */ - RadarSatRecord* Clone() - { - return new ImageOptionsFileDescriptor(*this); - }; - - /** - * @brief Reads the class data from a stream - */ - void Read(std::istream& is) - { - is>>*this; - }; - - /** - * @brief Writes the class to a stream - */ - void Write(std::ostream& os) - { - os<<*this; - }; - /** - * @brief ASCII flag - */ - std::string get_ascii_flag() - { - return _ascii_flag; - }; - - /** - * @brief Format control document - */ - std::string get_format_doc() - { - return _format_doc; - }; - /** - * @brief Format document revision - */ - std::string get_format_rev() - { - return _format_rev; - }; - /** - * @brief File design revision - */ - std::string get_design_rev() - { - return _design_rev; - }; - /** - * @brief Software identifier - */ - std::string get_software_id() - { - return _software_id; - }; - /** - * @brief File number - */ - int get_file_num() - { - return _file_num; - }; - /** - * @brief File name - */ - std::string get_file_name() - { - return _file_name; - }; - /** - * @brief Record sequence/location flag - */ - std::string get_rec_seq() - { - return _rec_seq; - }; - /** - * @brief Sequence number location - */ - int get_seq_loc() - { - return _seq_loc; - }; - /** - * @brief Sequence number length - */ - int get_seq_len() - { - return _seq_len; - }; - /** - * @brief Record code/location flag - */ - std::string get_rec_code() - { - return _rec_code; - }; - /** - * @brief Record code location - */ - int get_code_loc() - { - return _code_loc; - }; - /** - * @brief Record code length - */ - int get_code_len() - { - return _code_len; - }; - /** - * @brief Record length/location flag - */ - std::string get_rec_len() - { - return _rec_len; - }; - /** - * @brief Record length location - */ - int get_rlen_loc() - { - return _rlen_loc; - }; - /** - * @brief Record length length - */ - int get_rlen_len() - { - return _rlen_len; - }; - - /** - * @brief Number of SAR data records - */ - int get_n_dataset() - { - return _n_dataset; - }; - /** - * @brief SAR data record length - */ - int get_l_dataset() - { - return _l_dataset; - }; - - /** - * @brief Number of bits per sample - */ - int get_nbit() - { - return _nbit; - }; - /** - * @brief Samples per data group - */ - int get_nsamp() - { - return _nsamp; - }; - /** - * @brief Bytes per data group - */ - int get_nbyte() - { - return _nbyte; - }; - /** - * @brief Sample justification and order - */ - std::string get_justify() - { - return _justify; - }; - /** - * @brief Number of SAR channels - */ - int get_nchn() - { - return _nchn; - }; - /** - * @brief Lines per data set - */ - int get_nlin() - { - return _nlin; - }; - /** - * @brief Left border pixels per line - */ - int get_nleft() - { - return _nleft; - }; - /** - * @brief Groups per line per channel - */ - int get_ngrp() - { - return _ngrp; - }; - /** - * @brief Right border pixels per line - */ - int get_nright() - { - return _nright; - }; - /** - * @brief Top border lines - */ - int get_ntop() - { - return _ntop; - }; - /** - * @brief Bottom border lines - */ - int get_nbott() - { - return _nbott; - }; - /** - * @brief Interleave indicator - */ - std::string get_intleav() - { - return _intleav; - }; - /** - * @brief Number of physical records per line - */ - int get_nrec_lin() - { - return _nrec_lin; - }; - /** - * @brief Number of physical records per multi-channel line in this file - */ - int get_nrec_chn() - { - return _nrec_chn; - }; - /** - * @brief Number of bytes of prefix data per record - */ - int get_n_prefix() - { - return _n_prefix; - }; - /** - * @brief Number of bytes of SAR data (or pixel data) per record - */ - int get_n_sar() - { - return _n_sar; - }; - /** - * @brief Number of bytes of suffix data per record - */ - int get_n_suffix() - { - return _n_suffix; - }; - - /** - * @brief Line number locator - */ - std::string get_lin_loc() - { - return _lin_loc; - }; - /** - * @brief Channel number locator - */ - std::string get_chn_loc() - { - return _chn_loc; - }; - /** - * @brief Time locator - */ - std::string get_tim_loc() - { - return _tim_loc; - }; - /** - * @brief Left fill locator - */ - std::string get_left_loc() - { - return _left_loc; - }; - /** - * @brief Right fill locator - */ - std::string get_right_loc() - { - return _right_loc; - }; - /** - * @brief Pad pixel indicator - */ - std::string get_pad_ind() - { - return _pad_ind; - }; - - /** - * @brief Quality code locator - */ - std::string get_qual_loc() - { - return _qual_loc; - }; - /** - * @brief Calibration info locator - */ - std::string get_cali_loc() - { - return _cali_loc; - }; - /** - * @brief Gain value locator - */ - std::string get_gain_loc() - { - return _gain_loc; - }; - /** - * @brief Bias value locator - */ - std::string get_bias_loc() - { - return _bias_loc; - }; - /** - * @brief Data type identifier - */ - std::string get_type_id() - { - return _type_id; - }; - /** - * @brief Data type code - */ - std::string get_type_code() - { - return _type_code; - }; - /** - * @brief Number of left fill bits - */ - int get_left_fill() - { - return _left_fill; - }; - /** - * @brief Number of right fill bits - */ - int get_right_fill() - { - return _right_fill; - }; - /** - * @brief Maximum data range of pixel - */ - int get_pix_rng() - { - return _pix_rng; - }; - -protected: - /** - * @brief ASCII flag - */ - std::string _ascii_flag; - - /** - * @brief Format control document - */ - std::string _format_doc; - /** - * @brief Format document revision - */ - std::string _format_rev; - /** - * @brief File design revision - */ - std::string _design_rev; - /** - * @brief Software identifier - */ - std::string _software_id; - /** - * @brief File number - */ - int _file_num; - /** - * @brief File name - */ - std::string _file_name; - /** - * @brief Record sequence/location flag - */ - std::string _rec_seq; - /** - * @brief Sequence number location - */ - int _seq_loc; - /** - * @brief Sequence number length - */ - int _seq_len; - /** - * @brief Record code/location flag - */ - std::string _rec_code; - /** - * @brief Record code location - */ - int _code_loc; - /** - * @brief Record code length - */ - int _code_len; - /** - * @brief Record length/location flag - */ - std::string _rec_len; - /** - * @brief Record length location - */ - int _rlen_loc; - /** - * @brief Record length length - */ - int _rlen_len; - - - /** - * @brief Number of SAR data records - */ - int _n_dataset; - /** - * @brief SAR data record length - */ - int _l_dataset; - - /** - * @brief Number of bits per sample - */ - int _nbit; - /** - * @brief Samples per data group - */ - int _nsamp; - /** - * @brief Bytes per data group - */ - int _nbyte; - /** - * @brief Sample justification and order - */ - std::string _justify; - /** - * @brief Number of SAR channels - */ - int _nchn; - /** - * @brief Lines per data set - */ - int _nlin; - /** - * @brief Left border pixels per line - */ - int _nleft; - /** - * @brief Groups per line per channel - */ - int _ngrp; - /** - * @brief Right border pixels per line - */ - int _nright; - /** - * @brief Top border lines - */ - int _ntop; - /** - * @brief Bottom border lines - */ - int _nbott; - /** - * @brief Interleave indicator - */ - std::string _intleav; - /** - * @brief Number of physical records per line - */ - int _nrec_lin; - /** - * @brief Number of physical records per multi-channel line in this file - */ - int _nrec_chn; - /** - * @brief Number of bytes of prefix data per record - */ - int _n_prefix; - /** - * @brief Number of bytes of SAR data (or pixel data) per record - */ - int _n_sar; - /** - * @brief Number of bytes of suffix data per record - */ - int _n_suffix; - - /** - * @brief Line number locator - */ - std::string _lin_loc; - /** - * @brief Channel number locator - */ - std::string _chn_loc; - /** - * @brief Time locator - */ - std::string _tim_loc; - /** - * @brief Left fill locator - */ - std::string _left_loc; - /** - * @brief Right fill locator - */ - std::string _right_loc; - /** - * @brief Pad pixel indicator - */ - std::string _pad_ind; - - /** - * @brief Quality code locator - */ - std::string _qual_loc; - /** - * @brief Calibration info locator - */ - std::string _cali_loc; - /** - * @brief Gain value locator - */ - std::string _gain_loc; - /** - * @brief Bias value locator - */ - std::string _bias_loc; - /** - * @brief Data type identifier - */ - std::string _type_id; - /** - * @brief Data type code - */ - std::string _type_code; - /** - * @brief Number of left fill bits - */ - int _left_fill; - /** - * @brief Number of right fill bits - */ - int _right_fill; - /** - * @brief Maximum data range of pixel - */ - int _pix_rng; - -private: -}; -#endif diff --git a/Utilities/otbossim/include/ossim/imaging/RadarSat/Data/ProcessedDataRecord.h b/Utilities/otbossim/include/ossim/imaging/RadarSat/Data/ProcessedDataRecord.h deleted file mode 100644 index 58e65c1b822699c2b66e53f0c06ee876f2fd10f9..0000000000000000000000000000000000000000 --- a/Utilities/otbossim/include/ossim/imaging/RadarSat/Data/ProcessedDataRecord.h +++ /dev/null @@ -1,408 +0,0 @@ -#ifndef ProcessedDataRecord_h -#define ProcessedDataRecord_h - -#include <iostream> - -#include <ossim/imaging/RadarSat/RadarSatRecord.h> -#include <ossim/imaging/RadarSat/RadarSatRecordHeader.h> -#include <ossim/base/ossimCommon.h> - -/** - * @ingroup ProcessedDataRecord - * @brief This class is able to read an Processed Data Record - * @author Magellium, Vincent Martin - * @version 1.0 - * @date 03-28-08 - */ -class ProcessedDataRecord : public RadarSatRecord -{ -public: - /** - * @brief Constructor - */ - ProcessedDataRecord(); - - /** - * @brief Destructor - */ - ~ProcessedDataRecord(); - - /** - * @brief Copy constructor - */ - ProcessedDataRecord(const ProcessedDataRecord& rhs); - - /** - * @brief Copy operator - */ - ProcessedDataRecord& operator=(const ProcessedDataRecord& rhs); - /** - * @brief This function writes the ProcessedDataRecord in a stream - */ - friend std::ostream& operator<<(std::ostream& os, const ProcessedDataRecord& data); - - /** - * @brief This function reads a ProcessedDataRecord from a stream - */ - friend std::istream& operator>>(std::istream& is, ProcessedDataRecord& data); - - /** - * @brief This function is able to create a new instance of the class - */ - RadarSatRecord* Instanciate() - { - return new ProcessedDataRecord(); - }; - - /** - * @brief This function is able to create a new instance of the class initialised with the data of the calling instance - */ - RadarSatRecord* Clone() - { - return new ProcessedDataRecord(*this); - }; - - /** - * @brief Reads the class data from a stream - */ - void Read(std::istream& is) - { - is>>*this; - }; - - /** - * @brief Writes the class to a stream - */ - void Write(std::ostream& os) - { - os<<*this; - }; - /** - * @brief Image data line number - */ - int get_line_num() {return _line_num;}; - - /** - * @brief Image data record index - */ - int get_rec_num() {return _rec_num;}; - /** - * @brief Left fill pixel count - */ - int get_n_left_pixel() {return _n_left_pixel;}; - /** - * @brief Data pixel count - */ - int get_n_data_pixel() {return _n_data_pixel;}; - /** - * @brief Right fill pixel count - */ - int get_n_right_pixel() {return _n_right_pixel;}; - /** - * @brief Sensor parameter update flag - */ - int get_sensor_updf() {return _sensor_updf;}; - /** - * @brief Acquisition year - */ - int get_acq_year() {return _acq_year;}; - /** - * @brief Acquisition day - */ - int get_acq_day() {return _acq_day;}; - /** - * @brief Acquisition msecs - */ - int get_acq_msec() {return _acq_msec;}; - /** - * @brief SAR channel indicator - */ - int get_sar_chan_ind() {return _sar_chan_ind;}; - /** - * @brief SAR channel code - */ - int get_sar_chan_code() {return _sar_chan_code;}; - /** - * @brief Transmitted polarization - */ - int get_tran_polar() {return _tran_polar;}; - /** - * @brief Received polarization - */ - int get_recv_polar() {return _recv_polar;}; - /** - * @brief PRF - */ - int get_prf() {return _prf;}; - /** - * @brief Slant range to first pixel, m - */ - int get_sr_first() {return _sr_first;}; - /** - * @brief Slant range to mid-pixel, m - */ - int get_sr_mid() {return _sr_mid;}; - /** - * @brief Slant range to last pixel, m - */ - int get_sr_last() {return _sr_last;}; - /** - * @brief First pixel Doppler centroid, Hz - */ - int get_fdc_first() {return _fdc_first;}; - /** - * @brief Mid pixel Doppler centroid, Hz - */ - int get_fdc_mid() {return _fdc_mid;}; - /** - * @brief Last pixel Doppler centroid, Hz - */ - int get_fdc_last() {return _fdc_last;}; - /** - * @brief First pixel azimuth FM rate, Hz - */ - int get_ka_first() {return _ka_first;}; - /** - * @brief Mid pixel azimuth FM rate, Hz - */ - int get_ka_mid() {return _ka_mid;}; - /** - * @brief Last pixel azimuth FM rate, Hz - */ - int get_ka_last() {return _ka_last;}; - /** - * @brief Nadir look angle, 10e-6 deg - */ - int get_nadir_ang() {return _nadir_ang;}; - /** - * @brief Azimuth squint angle, 10e-6 deg - */ - int get_squint_ang() {return _squint_ang;}; - /** - * @brief Geographic ref parameter update flag - */ - int get_geo_updf() {return _geo_updf;}; - /** - * @brief First pixel latitude, 10e-6 deg - */ - int get_lat_first() {return _lat_first;}; - /** - * @brief Mid-pixel latitude, 10e-6 deg - */ - int get_lat_mid() {return _lat_mid;}; - /** - * @brief Last-pixel latitude, 10e-6 deg - */ - int get_lat_last() {return _lat_last;}; - /** - * @brief First pixel longitude, 10e-6 deg - */ - int get_lon_first() {return _lon_first;}; - /** - * @brief Mid-pixel longitude, 10e-6 deg - */ - int get_lon_mid() {return _lon_mid;}; - /** - * @brief Last-pixel longitude, 10e-6 deg - */ - int get_lon_last() {return _lon_last;}; - /** - * @brief Northing of first pixel, m - */ - int get_north_first() {return _north_first;}; - /** - * @brief Northing of last pixel, m - */ - int get_north_last() {return _north_last;}; - /** - * @brief Easting of first pixel, m - */ - int get_east_first() {return _east_first;}; - /** - * @brief Easting of last pixel, m - */ - int get_east_last() {return _east_last;}; - /** - * @brief Line heading, 10e-6 deg - */ - int get_heading() {return _heading;}; - -protected: - /** - * @brief Image data line number - */ - int _line_num; - - /** - * @brief Image data record index - */ - int _rec_num; - /** - * @brief Left fill pixel count - */ - int _n_left_pixel; - /** - * @brief Data pixel count - */ - int _n_data_pixel; - /** - * @brief Right fill pixel count - */ - int _n_right_pixel; - /** - * @brief Sensor parameter update flag - */ - int _sensor_updf; - /** - * @brief Acquisition year - */ - int _acq_year; - /** - * @brief Acquisition day - */ - int _acq_day; - /** - * @brief Acquisition msecs - */ - int _acq_msec; - /** - * @brief SAR channel indicator - */ - int _sar_chan_ind; - /** - * @brief SAR channel code - */ - int _sar_chan_code; - /** - * @brief Transmitted polarization - */ - int _tran_polar; - /** - * @brief Received polarization - */ - int _recv_polar; - /** - * @brief PRF - */ - int _prf; - /** - * @brief Slant range to first pixel, m - */ - int _sr_first; - /** - * @brief Slant range to mid-pixel, m - */ - int _sr_mid; - - /** - * @brief Slant range to last pixel, m - */ - int _sr_last; - /** - * @brief First pixel Doppler centroid, Hz - */ - int _fdc_first; - - /** - * @brief Mid pixel Doppler centroid, Hz - */ - int _fdc_mid; - /** - * @brief Last pixel Doppler centroid, Hz - */ - int _fdc_last; - /** - * @brief First pixel azimuth FM rate, Hz - */ - int _ka_first; - /** - * @brief Mid pixel azimuth FM rate, Hz - */ - int _ka_mid; - /** - * @brief Last pixel azimuth FM rate, Hz - */ - int _ka_last; - /** - * @brief Nadir look angle, 10e-6 deg - */ - int _nadir_ang; - /** - * @brief Azimuth squint angle, 10e-6 deg - */ - int _squint_ang; - /** - * @brief Geographic ref parameter update flag - */ - int _geo_updf; - /** - * @brief First pixel latitude, 10e-6 deg - */ - int _lat_first; - /** - * @brief Mid-pixel latitude, 10e-6 deg - */ - int _lat_mid; - /** - * @brief Last-pixel latitude, 10e-6 deg - */ - int _lat_last; - /** - * @brief First pixel longitude, 10e-6 deg - */ - int _lon_first; - /** - * @brief Mid-pixel longitude, 10e-6 deg - */ - int _lon_mid; - /** - * @brief Last-pixel longitude, 10e-6 deg - */ - int _lon_last; - /** - * @brief Northing of first pixel, m - */ - int _north_first; - /** - * @brief Northing of last pixel, m - */ - int _north_last; - /** - * @brief Easting of first pixel, m - */ - int _east_first; - /** - * @brief Easting of last pixel, m - */ - int _east_last; - /** - * @brief Line heading, 10e-6 deg - */ - int _heading; - -private: - /** - * @brief This function switches the LSB value and the MSB value of the parameter - */ - template<typename T> - void SwitchEndian(T &value) { - - char *buffer; - char *res; - int nb_octets = sizeof(T); - - if (ossim::byteOrder() == OSSIM_LITTLE_ENDIAN) { - buffer = (char* )malloc(nb_octets); - res = (char* )malloc(nb_octets); - - memcpy(buffer,&value,nb_octets); - - for (int i=0; i<nb_octets/2; i++) { - res[i] = buffer[nb_octets-1-i]; - res[nb_octets-1-i] = buffer[i]; - } - memcpy(&value,res,nb_octets); - } - } -}; -#endif diff --git a/Utilities/otbossim/include/ossim/imaging/RadarSat/Leader/AttitudeData.h b/Utilities/otbossim/include/ossim/imaging/RadarSat/Leader/AttitudeData.h deleted file mode 100644 index f3a152ed3b61036bc12cbbf880c5279a73697f20..0000000000000000000000000000000000000000 --- a/Utilities/otbossim/include/ossim/imaging/RadarSat/Leader/AttitudeData.h +++ /dev/null @@ -1,143 +0,0 @@ -#ifndef AttitudeData_h -#define AttitudeData_h - -#include <iostream> - -#include <ossim/imaging/RadarSat/RadarSatRecord.h> -#include <ossim/imaging/RadarSat/RadarSatRecordHeader.h> - -#include <ossim/imaging/RadarSat/Leader/DataPointDataRecord.h> -/** - * @ingroup AttitudeDataRecord - * @brief This class is able to read a Attitude data record - * @author Magellium, Pacome Dentraygues - * @version 1.0 - * @date 02-12-07 - */ -class AttitudeData : public RadarSatRecord -{ -public: - /** - * @brief Constructor - */ - AttitudeData(); - - /** - * @brief Destructor - */ - ~AttitudeData(); - - /** - * @brief Copy constructor - */ - AttitudeData(const AttitudeData& rhs); - - /** - * @brief Copy operator - */ - AttitudeData& operator=(const AttitudeData& rhs); - /** - * @brief This function writes the AttitudeData in a stream - */ - friend std::ostream& operator<<(std::ostream& os, const AttitudeData& data); - - /** - * @brief This function reads a AttitudeData from a stream - */ - friend std::istream& operator>>(std::istream& is, AttitudeData& data); - - /** - * @brief This function is able to create a new instance of the class - */ - RadarSatRecord* Instanciate() - { - return new AttitudeData(); - }; - - /** - * @brief This function is able to create a new instance of the class initialised with the data of the calling instance - */ - RadarSatRecord* Clone() - { - return new AttitudeData(*this); - }; - - /** - * @brief Reads the class data from a stream - */ - void Read(std::istream& is) - { - is>>*this; - }; - - /** - * @brief Writes the class to a stream - */ - void Write(std::ostream& os) - { - os<<*this; - }; - - /** - * @brief Number of data points - */ - int get_npoint() - { - return _npoint; - }; - /** - * @brief Data points - */ - DataPointDataRecord* get_att_vect() - { - return _att_vect; - }; - /** - * @brief Pitch bias (degrees) - */ - double get_pitch_bias() - { - return _pitch_bias; - }; - /** - * @brief Roll bias (degrees) - */ - double get_roll_bias() - { - return _roll_bias; - }; - /** - * @brief Yaw bias (degrees) - */ - double get_yaw_bias() - { - return _yaw_bias; - }; - - -protected: - /** - * @brief Number of data points - */ - int _npoint; - /** - * @brief Data points - */ - DataPointDataRecord _att_vect[20]; - /** - * @brief Pitch bias (degrees) - */ - double _pitch_bias; - /** - * @brief Roll bias (degrees) - */ - double _roll_bias; - /** - * @brief Yaw bias (degrees) - */ - double _yaw_bias; - - -private: -}; -#endif diff --git a/Utilities/otbossim/include/ossim/imaging/RadarSat/Leader/BeamInformationRecord.h b/Utilities/otbossim/include/ossim/imaging/RadarSat/Leader/BeamInformationRecord.h deleted file mode 100644 index 97f8a3f3ef1d8afc8d5ad8c7bd9735e9f6008824..0000000000000000000000000000000000000000 --- a/Utilities/otbossim/include/ossim/imaging/RadarSat/Leader/BeamInformationRecord.h +++ /dev/null @@ -1,103 +0,0 @@ -#ifndef BeamInformationRecord_h -#define BeamInformationRecord_h - -#include <iostream> - -#include <ossim/imaging/RadarSat/RadarSatRecord.h> - -/** - * @ingroup ProcessingParametersRecord - * @brief This class is able to read a Beam information record - * @author Magellium, Pacome Dentraygues - * @version 1.0 - * @date 30-11-07 - */ -class BeamInformationRecord -{ -public: - /** - * @brief Constructor - */ - BeamInformationRecord(); - - /** - * @brief Destructor - */ - ~BeamInformationRecord(); - - /** - * @brief Copy constructor - */ - BeamInformationRecord(const BeamInformationRecord& rhs); - - /** - * @brief Copy operator - */ - BeamInformationRecord& operator=(const BeamInformationRecord& rhs); - - /** - * @brief This function writes the BeamInformationRecord in a stream - */ - friend std::ostream& operator<<(std::ostream& os, const BeamInformationRecord& data); - - /** - * @brief This function reads a BeamInformationRecord from a stream - */ - friend std::istream& operator>>(std::istream& is, BeamInformationRecord& data); - - /** - * @brief Beam type - */ - std::string get_beam_type() - { - return _beam_type; - }; - - /** - * @brief Elevation beam look angle source - */ - std::string get_beam_look_src() - { - return _beam_look_src; - }; - - /** - * @brief Applied elevation beam look angle (deg) - */ - double get_beam_look_ang() - { - return _beam_look_ang; - }; - - /** - * @brief Actual PRF (Hz) - */ - double get_prf() - { - return _prf; - }; -protected: - - /** - * @brief Beam type - */ - std::string _beam_type; - - /** - * @brief Elevation beam look angle source - */ - std::string _beam_look_src; - - /** - * @brief Applied elevation beam look angle (deg) - */ - double _beam_look_ang; - - /** - * @brief Actual PRF (Hz) - */ - double _prf; -private: - -}; -#endif \ No newline at end of file diff --git a/Utilities/otbossim/include/ossim/imaging/RadarSat/Leader/BeamPixelCountRecord.h b/Utilities/otbossim/include/ossim/imaging/RadarSat/Leader/BeamPixelCountRecord.h deleted file mode 100644 index 7fa7a976d63badf00bdce4412725df28e8935116..0000000000000000000000000000000000000000 --- a/Utilities/otbossim/include/ossim/imaging/RadarSat/Leader/BeamPixelCountRecord.h +++ /dev/null @@ -1,76 +0,0 @@ -#ifndef BeamPixelCountRecord_h -#define BeamPixelCountRecord_h - -#include <iostream> - -#include <ossim/imaging/RadarSat/RadarSatRecord.h> - -/** - * @ingroup ProcessingParametersRecord - * @brief This class is able to read a Beam pixel count record - * @author Magellium, Pacome Dentraygues - * @version 1.0 - * @date 30-11-07 - */ -class BeamPixelCountRecord -{ -public: - /** - * @brief Constructor - */ - BeamPixelCountRecord(); - - /** - * @brief Destructor - */ - ~BeamPixelCountRecord(); - - /** - * @brief Copy constructor - */ - BeamPixelCountRecord(const BeamPixelCountRecord& rhs); - - /** - * @brief Copy operator - */ - BeamPixelCountRecord& operator=(const BeamPixelCountRecord& rhs); - - /** - * @brief This function writes the BeamPixelCountRecord in a stream - */ - friend std::ostream& operator<<(std::ostream& os, const BeamPixelCountRecord& data); - - /** - * @brief This function reads a BeamPixelCountRecord from a stream - */ - friend std::istream& operator>>(std::istream& is, BeamPixelCountRecord& data); - - /** - * @brief Pixel count update date/time - */ - std::string get_pix_update() - { - return _pix_update; - }; - - /** - * @brief Count of image pixels in beams - */ - int* get_n_pix() - { - return _n_pix; - }; -protected: - - /** - * @brief Pixel count update date/time - */ - std::string _pix_update; - /** - * @brief Count of image pixels in beams - */ - int _n_pix[4]; -private: - -}; -#endif \ No newline at end of file diff --git a/Utilities/otbossim/include/ossim/imaging/RadarSat/Leader/CompensationDataRecord.h b/Utilities/otbossim/include/ossim/imaging/RadarSat/Leader/CompensationDataRecord.h deleted file mode 100644 index b28aa61e7b871fff13c86497e563430fa06d4fa0..0000000000000000000000000000000000000000 --- a/Utilities/otbossim/include/ossim/imaging/RadarSat/Leader/CompensationDataRecord.h +++ /dev/null @@ -1,151 +0,0 @@ -#ifndef CompensationDataRecord_h -#define CompensationDataRecord_h - -#include <iostream> - -#include <ossim/imaging/RadarSat/RadarSatRecord.h> -#include <ossim/imaging/RadarSat/RadarSatRecordHeader.h> - -/** - * @ingroup RadiometricCompensationDataRecord - * @brief This class is able to read a Compensation data record - * @author Magellium, Pacome Dentraygues - * @version 1.0 - * @date 03-12-07 - */ -class CompensationDataRecord -{ -public: - /** - * @brief Constructor - */ - CompensationDataRecord(); - - /** - * @brief Destructor - */ - ~CompensationDataRecord(); - - /** - * @brief Copy constructor - */ - CompensationDataRecord(const CompensationDataRecord& rhs); - - /** - * @brief Copy operator - */ - CompensationDataRecord& operator=(const CompensationDataRecord& rhs); - /** - * @brief This function writes the CompensationDataRecord in a stream - */ - friend std::ostream& operator<<(std::ostream& os, const CompensationDataRecord& data); - - /** - * @brief This function reads a CompensationDataRecord from a stream - */ - friend std::istream& operator>>(std::istream& is, CompensationDataRecord& data); - - /** - * @brief Compensation data designator - */ - std::string get_comp_desig() - { - return _comp_desig; - }; - /** - * @brief Compensation data descriptor - */ - std::string get_comp_descr() - { - return _comp_descr; - }; - /** - * @brief Number of compensation records - */ - int get_n_comp_rec() - { - return _n_comp_rec; - }; - /** - * @brief Compensation record sequence number - */ - int get_comp_seq_no() - { - return _comp_seq_no; - }; - /** - * @brief Number of beam table entries - */ - int get_beam_tab_size() - { - return _beam_tab_size; - }; - /** - * @brief Elevation gain beam profile - */ - double* get_beam_tab() - { - return _beam_tab; - }; - /** - * @brief Beam type - */ - std::string get_beam_type() - { - return _beam_type; - }; - /** - * @brief Look angle of beam table centre - */ - double get_look_angle() - { - return _look_angle; - }; - /** - * @brief Increment between beam table entries - */ - double get_beam_tab_inc() - { - return _beam_tab_inc; - }; - -protected: - /** - * @brief Compensation data designator - */ - std::string _comp_desig; - /** - * @brief Compensation data descriptor - */ - std::string _comp_descr; - /** - * @brief Number of compensation records - */ - int _n_comp_rec; - /** - * @brief Compensation record sequence number - */ - int _comp_seq_no; - /** - * @brief Number of beam table entries - */ - int _beam_tab_size; - /** - * @brief Elevation gain beam profile - */ - double _beam_tab[256]; - /** - * @brief Beam type - */ - std::string _beam_type; - /** - * @brief Look angle of beam table centre - */ - double _look_angle; - /** - * @brief Increment between beam table entries - */ - double _beam_tab_inc; -private: -}; -#endif diff --git a/Utilities/otbossim/include/ossim/imaging/RadarSat/Leader/DataHistogramProcessedData.h b/Utilities/otbossim/include/ossim/imaging/RadarSat/Leader/DataHistogramProcessedData.h deleted file mode 100644 index 7c47bb4cddc7154fa5e0b89fa9ad7bce0e83d162..0000000000000000000000000000000000000000 --- a/Utilities/otbossim/include/ossim/imaging/RadarSat/Leader/DataHistogramProcessedData.h +++ /dev/null @@ -1,161 +0,0 @@ -#ifndef DataHistogramProcessedData_h -#define DataHistogramProcessedData_h - -#include<iostream> - -#include <ossim/imaging/RadarSat/RadarSatRecord.h> -#include <ossim/imaging/RadarSat/RadarSatRecordHeader.h> -#include <ossim/imaging/RadarSat/Leader/DataHistogramRecord.h> -/** - * @ingroup ProcessedData16bitHistogramRecord - * @brief This class is able to read a data histogram record - Processed data - * @author Magellium, Pacome Dentraygues - * @version 1.0 - * @date 23-11-07 - * @warning There is an error in the documentation for the spare at the end of the record. - * They say 3 bytes (A3) but they also say that the spare is on the bytes 16917, 16918, 16919 and 16920. - * In the data files I have, I need to use a spare of 4 bytes. - */ -class DataHistogramProcessedData : public RadarSatRecord -{ -public: - /** - * @brief Constructor - */ - DataHistogramProcessedData(); - - /** - * @brief Destructor - */ - ~DataHistogramProcessedData(); - - /** - * @brief Copy constructor - */ - DataHistogramProcessedData(const DataHistogramProcessedData& rhs); - - /** - * @brief Copy operator - */ - DataHistogramProcessedData& operator=(const DataHistogramProcessedData& rhs); - /** - * @brief This function writes the DataHistogramProcessedData in a stream - */ - friend std::ostream& operator<<(std::ostream& os, const DataHistogramProcessedData& data); - - /** - * @brief This function reads a DataHistogramProcessedData from a stream - */ - friend std::istream& operator>>(std::istream& is, DataHistogramProcessedData& data); - - /** - * @brief This function is able to create a new instance of the class - */ - RadarSatRecord* Instanciate() - { - return new DataHistogramProcessedData(); - }; - - /** - * @brief This function is able to create a new instance of the class initialised with the data of the calling instance - */ - RadarSatRecord* Clone() - { - return new DataHistogramProcessedData(*this); - }; - - /** - * @brief Reads the class data from a stream - */ - void Read(std::istream& is) - { - is>>*this; - }; - - /** - * @brief Writes the class to a stream - */ - void Write(std::ostream& os) - { - os<<*this; - }; - - /** - * @brief Record sequence number - */ - int get_rec_seq() - { - return _rec_seq; - }; - /** - * @brief SAR channel indicator - */ - int get_sar_chn() - { - return _sar_chn; - }; - - /** - * @brief Number of histogram table data sets in this record - */ - int get_ntab() - { - return _ntab; - }; - - /** - * @brief Histogram table data set size - */ - int get_ltab() - { - return _ltab; - }; - - /** - * @brief Histogram data record #1 - */ - DataHistogramRecord get_histogram1() - { - return _histogram1; - }; - - /** - * @brief Histogram data record #2 - */ - DataHistogramRecord get_histogram2() - { - return _histogram2; - }; -protected: - /** - * @brief Record sequence number - */ - int _rec_seq; - /** - * @brief SAR channel indicator - */ - int _sar_chn; - - /** - * @brief Number of histogram table data sets in this record - */ - int _ntab; - /** - * @brief Histogram table data set size - */ - int _ltab; - /** - * @brief Histogram data record #1 - */ - DataHistogramRecord _histogram1; - /** - * @brief Histogram data record #2 - */ - DataHistogramRecord _histogram2; - -private: - - -}; - -#endif \ No newline at end of file diff --git a/Utilities/otbossim/include/ossim/imaging/RadarSat/Leader/DataHistogramRecord.h b/Utilities/otbossim/include/ossim/imaging/RadarSat/Leader/DataHistogramRecord.h deleted file mode 100644 index 6335a580319030c2e5c8492e3d88e857d9ce6528..0000000000000000000000000000000000000000 --- a/Utilities/otbossim/include/ossim/imaging/RadarSat/Leader/DataHistogramRecord.h +++ /dev/null @@ -1,291 +0,0 @@ -#ifndef DataHistogramRecord_h -#define DataHistogramRecord_h - -#include<iostream> - -#include <ossim/imaging/RadarSat/RadarSatRecord.h> -#include <ossim/imaging/RadarSat/RadarSatRecordHeader.h> -/** - * @ingroup ProcessedData16bitHistogramRecord - * @ingroup SignalDataHistogramRecord - * @brief This class is able to read a data histogram record - * @author Magellium, Pacome Dentraygues - * @version 1.0 - * @date 23-11-07 - */ -class DataHistogramRecord -{ -public: - /** - * @brief Constructor - */ - DataHistogramRecord(); - - /** - * @brief Destructor - */ - ~DataHistogramRecord(); - - /** - * @brief Copy constructor - */ - DataHistogramRecord(const DataHistogramRecord& rhs); - - /** - * @brief Copy operator - */ - DataHistogramRecord& operator=(const DataHistogramRecord& rhs); - - /** - * @brief This function writes the DataHistogramRecord in a stream - */ - friend std::ostream& operator<<(std::ostream& os, const DataHistogramRecord& data); - - /** - * @brief This function reads a DataHistogramRecord from a stream - */ - friend std::istream& operator>>(std::istream& is, DataHistogramRecord& data); - - - - /** - * @brief Histogram descriptor - */ - std::string get_hist_desc() - { - return _hist_desc; - }; - /** - * @brief Records per table - */ - int get_nrec() - { - return _nrec; - }; - /** - * @brief Table sequence number - */ - int get_tab_seq() - { - return _tab_seq; - }; - /** - * @brief Total number of table bins - */ - int get_nbin() - { - return _nbin; - }; - /** - * @brief Total number of lines - */ - int get_ns_lin() - { - return _ns_lin; - }; - /** - * @brief Total number of pixels per line - */ - int get_ns_pix() - { - return _ns_pix; - }; - /** - * @brief Group size along line axis - */ - int get_ngrp_lin() - { - return _ngrp_lin; - }; - /** - * @brief Group size along pixel axis - */ - int get_ngrp_pix() - { - return _ngrp_pix; - }; - /** - * @brief Number of samples used per group along line axis - */ - int get_nsamp_lin() - { - return _nsamp_lin; - }; - /** - * @brief Number of samples used per group along pixel - */ - int get_nsamp_pix() - { - return _nsamp_pix; - }; - /** - * @brief Minimum first bin - */ - double get_min_smp() - { - return _min_smp; - }; - /** - * @brief Maximum last bin - */ - double get_max_smp() - { - return _max_smp; - }; - /** - * @brief Mean sample value - */ - double get_mean_smp() - { - return _mean_smp; - }; - /** - * @brief Sample standard deviation - */ - double get_std_smp() - { - return _std_smp; - }; - /** - * @brief Sample value increment - */ - double get_smp_inc() - { - return _smp_inc; - }; - /** - * @brief Minimum histogram value - */ - double get_min_hist() - { - return _min_hist; - }; - /** - * @brief Maximum histogram value - */ - double get_max_hist() - { - return _max_hist; - }; - /** - * @brief Histogram mean value - */ - double get_mean_hist() - { - return _mean_hist; - }; - /** - * @brief Histogram standard deviation - */ - double get_std_hist() - { - return _std_hist; - }; - /** - * @brief Histogram table size - */ - int get_nhist() - { - return _nhist; - }; - - /** - * @brief Histogram table values of 16 bins for Ix16 bins for Q - */ - int* get_hist() - { - return _hist; - }; -protected: - - - /** - * @brief Histogram descriptor - */ - std::string _hist_desc; - /** - * @brief Records per table - */ - int _nrec; - /** - * @brief Table sequence number - */ - int _tab_seq; - /** - * @brief Total number of table bins - */ - int _nbin; - /** - * @brief Total number of lines - */ - int _ns_lin; - /** - * @brief Total number of pixels per line - */ - int _ns_pix; - /** - * @brief Group size along line axis - */ - int _ngrp_lin; - /** - * @brief Group size along pixel axis - */ - int _ngrp_pix; - /** - * @brief Number of samples used per group along line axis - */ - int _nsamp_lin; - /** - * @brief Number of samples used per group along pixel - */ - int _nsamp_pix; - /** - * @brief Minimum first bin - */ - double _min_smp; - /** - * @brief Maximum last bin - */ - double _max_smp; - /** - * @brief Mean sample value - */ - double _mean_smp; - /** - * @brief Sample standard deviation - */ - double _std_smp; - /** - * @brief Sample value increment - */ - double _smp_inc; - /** - * @brief Minimum histogram value - */ - double _min_hist; - /** - * @brief Maximum histogram value - */ - double _max_hist; - /** - * @brief Histogram mean value - */ - double _mean_hist; - /** - * @brief Histogram standard deviation - */ - double _std_hist; - /** - * @brief Histogram table size - */ - int _nhist; - /** - * @brief Histogram table values - */ - int* _hist; -private: - - -}; - -#endif \ No newline at end of file diff --git a/Utilities/otbossim/include/ossim/imaging/RadarSat/Leader/DataHistogramSignalData.h b/Utilities/otbossim/include/ossim/imaging/RadarSat/Leader/DataHistogramSignalData.h deleted file mode 100644 index c882e014681d06f2b8b5c9999b58e6d2799db1fa..0000000000000000000000000000000000000000 --- a/Utilities/otbossim/include/ossim/imaging/RadarSat/Leader/DataHistogramSignalData.h +++ /dev/null @@ -1,147 +0,0 @@ -#ifndef DataHistogramSignalData_h -#define DataHistogramSignalData_h - -#include <iostream> - -#include <ossim/imaging/RadarSat/RadarSatRecord.h> -#include <ossim/imaging/RadarSat/RadarSatRecordHeader.h> -#include <ossim/imaging/RadarSat/Leader/DataHistogramRecord.h> -/** - * @ingroup SignalDataHistogramRecord - * @brief This class is able to read a data histogram record - Signal data - * @author Magellium, Pacome Dentraygues - * @version 1.0 - * @date 23-11-07 - */ -class DataHistogramSignalData : public RadarSatRecord -{ -public: - /** - * @brief Constructor - */ - DataHistogramSignalData(); - - /** - * @brief Destructor - */ - ~DataHistogramSignalData(); - - /** - * @brief Copy constructor - */ - DataHistogramSignalData(const DataHistogramSignalData& rhs); - - /** - * @brief Copy operator - */ - DataHistogramSignalData& operator=(const DataHistogramSignalData& rhs); - /** - * @brief This function writes the DataHistogramSignalData in a stream - */ - friend std::ostream& operator<<(std::ostream& os, const DataHistogramSignalData& data); - - /** - * @brief This function reads a DataHistogramSignalData from a stream - */ - friend std::istream& operator>>(std::istream& is, DataHistogramSignalData& data); - - /** - * @brief This function is able to create a new instance of the class - */ - RadarSatRecord* Instanciate() - { - return new DataHistogramSignalData(); - }; - - /** - * @brief This function is able to create a new instance of the class initialised with the data of the calling instance - */ - RadarSatRecord* Clone() - { - return new DataHistogramSignalData(*this); - }; - - /** - * @brief Reads the class data from a stream - */ - void Read(std::istream& is) - { - is>>*this; - }; - - /** - * @brief Writes the class to a stream - */ - void Write(std::ostream& os) - { - os<<*this; - }; - - /** - * @brief Record sequence number - */ - int get_rec_seq() - { - return _rec_seq; - }; - /** - * @brief SAR channel indicator - */ - int get_sar_chn() - { - return _sar_chn; - }; - - /** - * @brief Number of histogram table data sets in this record - */ - int get_ntab() - { - return _ntab; - }; - - /** - * @brief Histogram table data set size - */ - int get_ltab() - { - return _ltab; - }; - - /** - * @brief Histogram data record - */ - DataHistogramRecord get_histogram() - { - return _histogram; - }; - -protected: - /** - * @brief Record sequence number - */ - int _rec_seq; - /** - * @brief SAR channel indicator - */ - int _sar_chn; - - /** - * @brief Number of histogram table data sets in this record - */ - int _ntab; - /** - * @brief Histogram table data set size - */ - int _ltab; - /** - * @brief Histogram data record - */ - DataHistogramRecord _histogram; - -private: - - -}; - -#endif \ No newline at end of file diff --git a/Utilities/otbossim/include/ossim/imaging/RadarSat/Leader/DataPointDataRecord.h b/Utilities/otbossim/include/ossim/imaging/RadarSat/Leader/DataPointDataRecord.h deleted file mode 100644 index 01f71a3c51b14d2b552a6a69976c75987a9e6af2..0000000000000000000000000000000000000000 --- a/Utilities/otbossim/include/ossim/imaging/RadarSat/Leader/DataPointDataRecord.h +++ /dev/null @@ -1,206 +0,0 @@ -#ifndef DataPointDataRecord_h -#define DataPointDataRecord_h - -#include <iostream> - -#include <ossim/imaging/RadarSat/RadarSatRecord.h> -#include <ossim/imaging/RadarSat/RadarSatRecordHeader.h> - -/** - * @ingroup AttitudeDataRecord - * @brief This class is able to read a Data point data record - * @author Magellium, Pacome Dentraygues - * @version 1.0 - * @date 02-12-07 - */ -class DataPointDataRecord -{ -public: - /** - * @brief Constructor - */ - DataPointDataRecord(); - - /** - * @brief Destructor - */ - ~DataPointDataRecord(); - - /** - * @brief Copy constructor - */ - DataPointDataRecord(const DataPointDataRecord& rhs); - - /** - * @brief Copy operator - */ - DataPointDataRecord& operator=(const DataPointDataRecord& rhs); - /** - * @brief This function writes the DataPointDataRecord in a stream - */ - friend std::ostream& operator<<(std::ostream& os, const DataPointDataRecord& data); - - /** - * @brief This function reads a DataPointDataRecord from a stream - */ - friend std::istream& operator>>(std::istream& is, DataPointDataRecord& data); - - /** - * @brief Day of the year, GMT - */ - int get_gmt_day() - { - return _gmt_day; - }; - /** - * @brief Milliseconds of day, GMT - */ - int get_gmt_sec() - { - return _gmt_sec; - }; - /** - * @brief Pitch data quality flag - */ - int get_pitch_flag() - { - return _pitch_flag; - }; - /** - * @brief Roll data quality flag - */ - int get_roll_flag() - { - return _roll_flag; - }; - /** - * @brief Yaw data quality flag - */ - int get_yaw_flag() - { - return _yaw_flag; - }; - /** - * @brief Pitch error, degrees - */ - double get_pitch() - { - return _pitch; - }; - /** - * @brief Roll error, degrees - */ - double get_roll() - { - return _roll; - }; - /** - * @brief Yaw error, degrees - */ - double get_yaw() - { - return _yaw; - }; - /** - * @brief Pitch rate data quality flag - */ - int get_pitch_rate_flag() - { - return _pitch_rate_flag; - }; - /** - * @brief Roll rate data quality fla - */ - int get_roll_rate_flag() - { - return _roll_rate_flag; - }; - /** - * @brief Yaw rate data quality flag - */ - int get_yaw_rate_flag() - { - return _yaw_rate_flag; - }; - /** - * @brief Pitch rate, degrees/sec - */ - double get_pitch_rate() - { - return _pitch_rate; - }; - /** - * @brief Roll rate, degrees/sec - */ - double get_roll_rate() - { - return _roll_rate; - }; - /** - * @brief Yaw rate, degrees/sec - */ - double get_yaw_rate() - { - return _yaw_rate; - }; - -protected: - /** - * @brief Day of the year, GMT - */ - int _gmt_day; - /** - * @brief Milliseconds of day, GMT - */ - int _gmt_sec; - /** - * @brief Pitch data quality flag - */ - int _pitch_flag; - /** - * @brief Roll data quality flag - */ - int _roll_flag; - /** - * @brief Yaw data quality flag - */ - int _yaw_flag; - /** - * @brief Pitch error, degrees - */ - double _pitch; - /** - * @brief Roll error, degrees - */ - double _roll; - /** - * @brief Yaw error, degrees - */ - double _yaw; - /** - * @brief Pitch rate data quality flag - */ - int _pitch_rate_flag; - /** - * @brief Roll rate data quality fla - */ - int _roll_rate_flag; - /** - * @brief Yaw rate data quality flag - */ - int _yaw_rate_flag; - /** - * @brief Pitch rate, degrees/sec - */ - double _pitch_rate; - /** - * @brief Roll rate, degrees/sec - */ - double _roll_rate; - /** - * @brief Yaw rate, degrees/sec - */ - double _yaw_rate; -private: -}; -#endif diff --git a/Utilities/otbossim/include/ossim/imaging/RadarSat/Leader/DataQuality.h b/Utilities/otbossim/include/ossim/imaging/RadarSat/Leader/DataQuality.h deleted file mode 100644 index dfa392f27a01d77a6d63e87807e5775122c67d59..0000000000000000000000000000000000000000 --- a/Utilities/otbossim/include/ossim/imaging/RadarSat/Leader/DataQuality.h +++ /dev/null @@ -1,389 +0,0 @@ -#ifndef DataQuality_h -#define DataQuality_h - -#include <iostream> - -#include <ossim/imaging/RadarSat/RadarSatRecord.h> -#include <ossim/imaging/RadarSat/RadarSatRecordHeader.h> - -#include <ossim/imaging/RadarSat/Leader/RadiometryUncertaintyRecord.h> -#include <ossim/imaging/RadarSat/Leader/MisregistrationRecord.h> -/** - * @ingroup DataQualitySummaryRecord - * @brief This class is able to read a data quality record - * @author Magellium, Pacome Dentraygues - * @version 1.0 - * @date 23-11-07 - */ -class DataQuality : public RadarSatRecord -{ -public: - /** - * @brief Constructor - */ - DataQuality(); - - /** - * @brief Destructor - */ - ~DataQuality(); - - /** - * @brief Copy constructor - */ - DataQuality(const DataQuality& rhs); - - /** - * @brief Copy operator - */ - DataQuality& operator=(const DataQuality& rhs); - /** - * @brief This function writes the DataQuality in a stream - */ - friend std::ostream& operator<<(std::ostream& os, const DataQuality& data); - - /** - * @brief This function reads a DataQuality from a stream - */ - friend std::istream& operator>>(std::istream& is, DataQuality& data); - - /** - * @brief This function is able to create a new instance of the class - */ - RadarSatRecord* Instanciate() - { - return new DataQuality(); - }; - - /** - * @brief This function is able to create a new instance of the class initialised with the data of the calling instance - */ - RadarSatRecord* Clone() - { - return new DataQuality(*this); - }; - - /** - * @brief Reads the class data from a stream - */ - void Read(std::istream& is) - { - is>>*this; - }; - - /** - * @brief Writes the class to a stream - */ - void Write(std::ostream& os) - { - os<<*this; - }; - - /** - * @brief Record sequence number - */ - int get_rec_seq() - { - return _rec_seq; - }; - /** - * @brief SAR channel indicator - */ - std::string get_sar_chn() - { - return _sar_chn; - }; - /** - * @brief Calibration update date - */ - std::string get_cali_date() - { - return _cali_date; - }; - /** - * @brief Number of channels - */ - int get_nchn() - { - return _nchn; - }; - /** - * @brief Nominal integrated side lobe ratio - */ - double get_islr() - { - return _islr; - }; - /** - * @brief Nominal peak side lobe ratio - */ - double get_pslr() - { - return _pslr; - }; - /** - * @brief Nominal azimuth ambiguity - */ - double get_azi_ambig() - { - return _azi_ambig; - }; - /** - * @brief Nominal range ambiguity - */ - double get_rng_ambig() - { - return _rng_ambig; - }; - /** - * @brief Nominal signal to noise ratio - */ - double get_snr() - { - return _snr; - }; - /** - * @brief Nominal bit error rate - */ - double get_ber() - { - return _ber; - }; - /** - * @brief Nominal slant range resolution - */ - double get_rng_res() - { - return _rng_res; - }; - /** - * @brief Nominal azimuth resolution,meter - */ - double get_azi_res() - { - return _azi_res; - }; - /** - * @brief Nominal radiometric resolution,dB - */ - double get_rad_res() - { - return _rad_res; - }; - /** - * @brief Instantaneous dynamic range - */ - double get_dyn_rng() - { - return _dyn_rng; - }; - /** - * @brief Nominal radiometric uncertainty,dB - */ - double get_rad_unc_db() - { - return _rad_unc_db; - }; - /** - * @brief Nominal Radiometric uncertainty,deg - */ - double get_rad_unc_deg() - { - return _rad_unc_deg; - }; - /** - * @brief Radiometric data quality - */ - RadiometryUncertaintyRecord* get_rad_unc() - { - return _rad_unc; - }; - /** - * @brief Nominal along track location error - */ - double get_alt_locerr() - { - return _alt_locerr; - }; - /** - * @brief Nominal cross track location error - */ - double get_crt_locerr() - { - return _crt_locerr; - }; - /** - * @brief Nominal along track distortion scale - */ - double get_alt_scale() - { - return _alt_scale; - }; - /** - * @brief Nominal cross track distortion scale - */ - double get_crt_scale() - { - return _crt_scale; - }; - /** - * @brief Nominal distortion skew - */ - double get_dis_skew() - { - return _dis_skew; - }; - /** - * @brief Nominal Scene orientation error - */ - double get_ori_err() - { - return _ori_err; - }; - /** - * @brief Misregistration error - */ - MisregistrationRecord* get_misreg() - { - return _misreg; - }; - /** - * @brief Nominal noise equivalent sigma zero - */ - double get_nesz() - { - return _nesz; - }; - /** - * @brief Nominal equivalent number of looks - */ - double get_enl() - { - return _enl; - }; - /** - * @brief Default parameters table update date - */ - std::string get_tb_update() - { - return _tb_update; - }; - - -protected: - - /** - * @brief Record sequence number - */ - int _rec_seq; - /** - * @brief SAR channel indicator - */ - std::string _sar_chn; - /** - * @brief Calibration update date - */ - std::string _cali_date; - /** - * @brief Number of channels - */ - int _nchn; - /** - * @brief Nominal integrated side lobe ratio - */ - double _islr; - /** - * @brief Nominal peak side lobe ratio - */ - double _pslr; - /** - * @brief Nominal azimuth ambiguity - */ - double _azi_ambig; - /** - * @brief Nominal range ambiguity - */ - double _rng_ambig; - /** - * @brief Nominal signal to noise ratio - */ - double _snr; - /** - * @brief Nominal bit error rate - */ - double _ber; - /** - * @brief Nominal slant range resolution - */ - double _rng_res; - /** - * @brief Nominal azimuth resolution,meter - */ - double _azi_res; - /** - * @brief Nominal radiometric resolution,dB - */ - double _rad_res; - /** - * @brief Instantaneous dynamic range - */ - double _dyn_rng; - /** - * @brief Nominal radiometric uncertainty,dB - */ - double _rad_unc_db; - /** - * @brief Nominal Radiometric uncertainty,deg - */ - double _rad_unc_deg; - /** - * @brief Radiometric data quality - */ - RadiometryUncertaintyRecord _rad_unc[16]; - /** - * @brief Nominal along track location error - */ - double _alt_locerr; - /** - * @brief Nominal cross track location error - */ - double _crt_locerr; - /** - * @brief Nominal along track distortion scale - */ - double _alt_scale; - /** - * @brief Nominal cross track distortion scale - */ - double _crt_scale; - /** - * @brief Nominal distortion skew - */ - double _dis_skew; - /** - * @brief Nominal Scene orientation error - */ - double _ori_err; - /** - * @brief Misregistration error - */ - MisregistrationRecord _misreg[16]; - /** - * @brief Nominal noise equivalent sigma zero - */ - double _nesz; - /** - * @brief Nominal equivalent number of looks - */ - double _enl; - /** - * @brief Default parameters table update date - */ - std::string _tb_update; - -private: - - -}; - -#endif \ No newline at end of file diff --git a/Utilities/otbossim/include/ossim/imaging/RadarSat/Leader/DataSetSummary.h b/Utilities/otbossim/include/ossim/imaging/RadarSat/Leader/DataSetSummary.h deleted file mode 100644 index 27e2f50d5e5ee5b7e0b9140fe16b497d7152049e..0000000000000000000000000000000000000000 --- a/Utilities/otbossim/include/ossim/imaging/RadarSat/Leader/DataSetSummary.h +++ /dev/null @@ -1,1064 +0,0 @@ -#ifndef DataSetSummary_h -#define DataSetSummary_h - -#include <iostream> -#include <ossim/imaging/RadarSat/RadarSatRecordHeader.h> -#include <ossim/imaging/RadarSat/RadarSatRecord.h> -/** - * @ingroup DataSetSummaryRecord - * @brief This class is able to read the SAR leader data set summary record of the leader file - * @author Magellium, Pacome Dentraygues - * @version 1.0 - * @date 23-11-07 - */ -class DataSetSummary : public RadarSatRecord -{ -public: - /** - * @brief Constructor - */ - DataSetSummary(); - - /** - * @brief Destructor - */ - ~DataSetSummary(); - - /** - * @brief This function write the DataSetSummary in a stream - */ - friend std::ostream& operator<<(std::ostream& os, const DataSetSummary& data); - - /** - * @brief This function read a DataSetSummary from a stream - */ - friend std::istream& operator>>(std::istream& is, DataSetSummary& data); - - /** - * @brief Copy constructor - */ - DataSetSummary(const DataSetSummary& rhs); - - /** - * @brief Copy operator - */ - DataSetSummary& operator=(const DataSetSummary& rhs); - - /** - * @brief This function is able to create a new instance of the class - */ - RadarSatRecord* Instanciate() - { - return new DataSetSummary(); - }; - - /** - * @brief This function is able to create a new instance of the class initialised with the data of the calling instance - */ - RadarSatRecord* Clone() - { - return new DataSetSummary(*this); - }; - - /** - * @brief Reads the class data from a stream - */ - void Read(std::istream& is) - { - is>>*this; - }; - - /** - * @brief Writes the class to a stream - */ - void Write(std::ostream& os) - { - os<<*this; - }; - - /** - * @brief Sequence number - */ - int get_seq_num() - { - return _seq_num; - }; - /** - * @brief SAR channel indicator - */ - int get_sar_chn() - { - return _sar_chn; - }; - /** - * @brief Scene identifier - */ - std::string get_scene_id() - { - return _scene_id; - }; - /** - * @brief Scene designator - */ - std::string get_scene_des() - { - return _scene_des; - }; - /** - * @brief Input scene centre time - */ - std::string get_inp_sctim() - { - return _inp_sctim; - }; - /** - * @brief Ascending/descending - */ - std::string get_asc_des() - { - return _asc_des; - }; - /** - * @brief Processed scene centre latitude - */ - double get_pro_lat() - { - return _pro_lat; - }; - /** - * @brief Processed scene centre longitude - */ - double get_pro_long() - { - return _pro_long; - }; - /** - * @brief Processed scene centre headng - */ - double get_pro_head() - { - return _pro_head; - }; - /** - * @brief Ellipsoid designator - */ - std::string get_ellip_des() - { - return _ellip_des; - }; - /** - * @brief Ellipsoid semi-major axis, km - */ - double get_ellip_maj() - { - return _ellip_maj; - }; - /** - * @brief Ellipsoid semi_minor axis, km - */ - double get_ellip_min() - { - return _ellip_min; - }; - /** - * @brief Earth's mass - */ - double get_earth_mass() - { - return _earth_mass; - }; - /** - * @brief Gravitational constant - */ - double get_grav_const() - { - return _grav_const; - }; - /** - * @brief Ellipsoid J2-4 parameters - */ - double* get_ellip_j() - { - return _ellip_j; - }; - - /** - * @brief Average terrain height, km - */ - double get_terrain_h() - { - return _terrain_h; - }; - /** - * @brief Scene centre line number - */ - int get_sc_lin() - { - return _sc_lin; - }; - /** - * @brief Scene centre pixel number - */ - int get_sc_pix() - { - return _sc_pix; - }; - /** - * @brief Scene length, km - */ - double get_scene_len() - { - return _scene_len; - }; - /** - * @brief Scene width, km - */ - double get_scene_wid() - { - return _scene_wid; - }; - - /** - * @brief Number of SAR channels - */ - double get_nchn() - { - return _nchn; - }; - - /** - * @brief Mission identifier - */ - std::string get_mission_id() - { - return _mission_id; - }; - /** - * @brief Sensor identifier - */ - std::string get_sensor_id() - { - return _sensor_id; - }; - /** - * @brief Orbit number - */ - std::string get_orbit_num() - { - return _orbit_num; - }; - /** - * @brief Platform geodetic latitude - */ - double get_plat_lat() - { - return _plat_lat; - }; - /** - * @brief Platform geodetic longitude - */ - double get_plat_long() - { - return _plat_long; - }; - /** - * @brief Platform heading - */ - double get_plat_head() - { - return _plat_head; - }; - /** - * @brief Sensor clock angle - */ - double get_clock_ang() - { - return _clock_ang; - }; - /** - * @brief Incidence angle - */ - double get_incident_ang() - { - return _incident_ang; - }; - - /** - * @brief Radar wave length - */ - double get_wave_length() - { - return _wave_length; - }; - /** - * @brief Motion compensation indicator - */ - std::string get_motion_comp() - { - return _motion_comp; - }; - /** - * @brief Range pulse code specifier - */ - std::string get_pulse_code() - { - return _pulse_code; - }; - /** - * @brief Range chirp coefficients - */ - double* get_ampl_coef() - { - return _ampl_coef; - }; - /** - * @brief Range phase coefficients - */ - double* get_phas_coef() - { - return _phas_coef; - }; - /** - * @brief Chirp extraction index - */ - int get_chirp_ext_ind() - { - return _chirp_ext_ind; - }; - - /** - * @brief Range sampling rate - */ - double get_fr() - { - return _fr; - }; - /** - * @brief Range gate start time - */ - double get_rng_gate() - { - return _rng_gate; - }; - /** - * @brief Range pulse length - */ - double get_rng_length() - { - return _rng_length; - }; - /** - * @brief Baseband conversion flag - */ - std::string get_baseband_f() - { - return _baseband_f; - }; - /** - * @brief Range compressed flag - */ - std::string get_rngcmp_f() - { - return _rngcmp_f; - }; - /** - * @brief Like polarized gain - */ - double get_gn_polar() - { - return _gn_polar; - }; - /** - * @brief Cross polarized gain - */ - double get_gn_cross() - { - return _gn_cross; - }; - /** - * @brief Number of bits per channel - */ - int get_chn_bits() - { - return _chn_bits; - }; - /** - * @brief Quantization descriptor - */ - std::string get_quant_desc() - { - return _quant_desc; - }; - /** - * @brief I channel DC bias - */ - double get_i_bias() - { - return _i_bias; - }; - /** - * @brief Q channel DC bias - */ - double get_q_bias() - { - return _q_bias; - }; - /** - * @brief I/Q channel ratio - */ - double get_iq_ratio() - { - return _iq_ratio; - }; - - - /** - * @brief Electronic boresight - */ - double get_ele_sight() - { - return _ele_sight; - }; - /** - * @brief Mechanical boresight - */ - double get_mech_sight() - { - return _mech_sight; - }; - /** - * @brief Echo tracker on/off flag - */ - std::string get_echo_track() - { - return _echo_track; - }; - /** - * @brief Nominal PRF, Hz - */ - double get_fa() - { - return _fa; - }; - /** - * @brief Elevation beamwidth - */ - double get_elev_beam() - { - return _elev_beam; - }; - /** - * @brief Azimuth beamwidth - */ - double get_azim_beam() - { - return _azim_beam; - }; - /** - * @brief Satellite binary time - */ - int get_sat_bintim() - { - return _sat_bintim; - }; - /** - * @brief Satellite clock time - */ - int get_sat_clktim() - { - return _sat_clktim; - }; - /** - * @brief Satellite clock increment - */ - int get_sat_clkinc() - { - return _sat_clkinc; - }; - - /** - * @brief Processing facility identifier - */ - std::string get_fac_id() - { - return _fac_id; - }; - /** - * @brief Processing system identifier - */ - std::string get_sys_id() - { - return _sys_id; - }; - /** - * @brief Processing version identifier - */ - std::string get_ver_id() - { - return _ver_id; - }; - /** - * @brief Facility process code - */ - std::string get_fac_code() - { - return _fac_code; - }; - /** - * @brief Product level code - */ - std::string get_lev_code() - { - return _lev_code; - }; - /** - * @brief Product type specifier - */ - std::string get_prod_type() - { - return _prod_type; - }; - /** - * @brief Processing algorithm identifier - */ - std::string get_algor_id() - { - return _algor_id; - }; - /** - * @brief Number of azimuth looks - */ - double get_n_azilok() - { - return _n_azilok; - }; - /** - * @brief Number of range looks - */ - double get_n_rnglok() - { - return _n_rnglok; - }; - /** - * @brief Bandwidth per look in azimuth,Hz - */ - double get_bnd_azilok() - { - return _bnd_azilok; - }; - /** - * @brief Bandwidth per look in range,Hz - */ - double get_bnd_rnglok() - { - return _bnd_rnglok; - }; - /** - * @brief Total azimuth look bandwidth - */ - double get_bnd_azi() - { - return _bnd_azi; - }; - /** - * @brief Total range look bandwidth - */ - double get_bnd_rng() - { - return _bnd_rng; - }; - /** - * @brief Azimuth weighting designator - */ - std::string get_azi_weight() - { - return _azi_weight; - }; - /** - * @brief Range weighting designator - */ - std::string get_rng_weight() - { - return _rng_weight; - }; - /** - * @brief Data input source - */ - std::string get_data_inpsrc() - { - return _data_inpsrc; - }; - /** - * @brief Range resolution, meter - */ - double get_rng_res() - { - return _rng_res; - }; - /** - * @brief Azimuth resolution, meter - */ - double get_azi_res() - { - return _azi_res; - }; - /** - * @brief Radiometric stretch terms - */ - double* get_radi_stretch() - { - return _radi_stretch; - }; - /** - * @brief Along track Doppler frequency terms - */ - double* get_alt_dopcen() - { - return _alt_dopcen; - }; - - /** - * @brief Cross track Doppler frequency terms - */ - double* get_crt_dopcen() - { - return _crt_dopcen; - }; - /** - * @brief Pixel time direction indicator - */ - std::string get_time_dir_pix() - { - return _time_dir_pix; - }; - /** - * @brief Line time direction indicator - */ - std::string get_time_dir_lin() - { - return _time_dir_lin; - }; - /** - * @brief Along track Doppler rate term - */ - double* get_alt_rate() - { - return _alt_rate; - }; - - /** - * @brief Cross track Doppler rate term - */ - double* get_crt_rate() - { - return _crt_rate; - }; - - /** - * @brief Line content indicator - */ - std::string get_line_cont() - { - return _line_cont; - }; - /** - * @brief Clutter lock applied flag - */ - std::string get_clutter_lock() - { - return _clutter_lock; - }; - /** - * @brief Auto-focus applied flag - */ - std::string get_auto_focus() - { - return _auto_focus; - }; - /** - * @brief Line spacing, meters - */ - double get_line_spacing() - { - return _line_spacing; - }; - /** - * @brief Pixel spacing, meters - */ - double get_pix_spacing() - { - return _pix_spacing; - }; - /** - * @brief Range compression designator - */ - std::string get_rngcmp_desg() - { - return _rngcmp_desg; - }; - -protected: - /** - * @brief Sequence number - */ - int _seq_num; - /** - * @brief SAR channel indicator - */ - int _sar_chn; - /** - * @brief Scene identifier - */ - std::string _scene_id; - /** - * @brief Scene designator - */ - std::string _scene_des; - /** - * @brief Input scene centre time - */ - std::string _inp_sctim; - /** - * @brief Ascending/descending - */ - std::string _asc_des; - /** - * @brief Processed scene centre latitude - */ - double _pro_lat; - /** - * @brief Processed scene centre longitude - */ - double _pro_long; - /** - * @brief Processed scene centre headng - */ - double _pro_head; - /** - * @brief Ellipsoid designator - */ - std::string _ellip_des; - /** - * @brief Ellipsoid semi-major axis, km - */ - double _ellip_maj; - /** - * @brief Ellipsoid semi_minor axis, km - */ - double _ellip_min; - /** - * @brief Earth's mass - */ - double _earth_mass; - /** - * @brief Gravitational constant - */ - double _grav_const; - /** - * @brief Ellipsoid J2-4 parameters - */ - double _ellip_j[3]; - - /** - * @brief Average terrain height, km - */ - double _terrain_h; - /** - * @brief Scene centre line number - */ - int _sc_lin; - /** - * @brief Scene centre pixel number - */ - int _sc_pix; - /** - * @brief Scene length, km - */ - double _scene_len; - /** - * @brief Scene width, km - */ - double _scene_wid; - - /** - * @brief Number of SAR channels - */ - double _nchn; - - /** - * @brief Mission identifier - */ - std::string _mission_id; - /** - * @brief Sensor identifier - */ - std::string _sensor_id; - /** - * @brief Orbit number - */ - std::string _orbit_num; - /** - * @brief Platform geodetic latitude - */ - double _plat_lat; - /** - * @brief Platform geodetic longitude - */ - double _plat_long; - /** - * @brief Platform heading - */ - double _plat_head; - /** - * @brief Sensor clock angle - */ - double _clock_ang; - /** - * @brief Incidence angle - */ - double _incident_ang; - - /** - * @brief Radar wave length - */ - double _wave_length; - /** - * @brief Motion compensation indicator - */ - std::string _motion_comp; - /** - * @brief Range pulse code specifier - */ - std::string _pulse_code; - /** - * @brief Range chirp coefficients - */ - double _ampl_coef[5]; - /** - * @brief Range phase coefficients - */ - double _phas_coef[5]; - /** - * @brief Chirp extraction index - */ - int _chirp_ext_ind; - - /** - * @brief Range sampling rate - */ - double _fr; - /** - * @brief Range gate start time - */ - double _rng_gate; - /** - * @brief Range pulse length - */ - double _rng_length; - /** - * @brief Baseband conversion flag - */ - std::string _baseband_f; - /** - * @brief Range compressed flag - */ - std::string _rngcmp_f; - /** - * @brief Like polarized gain - */ - double _gn_polar; - /** - * @brief Cross polarized gain - */ - double _gn_cross; - /** - * @brief Number of bits per channel - */ - int _chn_bits; - /** - * @brief Quantization descriptor - */ - std::string _quant_desc; - /** - * @brief I channel DC bias - */ - double _i_bias; - /** - * @brief Q channel DC bias - */ - double _q_bias; - /** - * @brief I/Q channel ratio - */ - double _iq_ratio; - - /** - * @brief Electronic boresight - */ - double _ele_sight; - /** - * @brief Mechanical boresight - */ - double _mech_sight; - /** - * @brief Echo tracker on/off flag - */ - std::string _echo_track; - /** - * @brief Nominal PRF, Hz - */ - double _fa; - /** - * @brief Elevation beamwidth - */ - double _elev_beam; - /** - * @brief Azimuth beamwidth - */ - double _azim_beam; - /** - * @brief Satellite binary time - */ - int _sat_bintim; - /** - * @brief Satellite clock time - */ - int _sat_clktim; - /** - * @brief Satellite clock increment - */ - int _sat_clkinc; - - /** - * @brief Processing facility identifier - */ - std::string _fac_id; - /** - * @brief Processing system identifier - */ - std::string _sys_id; - /** - * @brief Processing version identifier - */ - std::string _ver_id; - /** - * @brief Facility process code - */ - std::string _fac_code; - /** - * @brief Product level code - */ - std::string _lev_code; - /** - * @brief Product type specifier - */ - std::string _prod_type; - /** - * @brief Processing algorithm identifier - */ - std::string _algor_id; - /** - * @brief Number of azimuth looks - */ - double _n_azilok; - /** - * @brief Number of range looks - */ - double _n_rnglok; - /** - * @brief Bandwidth per look in azimuth,Hz - */ - double _bnd_azilok; - /** - * @brief Bandwidth per look in range,Hz - */ - double _bnd_rnglok; - /** - * @brief Total azimuth look bandwidth - */ - double _bnd_azi; - /** - * @brief Total range look bandwidth - */ - double _bnd_rng; - /** - * @brief Azimuth weighting designator - */ - std::string _azi_weight; - /** - * @brief Range weighting designator - */ - std::string _rng_weight; - /** - * @brief Data input source - */ - std::string _data_inpsrc; - /** - * @brief Range resolution, meter - */ - double _rng_res; - /** - * @brief Azimuth resolution, meter - */ - double _azi_res; - /** - * @brief Radiometric stretch terms - */ - double _radi_stretch[2]; - /** - * @brief Along track Doppler frequency terms - */ - double _alt_dopcen[3]; - - /** - * @brief Cross track Doppler frequency terms - */ - double _crt_dopcen[3]; - /** - * @brief Pixel time direction indicator - */ - std::string _time_dir_pix; - /** - * @brief Line time direction indicator - */ - std::string _time_dir_lin; - /** - * @brief Along track Doppler rate term - */ - double _alt_rate[3]; - - /** - * @brief Cross track Doppler rate term - */ - double _crt_rate[3]; - - /** - * @brief Line content indicator - */ - std::string _line_cont; - /** - * @brief Clutter lock applied flag - */ - std::string _clutter_lock; - /** - * @brief Auto-focus applied flag - */ - std::string _auto_focus; - /** - * @brief Line spacing, meters - */ - double _line_spacing; - /** - * @brief Pixel spacing, meters - */ - double _pix_spacing; - /** - * @brief Range compression designator - */ - std::string _rngcmp_desg; - -private: - -}; - -#endif \ No newline at end of file diff --git a/Utilities/otbossim/include/ossim/imaging/RadarSat/Leader/DopplerCentroidEstimateRecord.h b/Utilities/otbossim/include/ossim/imaging/RadarSat/Leader/DopplerCentroidEstimateRecord.h deleted file mode 100644 index b08bee902e95b0d9294aa1e71defead749e2162b..0000000000000000000000000000000000000000 --- a/Utilities/otbossim/include/ossim/imaging/RadarSat/Leader/DopplerCentroidEstimateRecord.h +++ /dev/null @@ -1,86 +0,0 @@ -#ifndef DopplerCentroidEstimateRecord_h -#define DopplerCentroidEstimateRecord_h - -#include <iostream> - -#include <ossim/imaging/RadarSat/RadarSatRecord.h> - -/** - * @ingroup ProcessingParametersRecord - * @brief This class is able to read a Doppler centroid estimates record - * @author Magellium, Pacome Dentraygues - * @version 1.0 - * @date 30-11-07 - */ -class DopplerCentroidEstimateRecord -{ -public: - /** - * @brief Constructor - */ - DopplerCentroidEstimateRecord(); - - /** - * @brief Destructor - */ - ~DopplerCentroidEstimateRecord(); - - /** - * @brief Copy constructor - */ - DopplerCentroidEstimateRecord(const DopplerCentroidEstimateRecord& rhs); - - /** - * @brief Copy operator - */ - DopplerCentroidEstimateRecord& operator=(const DopplerCentroidEstimateRecord& rhs); - - /** - * @brief This function writes the DopplerCentroidEstimateRecord in a stream - */ - friend std::ostream& operator<<(std::ostream& os, const DopplerCentroidEstimateRecord& data); - - /** - * @brief This function reads a DopplerCentroidEstimateRecord from a stream - */ - friend std::istream& operator>>(std::istream& is, DopplerCentroidEstimateRecord& data); - - /** - * @brief Doppler centroid confidence measure - */ - double get_dopcen_conf() - { - return _dopcen_conf; - } - /** - * @brief Doppler centroid reference time (sec) - */ - double get_dopcen_ref_tim() - { - return _dopcen_ref_tim; - } - /** - * @brief Doppler centroid coefficients - */ - double* get_dopcen_coef() - { - return _dopcen_coef; - } - -protected: - /** - * @brief Doppler centroid confidence measure - */ - double _dopcen_conf; - /** - * @brief Doppler centroid reference time (sec) - */ - double _dopcen_ref_tim; - /** - * @brief Doppler centroid coefficients - */ - double _dopcen_coef[4]; -private: - -}; -#endif \ No newline at end of file diff --git a/Utilities/otbossim/include/ossim/imaging/RadarSat/Leader/FileDescriptor.h b/Utilities/otbossim/include/ossim/imaging/RadarSat/Leader/FileDescriptor.h deleted file mode 100644 index 1fdf23322ba27983d5255abcae59eee08be3dfe8..0000000000000000000000000000000000000000 --- a/Utilities/otbossim/include/ossim/imaging/RadarSat/Leader/FileDescriptor.h +++ /dev/null @@ -1,618 +0,0 @@ -#ifndef FileDescriptor_h -#define FileDescriptor_h - - -#include<iostream> -#include <ossim/imaging/RadarSat/RadarSatRecordHeader.h> -#include <ossim/imaging/RadarSat/RadarSatRecord.h> -/** - * @ingroup SARLeaderFileDescriptorRecord - * @brief This class is able to read the SAR leader file descriptor record of the leader file - * @author Magellium, Pacome Dentraygues - * @version 1.0 - * @date 23-11-07 - */ -class FileDescriptor : public RadarSatRecord -{ -public: - /** - * @brief Constructor - */ - FileDescriptor(); - /** - * @brief Destructor - */ - ~FileDescriptor(); - - /** - * @brief This function writes the FileDescriptor in a stream - */ - friend std::ostream& operator<<(std::ostream& os, const FileDescriptor& data); - - /** - * @brief This function reads a FileDescriptor from a stream - */ - friend std::istream& operator>>(std::istream& is, FileDescriptor& data); - - /** - * @brief Copy constructor - */ - FileDescriptor(const FileDescriptor& rhs); - - /** - * @brief Copy operator - */ - FileDescriptor& operator=(const FileDescriptor& rhs); - - /** - * @brief This function is able to create a new instance of the class - */ - RadarSatRecord* Instanciate() - { - return new FileDescriptor(); - }; - - /** - * @brief This function is able to create a new instance of the class initialised with the data of the calling instance - */ - RadarSatRecord* Clone() - { - return new FileDescriptor(*this); - }; - - /** - * @brief Reads the class data from a stream - */ - void Read(std::istream& is) - { - is>>*this; - }; - - /** - * @brief Writes the class to a stream - */ - void Write(std::ostream& os) - { - os<<*this; - }; - - /** - * @brief ASCII flag - */ - std::string get_ascii_flag() - { - return _ascii_flag; - }; - - /** - * @brief Format control documentation - */ - std::string get_format_doc() - { - return _format_doc; - }; - /** - * @brief Format doc version - */ - std::string get_format_ver() - { - return _format_ver; - }; - /** - * @brief Format doc revision - */ - std::string get_design_rev() - { - return _design_rev; - }; - /** - * @brief Software identifier - */ - std::string get_software_id() - { - return _software_id; - }; - /** - * @brief File number - */ - int get_file_num() - { - return _file_num ; - }; - /** - * @brief File name - */ - std::string get_file_name() - { - return _file_name; - }; - /** - * @brief Record sequence/location flag - */ - std::string get_rec_seq() - { - return _rec_seq; - }; - /** - * @brief Sequence number location - */ - int get_seq_loc() - { - return _seq_loc; - }; - /** - * @brief Sequence number lenght - */ - int get_seq_len() - { - return _seq_len; - }; - /** - * @brief Record code/location flag - */ - std::string get_rec_code() - { - return _rec_code; - }; - /** - * @brief Record code location - */ - int get_code_loc() - { - return _code_loc; - }; - /** - * @brief Record code length - */ - int get_code_len() - { - return _code_len; - }; - /** - * @brief Record length/location flag - */ - std::string get_rec_len() - { - return _rec_len; - }; - /** - * @brief Record lenght location - */ - int get_rlen_loc() - { - return _rlen_loc; - }; - /** - * @brief Record length, bytes - */ - int get_rlen_len() - { - return _rlen_len; - }; - /** - * @brief Number of dataset summ records - */ - int get_n_dataset() - { - return _n_dataset; - }; - /** - * @brief Data set summary record length, bytes - */ - int get_l_dataset() - { - return _l_dataset; - }; - /** - * @brief Number of map proj records - */ - int get_n_map_proj() - { - return _n_map_proj; - }; - /** - * @brief Map projection record length, bytes - */ - int get_l_map_proj() - { - return _l_map_proj; - }; - /** - * @brief Number of platform position records - */ - int get_n_plat_pos() - { - return _n_plat_pos; - }; - /** - * @brief Platform position record length, bytes - */ - int get_l_plat_pos() - { - return _l_plat_pos; - }; - /** - * @brief Number of attitude data records - */ - int get_n_att_data() - { - return _n_att_data; - }; - /** - * @brief Attitude data record length, bytes - */ - int get_l_att_data() - { - return _l_att_data; - }; - /** - * @brief Number of radiometric data records - */ - int get_n_radi_data() - { - return _n_radi_data; - }; - /** - * @brief Radiometric data record length, bytes - */ - int get_l_radi_data() - { - return _l_radi_data; - }; - /** - * @brief Number of radiometric compensation records - */ - int get_n_radi_comp() - { - return _n_radi_comp; - }; - /** - * @brief Radiometric compensation record length, bytes - */ - int get_l_radi_comp() - { - return _l_radi_comp; - }; - /** - * @brief Number of data quality summary records - */ - int get_n_qual_sum() - { - return _n_qual_sum; - }; - /** - * @brief Data quality summary record length, bytes - */ - int get_l_qual_sum() - { - return _l_qual_sum; - }; - /** - * @brief Number of data histogram records - */ - int get_n_data_his() - { - return _n_data_his; - }; - /** - * @brief Data histogram record length, bytes - */ - int get_l_data_his() - { - return _l_data_his; - }; - /** - * @brief Number of range spectra records - */ - int get_n_rang_spec() - { - return _n_rang_spec ; - }; - /** - * @brief Range spectra record length, bytes - */ - int get_l_rang_spec() - { - return _l_rang_spec; - }; - /** - * @brief Number of DEM descriptor records - */ - int get_n_dem_desc() - { - return _n_dem_desc; - }; - /** - * @brief DEM desc record length, bytes - */ - int get_l_dem_desc() - { - return _l_dem_desc; - }; - /** - * @brief Number of RADAR par records - */ - int get_n_radar_par() - { - return _n_radar_par; - }; - /** - * @brief RADAR par record length, bytes - */ - int get_l_radar_par() - { - return _l_radar_par; - }; - /** - * @brief Number of annotation data records - */ - int get_n_anno_data() - { - return _n_anno_data; - }; - /** - * @brief Annotation data record length, bytes - */ - int get_l_anno_data() - { - return _l_anno_data; - }; - /** - * @brief Number of processing parameter records - */ - int get_n_det_proc() - { - return _n_det_proc; - }; - /** - * @brief Processing parameter record length, bytes - */ - int get_l_det_proc() - { - return _l_det_proc; - }; - /** - * @brief Number of calibration records - */ - int get_n_cal() - { - return _n_cal; - }; - /** - * @brief Calibration record length, bytes - */ - int get_l_cal() - { - return _l_cal; - }; - /** - * @brief Number of GCP records - */ - int get_n_gcp() - { - return _n_gcp; - }; - /** - * @brief GCP record length, bytes - */ - int get_l_gcp() - { - return _l_gcp; - }; - /** - * @brief Number of facility data records - */ - int get_n_fac_data() - { - return _n_fac_data; - }; - /** - * @brief Fac data record length, bytes - */ - int get_l_fac_data() - { - return _l_fac_data; - }; - -protected: - /** - * @brief ASCII flag - */ - std::string _ascii_flag; - - /** - * @brief Format control documentation - */ - std::string _format_doc; - /** - * @brief Format doc version - */ - std::string _format_ver; - /** - * @brief Format doc revision - */ - std::string _design_rev; - /** - * @brief Software identifier - */ - std::string _software_id; - /** - * @brief File number - */ - int _file_num; - /** - * @brief File name - */ - std::string _file_name; - /** - * @brief Record sequence/location flag - */ - std::string _rec_seq; - /** - * @brief Sequence number location - */ - int _seq_loc; - /** - * @brief Sequence number lenght - */ - int _seq_len; - /** - * @brief Record code/location flag - */ - std::string _rec_code; - /** - * @brief Record code location - */ - int _code_loc; - /** - * @brief Record code length - */ - int _code_len; - /** - * @brief Record length/location flag - */ - std::string _rec_len; - /** - * @brief Record lenght location - */ - int _rlen_loc; - /** - * @brief Record length, bytes - */ - int _rlen_len; - - - /** - * @brief Number of dataset summ records - */ - int _n_dataset; - /** - * @brief Data set summary record length, bytes - */ - int _l_dataset; - /** - * @brief Number of map proj records - */ - int _n_map_proj; - /** - * @brief Map projection record length, bytes - */ - int _l_map_proj; - /** - * @brief Number of platform position records - */ - int _n_plat_pos; - /** - * @brief Platform position record length, bytes - */ - int _l_plat_pos; - /** - * @brief Number of attitude data records - */ - int _n_att_data; - /** - * @brief Attitude data record length, bytes - */ - int _l_att_data; - /** - * @brief Number of radiometric data records - */ - int _n_radi_data; - /** - * @brief Radiometric data record length, bytes - */ - int _l_radi_data; - /** - * @brief Number of radiometric compensation records - */ - int _n_radi_comp; - /** - * @brief Radiometric compensation record length, bytes - */ - int _l_radi_comp; - /** - * @brief Number of data quality summary records - */ - int _n_qual_sum; - /** - * @brief Data quality summary record length, bytes - */ - int _l_qual_sum; - /** - * @brief Number of data histogram records - */ - int _n_data_his; - /** - * @brief Data histogram record length, bytes - */ - int _l_data_his; - /** - * @brief Number of range spectra records - */ - int _n_rang_spec; - /** - * @brief Range spectra record length, bytes - */ - int _l_rang_spec; - /** - * @brief Number of DEM descriptor records - */ - int _n_dem_desc; - /** - * @brief DEM desc record length, bytes - */ - int _l_dem_desc; - /** - * @brief Number of RADAR par records - */ - int _n_radar_par; - /** - * @brief RADAR par record length, bytes - */ - int _l_radar_par; - /** - * @brief Number of annotation data records - */ - int _n_anno_data; - /** - * @brief Annotation data record length, bytes - */ - int _l_anno_data; - /** - * @brief Number of processing parameter records - */ - int _n_det_proc; - /** - * @brief Processing parameter record length, bytes - */ - int _l_det_proc; - /** - * @brief Number of calibration records - */ - int _n_cal; - /** - * @brief Calibration record length, bytes - */ - int _l_cal; - /** - * @brief Number of GCP records - */ - int _n_gcp; - /** - * @brief GCP record length, bytes - */ - int _l_gcp; - - /** - * @brief Number of facility data records - */ - int _n_fac_data; - /** - * @brief Fac data record length, bytes - */ - int _l_fac_data; - -private: -}; - -#endif \ No newline at end of file diff --git a/Utilities/otbossim/include/ossim/imaging/RadarSat/Leader/Leader.h b/Utilities/otbossim/include/ossim/imaging/RadarSat/Leader/Leader.h deleted file mode 100644 index ed5fcea67b74039f15b40b434dfb8cd47d3a6e74..0000000000000000000000000000000000000000 --- a/Utilities/otbossim/include/ossim/imaging/RadarSat/Leader/Leader.h +++ /dev/null @@ -1,95 +0,0 @@ -#ifndef Leader_h -#define Leader_h - -#include <iostream> -#include "FileDescriptor.h" -#include "DataSetSummary.h" -#include "DataQuality.h" -#include "DataHistogramSignalData.h" -#include "DataHistogramProcessedData.h" -#include <map> - -class RadiometricData; -class RadiometricCompensationData; -class AttitudeData; -class PlatformPositionData; -class ProcessingParameters; -class DataHistogramProcessedData; -class DataHistogramSignalData; -class DataQuality; -class DataSetSummary; -class FileDescriptor; - -/** - * @ingroup LeaderFile - * @brief This class is able to read the leader file of the RadarSat file structure - * @author Magellium, Pacome Dentraygues - * @version 1.0 - * @date 23-11-07 - */ -class Leader -{ -public: - /** - * @brief Constructor - */ - Leader(); - - /** - * @brief Destructor - */ - ~Leader(); - - /** - * @brief This function writes the Leader in a stream - */ - friend std::ostream& operator<<(std::ostream& os, const Leader& data); - - /** - * @brief This function reads a Leader from a stream - */ - friend std::istream& operator>>(std::istream& is, Leader& data); - - /** - * @brief Copy constructor - */ - Leader(const Leader& rhs); - - /** - * @brief Copy operator - */ - Leader& operator=(const Leader& rhs); - - /** - * @brief Removes all the previous records from the Leader - */ - void ClearRecords(); - - RadiometricData * get_RadiometricData(); - RadiometricCompensationData * get_RadiometricCompensationData(); - AttitudeData * get_AttitudeData(); - PlatformPositionData * get_PlatformPositionData(); - ProcessingParameters * get_ProcessingParameters(); - DataHistogramProcessedData * get_DataHistogramProcessedData(); - DataHistogramSignalData * get_DataHistogramSignalData(); - DataQuality * get_DataQuality(); - DataSetSummary * get_DataSetSummary(); - FileDescriptor * get_FileDescriptor(); -protected: - std::map<int, RadarSatRecord*> _records; - - static const int RadiometricDataID; - static const int RadiometricCompensationDataID; - static const int AttitudeDataID; - static const int PlatformPositionDataID; - static const int ProcessingParametersID; - static const int DataHistogramProcessedDataID; - static const int DataHistogramSignalDataID; - static const int DataQualityID; - static const int DataSetSummaryID; - static const int FileDescriptorID; -private: - -}; - -#endif \ No newline at end of file diff --git a/Utilities/otbossim/include/ossim/imaging/RadarSat/Leader/LeaderFactory.h b/Utilities/otbossim/include/ossim/imaging/RadarSat/Leader/LeaderFactory.h deleted file mode 100644 index 1726ea7c741adffff5bba1c3ec4d0941a5bdd1e5..0000000000000000000000000000000000000000 --- a/Utilities/otbossim/include/ossim/imaging/RadarSat/Leader/LeaderFactory.h +++ /dev/null @@ -1,33 +0,0 @@ -#ifndef LeaderFactory_h -#define LeaderFactory_h - - -#include <ossim/imaging/RadarSat/RadarSatRecordFactory.h> -#include <map> -/** - * @ingroup LeaderFile - * @brief This class is a factory able to construct Record base classes - * @author Magellium, Pacome Dentraygues - * @version 1.0 - * @date 23-11-07 - */ -class LeaderFactory : public RadarSatRecordFactory -{ -public: - /** - * @brief Contstructor - */ - LeaderFactory(); - /** - * @brief Destructor - */ - ~LeaderFactory(); - - -protected: - - -private: -}; - -#endif \ No newline at end of file diff --git a/Utilities/otbossim/include/ossim/imaging/RadarSat/Leader/MisregistrationRecord.h b/Utilities/otbossim/include/ossim/imaging/RadarSat/Leader/MisregistrationRecord.h deleted file mode 100644 index 066b2d8a7f06264be4bbf9b09589ed9313f43c59..0000000000000000000000000000000000000000 --- a/Utilities/otbossim/include/ossim/imaging/RadarSat/Leader/MisregistrationRecord.h +++ /dev/null @@ -1,75 +0,0 @@ -#ifndef MisregistrationRecord_h -#define MisregistrationRecord_h - -#include <iostream> - -#include <ossim/imaging/RadarSat/RadarSatRecord.h> -/** - * @ingroup DataQualitySummaryRecord - * @brief This class is able to read a misregistration record - * @author Magellium, Pacome Dentraygues - * @version 1.0 - * @date 23-11-07 - */ -class MisregistrationRecord -{ -public: - /** - * @brief Constructor - */ - MisregistrationRecord(); - - /** - * @brief Destructor - */ - ~MisregistrationRecord(); - - /** - * @brief Copy constructor - */ - MisregistrationRecord(const MisregistrationRecord& rhs); - - /** - * @brief Copy operator - */ - MisregistrationRecord& operator=(const MisregistrationRecord& rhs); - /** - * @brief This function writes the MisregistrationRecord in a stream - */ - friend std::ostream& operator<<(std::ostream& os, const MisregistrationRecord& data); - - /** - * @brief This function reads a MisregistrationRecord from a stream - */ - friend std::istream& operator>>(std::istream& is, MisregistrationRecord& data); - - /** - * @brief Nominal along track misregistration - */ - double get_alt_m() - { - return _alt_m; - }; - /** - * @brief Nominal cross track misregistration - */ - double get_crt_m() - { - return _crt_m; - }; -protected: - - /** - * @brief Nominal along track misregistration - */ - double _alt_m; - /** - * @brief Nominal cross track misregistration - */ - double _crt_m; -private: - - -}; - -#endif \ No newline at end of file diff --git a/Utilities/otbossim/include/ossim/imaging/RadarSat/Leader/PlatformPositionData.h b/Utilities/otbossim/include/ossim/imaging/RadarSat/Leader/PlatformPositionData.h deleted file mode 100644 index 6259995a5a09588d30cf077b01d658126433597c..0000000000000000000000000000000000000000 --- a/Utilities/otbossim/include/ossim/imaging/RadarSat/Leader/PlatformPositionData.h +++ /dev/null @@ -1,283 +0,0 @@ -#ifndef PlatformPositionData_h -#define PlatformPositionData_h - -#include <iostream> -#include <ossim/imaging/RadarSat/RadarSatRecord.h> -#include <ossim/imaging/RadarSat/RadarSatRecordHeader.h> - -#include <ossim/imaging/RadarSat/Leader/PositionVectorRecord.h> -/** - * @ingroup PlatformPositionDataRecord - * @brief This class is able to read a Platform position data record - * @author Magellium, Pacome Dentraygues - * @version 1.0 - * @date 02-12-07 - */ -class PlatformPositionData : public RadarSatRecord -{ -public: - /** - * @brief Constructor - */ - PlatformPositionData(); - - /** - * @brief Destructor - */ - ~PlatformPositionData(); - - /** - * @brief Copy constructor - */ - PlatformPositionData(const PlatformPositionData& rhs); - - /** - * @brief Copy operator - */ - PlatformPositionData& operator=(const PlatformPositionData& rhs); - /** - * @brief This function writes the PlatformPositionData in a stream - */ - friend std::ostream& operator<<(std::ostream& os, const PlatformPositionData& data); - - /** - * @brief This function reads a PlatformPositionData from a stream - */ - friend std::istream& operator>>(std::istream& is, PlatformPositionData& data); - - /** - * @brief This function is able to create a new instance of the class - */ - RadarSatRecord* Instanciate() - { - return new PlatformPositionData(); - }; - - /** - * @brief This function is able to create a new instance of the class initialised with the data of the calling instance - */ - RadarSatRecord* Clone() - { - return new PlatformPositionData(*this); - }; - - /** - * @brief Reads the class data from a stream - */ - void Read(std::istream& is) - { - is>>*this; - }; - - /** - * @brief Writes the class to a stream - */ - void Write(std::ostream& os) - { - os<<*this; - }; - - /** - * @brief Orbital elements designator - */ - std::string get_orbit_ele_desg() - { - return _orbit_ele_desg; - }; - /** - * @brief Orbital elements - */ - double* get_orbit_ele() - { - return _orbit_ele; - }; - /** - * @brief Number of data points - */ - int get_ndata() - { - return _ndata; - }; - /** - * @brief Year of data point - */ - int get_year() - { - return _year; - }; - /** - * @brief Month of data point - */ - int get_month() - { - return _month; - }; - /** - * @brief Day of data point - */ - int get_day() - { - return _day; - }; - /** - * @brief Day of year - */ - int get_gmt_day() - { - return _gmt_day; - }; - /** - * @brief Seconds of day - */ - double get_gmt_sec() - { - return _gmt_sec; - }; - /** - * @brief Data sampling interval - */ - double get_data_int() - { - return _data_int; - }; - /** - * @brief Reference coordinate system - */ - std::string get_ref_coord() - { - return _ref_coord; - }; - /** - * @brief Greenwich mean hour angle - */ - double get_hr_angle() - { - return _hr_angle; - }; - /** - * @brief Along track position error - */ - double get_alt_poserr() - { - return _alt_poserr; - }; - /** - * @brief Cross track position error - */ - double get_crt_poserr() - { - return _crt_poserr; - }; - /** - * @brief Radial position error - */ - double get_rad_poserr() - { - return _rad_poserr; - }; - /** - * @brief Along track velocity error - */ - double get_alt_velerr() - { - return _alt_velerr; - }; - /** - * @brief Cross track velocity error - */ - double get_crt_velerr() - { - return _crt_velerr; - }; - /** - * @brief Radial velocity error - */ - double get_rad_velerr() - { - return _rad_velerr; - }; - /** - * @brief Data point position/velocity - */ - PositionVectorRecord* get_pos_vect() - { - return _pos_vect; - }; - -protected: - /** - * @brief Orbital elements designator - */ - std::string _orbit_ele_desg; - /** - * @brief Orbital elements - */ - double _orbit_ele[6]; - /** - * @brief Number of data points - */ - int _ndata; - /** - * @brief Year of data point - */ - int _year; - /** - * @brief Month of data point - */ - int _month; - /** - * @brief Day of data point - */ - int _day; - /** - * @brief Day of year - */ - int _gmt_day; - /** - * @brief Seconds of day - */ - double _gmt_sec; - /** - * @brief Data sampling interval - */ - double _data_int; - /** - * @brief Reference coordinate system - */ - std::string _ref_coord; - /** - * @brief Greenwich mean hour angle - */ - double _hr_angle; - /** - * @brief Along track position error - */ - double _alt_poserr; - /** - * @brief Cross track position error - */ - double _crt_poserr; - /** - * @brief Radial position error - */ - double _rad_poserr; - /** - * @brief Along track velocity error - */ - double _alt_velerr; - /** - * @brief Cross track velocity error - */ - double _crt_velerr; - /** - * @brief Radial velocity error - */ - double _rad_velerr; - /** - * @brief Data point position/velocity - */ - PositionVectorRecord _pos_vect[64]; - -private: -}; -#endif diff --git a/Utilities/otbossim/include/ossim/imaging/RadarSat/Leader/PositionVectorRecord.h b/Utilities/otbossim/include/ossim/imaging/RadarSat/Leader/PositionVectorRecord.h deleted file mode 100644 index b628bb2412b58c826a4a9a8ab6c87fd750c778d9..0000000000000000000000000000000000000000 --- a/Utilities/otbossim/include/ossim/imaging/RadarSat/Leader/PositionVectorRecord.h +++ /dev/null @@ -1,75 +0,0 @@ -#ifndef PositionVectorRecord_h -#define PositionVectorRecord_h - -#include <iostream> -#include <ossim/imaging/RadarSat/RadarSatRecord.h> -/** - * @ingroup PlatformPositionDataRecord - * @brief This class is able to read a position vector record - * @author Magellium, Pacome Dentraygues - * @version 1.0 - * @date 23-11-07 - */ -class PositionVectorRecord -{ -public: - /** - * @brief Constructor - */ - PositionVectorRecord(); - - /** - * @brief Destructor - */ - ~PositionVectorRecord(); - - /** - * @brief Copy constructor - */ - PositionVectorRecord(const PositionVectorRecord& rhs); - - /** - * @brief Copy operator - */ - PositionVectorRecord& operator=(const PositionVectorRecord& rhs); - /** - * @brief This function writes the PositionVectorRecord in a stream - */ - friend std::ostream& operator<<(std::ostream& os, const PositionVectorRecord& data); - - /** - * @brief This function reads a PositionVectorRecord from a stream - */ - friend std::istream& operator>>(std::istream& is, PositionVectorRecord& data); - - /** - * @brief Data point position (m) - */ - double* get_pos() - { - return _pos; - }; - - /** - * @brief Data point velocity (mm/s) - */ - double* get_vel() - { - return _vel; - }; - -protected: - /** - * @brief Data point position (m) - */ - double _pos[3]; - /** - * @brief Data point velocity (mm/s) - */ - double _vel[3]; -private: - - -}; - -#endif \ No newline at end of file diff --git a/Utilities/otbossim/include/ossim/imaging/RadarSat/Leader/ProcessingParameters.h b/Utilities/otbossim/include/ossim/imaging/RadarSat/Leader/ProcessingParameters.h deleted file mode 100644 index 1a54350561e3016e079577554ac7431a62c8aa48..0000000000000000000000000000000000000000 --- a/Utilities/otbossim/include/ossim/imaging/RadarSat/Leader/ProcessingParameters.h +++ /dev/null @@ -1,1149 +0,0 @@ -#ifndef ProcessingParameters_h -#define ProcessingParameters_h - -#include <iostream> -#include <ossim/imaging/RadarSat/RadarSatRecord.h> -#include <ossim/imaging/RadarSat/RadarSatRecordHeader.h> - -#include <ossim/imaging/RadarSat/Leader/BeamInformationRecord.h> -#include <ossim/imaging/RadarSat/Leader/DopplerCentroidEstimateRecord.h> -#include <ossim/imaging/RadarSat/Leader/BeamPixelCountRecord.h> -#include <ossim/imaging/RadarSat/Leader/SRGRCoefficientSetRecord.h> -#include <ossim/imaging/RadarSat/Leader/TemperatureSettingsRecord.h> -/** - * @ingroup ProcessingParametersRecord - * @brief This class is able to read a Detailed processing parameters record - * @author Magellium, Pacome Dentraygues - * @version 1.0 - * @date 23-11-07 - */ -class ProcessingParameters : public RadarSatRecord -{ -public: - /** - * @brief Constructor - */ - ProcessingParameters(); - - /** - * @brief Destructor - */ - ~ProcessingParameters(); - - /** - * @brief Copy constructor - */ - ProcessingParameters(const ProcessingParameters& rhs); - - /** - * @brief Copy operator - */ - ProcessingParameters& operator=(const ProcessingParameters& rhs); - /** - * @brief This function writes the ProcessingParameters in a stream - */ - friend std::ostream& operator<<(std::ostream& os, const ProcessingParameters& data); - - /** - * @brief This function reads a ProcessingParameters from a stream - */ - friend std::istream& operator>>(std::istream& is, ProcessingParameters& data); - - /** - * @brief This function is able to create a new instance of the class - */ - RadarSatRecord* Instanciate() - { - return new ProcessingParameters(); - }; - - /** - * @brief This function is able to create a new instance of the class initialised with the data of the calling instance - */ - RadarSatRecord* Clone() - { - return new ProcessingParameters(*this); - }; - - /** - * @brief Reads the class data from a stream - */ - void Read(std::istream& is) - { - is>>*this; - }; - - /** - * @brief Writes the class to a stream - */ - void Write(std::ostream& os) - { - os<<*this; - }; - - /** - * @brief Record sequence number - */ - int get_rec_seq() - { - return _rec_seq; - }; - - /** - * @brief Input media - */ - std::string get_inp_media() - { - return _inp_media; - }; - /** - * @brief Number of tape input ids - */ - int get_n_tape_id() - { - return _n_tape_id; - }; - /** - * @brief Tape identifiers - */ - std::string* get_tape_id() - { - return _tape_id; - }; - /** - * @brief Expected ingest start time - */ - std::string get_exp_ing_start() - { - return _exp_ing_start; - }; - /** - * @brief Expected ingest stop time - */ - std::string get_exp_ing_stop() - { - return _exp_ing_stop; - }; - /** - * @brief Actual ingest start time - */ - std::string get_act_ing_start() - { - return _act_ing_start; - }; - /** - * @brief Actual ingest stop time - */ - std::string get_act_ing_stop() - { - return _act_ing_stop; - }; - /** - * @brief Processing start time - */ - std::string get_proc_start() - { - return _proc_start; - }; - /** - * @brief Processing stop time - */ - std::string get_proc_stop() - { - return _proc_stop; - }; - /** - * @brief Mean signal levels across range - */ - double* get_mn_sig_lev() - { - return _mn_sig_lev; - }; - /** - * @brief Source data quality indicator - */ - int get_scr_data_ind() - { - return _scr_data_ind; - }; - /** - * @brief Number of missing lines - */ - int get_miss_ln() - { - return _miss_ln; - }; - /** - * @brief Number of rejected lines - */ - int get_rej_ln() - { - return _rej_ln; - }; - /** - * @brief Number of time inconsistencies (large gaps) - */ - int get_large_gap() - { - return _large_gap; - }; - /** - * @brief Measured bit error rate - */ - double get_bit_err_rate() - { - return _bit_err_rate; - }; - /** - * @brief Percent of frames with CRC errors - */ - double get_fm_crc_err() - { - return _fm_crc_err; - }; - /** - * @brief Number of date inconsistencies - */ - int get_date_incons() - { - return _date_incons; - }; - /** - * @brief Number of unexpected PRF changes - */ - int get_prf_changes() - { - return _prf_changes; - }; - /** - * @brief Number of delay changes - */ - int get_delay_changes() - { - return _delay_changes; - }; - /** - * @brief Number of skipped frames - */ - int get_skipd_frams() - { - return _skipd_frams; - }; - /** - * @brief Range lines rejected before start time - */ - int get_rej_bf_start() - { - return _rej_bf_start; - }; - /** - * @brief Range lines rejected due to too few frames - */ - int get_rej_few_fram() - { - return _rej_few_fram; - }; - /** - * @brief Range lines rejected due to too many frames - */ - int get_rej_many_fram() - { - return _rej_many_fram; - }; - /** - * @brief Frames rejected due to master channel error - */ - int get_rej_mchn_err() - { - return _rej_mchn_err; - }; - /** - * @brief Frames rejected due to virtual channel error - */ - int get_rej_vchn_err() - { - return _rej_vchn_err; - }; - /** - * @brief Frames rejected due to incorrect recording type - */ - int get_rej_rec_type() - { - return _rej_rec_type; - }; - /** - * @brief Sensor configuration - */ - std::string get_sens_config() - { - return _sens_config; - }; - /** - * @brief Sensor orientation - */ - std::string get_sens_orient() - { - return _sens_orient; - }; - /** - * @brief Frame synch marker - */ - std::string get_sych_marker() - { - return _sych_marker; - }; - /** - * @brief Range reference function source - */ - std::string get_rng_ref_src() - { - return _rng_ref_src; - }; - /** - * @brief Range reference amplitude coefficients - */ - double* get_rng_amp_coef() - { - return _rng_amp_coef; - }; - /** - * @brief Range reference phase coefficients - */ - double* get_rng_phas_coef() - { - return _rng_phas_coef; - }; - /** - * @brief Error function amplitude coefficients - */ - double* get_err_amp_coef() - { - return _err_amp_coef; - }; - /** - * @brief Error function phase coefficients - */ - double* get_err_phas_coef() - { - return _err_phas_coef; - }; - /** - * @brief Pulse bandwidth code - */ - int get_pulse_bandw() - { - return _pulse_bandw; - }; - /** - * @brief ADC sampling rate - */ - std::string get_adc_samp_rate() - { - return _adc_samp_rate; - }; - /** - * @brief Replica AGC attenuation - */ - double get_rep_agc_attn() - { - return _rep_agc_attn; - }; - /** - * @brief Gain correction factor (dB) - */ - double get_gn_corctn_fctr() - { - return _gn_corctn_fctr; - }; - /** - * @brief Replica energy gain correction - */ - double get_rep_energy_gn() - { - return _rep_energy_gn; - }; - /** - * @brief Orbit data source - */ - std::string get_orb_data_src() - { - return _orb_data_src; - }; - /** - * @brief Pulse count 1 - */ - int get_pulse_cnt_1() - { - return _pulse_cnt_1; - }; - /** - * @brief Pulse count 2 - */ - int get_pulse_cnt_2() - { - return _pulse_cnt_2; - }; - /** - * @brief Beam edge detection requested - */ - std::string get_beam_edge_rqd() - { - return _beam_edge_rqd; - }; - /** - * @brief Beam edge confidence measure - */ - double get_beam_edge_conf() - { - return _beam_edge_conf; - }; - /** - * @brief Number of pixels in beam overlap - */ - int get_pix_overlap() - { - return _pix_overlap; - }; - /** - * @brief Number of beams - */ - int get_n_beams() - { - return _n_beams; - }; - /** - * @brief Beam info - */ - BeamInformationRecord* get_beam_info() - { - return _beam_info; - }; - /** - * @brief Number of pixel count updates - */ - int get_n_pix_updates() - { - return _n_pix_updates; - }; - /** - * @brief Beam pixel counts - */ - BeamPixelCountRecord* get_pix_count() - { - return _pix_count; - }; - /** - * @brief Processing window start time (sec) - */ - double get_pwin_start() - { - return _pwin_start; - }; - /** - * @brief Processing window end time (sec) - */ - double get_pwin_end() - { - return _pwin_end; - }; - /** - * @brief Recording type - */ - std::string get_recd_type() - { - return _recd_type; - }; - /** - * @brief Time increment between temperature settings (sec) - */ - double get_temp_set_inc() - { - return _temp_set_inc; - }; - /** - * @brief Number of temperature settings - */ - int get_n_temp_set() - { - return _n_temp_set; - }; - /** - * @brief Temperature settings - */ - TemperatureSettingsRecord* get_temp() - { - return _temp; - }; - /** - * @brief Number of image pixels - */ - int get_n_image_pix() - { - return _n_image_pix; - }; - /** - * @brief Percent zero pixels - */ - double get_prc_zero_pix() - { - return _prc_zero_pix; - }; - /** - * @brief Percent saturated pixels - */ - double get_prc_satur_pix() - { - return _prc_satur_pix; - }; - /** - * @brief Image histogram mean intensity - */ - double get_img_hist_mean() - { - return _img_hist_mean; - }; - /** - * @brief Image cumulative distribution - */ - double* get_img_cumu_dist() - { - return _img_cumu_dist; - }; - /** - * @brief Pre-image calibration gain factor - */ - double get_pre_img_gn() - { - return _pre_img_gn; - }; - /** - * @brief Post-image calibration gain factor - */ - double get_post_img_gn() - { - return _post_img_gn; - }; - /** - * @brief Time increment between Dopcen estimates (sec) - */ - double get_dopcen_inc() - { - return _dopcen_inc; - }; - /** - * @brief Number of Doppler centroid estimates - */ - int get_n_dopcen() - { - return _n_dopcen; - }; - /** - * @brief Doppler centroid estimates - */ - DopplerCentroidEstimateRecord* get_dopcen_est() - { - return _dopcen_est; - }; - /** - * @brief Doppler ambiguity error - */ - int get_dop_amb_err() - { - return _dop_amb_err; - }; - /** - * @brief Doppler ambiguity confidence measure - */ - double get_dopamb_conf() - { - return _dopamb_conf; - }; - /** - * @brief Ephemeris orbit data - */ - double* get_eph_orb_data() - { - return _eph_orb_data; - }; - /** - * @brief Application type - */ - std::string get_appl_type() - { - return _appl_type; - }; - /** - * @brief Slow time coefficients - * @todo Verifier le type de la variable lors de la lecture de la donnee - */ - double* get_slow_time_coef() - { - return _slow_time_coef; - }; - /** - * @brief Number of SRGR coefficient sets - */ - int get_n_srgr() - { - return _n_srgr; - }; - /** - * @brief SRGR coefficient sets - */ - SRGRCoefficientSetRecord* get_srgr_coefset() - { - return _srgr_coefset; - }; - /** - * @brief SGF product pixel spacing - */ - double get_pixel_spacing() - { - return _pixel_spacing; - }; - /** - * @brief GICS product required - */ - std::string get_gics_reqd() - { - return _gics_reqd; - }; - /** - * @brief Work order identifier - */ - std::string get_wo_number() - { - return _wo_number; - }; - /** - * @brief Work order entry date - */ - std::string get_wo_date() - { - return _wo_date; - }; - /** - * @brief Satellite identifier - */ - std::string get_satellite_id() - { - return _satellite_id; - }; - /** - * @brief User id - */ - std::string get_user_id() - { - return _user_id; - }; - /** - * @brief Completion message required flag - */ - std::string get_complete_msg() - { - return _complete_msg; - }; - /** - * @brief SGF product scene identifier - */ - std::string get_scene_id() - { - return _scene_id; - }; - /** - * @brief Density of SGF product media - */ - std::string get_density_in() - { - return _density_in; - }; - /** - * @brief SGF product identifier - */ - std::string get_media_id() - { - return _media_id; - }; - /** - * @brief Incidence angle of first pixel in SGF product line - */ - double get_angle_first() - { - return _angle_first; - }; - /** - * @brief Incidence angle of last pixel in SGF product line - */ - double get_angle_last() - { - return _angle_last; - }; - /** - * @brief GICS output product type - */ - std::string get_prod_type() - { - return _prod_type; - }; - /** - * @brief Map system identifier - */ - std::string get_map_system() - { - return _map_system; - }; - /** - * @brief GICS output product scene centre latitude - */ - double get_centre_lat() - { - return _centre_lat; - }; - /** - * @brief GICS output product scene centre longitude - */ - double get_centre_long() - { - return _centre_long; - }; - /** - * @brief GICS output product size - map eastings (km) - */ - double get_span_x() - { - return _span_x; - }; - /** - * @brief GICS output product size - map northings (km) - */ - double get_span_y() - { - return _span_y; - }; - /** - * @brief DTM correction to be applied flag - */ - std::string get_apply_dtm() - { - return _apply_dtm; - }; - /** - * @brief GICS output product density - */ - std::string get_density_out() - { - return _density_out; - }; - /** - * @brief Time of the first state vector - */ - std::string get_state_time() - { - return _state_time; - }; - /** - * @brief Number of state vectors - */ - int get_num_state_vectors() - { - return _num_state_vectors; - }; - /** - * @brief Time increment between state vectors - */ - double get_state_time_inc() - { - return _state_time_inc; - }; - -protected: - /** - * @brief Record sequence number - */ - int _rec_seq; - - /** - * @brief Input media - */ - std::string _inp_media; - /** - * @brief Number of tape input ids - */ - int _n_tape_id; - /** - * @brief Tape identifiers - */ - std::string _tape_id[10]; - /** - * @brief Expected ingest start time - */ - std::string _exp_ing_start; - /** - * @brief Expected ingest stop time - */ - std::string _exp_ing_stop; - /** - * @brief Actual ingest start time - */ - std::string _act_ing_start; - /** - * @brief Actual ingest stop time - */ - std::string _act_ing_stop; - /** - * @brief Processing start time - */ - std::string _proc_start; - /** - * @brief Processing stop time - */ - std::string _proc_stop; - /** - * @brief Mean signal levels across range - */ - double _mn_sig_lev[10]; - /** - * @brief Source data quality indicator - */ - int _scr_data_ind; - /** - * @brief Number of missing lines - */ - int _miss_ln; - /** - * @brief Number of rejected lines - */ - int _rej_ln; - /** - * @brief Number of time inconsistencies (large gaps) - */ - int _large_gap; - /** - * @brief Measured bit error rate - */ - double _bit_err_rate; - /** - * @brief Percent of frames with CRC errors - */ - double _fm_crc_err; - /** - * @brief Number of date inconsistencies - */ - int _date_incons; - /** - * @brief Number of unexpected PRF changes - */ - int _prf_changes; - /** - * @brief Number of delay changes - */ - int _delay_changes; - /** - * @brief Number of skipped frames - */ - int _skipd_frams; - /** - * @brief Range lines rejected before start time - */ - int _rej_bf_start; - /** - * @brief Range lines rejected due to too few frames - */ - int _rej_few_fram; - /** - * @brief Range lines rejected due to too many frames - */ - int _rej_many_fram; - /** - * @brief Frames rejected due to master channel error - */ - int _rej_mchn_err; - /** - * @brief Frames rejected due to virtual channel error - */ - int _rej_vchn_err; - /** - * @brief Frames rejected due to incorrect recording type - */ - int _rej_rec_type; - /** - * @brief Sensor configuration - */ - std::string _sens_config; - /** - * @brief Sensor orientation - */ - std::string _sens_orient; - /** - * @brief Frame synch marker - */ - std::string _sych_marker; - /** - * @brief Range reference function source - */ - std::string _rng_ref_src; - /** - * @brief Range reference amplitude coefficients - */ - double _rng_amp_coef[4]; - /** - * @brief Range reference phase coefficients - */ - double _rng_phas_coef[4]; - /** - * @brief Error function amplitude coefficients - */ - double _err_amp_coef[16]; - /** - * @brief Error function phase coefficients - */ - double _err_phas_coef[4]; - /** - * @brief Pulse bandwidth code - */ - int _pulse_bandw; - /** - * @brief ADC sampling rate - */ - std::string _adc_samp_rate; - /** - * @brief Replica AGC attenuation - */ - double _rep_agc_attn; - /** - * @brief Gain correction factor (dB) - */ - double _gn_corctn_fctr; - /** - * @brief Replica energy gain correction - */ - double _rep_energy_gn; - /** - * @brief Orbit data source - */ - std::string _orb_data_src; - /** - * @brief Pulse count 1 - */ - int _pulse_cnt_1; - /** - * @brief Pulse count 2 - */ - int _pulse_cnt_2; - /** - * @brief Beam edge detection requested - */ - std::string _beam_edge_rqd; - /** - * @brief Beam edge confidence measure - */ - double _beam_edge_conf; - /** - * @brief Number of pixels in beam overlap - */ - int _pix_overlap; - /** - * @brief Number of beams - */ - int _n_beams; - /** - * @brief Beam info - */ - BeamInformationRecord _beam_info[4]; - /** - * @brief Number of pixel count updates - */ - int _n_pix_updates; - /** - * @brief Beam pixel counts - */ - BeamPixelCountRecord _pix_count[20]; - /** - * @brief Processing window start time (sec) - */ - double _pwin_start; - /** - * @brief Processing window end time (sec) - */ - double _pwin_end; - /** - * @brief Recording type - */ - std::string _recd_type; - /** - * @brief Time increment between temperature settings (sec) - */ - double _temp_set_inc; - /** - * @brief Number of temperature settings - */ - int _n_temp_set; - /** - * @brief Temperature settings - */ - TemperatureSettingsRecord _temp[20]; - /** - * @brief Number of image pixels - */ - int _n_image_pix; - /** - * @brief Percent zero pixels - */ - double _prc_zero_pix; - /** - * @brief Percent saturated pixels - */ - double _prc_satur_pix; - /** - * @brief Image histogram mean intensity - */ - double _img_hist_mean; - /** - * @brief Image cumulative distribution - */ - double _img_cumu_dist[3]; - /** - * @brief Pre-image calibration gain factor - */ - double _pre_img_gn; - /** - * @brief Post-image calibration gain factor - */ - double _post_img_gn; - /** - * @brief Time increment between Dopcen estimates (sec) - */ - double _dopcen_inc; - /** - * @brief Number of Doppler centroid estimates - */ - int _n_dopcen; - /** - * @brief Doppler centroid estimates - */ - DopplerCentroidEstimateRecord _dopcen_est[20]; - /** - * @brief Doppler ambiguity error - */ - int _dop_amb_err; - /** - * @brief Doppler ambiguity confidence measure - */ - double _dopamb_conf; - /** - * @brief Ephemeris orbit data - */ - double _eph_orb_data[7]; - /** - * @brief Application type - */ - std::string _appl_type; - /** - * @brief Slow time coefficients - * @todo Verifier le type de la variable lors de la lecture de la donnee - */ - double _slow_time_coef[5]; - /** - * @brief Number of SRGR coefficient sets - */ - int _n_srgr; - /** - * @brief SRGR coefficient sets - */ - SRGRCoefficientSetRecord _srgr_coefset[20]; - /** - * @brief SGF product pixel spacing - */ - double _pixel_spacing; - /** - * @brief GICS product required - */ - std::string _gics_reqd; - /** - * @brief Work order identifier - */ - std::string _wo_number; - /** - * @brief Work order entry date - */ - std::string _wo_date; - /** - * @brief Satellite identifier - */ - std::string _satellite_id; - /** - * @brief User id - */ - std::string _user_id; - /** - * @brief Completion message required flag - */ - std::string _complete_msg; - /** - * @brief SGF product scene identifier - */ - std::string _scene_id; - /** - * @brief Density of SGF product media - */ - std::string _density_in; - /** - * @brief SGF product identifier - */ - std::string _media_id; - /** - * @brief Incidence angle of first pixel in SGF product line - */ - double _angle_first; - /** - * @brief Incidence angle of last pixel in SGF product line - */ - double _angle_last; - /** - * @brief GICS output product type - */ - std::string _prod_type; - /** - * @brief Map system identifier - */ - std::string _map_system; - /** - * @brief GICS output product scene centre latitude - */ - double _centre_lat; - /** - * @brief GICS output product scene centre longitude - */ - double _centre_long; - /** - * @brief GICS output product size - map eastings (km) - */ - double _span_x; - /** - * @brief GICS output product size - map northings (km) - */ - double _span_y; - /** - * @brief DTM correction to be applied flag - */ - std::string _apply_dtm; - /** - * @brief GICS output product density - */ - std::string _density_out; - /** - * @brief Time of the first state vector - */ - std::string _state_time; - /** - * @brief Number of state vectors - */ - int _num_state_vectors; - /** - * @brief Time increment between state vectors - */ - double _state_time_inc; - -private: -}; -#endif diff --git a/Utilities/otbossim/include/ossim/imaging/RadarSat/Leader/RadiometricCompensationData.h b/Utilities/otbossim/include/ossim/imaging/RadarSat/Leader/RadiometricCompensationData.h deleted file mode 100644 index 79e15e2628f40293ae2b01ace049e28278276e63..0000000000000000000000000000000000000000 --- a/Utilities/otbossim/include/ossim/imaging/RadarSat/Leader/RadiometricCompensationData.h +++ /dev/null @@ -1,140 +0,0 @@ -#ifndef RadiometricCompensationData_h -#define RadiometricCompensationData_h - -#include <iostream> - -#include <ossim/imaging/RadarSat/RadarSatRecord.h> -#include <ossim/imaging/RadarSat/RadarSatRecordHeader.h> - -#include <ossim/imaging/RadarSat/Leader/CompensationDataRecord.h> -/** - * @ingroup RadiometricCompensationDataRecord - * @brief This class is able to read a Radiometric Compensation data record - * @author Magellium, Pacome Dentraygues - * @version 1.0 - * @date 03-12-07 - */ -class RadiometricCompensationData : public RadarSatRecord -{ -public: - /** - * @brief Constructor - */ - RadiometricCompensationData(); - - /** - * @brief Destructor - */ - ~RadiometricCompensationData(); - - /** - * @brief Copy constructor - */ - RadiometricCompensationData(const RadiometricCompensationData& rhs); - - /** - * @brief Copy operator - */ - RadiometricCompensationData& operator=(const RadiometricCompensationData& rhs); - /** - * @brief This function writes the RadiometricCompensationData in a stream - */ - friend std::ostream& operator<<(std::ostream& os, const RadiometricCompensationData& data); - - /** - * @brief This function reads a RadiometricCompensationData from a stream - */ - friend std::istream& operator>>(std::istream& is, RadiometricCompensationData& data); - - /** - * @brief This function is able to create a new instance of the class - */ - RadarSatRecord* Instanciate() - { - return new RadiometricCompensationData(); - }; - - /** - * @brief This function is able to create a new instance of the class initialised with the data of the calling instance - */ - RadarSatRecord* Clone() - { - return new RadiometricCompensationData(*this); - }; - - /** - * @brief Reads the class data from a stream - */ - void Read(std::istream& is) - { - is>>*this; - }; - - /** - * @brief Writes the class to a stream - */ - void Write(std::ostream& os) - { - os<<*this; - }; - - /** - * @brief Record sequence number - */ - int get_seq_num() - { - return _seq_num; - }; - /** - * @brief SAR channel indicator - */ - int get_chan_ind() - { - return _chan_ind; - }; - /** - * @brief Number of data sets in record - */ - int get_n_dset() - { - return _n_dset; - }; - /** - * @brief Compensation data set size - */ - int get_dset_size() - { - return _dset_size; - }; - /** - * @brief Compensation data set records - */ - CompensationDataRecord* get_dset() - { - return _dset; - }; - -protected: - /** - * @brief Record sequence number - */ - int _seq_num; - /** - * @brief SAR channel indicator - */ - int _chan_ind; - /** - * @brief Number of data sets in record - */ - int _n_dset; - /** - * @brief Compensation data set size - */ - int _dset_size; - /** - * @brief Compensation data set records - */ - CompensationDataRecord _dset[4]; -private: -}; -#endif diff --git a/Utilities/otbossim/include/ossim/imaging/RadarSat/Leader/RadiometricData.h b/Utilities/otbossim/include/ossim/imaging/RadarSat/Leader/RadiometricData.h deleted file mode 100644 index b6fdaed36a1870131422c7716bf1c514cd7bdba3..0000000000000000000000000000000000000000 --- a/Utilities/otbossim/include/ossim/imaging/RadarSat/Leader/RadiometricData.h +++ /dev/null @@ -1,225 +0,0 @@ -#ifndef RadiometricData_h -#define RadiometricData_h - -#include <iostream> -#include <ossim/imaging/RadarSat/RadarSatRecord.h> -#include <ossim/imaging/RadarSat/RadarSatRecordHeader.h> - -/** - * @ingroup RadiometricDataRecord - * @brief This class is able to read a radiometric data record - * @author Magellium, Pacome Dentraygues - * @version 1.0 - * @date 03-12-07 - */ -class RadiometricData : public RadarSatRecord -{ -public: - /** - * @brief Constructor - */ - RadiometricData(); - - /** - * @brief Destructor - */ - ~RadiometricData(); - - /** - * @brief Copy constructor - */ - RadiometricData(const RadiometricData& rhs); - - /** - * @brief Copy operator - */ - RadiometricData& operator=(const RadiometricData& rhs); - /** - * @brief This function writes the RadiometricData in a stream - */ - friend std::ostream& operator<<(std::ostream& os, const RadiometricData& data); - - /** - * @brief This function reads a RadiometricData from a stream - */ - friend std::istream& operator>>(std::istream& is, RadiometricData& data); - - /** - * @brief This function is able to create a new instance of the class - */ - RadarSatRecord* Instanciate() - { - return new RadiometricData(); - }; - - /** - * @brief This function is able to create a new instance of the class initialised with the data of the calling instance - */ - RadarSatRecord* Clone() - { - return new RadiometricData(*this); - }; - - /** - * @brief Reads the class data from a stream - */ - void Read(std::istream& is) - { - is>>*this; - }; - - /** - * @brief Writes the class to a stream - */ - void Write(std::ostream& os) - { - os<<*this; - }; - - /** - * @brief Record sequence number - */ - int get_seq_num() - { - return _seq_num; - }; - /** - * @brief Number of data fields - */ - int get_n_data() - { - return _n_data; - }; - /** - * @brief Field size in bytes - */ - int get_field_size() - { - return _field_size; - }; - - /** - * @brief SAR channel indicator - */ - std::string get_chan_ind() - { - return _chan_ind; - }; - - /** - * @brief Table designator - */ - std::string get_table_desig() - { - return _table_desig; - }; - /** - * @brief Number of lookup table samples - */ - int get_n_samp() - { - return _n_samp; - }; - /** - * @brief Sample type designator - */ - std::string get_samp_type() - { - return _samp_type; - }; - /** - * @brief Increment between table entries, range samples - */ - int get_samp_inc() - { - return _samp_inc; - }; - /** - * @brief Output scaling gain table - */ - double* get_lookup_tab() - { - return _lookup_tab; - }; - - /** - * @brief Thermal noise reference level - */ - double get_noise_scale() - { - return _noise_scale; - }; - - /** - * @brief Scaling offset - */ - double get_offset() - { - return _offset; - }; - /** - * @brief Calibration constant - */ - double get_calib_const() - { - return _calib_const; - }; - - -protected: - /** - * @brief Record sequence number - */ - int _seq_num; - /** - * @brief Number of data fields - */ - int _n_data; - /** - * @brief Field size in bytes - */ - int _field_size; - - /** - * @brief SAR channel indicator - */ - std::string _chan_ind; - - /** - * @brief Table designator - */ - std::string _table_desig; - /** - * @brief Number of lookup table samples - */ - int _n_samp; - /** - * @brief Sample type designator - */ - std::string _samp_type; - /** - * @brief Increment between table entries, range samples - */ - int _samp_inc; - /** - * @brief Output scaling gain table - */ - double _lookup_tab[512]; - - /** - * @brief Thermal noise reference level - */ - double _noise_scale; - - /** - * @brief Scaling offset - */ - double _offset; - /** - * @brief Calibration constant - */ - double _calib_const; - -private: -}; -#endif diff --git a/Utilities/otbossim/include/ossim/imaging/RadarSat/Leader/RadiometryUncertaintyRecord.h b/Utilities/otbossim/include/ossim/imaging/RadarSat/Leader/RadiometryUncertaintyRecord.h deleted file mode 100644 index 79950a7a195e6d8f4a4ce60c9b4db4bf669abad9..0000000000000000000000000000000000000000 --- a/Utilities/otbossim/include/ossim/imaging/RadarSat/Leader/RadiometryUncertaintyRecord.h +++ /dev/null @@ -1,74 +0,0 @@ -#ifndef RadiometryUncertaintyRecord_h -#define RadiometryUncertaintyRecord_h - -#include<iostream> -#include <ossim/imaging/RadarSat/RadarSatRecord.h> -/** - * @ingroup DataQualitySummaryRecord - * @brief This class is able to read a radiometry uncertainty record - * @author Magellium, Pacome Dentraygues - * @version 1.0 - * @date 23-11-07 - */ -class RadiometryUncertaintyRecord -{ -public: - /** - * @brief Constructor - */ - RadiometryUncertaintyRecord(); - - /** - * @brief Destructor - */ - ~RadiometryUncertaintyRecord(); - - /** - * @brief Copy constructor - */ - RadiometryUncertaintyRecord(const RadiometryUncertaintyRecord& rhs); - - /** - * @brief Copy operator - */ - RadiometryUncertaintyRecord& operator=(const RadiometryUncertaintyRecord& rhs); - /** - * @brief This function writes the RadiometryUncertaintyRecord in a stream - */ - friend std::ostream& operator<<(std::ostream& os, const RadiometryUncertaintyRecord& data); - - /** - * @brief This function reads a RadiometryUncertaintyRecord from a stream - */ - friend std::istream& operator>>(std::istream& is, RadiometryUncertaintyRecord& data); - - /** - * @brief Units of db - */ - double get_db() - { - return _db; - }; - /** - * @brief Units of deg - */ - double get_deg() - { - return _deg; - }; -protected: - - /** - * @brief Units of db - */ - double _db; - /** - * @brief Units of deg - */ - double _deg; -private: - - -}; - -#endif \ No newline at end of file diff --git a/Utilities/otbossim/include/ossim/imaging/RadarSat/Leader/SRGRCoefficientSetRecord.h b/Utilities/otbossim/include/ossim/imaging/RadarSat/Leader/SRGRCoefficientSetRecord.h deleted file mode 100644 index 2fab270a45b399e778b549576bc487f48187a124..0000000000000000000000000000000000000000 --- a/Utilities/otbossim/include/ossim/imaging/RadarSat/Leader/SRGRCoefficientSetRecord.h +++ /dev/null @@ -1,76 +0,0 @@ -#ifndef SRGRCoefficientSetRecord_h -#define SRGRCoefficientSetRecord_h - -#include <iostream> -#include <ossim/imaging/RadarSat/RadarSatRecord.h> - -/** - * @ingroup ProcessingParametersRecord - * @brief This class is able to read a SRGR coefficients set record - * @author Magellium, Pacome Dentraygues - * @version 1.0 - * @date 30-11-07 - */ -class SRGRCoefficientSetRecord -{ -public: - /** - * @brief Constructor - */ - SRGRCoefficientSetRecord(); - - /** - * @brief Destructor - */ - ~SRGRCoefficientSetRecord(); - - /** - * @brief Copy constructor - */ - SRGRCoefficientSetRecord(const SRGRCoefficientSetRecord& rhs); - - /** - * @brief Copy operator - */ - SRGRCoefficientSetRecord& operator=(const SRGRCoefficientSetRecord& rhs); - - /** - * @brief This function writes the SRGRCoefficientSetRecord in a stream - */ - friend std::ostream& operator<<(std::ostream& os, const SRGRCoefficientSetRecord& data); - - /** - * @brief This function reads a SRGRCoefficientSetRecord from a stream - */ - friend std::istream& operator>>(std::istream& is, SRGRCoefficientSetRecord& data); - - /** - * @brief SRGR update date/time - */ - std::string get_srgr_update() - { - return _srgr_update; - } - - /** - * @brief SRGR coefficients - */ - double* get_srgr_coef() - { - return _srgr_coef; - } - -protected: - /** - * @brief SRGR update date/time - */ - std::string _srgr_update; - - /** - * @brief SRGR coefficients - */ - double _srgr_coef[6]; -private: - -}; -#endif \ No newline at end of file diff --git a/Utilities/otbossim/include/ossim/imaging/RadarSat/Leader/TemperatureSettingsRecord.h b/Utilities/otbossim/include/ossim/imaging/RadarSat/Leader/TemperatureSettingsRecord.h deleted file mode 100644 index 984b8b95b598c64849cdaf5bb7f984c575c5221b..0000000000000000000000000000000000000000 --- a/Utilities/otbossim/include/ossim/imaging/RadarSat/Leader/TemperatureSettingsRecord.h +++ /dev/null @@ -1,64 +0,0 @@ -#ifndef TemperatureSettingsRecord_h -#define TemperatureSettingsRecord_h - -#include <iostream> -#include <ossim/imaging/RadarSat/RadarSatRecord.h> - -/** - * @ingroup ProcessingParametersRecord - * @brief This class is able to read a Temperature Settings record - * @author Magellium, Pacome Dentraygues - * @version 1.0 - * @date 30-11-07 - */ -class TemperatureSettingsRecord -{ -public: - /** - * @brief Constructor - */ - TemperatureSettingsRecord(); - - /** - * @brief Destructor - */ - ~TemperatureSettingsRecord(); - - /** - * @brief Copy constructor - */ - TemperatureSettingsRecord(const TemperatureSettingsRecord& rhs); - - /** - * @brief Copy operator - */ - TemperatureSettingsRecord& operator=(const TemperatureSettingsRecord& rhs); - - /** - * @brief This function writes the TemperatureSettingsRecord in a stream - */ - friend std::ostream& operator<<(std::ostream& os, const TemperatureSettingsRecord& data); - - /** - * @brief This function reads a TemperatureSettingsRecord from a stream - */ - friend std::istream& operator>>(std::istream& is, TemperatureSettingsRecord& data); - - /** - * @brief Temperature settings - */ - int* get_temp_set() - { - return _temp_set; - }; - -protected: - - /** - * @brief Temperature settings - */ - int _temp_set[4]; -private: - -}; -#endif \ No newline at end of file diff --git a/Utilities/otbossim/include/ossim/imaging/RadarSat/RadarSatRecord.h b/Utilities/otbossim/include/ossim/imaging/RadarSat/RadarSatRecord.h deleted file mode 100644 index e613732374f3c8851f5e391989cd1c25d97ab319..0000000000000000000000000000000000000000 --- a/Utilities/otbossim/include/ossim/imaging/RadarSat/RadarSatRecord.h +++ /dev/null @@ -1,66 +0,0 @@ -#ifndef RadarSatRecord_h -#define RadarSatRecord_h - - -#include <ossim/imaging/RadarSat/RadarSatRecordHeader.h> -#include <iostream> -#include <cstdlib> - -/** - * @ingroup RadarSat - * @brief This class is the base class of all the record classes - * @author Magellium, Pacome Dentraygues - * @version 1.0 - * @date 23-11-07 - */ -class RadarSatRecord -{ -public: - /** - * @brief Constructor - * @param mnemonic Name of the record - */ - RadarSatRecord(std::string mnemonic); - /** - * @brief Destructor - */ - ~RadarSatRecord(); - - /** - * @brief Copy constructor - */ - RadarSatRecord(const RadarSatRecord& rhs); - - /** - * @brief This function is able to create a new instance of the class - */ - virtual RadarSatRecord* Instanciate() =0; - - /** - * @brief This function is able to create a new instance of the class initialised with the data of the calling instance - */ - virtual RadarSatRecord* Clone()=0; - - /** - * @brief Reads the class data from a stream - */ - virtual void Read(std::istream& is) =0; - - /** - * @brief Writes the class to a stream - */ - virtual void Write(std::ostream& os)=0; - - std::string get_mnemonic() - { - return _mnemonic; - }; - -protected: - - std::string _mnemonic; - -private: -}; - -#endif \ No newline at end of file diff --git a/Utilities/otbossim/include/ossim/imaging/RadarSat/RadarSatRecordFactory.h b/Utilities/otbossim/include/ossim/imaging/RadarSat/RadarSatRecordFactory.h deleted file mode 100644 index 6698b9adbc8f76c0a6dab9634d2b38c337411871..0000000000000000000000000000000000000000 --- a/Utilities/otbossim/include/ossim/imaging/RadarSat/RadarSatRecordFactory.h +++ /dev/null @@ -1,49 +0,0 @@ -#ifndef RadarSatRecordFactory_h -#define RadarSatRecordFactory_h - - -#include <ossim/imaging/RadarSat/RadarSatRecordHeader.h> -#include <ossim/imaging/RadarSat/RadarSatRecord.h> -#include <map> -/** - * @ingroup RadarSat - * @brief This class is a factory able to construct Record base classes given the id of the wanted record - * @author Magellium, Pacome Dentraygues - * @version 1.0 - * @date 23-11-07 - */ -class RadarSatRecordFactory -{ -public: - /** - * @brief Constructor - */ - RadarSatRecordFactory(); - /** - * @brief Destructor - */ - ~RadarSatRecordFactory(); - - /** - * @brief Add a new Record type available in this factory - * @param record Record to add in the factory - * @param id Id of the new available Record - */ - void RegisterRecord(int id, RadarSatRecord * record); - - /** - * @brief Instanciates a new Record - * @param id Id of the Record we want to instanciate - */ - RadarSatRecord* Instanciate(int id) ; -protected: - - /** - * @brief Contains all the available Records for the factory - */ - std::map<int, RadarSatRecord*> _availableRecords; - -private: -}; - -#endif \ No newline at end of file diff --git a/Utilities/otbossim/include/ossim/imaging/RadarSat/RadarSatRecordHeader.h b/Utilities/otbossim/include/ossim/imaging/RadarSat/RadarSatRecordHeader.h deleted file mode 100644 index 99ad20e767138381c92dd95159dfe7b21d94345b..0000000000000000000000000000000000000000 --- a/Utilities/otbossim/include/ossim/imaging/RadarSat/RadarSatRecordHeader.h +++ /dev/null @@ -1,129 +0,0 @@ -#ifndef RadarSatRecordHeader_h -#define RadarSatRecordHeader_h - -#include<iostream> -#include<cstring> - -/** - * @ingroup RadarSat - * @brief This class is able to read a record header - * @author Magellium, Pacome Dentraygues - * @version 1.0 - * @date 23-11-07 - */ -class RadarSatRecordHeader -{ -public: - /** - * @brief Constructor - */ - RadarSatRecordHeader(); - - /** - * @brief Destructor - */ - ~RadarSatRecordHeader(); - - /** - * @brief Copy constructor - */ - RadarSatRecordHeader(const RadarSatRecordHeader& rhs); - - /** - * @brief Copy operator - */ - RadarSatRecordHeader& operator=(const RadarSatRecordHeader& rhs); - /** - * @brief This function writes the RecordHeader in a stream - */ - friend std::ostream& operator<<(std::ostream& os, const RadarSatRecordHeader& data); - - /** - * @brief This function reads a RecordHeader from a stream - */ - friend std::istream& operator>>(std::istream& is, RadarSatRecordHeader& data); - - /** - * @brief Record sequence number - */ - int get_rec_seq() - { - return _rec_seq; - }; - - /** - * @brief First record sub-type code - */ - unsigned char get_rec_sub1() - { - return _rec_sub1; - }; - - /** - * @brief Record type code - */ - unsigned char get_rec_type() - { - return _rec_type; - }; - - /** - * @brief Second record sub-type code - */ - unsigned char get_rec_sub2() - { - return _rec_sub2; - }; - - /** - * @brief Third record sub-type code - */ - unsigned char get_rec_sub3() - { - return _rec_sub3; - }; - - /** - * @brief Length of this record (in bytes) - */ - int get_length() - { - return _length; - }; -protected: - - /** - * @brief This function switches the LSB value and the MSB value of the parameter - */ - void SwitchEndian(int& value); - - /** - * @brief Record sequence number - */ - int _rec_seq; - /** - * @brief First record sub-type code - */ - unsigned char _rec_sub1; - /** - * @brief Record type code - */ - unsigned char _rec_type; - /** - * @brief Second record sub-type code - */ - unsigned char _rec_sub2; - /** - * @brief Third record sub-type code - */ - unsigned char _rec_sub3; - /** - * @brief Length of this record (in bytes) - */ - int _length; -private: - - -}; - -#endif \ No newline at end of file diff --git a/Utilities/otbossim/include/ossim/imaging/ossimEnvisatAsarTileSource.h b/Utilities/otbossim/include/ossim/imaging/ossimEnvisatAsarTileSource.h deleted file mode 100644 index 5569665eca7ec16460df407d8083b7e8ed1e00f8..0000000000000000000000000000000000000000 --- a/Utilities/otbossim/include/ossim/imaging/ossimEnvisatAsarTileSource.h +++ /dev/null @@ -1,108 +0,0 @@ -#ifndef ossimEnvisatAsarTileSource_H -#define ossimEnvisatAsarTileSource_H - - -#include <ossim/imaging/ossimImageHandler.h> -#include <ossim/base/ossimIrect.h> -#include <ossim/imaging/EnvisatAsar/EnvisatAsarData.h> - -class ossimImageData; - -/** - * @brief This class is able to read an EnvisatAsar file structure - * @author Magellium, Pacome Dentraygues - * @version 1.0 - * @date 10-12-07 - */ -class OSSIMDLLEXPORT ossimEnvisatAsarTileSource : public ossimImageHandler -{ -public: - ossimEnvisatAsarTileSource(); - - virtual ~ossimEnvisatAsarTileSource(); - - virtual ossimString getLongName() const; - virtual ossimString getShortName() const; - - /*! - * Method to save the state of an object to a keyword list. - * Return true if ok or false on error. - */ - virtual bool saveState(ossimKeywordlist& kwl, - const char* prefix=0)const; - - /*! - * Method to the load (recreate) the state of an object from a keyword - * list. Returns true if ok or false on error. - */ - virtual bool loadState(const ossimKeywordlist& kwl, - const char* prefix=0); - - /*! - * Returns true if the image_file can be opened and is a valid tiff file. - */ - virtual bool open(); - virtual void close(); - virtual bool isOpen()const; - /*! - * Returns the number of lines in the image. - * Satisfies pure virtual from ImageHandler class. - */ - virtual ossim_uint32 getNumberOfLines(ossim_uint32 reduced_res_level = 0) const - { - return 0; - }; - - /*! - * Returns the number of samples in the image. - * Satisfies pure virtual from ImageHandler class. - */ - virtual ossim_uint32 getNumberOfSamples(ossim_uint32 reduced_res_level = 0) const - { - return 0; - }; - /*! - * Returns the width of the output tile. - */ - virtual ossim_uint32 getImageTileWidth() const - { - return 0; - }; - - /*! - * Returns the height of the output tile. - */ - virtual ossim_uint32 getImageTileHeight() const - { - return 0; - }; - /*! - * Returns the number of bands in the image. - * Satisfies pure virtual from ImageHandler class. - */ - virtual ossim_uint32 getNumberOfInputBands() const - { - return 0; - }; - - /** - * @brief Populates the keyword list with image geometry information - * - * This method is used to relay projection/model information to users. - * @param kwl Keyword list that will be initialized with geometry info. Returns true if geometry info is present, false if not. - * @param prefix The prefix is added to the resulting keyword list keywords. So is you if you pass in a prefix of "image01.", the keyword ul_lat will be like: "image01.ul_lat: -40.00000" - */ - bool getImageGeometry(ossimKeywordlist& kwl,const char* prefix = 0); - -protected: - /** - * @brief List of metadata contained in the Data file - */ - EnvisatAsarData * _EnvisatAsarData; - -private: - - TYPE_DATA -}; - -#endif \ No newline at end of file diff --git a/Utilities/otbossim/include/ossim/imaging/ossimRadarSatTileSource.h b/Utilities/otbossim/include/ossim/imaging/ossimRadarSatTileSource.h deleted file mode 100644 index 633f27629c5b645b9376c89804984737c69a7a71..0000000000000000000000000000000000000000 --- a/Utilities/otbossim/include/ossim/imaging/ossimRadarSatTileSource.h +++ /dev/null @@ -1,115 +0,0 @@ -#ifndef ossimRadarSatTileSource_H -#define ossimRadarSatTileSource_H - - -#include <ossim/imaging/ossimImageHandler.h> -#include <ossim/base/ossimIrect.h> -#include <ossim/imaging/RadarSat/Data/Data.h> -#include <ossim/imaging/RadarSat/Leader/Leader.h> - -namespace ossimplugins -{ -class ossimImageData; - -/** - * @brief This class is able to read an RadarSat file structure - * @author Magellium, Pacome Dentraygues - * @version 1.0 - * @date 10-12-07 - */ -class OSSIMDLLEXPORT ossimRadarSatTileSource : public ossimImageHandler -{ -public: - ossimRadarSatTileSource(); - - virtual ~ossimRadarSatTileSource(); - - virtual ossimString getLongName() const; - virtual ossimString getShortName() const; - - /*! - * Method to save the state of an object to a keyword list. - * Return true if ok or false on error. - */ - virtual bool saveState(ossimKeywordlist& kwl, - const char* prefix=0)const; - - /*! - * Method to the load (recreate) the state of an object from a keyword - * list. Return true if ok or false on error. - */ - virtual bool loadState(const ossimKeywordlist& kwl, - const char* prefix=0); - - /*! - * Returns true if the image_file can be opened and is a valid tiff file. - */ - virtual bool open(); - virtual void close(); - virtual bool isOpen()const; - /*! - * Returns the number of lines in the image. - * Satisfies pure virtual from ImageHandler class. - */ - virtual ossim_uint32 getNumberOfLines(ossim_uint32 reduced_res_level = 0) const - { - return 0; - }; - - /*! - * Returns the number of samples in the image. - * Satisfies pure virtual from ImageHandler class. - */ - virtual ossim_uint32 getNumberOfSamples(ossim_uint32 reduced_res_level = 0) const - { - return 0; - }; - /*! - * Returns the width of the output tile. - */ - virtual ossim_uint32 getImageTileWidth() const - { - return 0; - }; - - /*! - * Returns the height of the output tile. - */ - virtual ossim_uint32 getImageTileHeight() const - { - return 0; - }; - /*! - * Returns the number of bands in the image. - * Satisfies pure virtual from ImageHandler class. - */ - virtual ossim_uint32 getNumberOfInputBands() const - { - return 0; - }; - - /** - * @brief Populates the keyword list with image geometry information - * - * This method is used to relay projection/model information to users. - * @param kwl Keyword list that will be initialized with geometry info. Returns true if geometry info is present, false if not. - * @param prefix The prefix is added to the resulting keyword list keywords. So is you if you pass in a prefix of "image01.", the keyword ul_lat will be like: "image01.ul_lat: -40.00000" - */ - bool getImageGeometry(ossimKeywordlist& kwl,const char* prefix = 0); -protected: - /** - * @brief List of metadata contained in the Data file - */ - Data * _data; - - /** - * @brief List of metadata contained in the Leader file - */ - Leader * _leader; - -private: - - TYPE_DATA -}; -} -#endif diff --git a/Utilities/otbossim/include/ossim/projection/ossimEnvisatAsarModel.h b/Utilities/otbossim/include/ossim/projection/ossimEnvisatAsarModel.h deleted file mode 100644 index 473439976c5ae08cde67c5abf085acff56978f56..0000000000000000000000000000000000000000 --- a/Utilities/otbossim/include/ossim/projection/ossimEnvisatAsarModel.h +++ /dev/null @@ -1,76 +0,0 @@ -#ifndef ossimEnvisatAsarModel_H -#define ossimEnvisatAsarModel_H - -#include <ossim/projection/SARModel/DateTime/JSDDateTime.h> -#include <ossim/projection/ossimGeometricSarSensorModel.h> -#include <ossim/projection/ossimMapProjection.h> -#include <ossim/base/ossimIpt.h> -#include <ossim/base/ossimFilename.h> -#include <ossim/base/ossimGpt.h> -#include <ossim/base/ossimDpt.h> - -#include <iostream> - -class PlatformPosition; -class SensorParams; -class RefPoint; -/** - * @brief This class is able to direct localisation and indirect localisation using the EnvisatAsar sensor model - * @author Magellium, Pacome Dentraygues - * @version 1.0 - * @date 04-01-08 - */ -class OSSIMDLLEXPORT ossimEnvisatAsarModel : public ossimGeometricSarSensorModel -{ -public: - /** - * @brief Constructor - */ - ossimEnvisatAsarModel(); - - /** - * @brief Destructor - */ - ~ossimEnvisatAsarModel(); - - /** - * @brief This function associates an image column number to a slant range when the image is georeferenced (ground projected) - * @param col Column coordinate of the image point - */ - virtual double getSlantRangeFromGeoreferenced(double col) const; - -protected: - - /** - * @brief Slant Range to Ground Range (SRGR) number of coefficients sets - */ - int _n_srgr; - /** - * @brief SRGR coefficient sets - */ - std::vector< std::vector<double> > _srgr_coefset; - /** - * @brief SRGR coefficient sets update times - */ - std::vector<JSDDateTime> _srgr_update; - /** - * @brief Pixel spacing - */ - double _pixel_spacing; - -private: - virtual bool InitPlatformPosition(const ossimKeywordlist &kwl, const char *prefix); - virtual bool InitSensorParams(const ossimKeywordlist &kwl, const char *prefix); - virtual bool InitRefPoint(const ossimKeywordlist &kwl, const char *prefix); - /** - * @brief Initializes the Slant Range for each Ground Range data sets : _n_srgr,_srgr_coefset,_srgr_update,_pixel_spacing,_isProductGeoreferenced - */ - virtual bool InitSRGR(const ossimKeywordlist &kwl, const char *prefix); - /** - * @brief Finds the SRGR data set which update time is the closest to the center scene time - */ - std::vector<double> FindSRGRSetNumber(JSDDateTime date) const; - TYPE_DATA -}; - -#endif diff --git a/Utilities/otbossim/include/ossim/projection/ossimRadarSatModel.h b/Utilities/otbossim/include/ossim/projection/ossimRadarSatModel.h deleted file mode 100644 index 44cbd587266e8487c3c81b07d4a5387d24ca0a74..0000000000000000000000000000000000000000 --- a/Utilities/otbossim/include/ossim/projection/ossimRadarSatModel.h +++ /dev/null @@ -1,78 +0,0 @@ -#ifndef ossimRadarSatModel_H -#define ossimRadarSatModel_H - -#include <ossim/projection/SARModel/DateTime/JSDDateTime.h> - -#include <ossim/projection/ossimGeometricSarSensorModel.h> -#include <ossim/projection/ossimMapProjection.h> -#include <ossim/base/ossimIpt.h> -#include <ossim/base/ossimFilename.h> -#include <ossim/base/ossimGpt.h> -#include <ossim/base/ossimDpt.h> - -#include <iostream> - -class PlatformPosition; -class SensorParams; -class RefPoint; -/** - * @brief This class is able to direct localisation and indirect localisation using the RadarSat sensor model - * @author Magellium, Pacome Dentraygues - * @version 1.0 - * @date 04-01-08 - */ -class OSSIMDLLEXPORT ossimRadarSatModel : public ossimGeometricSarSensorModel -{ -public: - /** - * @brief Constructor - */ - ossimRadarSatModel(); - - /** - * @brief Destructor - */ - ~ossimRadarSatModel(); - - /** - * @brief This function associates an image column number to a slant range when the image is georeferenced (ground projected) - * @param col Column coordinate of the image point - */ - virtual double getSlantRangeFromGeoreferenced(double col) const; - -protected: - - /** - * @brief Slant Range for each Ground Range (SRGR) number of coefficients sets - */ - int _n_srgr; - /** - * @brief SRGR coefficient sets - */ - double _srgr_coefset[20][6]; - /** - * @brief SRGR coefficient sets update times - */ - double _srgr_update[20]; - /** - * @brief Pixel spacing - */ - double _pixel_spacing; - -private: - virtual bool InitPlatformPosition(const ossimKeywordlist &kwl, const char *prefix); - virtual bool InitSensorParams(const ossimKeywordlist &kwl, const char *prefix); - virtual bool InitRefPoint(const ossimKeywordlist &kwl, const char *prefix); - /** - * @brief Initializes the Slant Range for each Ground Range data sets : _n_srgr,_srgr_coefset,_srgr_update,_pixel_spacing,_isProductGeoreferenced - */ - virtual bool InitSRGR(const ossimKeywordlist &kwl, const char *prefix); - /** - * @brief Finds the SRGR data set which update time is the closest to the center scene time - */ - int FindSRGRSetNumber(JSDDateTime date) const; - TYPE_DATA - -}; - -#endif diff --git a/Utilities/otbossim/src/ossim/imaging/EnvisatAsar/AntennaElevationPatterns.cpp b/Utilities/otbossim/src/ossim/imaging/EnvisatAsar/AntennaElevationPatterns.cpp deleted file mode 100644 index 4e0f30a476b0a0049526650e9566096e220dbfb9..0000000000000000000000000000000000000000 --- a/Utilities/otbossim/src/ossim/imaging/EnvisatAsar/AntennaElevationPatterns.cpp +++ /dev/null @@ -1,82 +0,0 @@ -#include <ossim/imaging/EnvisatAsar/AntennaElevationPatterns.h> - -AntennaElevationPatterns::AntennaElevationPatterns() : EnvisatAsarRecord("AntennaElevationPatterns_rec") -{ -} - -AntennaElevationPatterns::~AntennaElevationPatterns() -{ -} - - -std::ostream& operator<<(std::ostream& os, const AntennaElevationPatterns& data) -{ - os<<"zero_doppler_time:"<<data._zero_doppler_time.c_str()<<std::endl; - - os<<"attach_flag:"<<data._attach_flag<<std::endl; - - os<<"swath:"<<data._swath.c_str()<<std::endl; - - for (int i = 0; i<33; i++) { - os<<"elevation pattern:"<<data._elevation_pattern[i]<<std::endl; - } - - return os; - -} - -std::istream& operator>>(std::istream& is, AntennaElevationPatterns& data) -{ - char buf16[17]; - buf16[16]='\0'; - char buf12[13]; - buf12[12] = '\0'; - char buf3[4]; - buf3[3] = '\0'; - char buf2[3]; - buf2[2] = '\0'; - char buf1[1]; - - is.read(buf12,12); - data._zero_doppler_time = buf12; - - is.read((char*)&(data._attach_flag),1); - - is.read(buf3,3); - data._swath = buf3; - - for (int i = 0; i<33; i++) { - is.read((char*)&(data._elevation_pattern[i]),4); - data.SwitchEndian(data._elevation_pattern[i]); - } - - is.read(buf16,14); - - return is; - -} - -AntennaElevationPatterns::AntennaElevationPatterns(const AntennaElevationPatterns& rhs): - EnvisatAsarRecord(rhs), - _zero_doppler_time(rhs._zero_doppler_time), - _attach_flag(rhs._attach_flag), - _swath(rhs._swath) - { - for (int i = 0; i<33; i++) { - _elevation_pattern[i] = rhs._elevation_pattern[i]; - } - } - - -AntennaElevationPatterns& AntennaElevationPatterns::operator=(const AntennaElevationPatterns& rhs) -{ - _zero_doppler_time = rhs._zero_doppler_time; - _attach_flag = rhs._attach_flag; - _swath = rhs._swath; - - for (int i = 0; i<33; i++) { - _elevation_pattern[i] = rhs._elevation_pattern[i]; - } - - return *this; -} diff --git a/Utilities/otbossim/src/ossim/imaging/EnvisatAsar/ChirpParameters.cpp b/Utilities/otbossim/src/ossim/imaging/EnvisatAsar/ChirpParameters.cpp deleted file mode 100644 index 8a4c9f5d0b99980a3f1fc34ee8559fddebd75198..0000000000000000000000000000000000000000 --- a/Utilities/otbossim/src/ossim/imaging/EnvisatAsar/ChirpParameters.cpp +++ /dev/null @@ -1,184 +0,0 @@ -#include <ossim/imaging/EnvisatAsar/ChirpParameters.h> - -ChirpParameters::ChirpParameters() : EnvisatAsarRecord("ChirpParameters_rec") -{ -} - -ChirpParameters::~ChirpParameters() -{ -} - - -std::ostream& operator<<(std::ostream& os, const ChirpParameters& data) -{ - os<<"zero_doppler_time:"<<data._zero_doppler_time.c_str()<<std::endl; - - os<<"attach_flag:"<<data._attach_flag<<std::endl; - - os<<"swath:"<<data._swath.c_str()<<std::endl; - - os<<"polar:"<<data._polar.c_str()<<std::endl; - - os<<"chirp_width:"<<data._chirp_width<<std::endl; - - os<<"chirp_sidelobe:"<<data._chirp_sidelobe<<std::endl; - - os<<"chirp_islr:"<<data._chirp_islr<<std::endl; - - os<<"chirp_peak_loc:"<<data._chirp_peak_loc<<std::endl; - - os<<"re_chirp_power:"<<data._re_chirp_power<<std::endl; - - os<<"elev_chirp_power:"<<data._elev_chirp_power<<std::endl; - - os<<"chirp_quality_flag:"<<data._chirp_quality_flag<<std::endl; - - os<<"ref_chirp_power:"<<data._ref_chirp_power<<std::endl; - - os<<"normalisation_source:"<<data._normalisation_source.c_str()<<std::endl; - - for (int i = 0 ; i<352; i++) { - os<<"cal_pulse_info["<<i<<"]:"<<data._cal_pulse_info[i]<<std::endl; - } - - return os; - -} - -std::istream& operator>>(std::istream& is, ChirpParameters& data) -{ - char buf64[65]; - buf64[64] = '\0'; - char buf32[33]; - buf32[32] = '\0'; - char buf27[28]; - buf27[27] = '\0'; - char buf20[21]; - buf20[20] = '\0'; - char buf16[17]; - buf16[16]='\0'; - char buf15[16]; - buf15[15] = '\0'; - char buf14[15]; - buf14[14] = '\0'; - char buf13[14]; - buf13[13] = '\0'; - char buf12[13]; - buf12[12] = '\0'; - char buf11[12]; - buf11[11] = '\0'; - char buf10[11]; - buf10[10] = '\0'; - char buf9[10]; - buf9[9] = '\0'; - char buf8[9]; - buf8[8] = '\0'; - char buf7[8]; - buf7[7] = '\0'; - char buf6[7]; - buf6[6] = '\0'; - char buf5[6]; - buf5[5] = '\0'; - char buf4[5]; - buf4[4] = '\0'; - char buf3[4]; - buf3[3] = '\0'; - char buf2[3]; - buf2[2] = '\0'; - char buf1[1]; - - is.read(buf12,12); - data._zero_doppler_time = buf12; - - is.read((char*)&(data._attach_flag),1); - - is.read(buf3,3); - data._swath = buf3; - - is.read(buf3,3); - data._polar = buf3; - - is.read((char*)&(data._chirp_width),4); - data.SwitchEndian(data._chirp_width); - - is.read((char*)&(data._chirp_sidelobe),4); - data.SwitchEndian(data._chirp_sidelobe); - - is.read((char*)&(data._chirp_islr),4); - data.SwitchEndian(data._chirp_islr); - - is.read((char*)&(data._chirp_peak_loc),4); - data.SwitchEndian(data._chirp_peak_loc); - - is.read((char*)&(data._re_chirp_power),4); - data.SwitchEndian(data._re_chirp_power); - - is.read((char*)&(data._elev_chirp_power),4); - data.SwitchEndian(data._elev_chirp_power); - - is.read((char*)&(data._chirp_quality_flag),1); - data.SwitchEndian(data._chirp_quality_flag); - - is.read((char*)&(data._ref_chirp_power),4); - data.SwitchEndian(data._ref_chirp_power); - - is.read(buf7,7); - data._normalisation_source = buf7; - - is.read(buf4,4); - - for (int i = 0; i<352; i++) { - is.read((char*)&(data._cal_pulse_info[i]),4); - data.SwitchEndian(data._cal_pulse_info[i]); - } - - is.read(buf16,16); - - return is; - -} - -ChirpParameters::ChirpParameters(const ChirpParameters& rhs): - EnvisatAsarRecord(rhs), - _zero_doppler_time(rhs._zero_doppler_time), - _attach_flag(rhs._attach_flag), - _swath(rhs._swath), - _polar(rhs._polar), - _chirp_width(rhs._chirp_width), - _chirp_sidelobe(rhs._chirp_sidelobe), - _chirp_islr(rhs._chirp_islr), - _chirp_peak_loc(rhs._chirp_peak_loc), - _re_chirp_power(rhs._re_chirp_power), - _elev_chirp_power(rhs._elev_chirp_power), - _chirp_quality_flag(rhs._chirp_quality_flag), - _ref_chirp_power(rhs._ref_chirp_power), - _normalisation_source(rhs._normalisation_source) - { - for (int i = 0; i<352; i++) { - _cal_pulse_info[i] = rhs._cal_pulse_info[i]; - } - } - - -ChirpParameters& ChirpParameters::operator=(const ChirpParameters& rhs) -{ - _zero_doppler_time = rhs._zero_doppler_time; - _attach_flag = rhs._attach_flag; - _swath = rhs._swath; - _polar = rhs._polar; - _chirp_width = rhs._chirp_width; - _chirp_sidelobe = rhs._chirp_sidelobe; - _chirp_islr = rhs._chirp_islr; - _chirp_peak_loc = rhs._chirp_peak_loc; - _re_chirp_power = rhs._re_chirp_power; - _elev_chirp_power = rhs._elev_chirp_power; - _chirp_quality_flag = rhs._chirp_quality_flag; - _ref_chirp_power = rhs._ref_chirp_power; - _normalisation_source = rhs._normalisation_source; - - for (int i = 0; i<352; i++) { - _cal_pulse_info[i] = rhs._cal_pulse_info[i]; - } - - return *this; -} diff --git a/Utilities/otbossim/src/ossim/imaging/EnvisatAsar/DopplerCentroidParameters.cpp b/Utilities/otbossim/src/ossim/imaging/EnvisatAsar/DopplerCentroidParameters.cpp deleted file mode 100644 index e44872466d5b00c2d4352dc8e14b5cb06bfcb760..0000000000000000000000000000000000000000 --- a/Utilities/otbossim/src/ossim/imaging/EnvisatAsar/DopplerCentroidParameters.cpp +++ /dev/null @@ -1,144 +0,0 @@ -#include <ossim/imaging/EnvisatAsar/DopplerCentroidParameters.h> - -DopplerCentroidParameters::DopplerCentroidParameters() : EnvisatAsarRecord("DopplerCentroidParameters_rec") -{ -} - -DopplerCentroidParameters::~DopplerCentroidParameters() -{ -} - - -std::ostream& operator<<(std::ostream& os, const DopplerCentroidParameters& data) -{ - os<<"zero_doppler_time:"<<data._zero_doppler_time.c_str()<<std::endl; - - os<<"attach_flag:"<<data._attach_flag<<std::endl; - - os<<"slant_range_time:"<<data._slant_range_time<<std::endl; - - os<<"dop_coef[0]:"<<data._dop_coef[0]<<std::endl; - os<<"dop_coef[1]:"<<data._dop_coef[1]<<std::endl; - os<<"dop_coef[2]:"<<data._dop_coef[2]<<std::endl; - os<<"dop_coef[3]:"<<data._dop_coef[3]<<std::endl; - os<<"dop_coef[4]:"<<data._dop_coef[4]<<std::endl; - - os<<"dop_conf:"<<data._dop_conf<<std::endl; - - os<<"dop_conf_below_thresh_flag:"<<data._dop_conf_below_thresh_flag<<std::endl; - - os<<"delta_dopp_coeff[0]:"<<data._delta_dopp_coeff[0]<<std::endl; - os<<"delta_dopp_coeff[1]:"<<data._delta_dopp_coeff[1]<<std::endl; - os<<"delta_dopp_coeff[2]:"<<data._delta_dopp_coeff[2]<<std::endl; - os<<"delta_dopp_coeff[3]:"<<data._delta_dopp_coeff[3]<<std::endl; - os<<"delta_dopp_coeff[4]:"<<data._delta_dopp_coeff[4]<<std::endl; - - return os; - -} - -std::istream& operator>>(std::istream& is, DopplerCentroidParameters& data) -{ - char buf64[65]; - buf64[64] = '\0'; - char buf32[33]; - buf32[32] = '\0'; - char buf27[28]; - buf27[27] = '\0'; - char buf20[21]; - buf20[20] = '\0'; - char buf16[17]; - buf16[16]='\0'; - char buf15[16]; - buf15[15] = '\0'; - char buf14[15]; - buf14[14] = '\0'; - char buf13[14]; - buf13[13] = '\0'; - char buf12[13]; - buf12[12] = '\0'; - char buf11[12]; - buf11[11] = '\0'; - char buf10[11]; - buf10[10] = '\0'; - char buf9[10]; - buf9[9] = '\0'; - char buf8[9]; - buf8[8] = '\0'; - char buf7[8]; - buf7[7] = '\0'; - char buf6[7]; - buf6[6] = '\0'; - char buf5[6]; - buf5[5] = '\0'; - char buf4[5]; - buf4[4] = '\0'; - char buf3[4]; - buf3[3] = '\0'; - char buf2[3]; - buf2[2] = '\0'; - char buf1[1]; - - is.read(buf12,12); - data._zero_doppler_time = buf12; - - is.read((char*)&(data._attach_flag),1); - - is.read((char*)&(data._slant_range_time),4); - data.SwitchEndian(data._slant_range_time); - - for (int i = 0; i <5; i++) { - is.read((char*)&(data._dop_coef[i]),4); - data.SwitchEndian(data._dop_coef[i]); - } - - is.read((char*)&(data._dop_conf),4); - data.SwitchEndian(data._dop_conf); - - is.read((char*)&(data._dop_conf_below_thresh_flag),1); - - for (int i = 0; i <5; i++) { - is.read((char*)&(data._delta_dopp_coeff[i]),2); - data.SwitchEndian(data._delta_dopp_coeff[i]); - } - - is.read(buf3,3); - - return is; - -} - -DopplerCentroidParameters::DopplerCentroidParameters(const DopplerCentroidParameters& rhs): - EnvisatAsarRecord(rhs), - _zero_doppler_time(rhs._zero_doppler_time), - _attach_flag(rhs._attach_flag), - _slant_range_time(rhs._slant_range_time), - _dop_conf(rhs._dop_conf), - _dop_conf_below_thresh_flag(rhs._dop_conf_below_thresh_flag) - { - for (int i = 0; i <5; i++) { - _dop_coef[i] = rhs._dop_coef[i]; - } - for (int i = 0; i <5; i++) { - _delta_dopp_coeff[i] = rhs._delta_dopp_coeff[i]; - } - } - - -DopplerCentroidParameters& DopplerCentroidParameters::operator=(const DopplerCentroidParameters& rhs) -{ - _zero_doppler_time = rhs._zero_doppler_time; - _attach_flag = rhs._attach_flag; - _slant_range_time = rhs._slant_range_time; - _dop_conf = rhs._dop_conf; - _dop_conf_below_thresh_flag = rhs._dop_conf_below_thresh_flag; - - for (int i = 0; i <5; i++) { - _dop_coef[i] = rhs._dop_coef[i]; - } - for (int i = 0; i <5; i++) { - _delta_dopp_coeff[i] = rhs._delta_dopp_coeff[i]; - } - - return *this; -} diff --git a/Utilities/otbossim/src/ossim/imaging/EnvisatAsar/EnvisatAsarData.cpp b/Utilities/otbossim/src/ossim/imaging/EnvisatAsar/EnvisatAsarData.cpp deleted file mode 100644 index b2703bf342c4fa5e0f3c61e34433c28b3efa3ab4..0000000000000000000000000000000000000000 --- a/Utilities/otbossim/src/ossim/imaging/EnvisatAsar/EnvisatAsarData.cpp +++ /dev/null @@ -1,269 +0,0 @@ -#include <ossim/imaging/EnvisatAsar/EnvisatAsarData.h> -#include <ossim/imaging/EnvisatAsar/EnvisatAsarDataFactory.h> - -#include <ossim/imaging/EnvisatAsar/sph.h> -#include <ossim/imaging/EnvisatAsar/mph.h> -#include <ossim/imaging/EnvisatAsar/SQ_ADSR.h> -#include <ossim/imaging/EnvisatAsar/MainProcessingParameters.h> -#include <ossim/imaging/EnvisatAsar/SRGRConversionParameters.h> -#include <ossim/imaging/EnvisatAsar/DopplerCentroidParameters.h> -#include <ossim/imaging/EnvisatAsar/ChirpParameters.h> -#include <ossim/imaging/EnvisatAsar/AntennaElevationPatterns.h> -#include <ossim/imaging/EnvisatAsar/GeolocationGrid.h> - - -EnvisatAsarData::EnvisatAsarData() -{ -} - -EnvisatAsarData::~EnvisatAsarData() -{ - ClearRecords(); -} - -std::ostream& operator<<(std::ostream& os, const EnvisatAsarData& data) -{ - std::list<EnvisatAsarRecord*>::const_iterator it = data._records.begin(); - while(it != data._records.end()) - { - (*it)->Write(os); - ++it; - } - return os; - -} - -std::istream& operator>>(std::istream& is, EnvisatAsarData& data) -{ - EnvisatAsarDataFactory factory; - - if (sizeof(int)!=4) std::cout << "EnvisatAsarData WARNING : (int) not coded over 32 bits, metadata might not be byte swapped correctly"<< std::endl ; - if (sizeof(float)!=4) std::cout << "EnvisatAsarData WARNING : (float) not coded over 32 bits, metadata might not be byte swapped correctly"<< std::endl ; - if (sizeof(double)!=8) std::cout << "EnvisatAsarData WARNING : (double) not coded over 64 bits, metadata might not be byte swapped correctly"<< std::endl ; - - data.ClearRecords(); - - // read the first record (MPH) - EnvisatAsarRecord* mph_record = factory.Instanciate("MPH"); - mph_record->Read(is); - data._records.push_back(mph_record); - - // read the second record (sph) and update it with the mph (number of dsd) - EnvisatAsarRecord* sph_record = factory.Instanciate("SPH"); - ((sph*)sph_record)->update_sph_from_mph(*((mph *)mph_record)); - sph_record->Read(is); - data._records.push_back(sph_record); - - std::vector<dsd> dsd_vector = ((sph*)sph_record)->get_dsd_vector(); - - // For each dsd, check if present in the file and in the record factory. - // If true, instanciate it and add to the EnvisatAsarRecord list. - std::vector<dsd>::iterator it = dsd_vector.begin(); - while(it != dsd_vector.end()) - { - std::string str = (it->get_ds_name()); - - if ( (it->get_ds_size()) != 0) - { - for (int i = 0; i<(it->get_num_dsr()); i++) - { - EnvisatAsarRecord* record = factory.Instanciate(str); - if (record != NULL) - { - is.seekg((it->get_ds_offset())+ i*(it->get_dsr_size())); - record->Read(is); - data._records.push_back(record); - } - } - } - ++it; - } - - return is; -} - - -EnvisatAsarData::EnvisatAsarData(const EnvisatAsarData& rhs) -{ - std::list<EnvisatAsarRecord*>::const_iterator it = rhs._records.begin(); - while(it != rhs._records.end()) - { - _records.push_back((*it)->Clone()); - ++it; - } -} - -EnvisatAsarData& EnvisatAsarData::operator=(const EnvisatAsarData& rhs) -{ - ClearRecords(); - std::list<EnvisatAsarRecord*>::const_iterator it = rhs._records.begin(); - while(it != rhs._records.end()) - { - _records.push_back((*it)->Clone()); - ++it; - } - - return *this; -} - -void EnvisatAsarData::ClearRecords() -{ - std::list<EnvisatAsarRecord*>::const_iterator it = _records.begin(); - while(it != _records.end()) - { - delete (*it); - ++it; - } - _records.clear(); -} -mph * EnvisatAsarData::get_mph() -{ - std::list<EnvisatAsarRecord*>::const_iterator it = _records.begin(); - while(it != _records.end()) - { - if ((*it)->get_mnemonic().compare("mph_rec") == 0) return (mph*)(*it); - ++it; - } - return NULL; -} -sph * EnvisatAsarData::get_sph() -{ - std::list<EnvisatAsarRecord*>::const_iterator it = _records.begin(); - while(it != _records.end()) - { - if ((*it)->get_mnemonic().compare("sph_rec") == 0) return (sph*)(*it); - ++it; - } - return NULL; -} - -SQ_ADSR * EnvisatAsarData::get_SQ_ADSR() -{ - std::list<EnvisatAsarRecord*>::const_iterator it = _records.begin(); - while(it != _records.end()) - { - if ((*it)->get_mnemonic().compare("SQ_ADSR_rec") == 0) return (SQ_ADSR*)(*it); - ++it; - } - return NULL; -} -MainProcessingParameters * EnvisatAsarData::get_MainProcessingParameters() -{ - std::list<EnvisatAsarRecord*>::const_iterator it = _records.begin(); - while(it != _records.end()) - { - if ((*it)->get_mnemonic().compare("MainProcessingParameters_rec") == 0) return (MainProcessingParameters*)(*it); - ++it; - } - return NULL; -} -DopplerCentroidParameters * EnvisatAsarData::get_DopplerCentroidParameters() -{ - std::list<EnvisatAsarRecord*>::const_iterator it = _records.begin(); - while(it != _records.end()) - { - if ((*it)->get_mnemonic().compare("DopplerCentroidParameters_rec") == 0) return (DopplerCentroidParameters*)(*it); - ++it; - } - return NULL; -} -SRGRConversionParameters * EnvisatAsarData::get_SRGRConversionParameters(int pos) -{ - std::list<EnvisatAsarRecord*>::const_iterator it = _records.begin(); - int cpt = 0; - while(it != _records.end()) - { - if ((*it)->get_mnemonic().compare("SRGRConversionParameters_rec") == 0) - { - if (cpt == pos) { - return (SRGRConversionParameters*)(*it); - } - else cpt++; - } - ++it; - } - return NULL; -} -ChirpParameters * EnvisatAsarData::get_ChirpParameters() -{ - std::list<EnvisatAsarRecord*>::const_iterator it = _records.begin(); - while(it != _records.end()) - { - if ((*it)->get_mnemonic().compare("ChirpParameters_rec") == 0) return (ChirpParameters*)(*it); - ++it; - } - return NULL; -} -AntennaElevationPatterns * EnvisatAsarData::get_AntennaElevationPatterns() -{ - std::list<EnvisatAsarRecord*>::const_iterator it = _records.begin(); - while(it != _records.end()) - { - if ((*it)->get_mnemonic().compare("AntennaElevationPatterns_rec") == 0) return (AntennaElevationPatterns*)(*it); - ++it; - } - return NULL; -} - -// Return the first Geolocation Grid Record -//GeolocationGrid * EnvisatAsarData::get_GeolocationGrid() -//{ -// std::list<EnvisatAsarRecord*>::const_iterator it = _records.begin(); -// while(it != _records.end()) -// { -// std::string str = (*it)->get_mnemonic(); -// if ((*it)->get_mnemonic().compare("GeolocationGrid_rec") == 0) -// { -// return (GeolocationGrid*)(*it); -// } -// ++it; -// } -// return NULL; -//} - -// Return the num_ds Geolocation Grid Record -GeolocationGrid * EnvisatAsarData::get_GeolocationGrid(int num_ds) -{ - std::list<EnvisatAsarRecord*>::const_iterator it = _records.begin(); - - int total_num_ds = 0; - while(it != _records.end()) - { - std::string str = (*it)->get_mnemonic(); - if ((*it)->get_mnemonic().compare("GeolocationGrid_rec") == 0) total_num_ds += 1; - ++it; - } - - int cpt = 0; - it = _records.begin(); - while(it != _records.end()) - { - std::string str = (*it)->get_mnemonic(); - if ((*it)->get_mnemonic().compare("GeolocationGrid_rec") == 0) - { - if ((cpt == num_ds) || (cpt == total_num_ds-1)) return (GeolocationGrid*)(*it); - cpt +=1; - - } - ++it; - } - return NULL; -} - - -int EnvisatAsarData::get_num_ds(EnvisatAsarRecord * record) -{ - if (record == NULL) return 0; - std::list<EnvisatAsarRecord*>::const_iterator it = _records.begin(); - int cpt = 0; - while(it != _records.end()) - { - std::string str = (*it)->get_mnemonic(); - if ((*it)->get_mnemonic().compare(record->get_mnemonic()) == 0) - { - cpt++; - } - ++it; - } - return cpt; -} diff --git a/Utilities/otbossim/src/ossim/imaging/EnvisatAsar/EnvisatAsarDataFactory.cpp b/Utilities/otbossim/src/ossim/imaging/EnvisatAsar/EnvisatAsarDataFactory.cpp deleted file mode 100644 index 70ba92afcb26b2701efcaebbddd931c9f2a37c23..0000000000000000000000000000000000000000 --- a/Utilities/otbossim/src/ossim/imaging/EnvisatAsar/EnvisatAsarDataFactory.cpp +++ /dev/null @@ -1,33 +0,0 @@ -#include <ossim/imaging/EnvisatAsar/EnvisatAsarDataFactory.h> -#include <ossim/imaging/EnvisatAsar/EnvisatAsarData.h> - -#include <ossim/imaging/EnvisatAsar/sph.h> -#include <ossim/imaging/EnvisatAsar/mph.h> -#include <ossim/imaging/EnvisatAsar/SQ_ADSR.h> -#include <ossim/imaging/EnvisatAsar/MainProcessingParameters.h> -#include <ossim/imaging/EnvisatAsar/SRGRConversionParameters.h> -#include <ossim/imaging/EnvisatAsar/DopplerCentroidParameters.h> -#include <ossim/imaging/EnvisatAsar/ChirpParameters.h> -#include <ossim/imaging/EnvisatAsar/AntennaElevationPatterns.h> -#include <ossim/imaging/EnvisatAsar/GeolocationGrid.h> - - -EnvisatAsarDataFactory::EnvisatAsarDataFactory() -{ - RegisterRecord("MPH" , new mph()); - RegisterRecord("SPH" , new sph()); - RegisterRecord("MDS1 SQ ADS " , new SQ_ADSR()); - RegisterRecord("MDS2 SQ ADS " , new SQ_ADSR()); - RegisterRecord("MAIN PROCESSING PARAMS ADS " , new MainProcessingParameters()); - RegisterRecord("DOP CENTROID COEFFS ADS " , new DopplerCentroidParameters()); - RegisterRecord("SR GR ADS " , new SRGRConversionParameters()); - RegisterRecord("CHIRP PARAMS ADS " , new ChirpParameters()); - RegisterRecord("MDS1 ANTENNA ELEV PATT ADS " , new AntennaElevationPatterns()); - RegisterRecord("MDS2 ANTENNA ELEV PATT ADS " , new AntennaElevationPatterns()); - RegisterRecord("GEOLOCATION GRID ADS " , new GeolocationGrid()); -} - -EnvisatAsarDataFactory::~EnvisatAsarDataFactory() -{ - -} \ No newline at end of file diff --git a/Utilities/otbossim/src/ossim/imaging/EnvisatAsar/EnvisatAsarRecord.cpp b/Utilities/otbossim/src/ossim/imaging/EnvisatAsar/EnvisatAsarRecord.cpp deleted file mode 100644 index f50b81c78dd1f1f4bc18c7964c3676fbeb18c5ef..0000000000000000000000000000000000000000 --- a/Utilities/otbossim/src/ossim/imaging/EnvisatAsar/EnvisatAsarRecord.cpp +++ /dev/null @@ -1,16 +0,0 @@ -#include <ossim/imaging/EnvisatAsar/EnvisatAsarRecord.h> -#include <memory.h> - -EnvisatAsarRecord::EnvisatAsarRecord(std::string mnemonic): - _mnemonic(mnemonic) -{ -} - -EnvisatAsarRecord::~EnvisatAsarRecord() -{ -} - -EnvisatAsarRecord::EnvisatAsarRecord(const EnvisatAsarRecord& rhs): - _mnemonic(rhs._mnemonic) -{ -} diff --git a/Utilities/otbossim/src/ossim/imaging/EnvisatAsar/EnvisatAsarRecordFactory.cpp b/Utilities/otbossim/src/ossim/imaging/EnvisatAsar/EnvisatAsarRecordFactory.cpp deleted file mode 100644 index 33c022af977a921554d34c3c8fe7413f9a53f9bf..0000000000000000000000000000000000000000 --- a/Utilities/otbossim/src/ossim/imaging/EnvisatAsar/EnvisatAsarRecordFactory.cpp +++ /dev/null @@ -1,27 +0,0 @@ -#include <ossim/imaging/EnvisatAsar/EnvisatAsarRecordFactory.h> - -EnvisatAsarRecordFactory::EnvisatAsarRecordFactory() -{ -} - -EnvisatAsarRecordFactory::~EnvisatAsarRecordFactory() -{ -} - -EnvisatAsarRecord* EnvisatAsarRecordFactory::Instanciate(std::string id) -{ - EnvisatAsarRecord* record = _availableRecords[id]; - if(record == NULL) - { - return NULL; - } - else - { - return record->Instanciate(); - } -} - -void EnvisatAsarRecordFactory::RegisterRecord(std::string id, EnvisatAsarRecord * record) -{ - _availableRecords[id] = record; -} \ No newline at end of file diff --git a/Utilities/otbossim/src/ossim/imaging/EnvisatAsar/GeolocationGrid.cpp b/Utilities/otbossim/src/ossim/imaging/EnvisatAsar/GeolocationGrid.cpp deleted file mode 100644 index 75f9f2be55897cf520ee307c6dd4baa0928f5429..0000000000000000000000000000000000000000 --- a/Utilities/otbossim/src/ossim/imaging/EnvisatAsar/GeolocationGrid.cpp +++ /dev/null @@ -1,203 +0,0 @@ -#include <ossim/imaging/EnvisatAsar/GeolocationGrid.h> - -GeolocationGrid::GeolocationGrid() : EnvisatAsarRecord("GeolocationGrid_rec") -{ -} - -GeolocationGrid::~GeolocationGrid() -{ -} - - -std::ostream& operator<<(std::ostream& os, const GeolocationGrid& data) -{ - os<<"first_zero_doppler_time_day:"<<data._first_zero_doppler_time_day<<std::endl; - - os<<"first_zero_doppler_time_sec:"<<data._first_zero_doppler_time_sec<<std::endl; - - os<<"first_zero_doppler_time_microsec:"<<data._first_zero_doppler_time_microsec<<std::endl; - - os<<"attach_flag:"<<data._attach_flag<<std::endl; - - os<<"line_num:"<<data._line_num<<std::endl; - - os<<"num_lines:"<<data._num_lines<<std::endl; - - os<<"sub_sat_track:"<<data._sub_sat_track<<std::endl; - - for (int i = 0; i<11; i++) { - os<<"samp_numbers["<<i<<"]:"<<data._samp_numbers[i]<<std::endl; - } - - for (int i = 0; i<11; i++) { - os<<"slant_range_times["<<i<<"]:"<<data._slant_range_times[i]<<std::endl; - } - - for (int i = 0; i<11; i++) { - os<<"angles["<<i<<"]:"<<data._angles[i]<<std::endl; - } - - for (int i = 0; i<11; i++) { - os<<"lats["<<i<<"]:"<<data._lats[i]<<std::endl; - } - - for (int i = 0; i<11; i++) { - os<<"longs["<<i<<"]:"<<data._longs[i]<<std::endl; - } - - os<<"last_zero_doppler_time:"<<data._last_zero_doppler_time.c_str()<<std::endl; - - os<<"last_line_tie_points:"<<data._last_line_tie_points.c_str()<<std::endl; - - return os; - -} - -std::istream& operator>>(std::istream& is, GeolocationGrid& data) -{ - char buf220[221]; - buf220[220] = '\0'; - char buf32[33]; - buf32[32] = '\0'; - char buf27[28]; - buf27[27] = '\0'; - char buf20[21]; - buf20[20] = '\0'; - char buf16[17]; - buf16[16]='\0'; - char buf15[16]; - buf15[15] = '\0'; - char buf14[15]; - buf14[14] = '\0'; - char buf13[14]; - buf13[13] = '\0'; - char buf12[13]; - buf12[12] = '\0'; - char buf11[12]; - buf11[11] = '\0'; - char buf10[11]; - buf10[10] = '\0'; - char buf9[10]; - buf9[9] = '\0'; - char buf8[9]; - buf8[8] = '\0'; - char buf7[8]; - buf7[7] = '\0'; - char buf6[7]; - buf6[6] = '\0'; - char buf5[6]; - buf5[5] = '\0'; - char buf4[5]; - buf4[4] = '\0'; - char buf3[4]; - buf3[3] = '\0'; - char buf2[3]; - buf2[2] = '\0'; - char buf1[1]; - - is.read((char*)&(data._first_zero_doppler_time_day),4); - data.SwitchEndian(data._first_zero_doppler_time_day); - - is.read((char*)&(data._first_zero_doppler_time_sec),4); - data.SwitchEndian(data._first_zero_doppler_time_sec); - - is.read((char*)&(data._first_zero_doppler_time_microsec),4); - data.SwitchEndian(data._first_zero_doppler_time_microsec); - - is.read((char*)&(data._attach_flag),1); - - is.read((char*)&(data._line_num),4); - data.SwitchEndian(data._line_num); - - is.read((char*)&(data._num_lines),4); - data.SwitchEndian(data._num_lines); - - is.read((char*)&(data._sub_sat_track),4); - data.SwitchEndian(data._sub_sat_track); - - for (int i = 0; i<11; i++) { - is.read((char*)&(data._samp_numbers[i]),4); - data.SwitchEndian(data._samp_numbers[i]); - } - - for (int i = 0; i<11; i++) { - is.read((char*)&(data._slant_range_times[i]),4); - data.SwitchEndian(data._slant_range_times[i]); - } - - for (int i = 0; i<11; i++) { - is.read((char*)&(data._angles[i]),4); - data.SwitchEndian(data._angles[i]); - } - - for (int i = 0; i<11; i++) { - is.read((char*)&(data._lats[i]),4); - data.SwitchEndian(data._lats[i]); - } - - for (int i = 0; i<11; i++) { - is.read((char*)&(data._longs[i]),4); - data.SwitchEndian(data._longs[i]); - } - - is.read(buf32,22); - - is.read(buf12,12); - data._last_zero_doppler_time = buf12; - - is.read(buf220,220); - data._last_line_tie_points = buf220; - - is.read(buf32,22); - - return is; - -} - -GeolocationGrid::GeolocationGrid(const GeolocationGrid& rhs): - EnvisatAsarRecord(rhs), - _first_zero_doppler_time_day(rhs._first_zero_doppler_time_day), - _first_zero_doppler_time_sec(rhs._first_zero_doppler_time_sec), - _first_zero_doppler_time_microsec(rhs._first_zero_doppler_time_microsec), - _attach_flag(rhs._attach_flag), - _line_num(rhs._line_num), - _num_lines(rhs._num_lines), - _sub_sat_track(rhs._sub_sat_track), - _last_zero_doppler_time(rhs._last_zero_doppler_time), - _last_line_tie_points(rhs._last_line_tie_points) - { - - for (int i = 0; i<11; i++) { - _samp_numbers[i] = rhs._samp_numbers[i]; - _slant_range_times[i] = rhs._slant_range_times[i]; - _angles[i] = rhs._angles[i]; - _lats[i] = rhs._lats[i]; - _longs[i] = rhs._longs[i]; - } - - - } - - -GeolocationGrid& GeolocationGrid::operator=(const GeolocationGrid& rhs) -{ - _first_zero_doppler_time_day = rhs._first_zero_doppler_time_day; - _first_zero_doppler_time_sec = rhs._first_zero_doppler_time_sec; - _first_zero_doppler_time_microsec = rhs._first_zero_doppler_time_microsec; - _attach_flag = rhs._attach_flag; - _line_num = rhs._line_num; - _num_lines = rhs._num_lines; - _sub_sat_track = rhs._sub_sat_track; - _last_zero_doppler_time = rhs._last_zero_doppler_time; - _last_line_tie_points = rhs._last_line_tie_points; - - for (int i = 0; i<11; i++) { - _samp_numbers[i] = rhs._samp_numbers[i]; - _slant_range_times[i] = rhs._slant_range_times[i]; - _angles[i] = rhs._angles[i]; - _lats[i] = rhs._lats[i]; - _longs[i] = rhs._longs[i]; - } - - return *this; -} diff --git a/Utilities/otbossim/src/ossim/imaging/EnvisatAsar/MainProcessingParameters.cpp b/Utilities/otbossim/src/ossim/imaging/EnvisatAsar/MainProcessingParameters.cpp deleted file mode 100644 index a6216ca60707a72b2edb34b9d6ea5d6a640c6e2b..0000000000000000000000000000000000000000 --- a/Utilities/otbossim/src/ossim/imaging/EnvisatAsar/MainProcessingParameters.cpp +++ /dev/null @@ -1,978 +0,0 @@ -#include <ossim/imaging/EnvisatAsar/MainProcessingParameters.h> - - - -MainProcessingParameters::MainProcessingParameters() : EnvisatAsarRecord("MainProcessingParameters_rec") -{ -} - -MainProcessingParameters::~MainProcessingParameters() -{ -} - -std::ostream& operator<<(std::ostream& os, const MainProcessingParameters& data) -{ - os<<"first_zero_doppler_time:"<<data._first_zero_doppler_time.c_str()<<std::endl; - - os<<"attach_flag:"<<data._attach_flag<<std::endl; - - os<<"last_zero_doppler_time:"<<data._last_zero_doppler_time.c_str()<<std::endl; - - os<<"work_order_id:"<<data._work_order_id.c_str()<<std::endl; - - os<<"time_diff:"<<data._time_diff<<std::endl; - - os<<"swath_num:"<<data._swath_num.c_str()<<std::endl; - - os<<"range_spacing:"<<data._range_spacing<<std::endl; - - os<<"azimut_spacing:"<<data._azimut_spacing<<std::endl; - - os<<"line_time_interval:"<<data._line_time_interval<<std::endl; - - os<<"num_output_lines:"<<data._num_output_lines<<std::endl; - - os<<"num_samples_per_line:"<<data._num_samples_per_line<<std::endl; - - os<<"data_type:"<<data._data_type.c_str()<<std::endl; - - os<<"num_range_lines_per_burst:"<<data._num_range_lines_per_burst<<std::endl; - - os<<"time_diff_zero_doppler:"<<data._time_diff_zero_doppler<<std::endl; - - os<<"data_analysis_flag:"<<data._data_analysis_flag<<std::endl; - - os<<"ant_elev_coor_flag:"<<data._ant_elev_coor_flag<<std::endl; - - os<<"chirp_extract_flag:"<<data._chirp_extract_flag<<std::endl; - - os<<"srgr_flag:"<<data._srgr_flag<<std::endl; - - os<<"dop_cen_flag:"<<data._dop_cen_flag<<std::endl; - - os<<"dop_amb_flag:"<<data._dop_amb_flag<<std::endl; - - os<<"range_spread_comp_flag:"<<data._range_spread_comp_flag<<std::endl; - - os<<"detected_flag:"<<data._detected_flag<<std::endl; - - os<<"look_sum_flag:"<<data._look_sum_flag<<std::endl; - - os<<"rms_equal_flag:"<<data._rms_equal_flag<<std::endl; - - os<<"ant_scal_flag:"<<data._ant_scal_flag<<std::endl; - - os<<"vga_com_echo_flag:"<<data._vga_com_echo_flag<<std::endl; - - os<<"vga_com_cal_flag:"<<data._vga_com_cal_flag<<std::endl; - - os<<"vga_com_nom_time_flag:"<<data._vga_com_nom_time_flag<<std::endl; - - os<<"gm_rng_comp_inv_filter_flag:"<<data._gm_rng_comp_inv_filter_flag<<std::endl; - - os<<"raw_data_analysis:"<<data._raw_data_analysis.c_str()<<std::endl; - - os<<"start_time_mds1:"<<data._start_time_mds1.c_str()<<std::endl; - - os<<"start_time_mds2:"<<data._start_time_mds2.c_str()<<std::endl; - - os<<"parameter_code:"<<data._parameter_code.c_str()<<std::endl; - - os<<"errors_counters:"<<data._errors_counters.c_str()<<std::endl; - - os<<"image_parameters 1:"<<data._image_parameters1.c_str()<<std::endl; - - os<<"prf_values[0]:"<<data._prf_values[0]<<std::endl; - - os<<"image_parameters 1:"<<data._image_parameters2.c_str()<<std::endl; - - os<<"first_proc_range_samp:"<<data._first_proc_range_samp<<std::endl; - - os<<"range_ref:"<<data._range_ref<<std::endl; - - os<<"range_samp_rate:"<<data._range_samp_rate<<std::endl; - - os<<"radar_freq:"<<data._radar_freq<<std::endl; - - os<<"num_looks_range:"<<data._num_looks_range<<std::endl; - - os<<"filter_range:"<<data._filter_range.c_str()<<std::endl; - - os<<"filter_coef_range:"<<data._filter_coef_range<<std::endl; - - os<<"bandwidth:"<<data._bandwidth.c_str()<<std::endl; - - os<<"nominal_chirp:"<<data._nominal_chirp.c_str()<<std::endl; - - os<<"num_lines_proc:"<<data._num_lines_proc<<std::endl; - - os<<"num_look_az:"<<data._num_look_az<<std::endl; - - os<<"look_bw_az:"<<data._look_bw_az<<std::endl; - - os<<"to_bw_az:"<<data._to_bw_az<<std::endl; - - os<<"filter_az:"<<data._filter_az.c_str()<<std::endl; - - os<<"filter_coef_az:"<<data._filter_coef_az<<std::endl; - - os<<"az_fm_rate[0]:"<<data._az_fm_rate[0]<<std::endl; - os<<"az_fm_rate[1]:"<<data._az_fm_rate[1]<<std::endl; - os<<"az_fm_rate[2]:"<<data._az_fm_rate[2]<<std::endl; - - os<<"ax_fm_origin:"<<data._ax_fm_origin<<std::endl; - - os<<"dop_amb_coef:"<<data._dop_amb_coef<<std::endl; - - os<<"calibration_factors:"<<data._calibration_factors.c_str()<<std::endl; - - os<<"noise_estimation:"<<data._noise_estimation.c_str()<<std::endl; - - os<<"output_statistics:"<<data._output_statistics.c_str()<<std::endl; - - os<<"avg_scene_height_ellpsoid:"<<data._avg_scene_height_ellpsoid<<std::endl; - - os<<"echo_comp:"<<data._echo_comp.c_str()<<std::endl; - - os<<"echo_comp_ratio:"<<data._echo_comp_ratio.c_str()<<std::endl; - - os<<"init_cal_comp:"<<data._init_cal_comp.c_str()<<std::endl; - - os<<"init_cal_ratio:"<<data._init_cal_ratio.c_str()<<std::endl; - - os<<"per_cal_comp:"<<data._per_cal_comp.c_str()<<std::endl; - - os<<"per_cal_ratio:"<<data._per_cal_ratio.c_str()<<std::endl; - - os<<"noise_comp:"<<data._noise_comp.c_str()<<std::endl; - - os<<"noise_comp_ratio:"<<data._noise_comp_ratio.c_str()<<std::endl; - - os<<"beam_overlap[0]:"<<data._beam_overlap[0]<<std::endl; - os<<"beam_overlap[1]:"<<data._beam_overlap[1]<<std::endl; - os<<"beam_overlap[2]:"<<data._beam_overlap[2]<<std::endl; - os<<"beam_overlap[3]:"<<data._beam_overlap[3]<<std::endl; - - os<<"lines_per_burst[0]:"<<data._lines_per_burst[0]<<std::endl; - os<<"lines_per_burst[1]:"<<data._lines_per_burst[1]<<std::endl; - os<<"lines_per_burst[2]:"<<data._lines_per_burst[2]<<std::endl; - os<<"lines_per_burst[3]:"<<data._lines_per_burst[3]<<std::endl; - os<<"lines_per_burst[4]:"<<data._lines_per_burst[4]<<std::endl; - - os<<"time_first_SS1_echo:"<<data._time_first_SS1_echo.c_str()<<std::endl; - - os<<"state_vector_time_1:"<<data._state_vector_time_1_day<<std::endl; - - os<<"state_vector_time_1:"<<data._state_vector_time_1_sec<<std::endl; - - os<<"state_vector_time_1:"<<data._state_vector_time_1_microsec<<std::endl; - - os<<"x_pos_1:"<<data._x_pos_1<<std::endl; - - os<<"y_pos_1:"<<data._y_pos_1<<std::endl; - - os<<"z_pos_1:"<<data._z_pos_1<<std::endl; - - os<<"x_vel_1:"<<data._x_vel_1<<std::endl; - - os<<"y_vel_1:"<<data._y_vel_1<<std::endl; - - os<<"z_vel_1:"<<data._z_vel_1<<std::endl; - - os<<"state_vector_time_2:"<<data._state_vector_time_2_day<<std::endl; - - os<<"state_vector_time_2:"<<data._state_vector_time_2_sec<<std::endl; - - os<<"state_vector_time_2:"<<data._state_vector_time_2_microsec<<std::endl; - - os<<"x_pos_2:"<<data._x_pos_2<<std::endl; - - os<<"y_pos_2:"<<data._y_pos_2<<std::endl; - - os<<"z_pos_2:"<<data._z_pos_2<<std::endl; - - os<<"x_vel_2:"<<data._x_vel_2<<std::endl; - - os<<"y_vel_2:"<<data._y_vel_2<<std::endl; - - os<<"z_vel_2:"<<data._z_vel_2<<std::endl; - - os<<"state_vector_time_3:"<<data._state_vector_time_3_day<<std::endl; - - os<<"state_vector_time_3:"<<data._state_vector_time_3_sec<<std::endl; - - os<<"state_vector_time_3:"<<data._state_vector_time_3_microsec<<std::endl; - - os<<"x_pos_3:"<<data._x_pos_3<<std::endl; - - os<<"y_pos_3:"<<data._y_pos_3<<std::endl; - - os<<"z_pos_3:"<<data._z_pos_3<<std::endl; - - os<<"x_vel_3:"<<data._x_vel_3<<std::endl; - - os<<"y_vel_3:"<<data._y_vel_3<<std::endl; - - os<<"z_vel_3:"<<data._z_vel_3<<std::endl; - - os<<"state_vector_time_4:"<<data._state_vector_time_4_day<<std::endl; - - os<<"state_vector_time_4:"<<data._state_vector_time_4_sec<<std::endl; - - os<<"state_vector_time_4:"<<data._state_vector_time_4_microsec<<std::endl; - - os<<"x_pos_4:"<<data._x_pos_4<<std::endl; - - os<<"y_pos_4:"<<data._y_pos_4<<std::endl; - - os<<"z_pos_4:"<<data._z_pos_4<<std::endl; - - os<<"x_vel_4:"<<data._x_vel_4<<std::endl; - - os<<"y_vel_4:"<<data._y_vel_4<<std::endl; - - os<<"z_vel_4:"<<data._z_vel_4<<std::endl; - - os<<"state_vector_time_5:"<<data._state_vector_time_5_day<<std::endl; - - os<<"state_vector_time_5:"<<data._state_vector_time_5_sec<<std::endl; - - os<<"state_vector_time_5:"<<data._state_vector_time_5_microsec<<std::endl; - - os<<"x_pos_5:"<<data._x_pos_5<<std::endl; - - os<<"y_pos_5:"<<data._y_pos_5<<std::endl; - - os<<"z_pos_5:"<<data._z_pos_5<<std::endl; - - os<<"x_vel_5:"<<data._x_vel_5<<std::endl; - - os<<"y_vel_5:"<<data._y_vel_5<<std::endl; - - os<<"z_vel_5:"<<data._z_vel_5<<std::endl; - - return os; - -} - -std::istream& operator>>(std::istream& is, MainProcessingParameters& data) -{ - char buf64[65]; - buf64[64] = '\0'; - char buf32[33]; - buf32[32] = '\0'; - char buf27[28]; - buf27[27] = '\0'; - char buf20[21]; - buf20[20] = '\0'; - char buf16[17]; - buf16[16]='\0'; - char buf15[16]; - buf15[15] = '\0'; - char buf14[15]; - buf14[14] = '\0'; - char buf13[14]; - buf13[13] = '\0'; - char buf12[13]; - buf12[12] = '\0'; - char buf11[12]; - buf11[11] = '\0'; - char buf10[11]; - buf10[10] = '\0'; - char buf9[10]; - buf9[9] = '\0'; - char buf8[9]; - buf8[8] = '\0'; - char buf7[8]; - buf7[7] = '\0'; - char buf6[7]; - buf6[6] = '\0'; - char buf5[6]; - buf5[5] = '\0'; - char buf4[5]; - buf4[4] = '\0'; - char buf3[4]; - buf3[3] = '\0'; - char buf2[3]; - buf2[2] = '\0'; - char buf1[1]; - - int * var_long; - - is.read(buf12,12); - data._first_zero_doppler_time = buf12; - - is.read((char*)&(data._attach_flag),1); - - is.read(buf12,12); - data._last_zero_doppler_time = buf12; - - is.read(buf12,12); - data._work_order_id = buf12; - - is.read((char*)&(data._time_diff),4); - data.SwitchEndian(data._time_diff); - - is.read(buf3,3); - data._swath_num = buf3; - - is.read((char*)&(data._range_spacing),4); - data.SwitchEndian(data._range_spacing); - - is.read((char*)&(data._azimut_spacing),4); - data.SwitchEndian(data._azimut_spacing); - - is.read((char*)&(data._line_time_interval),4); - data.SwitchEndian(data._line_time_interval); - - is.read((char*)&(data._num_output_lines),4); - data.SwitchEndian(data._num_output_lines); - - is.read((char*)&(data._num_samples_per_line),4); - data.SwitchEndian(data._num_samples_per_line); - - is.read(buf5,5); - data._data_type = buf5; - - is.read((char*)&(data._num_range_lines_per_burst),4); - data.SwitchEndian(data._num_range_lines_per_burst); - - is.read((char*)&(data._time_diff_zero_doppler),4); - data.SwitchEndian(data._time_diff_zero_doppler); - - is.read(buf64,43); - - is.read((char*)&(data._data_analysis_flag),1); - - is.read((char*)&(data._ant_elev_coor_flag),1); - - is.read((char*)&(data._chirp_extract_flag),1); - - is.read((char*)&(data._srgr_flag),1); - - is.read((char*)&(data._dop_cen_flag),1); - - is.read((char*)&(data._dop_amb_flag),1); - - is.read((char*)&(data._range_spread_comp_flag),1); - - is.read((char*)&(data._detected_flag),1); - - is.read((char*)&(data._look_sum_flag),1); - - is.read((char*)&(data._rms_equal_flag),1); - - is.read((char*)&(data._ant_scal_flag),1); - - is.read((char*)&(data._vga_com_echo_flag),1); - - is.read((char*)&(data._vga_com_cal_flag),1); - - is.read((char*)&(data._vga_com_nom_time_flag),1); - - is.read((char*)&(data._gm_rng_comp_inv_filter_flag),1); - - is.read(buf6,6); - - char buf184[185]; - buf184[184] = '\0'; - is.read(buf184,184); - data._raw_data_analysis = buf184; - - is.read(buf32,32); - - is.read(buf20,20); - data._start_time_mds1 = buf20; - - is.read(buf20,20); - data._start_time_mds2 = buf20; - - char buf120[121]; - buf120[120] = '\0'; - is.read(buf120,120); - data._parameter_code = buf120; - - is.read(buf64,60); - - is.read(buf64,40); - buf64[40] = '\0'; - data._errors_counters = buf64; - - is.read(buf32,26); - - is.read(buf64,60); - buf64[60] = '\0'; - data._image_parameters1 = buf64; - - for (int i = 0; i<5; i++) - { - is.read((char*)&(data._prf_values[i]),4); - data.SwitchEndian(data._prf_values[i]); - } - - char buf190[191]; - buf190[190] = '\0'; - is.read(buf190,190); - data._image_parameters2 = buf190; - - is.read(buf64,62); - - is.read((char*)&(data._first_proc_range_samp),4); - data.SwitchEndian(data._first_proc_range_samp); - - is.read((char*)&(data._range_ref),4); - data.SwitchEndian(data._range_ref); - - is.read((char*)&(data._range_samp_rate),4); - data.SwitchEndian(data._range_samp_rate); - - is.read((char*)&(data._radar_freq),4); - data.SwitchEndian(data._radar_freq); - - is.read((char*)&(data._num_looks_range),2); - data.SwitchEndian(data._num_looks_range); - - is.read(buf7,7); - data._filter_range = buf7; - - is.read((char*)&(data._filter_coef_range),4); - data.SwitchEndian(data._filter_coef_range); - - is.read(buf64,40); - buf64[40] = '\0'; - data._bandwidth = buf64; - - char buf160[161]; - buf160[160] = '\0'; - is.read(buf160,160); - data._nominal_chirp = buf160; - - is.read(buf64,60); - - is.read((char*)&(data._num_lines_proc),4); - data.SwitchEndian(data._num_lines_proc); - - is.read((char*)&(data._num_look_az),2); - data.SwitchEndian(data._num_look_az); - - is.read((char*)&(data._look_bw_az),4); - data.SwitchEndian(data._look_bw_az); - - is.read((char*)&(data._to_bw_az),4); - data.SwitchEndian(data._to_bw_az); - - is.read(buf7,7); - data._filter_az = buf7; - - is.read((char*)&(data._filter_coef_az),4); - data.SwitchEndian(data._filter_coef_az); - - for (int i = 0; i <3; i++) { - is.read((char*)&(data._az_fm_rate[i]),4); - data.SwitchEndian(data._az_fm_rate[i]); - } - - is.read((char*)&(data._ax_fm_origin),4); - data.SwitchEndian(data._ax_fm_origin); - - is.read((char*)&(data._dop_amb_coef),4); - data.SwitchEndian(data._dop_amb_coef); - - char buf128[129]; - buf128[128] = '\0'; - is.read(buf128,68); - - is.read(buf16,16); - data._calibration_factors = buf16; - - is.read(buf64,40); - buf64[40]='\0'; - data._noise_estimation = buf64; - - is.read(buf64,64); - - is.read(buf12,12); - - is.read(buf32,32); - data._output_statistics = buf32; - - is.read((char*)&(data._avg_scene_height_ellpsoid),4); - data.SwitchEndian(data._avg_scene_height_ellpsoid); - - is.read(buf64,48); - - is.read(buf4,4); - data._echo_comp = buf4; - - is.read(buf3,3); - data._echo_comp_ratio = buf3; - - is.read(buf4,4); - data._init_cal_comp = buf4; - - is.read(buf3,3); - data._init_cal_ratio = buf3; - - is.read(buf4,4); - data._per_cal_comp = buf4; - - is.read(buf3,3); - data._per_cal_ratio = buf3; - - is.read(buf4,4); - data._noise_comp = buf4; - - is.read(buf3,3); - data._noise_comp_ratio = buf3; - - is.read(buf64,64); - - for (int i=0;i<4;i++) - { - is.read((char*)&(data._beam_overlap[i]),4); - data.SwitchEndian(data._beam_overlap[i]); - } - for (int i=0;i<4;i++) - { - is.read((char*)&(data._beam_param[i]),4); - data.SwitchEndian(data._beam_param[i]); - } - for (int i=0;i<5;i++) - { - is.read((char*)&(data._lines_per_burst[i]),4); - data.SwitchEndian(data._lines_per_burst[i]); - } - - is.read(buf12,12); - data._time_first_SS1_echo = buf12; - - is.read(buf16,16); - - is.read((char*)&(data._state_vector_time_1_day),4); - data.SwitchEndian(data._state_vector_time_1_day); - - is.read((char*)&(data._state_vector_time_1_sec),4); - data.SwitchEndian(data._state_vector_time_1_sec); - - is.read((char*)&(data._state_vector_time_1_microsec),4); - data.SwitchEndian(data._state_vector_time_1_microsec); - - is.read((char*)&(data._x_pos_1),4); - data.SwitchEndian(data._x_pos_1); - - is.read((char*)&(data._y_pos_1),4); - data.SwitchEndian(data._y_pos_1); - - is.read((char*)&(data._z_pos_1),4); - data.SwitchEndian(data._z_pos_1); - - is.read((char*)&(data._x_vel_1),4); - data.SwitchEndian(data._x_vel_1); - - is.read((char*)&(data._y_vel_1),4); - data.SwitchEndian(data._y_vel_1); - - is.read((char*)&(data._z_vel_1),4); - data.SwitchEndian(data._z_vel_1); - - is.read((char*)&(data._state_vector_time_2_day),4); - data.SwitchEndian(data._state_vector_time_2_day); - - is.read((char*)&(data._state_vector_time_2_sec),4); - data.SwitchEndian(data._state_vector_time_2_sec); - - is.read((char*)&(data._state_vector_time_2_microsec),4); - data.SwitchEndian(data._state_vector_time_2_microsec); - - is.read((char*)&(data._x_pos_2),4); - data.SwitchEndian(data._x_pos_2); - - is.read((char*)&(data._y_pos_2),4); - data.SwitchEndian(data._y_pos_2); - - is.read((char*)&(data._z_pos_2),4); - data.SwitchEndian(data._z_pos_2); - - is.read((char*)&(data._x_vel_2),4); - data.SwitchEndian(data._x_vel_2); - - is.read((char*)&(data._y_vel_2),4); - data.SwitchEndian(data._y_vel_2); - - is.read((char*)&(data._z_vel_2),4); - data.SwitchEndian(data._z_vel_2); - - is.read((char*)&(data._state_vector_time_3_day),4); - data.SwitchEndian(data._state_vector_time_3_day); - - is.read((char*)&(data._state_vector_time_3_sec),4); - data.SwitchEndian(data._state_vector_time_3_sec); - - is.read((char*)&(data._state_vector_time_3_microsec),4); - data.SwitchEndian(data._state_vector_time_3_microsec); - - is.read((char*)&(data._x_pos_3),4); - data.SwitchEndian(data._x_pos_3); - - is.read((char*)&(data._y_pos_3),4); - data.SwitchEndian(data._y_pos_3); - - is.read((char*)&(data._z_pos_3),4); - data.SwitchEndian(data._z_pos_3); - - is.read((char*)&(data._x_vel_3),4); - data.SwitchEndian(data._x_vel_3); - - is.read((char*)&(data._y_vel_3),4); - data.SwitchEndian(data._y_vel_3); - - is.read((char*)&(data._z_vel_3),4); - data.SwitchEndian(data._z_vel_3); - - is.read((char*)&(data._state_vector_time_4_day),4); - data.SwitchEndian(data._state_vector_time_4_day); - - is.read((char*)&(data._state_vector_time_4_sec),4); - data.SwitchEndian(data._state_vector_time_4_sec); - - is.read((char*)&(data._state_vector_time_4_microsec),4); - data.SwitchEndian(data._state_vector_time_4_microsec); - - is.read((char*)&(data._x_pos_4),4); - data.SwitchEndian(data._x_pos_4); - - is.read((char*)&(data._y_pos_4),4); - data.SwitchEndian(data._y_pos_4); - - is.read((char*)&(data._z_pos_4),4); - data.SwitchEndian(data._z_pos_4); - - is.read((char*)&(data._x_vel_4),4); - data.SwitchEndian(data._x_vel_4); - - is.read((char*)&(data._y_vel_4),4); - data.SwitchEndian(data._y_vel_4); - - is.read((char*)&(data._z_vel_4),4); - data.SwitchEndian(data._z_vel_4); - - is.read((char*)&(data._state_vector_time_5_day),4); - data.SwitchEndian(data._state_vector_time_5_day); - - is.read((char*)&(data._state_vector_time_5_sec),4); - data.SwitchEndian(data._state_vector_time_5_sec); - - is.read((char*)&(data._state_vector_time_5_microsec),4); - data.SwitchEndian(data._state_vector_time_5_microsec); - - is.read((char*)&(data._x_pos_5),4); - data.SwitchEndian(data._x_pos_5); - - is.read((char*)&(data._y_pos_5),4); - data.SwitchEndian(data._y_pos_5); - - is.read((char*)&(data._z_pos_5),4); - data.SwitchEndian(data._z_pos_5); - - is.read((char*)&(data._x_vel_5),4); - data.SwitchEndian(data._x_vel_5); - - is.read((char*)&(data._y_vel_5),4); - data.SwitchEndian(data._y_vel_5); - - is.read((char*)&(data._z_vel_5),4); - data.SwitchEndian(data._z_vel_5); - - is.read(buf64,64); - -return is; - -} - -MainProcessingParameters::MainProcessingParameters(const MainProcessingParameters& rhs): - EnvisatAsarRecord(rhs), - _first_zero_doppler_time(rhs._first_zero_doppler_time), - _attach_flag(rhs._attach_flag), - _last_zero_doppler_time(rhs._last_zero_doppler_time), - _work_order_id(rhs._work_order_id), - _time_diff(rhs._time_diff), - _swath_num(rhs._swath_num), - _range_spacing(rhs._range_spacing), - _azimut_spacing(rhs._azimut_spacing), - _line_time_interval(rhs._line_time_interval), - _num_output_lines(rhs._num_output_lines), - _num_samples_per_line(rhs._num_samples_per_line), - _data_type(rhs._data_type), - _num_range_lines_per_burst(rhs._num_range_lines_per_burst), - _time_diff_zero_doppler(rhs._time_diff_zero_doppler), - _data_analysis_flag(rhs._data_analysis_flag), - _ant_elev_coor_flag(rhs._ant_elev_coor_flag), - _chirp_extract_flag(rhs._chirp_extract_flag), - _srgr_flag(rhs._srgr_flag), - _dop_cen_flag(rhs._dop_cen_flag), - _dop_amb_flag(rhs._dop_amb_flag), - _range_spread_comp_flag(rhs._range_spread_comp_flag), - _detected_flag(rhs._detected_flag), - _look_sum_flag(rhs._look_sum_flag), - _rms_equal_flag(rhs._rms_equal_flag), - _ant_scal_flag(rhs._ant_scal_flag), - _vga_com_echo_flag(rhs._vga_com_echo_flag), - _vga_com_cal_flag(rhs._vga_com_cal_flag), - _vga_com_nom_time_flag(rhs._vga_com_nom_time_flag), - _gm_rng_comp_inv_filter_flag(rhs._gm_rng_comp_inv_filter_flag), - _raw_data_analysis(rhs._raw_data_analysis), - _start_time_mds1(rhs._start_time_mds1), - _start_time_mds2(rhs._start_time_mds2), - _parameter_code(rhs._parameter_code), - _errors_counters(rhs._errors_counters), - _image_parameters1(rhs._image_parameters1), - _image_parameters2(rhs._image_parameters2), - _first_proc_range_samp(rhs._first_proc_range_samp), - _range_ref(rhs._range_ref), - _range_samp_rate(rhs._range_samp_rate), - _radar_freq(rhs._radar_freq), - _num_looks_range(rhs._num_looks_range), - _filter_range(rhs._filter_range), - _filter_coef_range(rhs._filter_coef_range), - _bandwidth(rhs._bandwidth), - _nominal_chirp(rhs._nominal_chirp), - _num_lines_proc(rhs._num_lines_proc), - _num_look_az(rhs._num_look_az), - _look_bw_az(rhs._look_bw_az), - _to_bw_az(rhs._to_bw_az), - _filter_az(rhs._filter_az), - _filter_coef_az(rhs._filter_coef_az), - _ax_fm_origin(rhs._ax_fm_origin), - _dop_amb_coef(rhs._dop_amb_coef), - _calibration_factors(rhs._calibration_factors), - _noise_estimation(rhs._noise_estimation), - _output_statistics(rhs._output_statistics), - _avg_scene_height_ellpsoid(rhs._avg_scene_height_ellpsoid), - _echo_comp(rhs._echo_comp), - _echo_comp_ratio(rhs._echo_comp_ratio), - _init_cal_comp(rhs._init_cal_comp), - _init_cal_ratio(rhs._init_cal_ratio), - _per_cal_comp(rhs._per_cal_comp), - _per_cal_ratio(rhs._per_cal_ratio), - _noise_comp(rhs._noise_comp), - _noise_comp_ratio(rhs._noise_comp_ratio), - _time_first_SS1_echo(rhs._time_first_SS1_echo), - _state_vector_time_1_day(rhs._state_vector_time_1_day), - _state_vector_time_1_sec(rhs._state_vector_time_1_sec), - _state_vector_time_1_microsec(rhs._state_vector_time_1_microsec), - _x_pos_1(rhs._x_pos_1), - _y_pos_1(rhs._y_pos_1), - _z_pos_1(rhs._z_pos_1), - _x_vel_1(rhs._x_vel_1), - _y_vel_1(rhs._y_vel_1), - _z_vel_1(rhs._z_vel_1), - _state_vector_time_2_day(rhs._state_vector_time_2_day), - _state_vector_time_2_sec(rhs._state_vector_time_2_sec), - _state_vector_time_2_microsec(rhs._state_vector_time_2_microsec), - _x_pos_2(rhs._x_pos_2), - _y_pos_2(rhs._y_pos_2), - _z_pos_2(rhs._z_pos_2), - _x_vel_2(rhs._x_vel_2), - _y_vel_2(rhs._y_vel_2), - _z_vel_2(rhs._z_vel_2), - _state_vector_time_3_day(rhs._state_vector_time_3_day), - _state_vector_time_3_sec(rhs._state_vector_time_3_sec), - _state_vector_time_3_microsec(rhs._state_vector_time_3_microsec), - _x_pos_3(rhs._x_pos_3), - _y_pos_3(rhs._y_pos_3), - _z_pos_3(rhs._z_pos_3), - _x_vel_3(rhs._x_vel_3), - _y_vel_3(rhs._y_vel_3), - _z_vel_3(rhs._z_vel_3), - _state_vector_time_4_day(rhs._state_vector_time_4_day), - _state_vector_time_4_sec(rhs._state_vector_time_4_sec), - _state_vector_time_4_microsec(rhs._state_vector_time_4_microsec), - _x_pos_4(rhs._x_pos_4), - _y_pos_4(rhs._y_pos_4), - _z_pos_4(rhs._z_pos_4), - _x_vel_4(rhs._x_vel_4), - _y_vel_4(rhs._y_vel_4), - _z_vel_4(rhs._z_vel_4), - _state_vector_time_5_day(rhs._state_vector_time_5_day), - _state_vector_time_5_sec(rhs._state_vector_time_5_sec), - _state_vector_time_5_microsec(rhs._state_vector_time_5_microsec), - _x_pos_5(rhs._x_pos_5), - _y_pos_5(rhs._y_pos_5), - _z_pos_5(rhs._z_pos_5), - _x_vel_5(rhs._x_vel_5), - _y_vel_5(rhs._y_vel_5), - _z_vel_5(rhs._z_vel_5) -{ - _az_fm_rate[0] = rhs._az_fm_rate[0]; - _az_fm_rate[1] = rhs._az_fm_rate[1]; - _az_fm_rate[2] = rhs._az_fm_rate[2]; - - _prf_values[0] = rhs._prf_values[0]; - _prf_values[1] = rhs._prf_values[1]; - _prf_values[2] = rhs._prf_values[2]; - _prf_values[3] = rhs._prf_values[3]; - _prf_values[4] = rhs._prf_values[4]; - - _beam_overlap[0]= rhs._beam_overlap[0]; - _beam_overlap[1]= rhs._beam_overlap[1]; - _beam_overlap[2]= rhs._beam_overlap[2]; - _beam_overlap[3]= rhs._beam_overlap[3]; - - _beam_param[0]= rhs._beam_param[0]; - _beam_param[1]= rhs._beam_param[1]; - _beam_param[2]= rhs._beam_param[2]; - _beam_param[3]= rhs._beam_param[3]; - - _lines_per_burst[0] =rhs._lines_per_burst[0]; - _lines_per_burst[1] =rhs._lines_per_burst[1]; - _lines_per_burst[2] =rhs._lines_per_burst[2]; - _lines_per_burst[3] =rhs._lines_per_burst[3]; - _lines_per_burst[4] =rhs._lines_per_burst[4]; -} - - -MainProcessingParameters& MainProcessingParameters::operator=(const MainProcessingParameters& rhs) -{ - _first_zero_doppler_time = rhs._first_zero_doppler_time; - _attach_flag = rhs._attach_flag; - _last_zero_doppler_time = rhs._last_zero_doppler_time; - _work_order_id = rhs._work_order_id; - _time_diff = rhs._time_diff; - _swath_num = rhs._swath_num; - _range_spacing = rhs._range_spacing; - _azimut_spacing = rhs._azimut_spacing; - _line_time_interval = rhs._line_time_interval; - _num_output_lines = rhs._num_output_lines; - _num_samples_per_line = rhs._num_samples_per_line; - _data_type = rhs._data_type; - _num_range_lines_per_burst = rhs._num_range_lines_per_burst; - _time_diff_zero_doppler = rhs._time_diff_zero_doppler; - _data_analysis_flag = rhs._data_analysis_flag; - _ant_elev_coor_flag = rhs._ant_elev_coor_flag; - _chirp_extract_flag = rhs._chirp_extract_flag; - _srgr_flag = rhs._srgr_flag; - _dop_cen_flag = rhs._dop_cen_flag; - _dop_amb_flag = rhs._dop_amb_flag; - _range_spread_comp_flag = rhs._range_spread_comp_flag; - _detected_flag = rhs._detected_flag; - _look_sum_flag = rhs._look_sum_flag; - _rms_equal_flag = rhs._rms_equal_flag; - _ant_scal_flag = rhs._ant_scal_flag; - _vga_com_echo_flag = rhs._vga_com_echo_flag; - _vga_com_cal_flag = rhs._vga_com_cal_flag; - _vga_com_nom_time_flag = rhs._vga_com_nom_time_flag; - _gm_rng_comp_inv_filter_flag = rhs._gm_rng_comp_inv_filter_flag; - _raw_data_analysis = rhs._raw_data_analysis; - _start_time_mds1 = rhs._start_time_mds1; - _start_time_mds2 = rhs._start_time_mds2; - _parameter_code = rhs._parameter_code; - _errors_counters = rhs._errors_counters; - _image_parameters1 = rhs._image_parameters1; - _image_parameters2 = rhs._image_parameters2; - _first_proc_range_samp = rhs._first_proc_range_samp; - _range_ref = rhs._range_ref; - _range_samp_rate = rhs._range_samp_rate; - _radar_freq = rhs._radar_freq; - _num_looks_range = rhs._num_looks_range; - _filter_range = rhs._filter_range; - _filter_coef_range = rhs._filter_coef_range; - _bandwidth = rhs._bandwidth; - _nominal_chirp = rhs._nominal_chirp; - _num_lines_proc = rhs._num_lines_proc; - _num_look_az = rhs._num_look_az; - _look_bw_az = rhs._look_bw_az; - _to_bw_az = rhs._to_bw_az; - _filter_az = rhs._filter_az; - _filter_coef_az = rhs._filter_coef_az; - _ax_fm_origin = rhs._ax_fm_origin; - _dop_amb_coef = rhs._dop_amb_coef; - _calibration_factors = rhs._calibration_factors; - _noise_estimation = rhs._noise_estimation; - _output_statistics = rhs._output_statistics; - _avg_scene_height_ellpsoid = rhs._avg_scene_height_ellpsoid; - _echo_comp = rhs._echo_comp; - _echo_comp_ratio = rhs._echo_comp_ratio; - _init_cal_comp = rhs._init_cal_comp; - _init_cal_ratio = rhs._init_cal_ratio; - _per_cal_comp = rhs._per_cal_comp; - _per_cal_ratio = rhs._per_cal_ratio; - _noise_comp = rhs._noise_comp; - _noise_comp_ratio = rhs._noise_comp_ratio; - _time_first_SS1_echo = rhs._time_first_SS1_echo; - _state_vector_time_1_day = rhs._state_vector_time_1_day; - _state_vector_time_1_sec = rhs._state_vector_time_1_sec; - _state_vector_time_1_microsec = rhs._state_vector_time_1_microsec; - _x_pos_1 = rhs._x_pos_1; - _y_pos_1 = rhs._y_pos_1; - _z_pos_1 = rhs._z_pos_1; - _x_vel_1 = rhs._x_vel_1; - _y_vel_1 = rhs._y_vel_1; - _z_vel_1 = rhs._z_vel_1; - _state_vector_time_2_day = rhs._state_vector_time_2_day; - _state_vector_time_2_sec = rhs._state_vector_time_2_sec; - _state_vector_time_2_microsec = rhs._state_vector_time_2_microsec; - _x_pos_2 = rhs._x_pos_2; - _y_pos_2 = rhs._y_pos_2; - _z_pos_2 = rhs._z_pos_2; - _x_vel_2 = rhs._x_vel_2; - _y_vel_2 = rhs._y_vel_2; - _z_vel_2 = rhs._z_vel_2; - _state_vector_time_3_day = rhs._state_vector_time_3_day; - _state_vector_time_3_sec = rhs._state_vector_time_3_sec; - _state_vector_time_3_microsec = rhs._state_vector_time_3_microsec; - _x_pos_3 = rhs._x_pos_3; - _y_pos_3 = rhs._y_pos_3; - _z_pos_3 = rhs._z_pos_3; - _x_vel_3 = rhs._x_vel_3; - _y_vel_3 = rhs._y_vel_3; - _z_vel_3 = rhs._z_vel_3; - _state_vector_time_4_day = rhs._state_vector_time_4_day; - _state_vector_time_4_sec = rhs._state_vector_time_4_sec; - _state_vector_time_4_microsec = rhs._state_vector_time_4_microsec; - _x_pos_4 = rhs._x_pos_4; - _y_pos_4 = rhs._y_pos_4; - _z_pos_4 = rhs._z_pos_4; - _x_vel_4 = rhs._x_vel_4; - _y_vel_4 = rhs._y_vel_4; - _z_vel_4 = rhs._z_vel_4; - _state_vector_time_5_day = rhs._state_vector_time_5_day; - _state_vector_time_5_sec = rhs._state_vector_time_5_sec; - _state_vector_time_5_microsec = rhs._state_vector_time_5_microsec; - _x_pos_5 = rhs._x_pos_5; - _y_pos_5 = rhs._y_pos_5; - _z_pos_5 = rhs._z_pos_5; - _x_vel_5 = rhs._x_vel_5; - _y_vel_5 = rhs._y_vel_5; - _z_vel_5 = rhs._z_vel_5; - - _az_fm_rate[0] = rhs._az_fm_rate[0]; - _az_fm_rate[1] = rhs._az_fm_rate[1]; - _az_fm_rate[2] = rhs._az_fm_rate[2]; - - _prf_values[0] = rhs._prf_values[0]; - _prf_values[1] = rhs._prf_values[1]; - _prf_values[2] = rhs._prf_values[2]; - _prf_values[3] = rhs._prf_values[3]; - _prf_values[4] = rhs._prf_values[4]; - - _beam_overlap[0]= rhs._beam_overlap[0]; - _beam_overlap[1]= rhs._beam_overlap[1]; - _beam_overlap[2]= rhs._beam_overlap[2]; - _beam_overlap[3]= rhs._beam_overlap[3]; - - _beam_param[0]= rhs._beam_param[0]; - _beam_param[1]= rhs._beam_param[1]; - _beam_param[2]= rhs._beam_param[2]; - _beam_param[3]= rhs._beam_param[3]; - - _lines_per_burst[0] =rhs._lines_per_burst[0]; - _lines_per_burst[1] =rhs._lines_per_burst[1]; - _lines_per_burst[2] =rhs._lines_per_burst[2]; - _lines_per_burst[3] =rhs._lines_per_burst[3]; - _lines_per_burst[4] =rhs._lines_per_burst[4]; - - return *this; -} - - - diff --git a/Utilities/otbossim/src/ossim/imaging/EnvisatAsar/SQ_ADSR.cpp b/Utilities/otbossim/src/ossim/imaging/EnvisatAsar/SQ_ADSR.cpp deleted file mode 100644 index be2b05d602c275ddc1f31b2c94f07093b84b57fa..0000000000000000000000000000000000000000 --- a/Utilities/otbossim/src/ossim/imaging/EnvisatAsar/SQ_ADSR.cpp +++ /dev/null @@ -1,350 +0,0 @@ -#include <ossim/imaging/EnvisatAsar/SQ_ADSR.h> - -SQ_ADSR::SQ_ADSR() : EnvisatAsarRecord("sq_adsr_rec") -{ -} - -SQ_ADSR::~SQ_ADSR() -{ -} - - - -std::ostream& operator<<(std::ostream& os, const SQ_ADSR& data) -{ - os<<"zero_doppler_time:"<<data._zero_doppler_time.c_str()<<std::endl; - - os<<"attach_flag:"<<data._attach_flag<<std::endl; - - os<<"input_mean_flag:"<<data._input_mean_flag<<std::endl; - - os<<"input_std_dev_flag:"<<data._input_std_dev_flag<<std::endl; - - os<<"input_gaps_flag:"<<data._input_gaps_flag<<std::endl; - - os<<"input_missing_lines_flag:"<<data._input_missing_lines_flag<<std::endl; - - os<<"dop_cen_flag:"<<data._dop_cen_flag<<std::endl; - - os<<"dop_amb_flag:"<<data._dop_amb_flag<<std::endl; - - os<<"output_mean_flag:"<<data._output_mean_flag<<std::endl; - - os<<"output_std_dev_flag:"<<data._output_std_dev_flag<<std::endl; - - os<<"chirp_flag:"<<data._chirp_flag<<std::endl; - - os<<"missing_data_set_flag:"<<data._missing_data_set_flag<<std::endl; - - os<<"invalid_downlink_flag:"<<data._invalid_downlink_flag<<std::endl; - - os<<"thres_chirp_broadening:"<<data._thres_chirp_broadening<<std::endl; - - os<<"thresh_chirp_sidelobe:"<<data._thresh_chirp_sidelobe<<std::endl; - - os<<"thresh_chirp_islr:"<<data._thresh_chirp_islr<<std::endl; - - os<<"thresh_input_mean:"<<data._thresh_input_mean<<std::endl; - - os<<"exp_input_mean:"<<data._exp_input_mean<<std::endl; - - os<<"thresh_input_std_dev:"<<data._thresh_input_std_dev<<std::endl; - - os<<"exp_input_std_dev:"<<data._exp_input_std_dev<<std::endl; - - os<<"thresh_dop_cen:"<<data._thresh_dop_cen<<std::endl; - - os<<"thresh_dop_amb:"<<data._thresh_dop_amb<<std::endl; - - os<<"thresh_output_mean:"<<data._thresh_output_mean<<std::endl; - - os<<"exp_output_mean:"<<data._exp_output_mean<<std::endl; - - os<<"thresh_output_std_dev:"<<data._thresh_output_std_dev<<std::endl; - - os<<"exp_output_std_dev:"<<data._exp_output_std_dev<<std::endl; - - os<<"thresh_input_missing_lines:"<<data._thresh_input_missing_lines<<std::endl; - - os<<"thresh_input_gaps:"<<data._thresh_input_gaps<<std::endl; - - os<<"lines_per_gaps:"<<data._lines_per_gaps<<std::endl; - - os<<"input_mean[0]:"<<data._input_mean[0]<<std::endl; - os<<"input_mean[1]:"<<data._input_mean[1]<<std::endl; - - os<<"input_std_dev[0]:"<<data._input_std_dev[0]<<std::endl; - os<<"input_std_dev[1]:"<<data._input_std_dev[1]<<std::endl; - - os<<"num_gaps:"<<data._num_gaps<<std::endl; - - os<<"num_missing_lines:"<<data._num_missing_lines<<std::endl; - - os<<"output_mean[0]:"<<data._output_mean[0]<<std::endl; - os<<"output_mean[1]:"<<data._output_mean[1]<<std::endl; - - os<<"output_std_dev[0]:"<<data._output_std_dev[0]<<std::endl; - os<<"output_std_dev[1]:"<<data._output_std_dev[1]<<std::endl; - - os<<"tot_errors:"<<data._tot_errors<<std::endl; - - return os; - -} - -std::istream& operator>>(std::istream& is, SQ_ADSR& data) -{ - char buf64[65]; - buf64[64] = '\0'; - char buf32[33]; - buf32[32] = '\0'; - char buf27[28]; - buf27[27] = '\0'; - char buf20[21]; - buf20[20] = '\0'; - char buf16[17]; - buf16[16]='\0'; - char buf15[16]; - buf15[15] = '\0'; - char buf14[15]; - buf14[14] = '\0'; - char buf13[14]; - buf13[13] = '\0'; - char buf12[13]; - buf12[12] = '\0'; - char buf11[12]; - buf11[11] = '\0'; - char buf10[11]; - buf10[10] = '\0'; - char buf9[10]; - buf9[9] = '\0'; - char buf8[9]; - buf8[8] = '\0'; - char buf7[8]; - buf7[7] = '\0'; - char buf6[7]; - buf6[6] = '\0'; - char buf5[6]; - buf5[5] = '\0'; - char buf4[5]; - buf4[4] = '\0'; - char buf3[4]; - buf3[3] = '\0'; - char buf2[3]; - buf2[2] = '\0'; - char buf1[1]; - - is.read(buf12,12); - data._zero_doppler_time = buf12; - - is.read((char*)&(data._attach_flag),1); - - is.read((char*)&(data._input_mean_flag),1); - - is.read((char*)&(data._input_std_dev_flag),1); - - is.read((char*)&(data._input_gaps_flag),1); - - is.read((char*)&(data._input_missing_lines_flag),1); - - is.read((char*)&(data._dop_cen_flag),1); - - is.read((char*)&(data._dop_amb_flag),1); - - is.read((char*)&(data._output_mean_flag),1); - - is.read((char*)&(data._output_std_dev_flag),1); - - is.read((char*)&(data._chirp_flag),1); - - is.read((char*)&(data._missing_data_set_flag),1); - - is.read((char*)&(data._invalid_downlink_flag),1); - - is.read(buf7,7); - - is.read((char*)&(data._thres_chirp_broadening),4); - data.SwitchEndian(data._thres_chirp_broadening); - - is.read((char*)&(data._thresh_chirp_sidelobe),4); - data.SwitchEndian(data._thresh_chirp_sidelobe); - - is.read((char*)&(data._thresh_chirp_islr),4); - data.SwitchEndian(data._thresh_chirp_islr); - - is.read((char*)&(data._thresh_input_mean),4); - data.SwitchEndian(data._thresh_input_mean); - - is.read((char*)&(data._exp_input_mean),4); - data.SwitchEndian(data._exp_input_mean); - - is.read((char*)&(data._thresh_input_std_dev),4); - data.SwitchEndian(data._thresh_input_std_dev); - - is.read((char*)&(data._exp_input_std_dev),4); - data.SwitchEndian(data._exp_input_std_dev); - - is.read((char*)&(data._thresh_dop_cen),4); - data.SwitchEndian(data._thresh_dop_cen); - - is.read((char*)&(data._thresh_dop_amb),4); - data.SwitchEndian(data._thresh_dop_amb); - - is.read((char*)&(data._thresh_output_mean),4); - data.SwitchEndian(data._thresh_output_mean); - - is.read((char*)&(data._exp_output_mean),4); - data.SwitchEndian(data._exp_output_mean); - - is.read((char*)&(data._thresh_output_std_dev),4); - data.SwitchEndian(data._thresh_output_std_dev); - - is.read((char*)&(data._exp_output_std_dev),4); - data.SwitchEndian(data._exp_output_std_dev); - - is.read((char*)&(data._thresh_input_missing_lines),4); - data.SwitchEndian(data._thresh_input_missing_lines); - - is.read((char*)&(data._thresh_input_gaps),4); - data.SwitchEndian(data._thresh_input_gaps); - - is.read((char*)&(data._lines_per_gaps),4); - data.SwitchEndian(data._lines_per_gaps); - - is.read(buf15,15); - - is.read((char*)&(data._input_mean[0]),4); - data.SwitchEndian(data._input_mean[0]); - - is.read((char*)&(data._input_mean[1]),4); - data.SwitchEndian(data._input_mean[1]); - - is.read((char*)&(data._input_std_dev[0]),4); - data.SwitchEndian(data._input_std_dev[0]); - is.read((char*)&(data._input_std_dev[1]),4); - data.SwitchEndian(data._input_std_dev[1]); - - is.read((char*)&(data._num_gaps),4); - data.SwitchEndian(data._num_gaps); - - is.read((char*)&(data._num_missing_lines),4); - data.SwitchEndian(data._num_missing_lines); - - is.read((char*)&(data._output_mean[0]),4); - data.SwitchEndian(data._output_mean[0]); - is.read((char*)&(data._output_mean[1]),4); - data.SwitchEndian(data._output_mean[1]); - - is.read((char*)&(data._output_std_dev[0]),4); - data.SwitchEndian(data._output_std_dev[0]); - - is.read((char*)&(data._output_std_dev[1]),4); - data.SwitchEndian(data._output_std_dev[1]); - - is.read((char*)&(data._tot_errors),4); - data.SwitchEndian(data._tot_errors); - - is.read(buf16,16); - - return is; - -} - -SQ_ADSR::SQ_ADSR(const SQ_ADSR& rhs): - EnvisatAsarRecord(rhs), - _zero_doppler_time(rhs._zero_doppler_time), - _attach_flag(rhs._attach_flag), - _input_mean_flag(rhs._input_mean_flag), - _input_std_dev_flag(rhs._input_std_dev_flag), - _input_gaps_flag(rhs._input_gaps_flag), - _input_missing_lines_flag(rhs._input_missing_lines_flag), - _dop_cen_flag(rhs._dop_cen_flag), - _dop_amb_flag(rhs._dop_amb_flag), - _output_mean_flag(rhs._output_mean_flag), - _output_std_dev_flag(rhs._output_std_dev_flag), - _chirp_flag(rhs._chirp_flag), - _missing_data_set_flag(rhs._missing_data_set_flag), - _invalid_downlink_flag(rhs._invalid_downlink_flag), - _thres_chirp_broadening(rhs._thres_chirp_broadening), - _thresh_chirp_sidelobe(rhs._thresh_chirp_sidelobe), - _thresh_chirp_islr(rhs._thresh_chirp_islr), - _thresh_input_mean(rhs._thresh_input_mean), - _exp_input_mean(rhs._exp_input_mean), - _thresh_input_std_dev(rhs._thresh_input_std_dev), - _exp_input_std_dev(rhs._exp_input_std_dev), - _thresh_dop_cen(rhs._thresh_dop_cen), - _thresh_dop_amb(rhs._thresh_dop_amb), - _thresh_output_mean(rhs._thresh_output_mean), - _exp_output_mean(rhs._exp_output_mean), - _thresh_output_std_dev(rhs._thresh_output_std_dev), - _exp_output_std_dev(rhs._exp_output_std_dev), - _thresh_input_missing_lines(rhs._thresh_input_missing_lines), - _thresh_input_gaps(rhs._thresh_input_gaps), - _lines_per_gaps(rhs._lines_per_gaps), - _num_gaps(rhs._num_gaps), - _num_missing_lines(rhs._num_missing_lines), - _tot_errors(rhs._tot_errors) -{ - _input_mean[0] = rhs._input_mean[0]; - _input_mean[1] = rhs._input_mean[1]; - - _input_std_dev[0] = rhs._input_std_dev[0]; - _input_std_dev[1] = rhs._input_std_dev[1]; - - _output_mean[0] = rhs._output_mean[0]; - _output_mean[1] = rhs._output_mean[1]; - - _output_std_dev[0] = rhs._output_std_dev[0]; - _output_std_dev[1] = rhs._output_std_dev[1]; - -} - -SQ_ADSR& SQ_ADSR::operator=(const SQ_ADSR& rhs) -{ - _zero_doppler_time = rhs._zero_doppler_time; - _attach_flag = rhs._attach_flag; - _input_mean_flag = rhs._input_mean_flag; - _input_std_dev_flag = rhs._input_std_dev_flag; - _input_gaps_flag = rhs._input_gaps_flag; - _input_missing_lines_flag = rhs._input_missing_lines_flag; - _dop_cen_flag = rhs._dop_cen_flag; - _dop_amb_flag = rhs._dop_amb_flag; - _output_mean_flag = rhs._output_mean_flag; - _output_std_dev_flag = rhs._output_std_dev_flag; - _chirp_flag = rhs._chirp_flag; - _missing_data_set_flag = rhs._missing_data_set_flag; - _invalid_downlink_flag = rhs._invalid_downlink_flag; - _thres_chirp_broadening = rhs._thres_chirp_broadening; - _thresh_chirp_sidelobe = rhs._thresh_chirp_sidelobe; - _thresh_chirp_islr = rhs._thresh_chirp_islr; - _thresh_input_mean = rhs._thresh_input_mean; - _exp_input_mean = rhs._exp_input_mean; - _thresh_input_std_dev = rhs._thresh_input_std_dev; - _exp_input_std_dev = rhs._exp_input_std_dev; - _thresh_dop_cen = rhs._thresh_dop_cen; - _thresh_dop_amb = rhs._thresh_dop_amb; - _thresh_output_mean = rhs._thresh_output_mean; - _exp_output_mean = rhs._exp_output_mean; - _thresh_output_std_dev = rhs._thresh_output_std_dev; - _exp_output_std_dev = rhs._exp_output_std_dev; - _thresh_input_missing_lines = rhs._thresh_input_missing_lines; - _thresh_input_gaps = rhs._thresh_input_gaps; - _lines_per_gaps = rhs._lines_per_gaps; - _num_gaps = rhs._num_gaps; - _num_missing_lines = rhs._num_missing_lines; - _tot_errors = rhs._tot_errors; - - _input_mean[0] = rhs._input_mean[0]; - _input_mean[1] = rhs._input_mean[1]; - - _input_std_dev[0] = rhs._input_std_dev[0]; - _input_std_dev[1] = rhs._input_std_dev[1]; - - _output_mean[0] = rhs._output_mean[0]; - _output_mean[1] = rhs._output_mean[1]; - - _output_std_dev[0] = rhs._output_std_dev[0]; - _output_std_dev[1] = rhs._output_std_dev[1]; - - return *this; -} diff --git a/Utilities/otbossim/src/ossim/imaging/EnvisatAsar/SRGRConversionParameters.cpp b/Utilities/otbossim/src/ossim/imaging/EnvisatAsar/SRGRConversionParameters.cpp deleted file mode 100644 index ec37e8e1452f3c35d010b05c607e3b9ee50d3919..0000000000000000000000000000000000000000 --- a/Utilities/otbossim/src/ossim/imaging/EnvisatAsar/SRGRConversionParameters.cpp +++ /dev/null @@ -1,96 +0,0 @@ -#include <ossim/imaging/EnvisatAsar/SRGRConversionParameters.h> - -SRGRConversionParameters::SRGRConversionParameters() : EnvisatAsarRecord("SRGRConversionParameters_rec") -{ -} - -SRGRConversionParameters::~SRGRConversionParameters() -{ -} - -std::ostream& operator<<(std::ostream& os, const SRGRConversionParameters& data) -{ - os<<"first_zero_doppler_time_day:"<<data._first_zero_doppler_time_day<<std::endl; - - os<<"first_zero_doppler_time_sec:"<<data._first_zero_doppler_time_sec<<std::endl; - - os<<"first_zero_doppler_time_microsec:"<<data._first_zero_doppler_time_microsec<<std::endl; - - os<<"attach_flag:"<<data._attach_flag<<std::endl; - - os<<"_slant_range_time:"<<data._slant_range_time<<std::endl; - - os<<"_ground_range_origin:"<<data._ground_range_origin<<std::endl; - - for (int i = 0; i<5; i++) { - os<<"_srgr_coef[i]:"<<data._srgr_coef[i]<<std::endl; - } - - return os; - -} - -std::istream& operator>>(std::istream& is, SRGRConversionParameters& data) -{ - char buf14[15]; - buf14[14] = '\0'; - char buf12[13]; - buf12[12] = '\0'; - - - is.read((char*)&(data._first_zero_doppler_time_day),4); - data.SwitchEndian(data._first_zero_doppler_time_day); - - is.read((char*)&(data._first_zero_doppler_time_sec),4); - data.SwitchEndian(data._first_zero_doppler_time_sec); - - is.read((char*)&(data._first_zero_doppler_time_microsec),4); - data.SwitchEndian(data._first_zero_doppler_time_microsec); - - is.read((char*)&(data._attach_flag),1); - - is.read((char*)&(data._slant_range_time),4); - data.SwitchEndian(data._slant_range_time); - - is.read((char*)&(data._ground_range_origin),4); - data.SwitchEndian(data._ground_range_origin); - - for (int i = 0; i<5; i++) { - is.read((char*)&(data._srgr_coef[i]),4); - data.SwitchEndian(data._srgr_coef[i]); - } - - is.read(buf14,14); - - return is; -} - - -SRGRConversionParameters::SRGRConversionParameters(const SRGRConversionParameters& rhs): - EnvisatAsarRecord(rhs), - _first_zero_doppler_time_day(rhs._first_zero_doppler_time_day), - _first_zero_doppler_time_sec(rhs._first_zero_doppler_time_sec), - _first_zero_doppler_time_microsec(rhs._first_zero_doppler_time_microsec), - _attach_flag(rhs._attach_flag), - _slant_range_time(rhs._slant_range_time), - _ground_range_origin(rhs._ground_range_origin) -{ - for (int i = 0; i<5; i++) { - _srgr_coef[i] = rhs._srgr_coef[i]; - } -} - -SRGRConversionParameters& SRGRConversionParameters::operator=(const SRGRConversionParameters& rhs) -{ - _first_zero_doppler_time_day = rhs._first_zero_doppler_time_day; - _first_zero_doppler_time_sec = rhs._first_zero_doppler_time_sec; - _first_zero_doppler_time_microsec = rhs._first_zero_doppler_time_microsec; - _attach_flag = rhs._attach_flag; - _slant_range_time = rhs._slant_range_time; - - for (int i = 0; i<5; i++) { - _srgr_coef[i] = rhs._srgr_coef[i]; - } - - return *this; -} diff --git a/Utilities/otbossim/src/ossim/imaging/EnvisatAsar/dsd.cpp b/Utilities/otbossim/src/ossim/imaging/EnvisatAsar/dsd.cpp deleted file mode 100644 index 769060aa6dae543c9d4d7cd55df76428885365af..0000000000000000000000000000000000000000 --- a/Utilities/otbossim/src/ossim/imaging/EnvisatAsar/dsd.cpp +++ /dev/null @@ -1,143 +0,0 @@ -#include <ossim/imaging/EnvisatAsar/dsd.h> - -dsd::dsd() : EnvisatAsarRecord("dsd_rec") -{ -} - -dsd::~dsd() -{ -} - -std::ostream& operator<<(std::ostream& os, const dsd& data) -{ - os<<"ds_name:"<<data._ds_name.c_str()<<std::endl; - os<<"ds_type:"<<data._ds_type.c_str()<<std::endl; - os<<"filename:"<<data._filename.c_str()<<std::endl; - os<<"ds_offset:"<<data._ds_offset<<std::endl; - os<<"ds_size:"<<data._ds_size<<std::endl; - os<<"num_dsr:"<<data._num_dsr<<std::endl; - os<<"dsr_size:"<<data._dsr_size<<std::endl; - - return os; -} - -std::istream& operator>>(std::istream& is, dsd& data) -{ - char buf64[65]; - buf64[64] = '\0'; - char buf32[33]; - buf32[32] = '\0'; - char buf28[29]; - buf28[28] = '\0'; - char buf27[28]; - buf27[27] = '\0'; - char buf20[21]; - buf20[20] = '\0'; - char buf16[17]; - buf16[16]='\0'; - char buf15[16]; - buf15[15] = '\0'; - char buf14[15]; - buf14[14] = '\0'; - char buf13[14]; - buf13[13] = '\0'; - char buf12[13]; - buf12[12] = '\0'; - char buf11[12]; - buf11[11] = '\0'; - char buf10[11]; - buf10[10] = '\0'; - char buf9[10]; - buf9[9] = '\0'; - char buf8[9]; - buf8[8] = '\0'; - char buf7[8]; - buf7[7] = '\0'; - char buf6[7]; - buf6[6] = '\0'; - char buf5[6]; - buf5[5] = '\0'; - char buf4[5]; - buf4[4] = '\0'; - char buf3[4]; - buf3[3] = '\0'; - char buf2[3]; - buf2[2] = '\0'; - char buf1[1]; - - is.read(buf9,9); - - is.read(buf28,28); - data._ds_name = buf28; - - is.read(buf10,10); - - is.read(buf1,1); - data._ds_type = buf1; - - is.read(buf11,11); - - is.read(buf64,62); - buf64[62] = '\0'; - data._filename = buf64; - - is.read(buf12,12); - - is.read(buf27,21); - buf27[21] = '\0'; - data._ds_offset = atof(buf27); - - is.read(buf16,16); - - is.read(buf27,21); - buf27[21] = '\0'; - data._ds_size = atof(buf27); - - is.read(buf16,16); - - is.read(buf11,11); - data._num_dsr = atol(buf11); - - is.read(buf10,10); - - is.read(buf11,11); - data._dsr_size = atol(buf11); - - is.read(buf64,41); - - return is; - -} - std::string _ds_name; - std::string _ds_type; - std::string _filename; - double _ds_offset; - double _ds_size; - int _num_dsr; - int _dsr_size; - -dsd::dsd(const dsd& rhs): - EnvisatAsarRecord(rhs), - _ds_name(rhs._ds_name), - _ds_type(rhs._ds_type), - _filename(rhs._filename), - _ds_offset(rhs._ds_offset), - _ds_size(rhs._ds_size), - _num_dsr(rhs._num_dsr), - _dsr_size(rhs._dsr_size) - { - } - - -dsd& dsd::operator=(const dsd& rhs) -{ - _ds_name = rhs._ds_name; - _ds_type = rhs._ds_type; - _filename = rhs._filename; - _ds_offset = rhs._ds_offset; - _ds_size = rhs._ds_size; - _num_dsr = rhs._num_dsr; - _dsr_size = rhs._dsr_size; - - return *this; -} diff --git a/Utilities/otbossim/src/ossim/imaging/EnvisatAsar/mph.cpp b/Utilities/otbossim/src/ossim/imaging/EnvisatAsar/mph.cpp deleted file mode 100644 index cc56ec25c89ee79f299659787c8cffeb6b15c444..0000000000000000000000000000000000000000 --- a/Utilities/otbossim/src/ossim/imaging/EnvisatAsar/mph.cpp +++ /dev/null @@ -1,811 +0,0 @@ -#include <ossim/imaging/EnvisatAsar/mph.h> - - -mph::mph() : EnvisatAsarRecord("mph_rec") -{ -} - -mph::~mph() -{ -} - -std::ostream& operator<<(std::ostream& os, const mph& data) -{ - os<<"product_name:"<<data._product_name.c_str()<<std::endl; - - os<<"product:"<<data._product.c_str()<<std::endl; - - os<<"proc_stage_title:"<<data._proc_stage_title.c_str()<<std::endl; - - os<<"proc_stage:"<<data._proc_stage.c_str()<<std::endl; - - os<<"ref_doc_title:"<<data._ref_doc_title.c_str()<<std::endl; - - os<<"ref_doc:"<<data._ref_doc.c_str()<<std::endl; - - os<<"acq_stat_id_title:"<<data._acq_stat_id_title.c_str()<<std::endl; - - os<<"acq_station:"<<data._acq_station.c_str()<<std::endl; - - os<<"proc_center_title:"<<data._proc_center_title.c_str()<<std::endl; - - os<<"proc_center:"<<data._proc_center.c_str()<<std::endl; - - os<<"proc_time_title:"<<data._proc_time_title.c_str()<<std::endl; - - os<<"proc_time:"<<data._proc_time.c_str()<<std::endl; - - os<<"soft_version_title:"<<data._soft_version_title.c_str()<<std::endl; - - os<<"soft_version:"<<data._soft_version.c_str()<<std::endl; - - os<<"sensing_start_title:"<<data._sensing_start_title.c_str()<<std::endl; - - os<<"sensing_start:"<<data._sensing_start.c_str()<<std::endl; - - os<<"sensing_stop_title:"<<data._sensing_stop_title.c_str()<<std::endl; - - os<<"sensing_stop:"<<data._sensing_stop.c_str()<<std::endl; - - os<<"phase_title:"<<data._phase_title.c_str()<<std::endl; - - os<<"phase:"<<data._phase.c_str()<<std::endl; - - os<<"cycle_title:"<<data._cycle_title.c_str()<<std::endl; - - os<<"cycle:"<<data._cycle.c_str()<<std::endl; - - os<<"relative_orbit_title:"<<data._relative_orbit_title.c_str()<<std::endl; - - os<<"rel_orbit:"<<data._rel_orbit.c_str()<<std::endl; - - os<<"absolute_orbit_title:"<<data._absolute_orbit_title.c_str()<<std::endl; - - os<<"abs_orbit:"<<data._abs_orbit.c_str()<<std::endl; - - os<<"state_vector_time_title:"<<data._state_vector_time_title.c_str()<<std::endl; - - os<<"state_vector_time:"<<data._state_vector_time.c_str()<<std::endl; - - os<<"delta_ut1_title:"<<data._delta_ut1_title.c_str()<<std::endl; - - os<<"delta_ut1:"<<data._delta_ut1.c_str()<<std::endl; - - os<<"delta_ut1_units:"<<data._delta_ut1_units.c_str()<<std::endl; - - os<<"x_position_title:"<<data._x_position_title.c_str()<<std::endl; - - os<<"x_position:"<<data._x_position.c_str()<<std::endl; - - os<<"x_position_units:"<<data._x_position_units.c_str()<<std::endl; - - os<<"y_position_title:"<<data._y_position_title.c_str()<<std::endl; - - os<<"y_position:"<<data._y_position.c_str()<<std::endl; - - os<<"y_position_units:"<<data._y_position_units.c_str()<<std::endl; - - os<<"z_position_title:"<<data._z_position_title.c_str()<<std::endl; - - os<<"z_position:"<<data._z_position.c_str()<<std::endl; - - os<<"z_position_units:"<<data._z_position_units.c_str()<<std::endl; - - os<<"x_velocity_title:"<<data._x_velocity_title.c_str()<<std::endl; - - os<<"x_velocity:"<<data._x_velocity.c_str()<<std::endl; - - os<<"x_velocity_units:"<<data._x_velocity_units.c_str()<<std::endl; - - os<<"y_velocity_title:"<<data._y_velocity_title.c_str()<<std::endl; - - os<<"y_velocity:"<<data._y_velocity.c_str()<<std::endl; - - os<<"y_velocity_units:"<<data._y_velocity_units.c_str()<<std::endl; - - os<<"z_velocity_title:"<<data._z_velocity_title.c_str()<<std::endl; - - os<<"z_velocity:"<<data._z_velocity.c_str()<<std::endl; - - os<<"z_velocity_units:"<<data._z_velocity_units.c_str()<<std::endl; - - os<<"vector_source_title:"<<data._vector_source_title.c_str()<<std::endl; - - os<<"vector_source:"<<data._vector_source.c_str()<<std::endl; - - os<<"spare_4:"<<data._spare_4.c_str()<<std::endl; - - os<<"utc_sbt_time_title:"<<data._utc_sbt_time_title.c_str()<<std::endl; - - os<<"utc_sbt_time:"<<data._utc_sbt_time.c_str()<<std::endl; - - os<<"sat_binary_time_title:"<<data._sat_binary_time_title.c_str()<<std::endl; - - os<<"sat_binary_time:"<<data._sat_binary_time.c_str()<<std::endl; - - os<<"clock_step_title:"<<data._clock_step_title.c_str()<<std::endl; - - os<<"clock_step:"<<data._clock_step.c_str()<<std::endl; - - os<<"clock_step_units:"<<data._clock_step_units.c_str()<<std::endl; - - os<<"leap_utc_title:"<<data._leap_utc_title.c_str()<<std::endl; - - os<<"leap_utc:"<<data._leap_utc.c_str()<<std::endl; - - os<<"leap_sign_title:"<<data._leap_sign_title.c_str()<<std::endl; - - os<<"leap_sign:"<<data._leap_sign.c_str()<<std::endl; - - os<<"leap_err_title:"<<data._leap_err_title.c_str()<<std::endl; - - os<<"leap_err:"<<data._leap_err.c_str()<<std::endl; - - os<<"product_err_title:"<<data._product_err_title.c_str()<<std::endl; - - os<<"product_err:"<<data._product_err.c_str()<<std::endl; - - os<<"total_size_title:"<<data._total_size_title.c_str()<<std::endl; - - os<<"tot_size:"<<data._tot_size.c_str()<<std::endl; - - os<<"total_size_units:"<<data._total_size_units.c_str()<<std::endl; - - os<<"sph_size_title:"<<data._sph_size_title.c_str()<<std::endl; - - os<<"sph_size:"<<data._sph_size.c_str()<<std::endl; - - os<<"sph_size_units:"<<data._sph_size_units.c_str()<<std::endl; - - os<<"number_of_dsd_title:"<<data._number_of_dsd_title.c_str()<<std::endl; - - os<<"num_dsd:"<<data._num_dsd<<std::endl; - - os<<"size_of_dsd_title:"<<data._size_of_dsd_title.c_str()<<std::endl; - - os<<"dsd_size:"<<data._dsd_size<<std::endl; - - os<<"size_of_dsd_units:"<<data._size_of_dsd_units.c_str()<<std::endl; - - os<<"number_of_ds_att_title:"<<data._number_of_ds_att_title.c_str()<<std::endl; - - os<<"num_data_sets:"<<data._num_data_sets<<std::endl; - - return os; - -} - -std::istream& operator>>(std::istream& is, mph& data) -{ - char buf64[65]; - buf64[64] = '\0'; - char buf32[33]; - buf32[32] = '\0'; - char buf27[28]; - buf27[27]='\0'; - char buf16[17]; - buf16[16]='\0'; - char buf15[16]; - buf15[15] = '\0'; - char buf14[15]; - buf14[14] = '\0'; - char buf13[14]; - buf13[13] = '\0'; - char buf12[13]; - buf12[12] = '\0'; - char buf11[12]; - buf11[11] = '\0'; - char buf10[11]; - buf10[10] = '\0'; - char buf9[10]; - buf9[9] = '\0'; - char buf8[9]; - buf8[8] = '\0'; - char buf7[8]; - buf7[7] = '\0'; - char buf6[7]; - buf6[6] = '\0'; - char buf5[6]; - buf5[5] = '\0'; - char buf4[5]; - buf4[4] = '\0'; - char buf3[4]; - buf3[3] = '\0'; - char buf2[3]; - buf2[2] = '\0'; - char buf1[1]; - - - is.read(buf8,8); - data._product_name = buf8; - - is.read(buf1,1); - - is.read(buf64,62); - buf64[62]='\0'; - data._product = buf64; - - is.read(buf1,1); - - is.read(buf1,1); - - is.read(buf16,11); - buf16[11]='\0'; - data._proc_stage_title = buf16; - - is.read(buf1,1); - data._proc_stage = buf1; - - is.read(buf1,1); - - is.read(buf8,8); - data._ref_doc_title = buf8; - - is.read(buf1,1); - - is.read(buf32,23); - buf32[23]='\0'; - data._ref_doc = buf32; - - is.read(buf1,1); - - is.read(buf1,1); - - is.read(buf64,40); - - is.read(buf1,1); - - is.read(buf32,20); - buf32[20]='\0'; - data._acq_stat_id_title = buf32; - - is.read(buf1,1); - - is.read(buf32,20); - buf32[20]='\0'; - data._acq_station = buf32; - - is.read(buf1,1); - - is.read(buf1,1); - - is.read(buf16,12); - buf16[12]='\0'; - data._proc_center_title = buf16; - - is.read(buf1,1); - - is.read(buf8,6); - buf8[6]='\0'; - data._proc_center = buf8; - - is.read(buf1,1); - - is.read(buf1,1); - - is.read(buf16,10); - buf16[10]='\0'; - data._proc_time_title = buf16; - - is.read(buf1,1); - - is.read(buf32,27); - buf32[27]='\0'; - data._proc_time = buf32; - - is.read(buf1,1); - - is.read(buf1,1); - - is.read(buf16,13); - buf16[13]='\0'; - data._soft_version_title = buf16; - - is.read(buf1,1); - - is.read(buf16,14); - buf16[14]='\0'; - data._soft_version = buf16; - - is.read(buf1,1); - - is.read(buf1,1); - - is.read(buf64,40); - - is.read(buf1,1); - - is.read(buf16,14); - buf16[14]='\0'; - data._sensing_start_title = buf16; - - is.read(buf1,1); - - is.read(buf32,27); - buf32[27]='\0'; - data._sensing_start = buf32; - - is.read(buf1,1); - - is.read(buf1,1); - - is.read(buf16,13); - buf16[13]='\0'; - data._sensing_stop_title = buf16; - - is.read(buf1,1); - - is.read(buf32,27); - buf32[27]='\0'; - data._sensing_stop = buf32; - - is.read(buf1,1); - - is.read(buf1,1); - - is.read(buf64,40); - - is.read(buf1,1); - - is.read(buf6,6); - data._phase_title = buf6; - - is.read(buf1,1); - data._phase = buf1; - - is.read(buf1,1); - - is.read(buf6,6); - data._cycle_title = buf6; - - is.read(buf4,4); - data._cycle = buf4; - - is.read(buf1,1); - - is.read(buf10,10); - data._relative_orbit_title = buf10; - - is.read(buf6,6); - data._rel_orbit = buf6; - - is.read(buf1,1); - - is.read(buf10,10); - data._absolute_orbit_title = buf10; - - is.read(buf6,6); - data._abs_orbit = buf6; - - is.read(buf1,1); - - is.read(buf32,18); - buf32[18]='\0'; - data._state_vector_time_title = buf32; - - is.read(buf1,1); - - is.read(buf27,27); - data._state_vector_time = buf27; - - is.read(buf1,1); - - is.read(buf1,1); - - is.read(buf10,10); - data._delta_ut1_title = buf10; - - is.read(buf8,8); - data._delta_ut1 = buf8; - - is.read(buf4,3); - buf4[3]='\0'; - data._delta_ut1_units = buf4; - - is.read(buf1,1); - - is.read(buf11,11); - data._x_position_title = buf11; - - is.read(buf12,12); - data._x_position = buf12; - - is.read(buf3,3); - data._x_position_units = buf3; - - is.read(buf1,1); - - is.read(buf11,11); - data._y_position_title = buf11; - - is.read(buf12,12); - data._y_position = buf12; - - is.read(buf3,3); - data._y_position_units = buf3; - - is.read(buf1,1); - - is.read(buf11,11); - data._z_position_title = buf11; - - is.read(buf12,12); - data._z_position = buf12; - - is.read(buf3,3); - data._z_position_units = buf3; - - is.read(buf1,1); - - is.read(buf11,11); - data._x_velocity_title = buf11; - - is.read(buf12,12); - data._x_velocity = buf12; - - is.read(buf8,5); - buf8[5] = '\0'; - data._x_velocity_units = buf8; - - is.read(buf1,1); - - is.read(buf11,11); - data._y_velocity_title = buf11; - - is.read(buf12,12); - data._y_velocity = buf12; - - is.read(buf8,5); - buf8[5] = '\0'; - data._y_velocity_units = buf8; - - is.read(buf1,1); - - is.read(buf11,11); - data._z_velocity_title = buf11; - - is.read(buf12,12); - data._z_velocity = buf12; - - is.read(buf8,5); - buf8[5] = '\0'; - data._z_velocity_units = buf8; - - is.read(buf1,1); - - is.read(buf16,14); - buf16[14] = '\0'; - data._vector_source_title = buf16; - - is.read(buf1,1); - - is.read(buf2,2); - data._vector_source = buf2; - - is.read(buf1,1); - - is.read(buf1,1); - - is.read(buf64,40); - buf64[40] = '\0'; - data._spare_4 = buf64; - - is.read(buf1,1); - - is.read(buf16,13); - buf16[13] = '\0'; - data._utc_sbt_time_title = buf16; - - is.read(buf1,1); - - is.read(buf27,27); - data._utc_sbt_time = buf27; - - is.read(buf1,1); - - is.read(buf1,1); - - is.read(buf16,16); - data._sat_binary_time_title = buf16; - - is.read(buf11,11); - data._sat_binary_time = buf11; - - is.read(buf1,1); - - is.read(buf11,11); - data._clock_step_title = buf11; - - is.read(buf11,11); - data._clock_step = buf11; - - is.read(buf4,4); - data._clock_step_units = buf4; - - is.read(buf1,1); - - is.read(buf32,32); - - is.read(buf1,1); - - is.read(buf10,9); - buf10[9] = '\0'; - data._leap_utc_title = buf10; - - is.read(buf1,1); - - is.read(buf27,27); - data._leap_utc = buf27; - - is.read(buf1,1); - - is.read(buf1,1); - - is.read(buf10,10); - data._leap_sign_title = buf10; - - is.read(buf4,4); - data._leap_sign = buf4; - - is.read(buf1,1); - - is.read(buf10,9); - buf10[9] = '\0'; - data._leap_err_title = buf10; - - is.read(buf1,1); - data._leap_err = buf1; - - is.read(buf1,1); - - is.read(buf64,40); - - is.read(buf1,1); - - is.read(buf12,12); - data._product_err_title = buf12; - - is.read(buf1,1); - data._product_err = buf1; - - is.read(buf1,1); - - is.read(buf10,9); - buf10[9] = '\0'; - data._total_size_title = buf10; - - is.read(buf32,21); - buf32[21] = '\0'; - data._tot_size = buf32; - - is.read(buf7,7); - data._total_size_units = buf7; - - is.read(buf1,1); - - is.read(buf10,9); - buf10[9] = '\0'; - data._sph_size_title = buf10; - - is.read(buf11,11); - data._sph_size = buf11; - - is.read(buf8,7); - buf8[7] = '\0'; - data._sph_size_units = buf8; - - is.read(buf1,1); - - is.read(buf8,8); - data._number_of_dsd_title = buf8; - - is.read(buf11,11); - data._num_dsd = atoi(buf11); - - is.read(buf1,1); - - is.read(buf10,9); - buf10[9] = '\0'; - data._size_of_dsd_title = buf10; - - is.read(buf11,11); - data._dsd_size = atoi(buf11); - - is.read(buf8,7); - buf8[7] = '\0'; - data._size_of_dsd_units = buf8; - - is.read(buf1,1); - - is.read(buf16,14); - buf16[14] = '\0'; - data._number_of_ds_att_title = buf16; - - is.read(buf11,11); - data._num_data_sets = atoi(buf11); - - is.read(buf1,1); - - is.read(buf64,40); - - is.read(buf1,1); - - return is; -} - - -mph::mph(const mph& rhs): - EnvisatAsarRecord(rhs), - _product_name(rhs._product_name), - _product(rhs._product), - _proc_stage_title(rhs._proc_stage_title), - _proc_stage(rhs._proc_stage), - _ref_doc_title(rhs._ref_doc_title), - _ref_doc(rhs._ref_doc), - _acq_stat_id_title(rhs._acq_stat_id_title), - _acq_station(rhs._acq_station), - _proc_center_title(rhs._proc_center_title), - _proc_center(rhs._proc_center), - _proc_time_title(rhs._proc_time_title), - _proc_time(rhs._proc_time), - _soft_version_title(rhs._soft_version_title), - _soft_version(rhs._soft_version), - _sensing_start_title(rhs._sensing_start_title), - _sensing_start(rhs._sensing_start), - _sensing_stop_title(rhs._sensing_stop_title), - _sensing_stop(rhs._sensing_stop), - _phase_title(rhs._phase_title), - _phase(rhs._phase), - _cycle_title(rhs._cycle_title), - _cycle(rhs._cycle), - _relative_orbit_title(rhs._relative_orbit_title), - _rel_orbit(rhs._rel_orbit), - _absolute_orbit_title(rhs._absolute_orbit_title), - _abs_orbit(rhs._abs_orbit), - _state_vector_time_title(rhs._state_vector_time_title), - _state_vector_time(rhs._state_vector_time), - _delta_ut1_title(rhs._delta_ut1_title), - _delta_ut1(rhs._delta_ut1), - _delta_ut1_units(rhs._delta_ut1_units), - _x_position_title(rhs._x_position_title), - _x_position(rhs._x_position), - _x_position_units(rhs._x_position_units), - _y_position_title(rhs._y_position_title), - _y_position(rhs._y_position), - _y_position_units(rhs._y_position_units), - _z_position_title(rhs._z_position_title), - _z_position(rhs._z_position), - _z_position_units(rhs._z_position_units), - _x_velocity_title(rhs._x_velocity_title), - _x_velocity(rhs._x_velocity), - _x_velocity_units(rhs._x_velocity_units), - _y_velocity_title(rhs._y_velocity_title), - _y_velocity(rhs._y_velocity), - _y_velocity_units(rhs._y_velocity_units), - _z_velocity_title(rhs._z_velocity_title), - _z_velocity(rhs._z_velocity), - _z_velocity_units(rhs._z_velocity_units), - _vector_source_title(rhs._vector_source_title), - _vector_source(rhs._vector_source), - _spare_4(rhs._spare_4), - _utc_sbt_time_title(rhs._utc_sbt_time_title), - _utc_sbt_time(rhs._utc_sbt_time), - _sat_binary_time_title(rhs._sat_binary_time_title), - _sat_binary_time(rhs._sat_binary_time), - _clock_step_title(rhs._clock_step_title), - _clock_step(rhs._clock_step), - _clock_step_units(rhs._clock_step_units), - _leap_utc_title(rhs._leap_utc_title), - _leap_utc(rhs._leap_utc), - _leap_sign_title(rhs._leap_sign_title), - _leap_sign(rhs._leap_sign), - _leap_err_title(rhs._leap_err_title), - _leap_err(rhs._leap_err), - _product_err_title(rhs._product_err_title), - _product_err(rhs._product_err), - _total_size_title(rhs._total_size_title), - _tot_size(rhs._tot_size), - _total_size_units(rhs._total_size_units), - _sph_size_title(rhs._sph_size_title), - _sph_size(rhs._sph_size), - _sph_size_units(rhs._sph_size_units), - _number_of_dsd_title(rhs._number_of_dsd_title), - _num_dsd(rhs._num_dsd), - _size_of_dsd_title(rhs._size_of_dsd_title), - _dsd_size(rhs._dsd_size), - _size_of_dsd_units(rhs._size_of_dsd_units), - _number_of_ds_att_title(rhs._number_of_ds_att_title), - _num_data_sets(rhs._num_data_sets) - {} - - -mph& mph::operator=(const mph& rhs) -{ - _product_name = rhs._product_name; - _product = rhs._product; - _proc_stage_title = rhs._proc_stage_title; - _proc_stage = rhs._proc_stage; - _ref_doc_title = rhs._ref_doc_title; - _ref_doc = rhs._ref_doc; - _acq_stat_id_title = rhs._acq_stat_id_title; - _acq_station = rhs._acq_station; - _proc_center_title = rhs._proc_center_title; - _proc_center = rhs._proc_center; - _proc_time_title = rhs._proc_time_title; - _proc_time = rhs._proc_time; - _soft_version_title = rhs._soft_version_title; - _soft_version = rhs._soft_version; - _sensing_start_title = rhs._sensing_start_title; - _sensing_start = rhs._sensing_start; - _sensing_stop_title = rhs._sensing_stop_title; - _sensing_stop = rhs._sensing_stop; - _phase_title = rhs._phase_title; - _phase = rhs._phase; - _cycle_title = rhs._cycle_title; - _cycle = rhs._cycle; - _relative_orbit_title = rhs._relative_orbit_title; - _rel_orbit = rhs._rel_orbit; - _absolute_orbit_title = rhs._absolute_orbit_title; - _abs_orbit = rhs._abs_orbit; - _state_vector_time_title = rhs._state_vector_time_title; - _state_vector_time = rhs._state_vector_time; - _delta_ut1_title = rhs._delta_ut1_title; - _delta_ut1 = rhs._delta_ut1; - _delta_ut1_units = rhs._delta_ut1_units; - _x_position_title = rhs._x_position_title; - _x_position = rhs._x_position; - _x_position_units = rhs._x_position_units; - _y_position_title = rhs._y_position_title; - _y_position = rhs._y_position; - _y_position_units = rhs._y_position_units; - _z_position_title = rhs._z_position_title; - _z_position = rhs._z_position; - _z_position_units = rhs._z_position_units; - _x_velocity_title = rhs._x_velocity_title; - _x_velocity = rhs._x_velocity; - _x_velocity_units = rhs._x_velocity_units; - _y_velocity_title = rhs._y_velocity_title; - _y_velocity = rhs._y_velocity; - _y_velocity_units = rhs._y_velocity_units; - _z_velocity_title = rhs._z_velocity_title; - _z_velocity = rhs._z_velocity; - _z_velocity_units = rhs._z_velocity_units; - _vector_source_title = rhs._vector_source_title; - _vector_source = rhs._vector_source; - _spare_4 = rhs._spare_4; - _utc_sbt_time_title = rhs._utc_sbt_time_title; - _utc_sbt_time = rhs._utc_sbt_time; - _sat_binary_time_title = rhs._sat_binary_time_title; - _sat_binary_time = rhs._sat_binary_time; - _clock_step_title = rhs._clock_step_title; - _clock_step = rhs._clock_step; - _clock_step_units = rhs._clock_step_units; - _leap_utc_title = rhs._leap_utc_title; - _leap_utc = rhs._leap_utc; - _leap_sign_title = rhs._leap_sign_title; - _leap_sign = rhs._leap_sign; - _leap_err_title = rhs._leap_err_title; - _leap_err = rhs._leap_err; - _product_err_title = rhs._product_err_title; - _product_err = rhs._product_err; - _total_size_title = rhs._total_size_title; - _tot_size = rhs._tot_size; - _total_size_units = rhs._total_size_units; - _sph_size_title = rhs._sph_size_title; - _sph_size = rhs._sph_size; - _sph_size_units = rhs._sph_size_units; - _number_of_dsd_title = rhs._number_of_dsd_title; - _num_dsd = rhs._num_dsd; - _size_of_dsd_title = rhs._size_of_dsd_title; - _dsd_size = rhs._dsd_size; - _size_of_dsd_units = rhs._size_of_dsd_units; - _number_of_ds_att_title = rhs._number_of_ds_att_title; - _num_data_sets = rhs._num_data_sets; - - return *this; -} - - - - - diff --git a/Utilities/otbossim/src/ossim/imaging/EnvisatAsar/sph.cpp b/Utilities/otbossim/src/ossim/imaging/EnvisatAsar/sph.cpp deleted file mode 100644 index 8e2a56d1bdd4356f1b9a61695de27055a81a60f4..0000000000000000000000000000000000000000 --- a/Utilities/otbossim/src/ossim/imaging/EnvisatAsar/sph.cpp +++ /dev/null @@ -1,772 +0,0 @@ -#include <ossim/imaging/EnvisatAsar/sph.h> -#include <ossim/imaging/EnvisatAsar/mph.h> - -sph::sph() : EnvisatAsarRecord("sph_rec") -{ - this->_num_dsd = 18; - this->_size_dsd = 280; -} - -sph::sph(const mph& data) : EnvisatAsarRecord("sph_rec") -{ - this->_num_dsd = data._num_dsd ; - this->_size_dsd = data._dsd_size; -} - -sph::~sph() -{ -} - - -std::ostream& operator<<(std::ostream& os, const sph& data) -{ - os<<"sph_desc_title:"<<data._sph_desc_title.c_str()<<std::endl; - - os<<"sph_desc:"<<data._sph_desc.c_str()<<std::endl; - - os<<"strip_cont_ind_title:"<<data._strip_cont_ind_title.c_str()<<std::endl; - - os<<"strip_cont_ind std::string:"<<data._strip_cont_ind.c_str()<<std::endl; - - os<<"slice_pos_title:"<<data._slice_pos_title.c_str()<<std::endl; - - os<<"slice_position:"<<data._slice_position.c_str()<<std::endl; - - os<<"num_slices_title:"<<data._num_slices_title.c_str()<<std::endl; - - os<<"num_slices:"<<data._num_slices.c_str()<<std::endl; - - os<<"first_line_time_title:"<<data._first_line_time_title.c_str()<<std::endl; - - os<<"first_line_time:"<<data._first_line_time.c_str()<<std::endl; - - os<<"last_line_time_title:"<<data._last_line_time_title.c_str()<<std::endl; - - os<<"last_line_time:"<<data._last_line_time.c_str()<<std::endl; - - os<<"first_near_lat_title:"<<data._first_near_lat_title.c_str()<<std::endl; - - os<<"first_near_lat:"<<data._first_near_lat.c_str()<<std::endl; - - os<<"first_near_lat_units:"<<data._first_near_lat_units.c_str()<<std::endl; - - os<<"first_near_long_title:"<<data._first_near_long_title.c_str()<<std::endl; - - os<<"first_near_long:"<<data._first_near_long.c_str()<<std::endl; - - os<<"first_near_long_units:"<<data._first_near_long_units.c_str()<<std::endl; - - os<<"first_mid_lat_title:"<<data._first_mid_lat_title.c_str()<<std::endl; - - os<<"first_mid_lat:"<<data._first_mid_lat.c_str()<<std::endl; - - os<<"first_mid_lat_units:"<<data._first_mid_lat_units.c_str()<<std::endl; - - os<<"first_mid_long_title:"<<data._first_mid_long_title.c_str()<<std::endl; - - os<<"first_mid_long:"<<data._first_mid_long.c_str()<<std::endl; - - os<<"first_mid_long_units:"<<data._first_mid_long_units.c_str()<<std::endl; - - os<<"first_far_lat_title:"<<data._first_far_lat_title.c_str()<<std::endl; - - os<<"first_far_lat:"<<data._first_far_lat.c_str()<<std::endl; - - os<<"first_far_lat_units:"<<data._first_far_lat_units.c_str()<<std::endl; - - os<<"first_far_long_title:"<<data._first_far_long_title.c_str()<<std::endl; - - os<<"first_far_long:"<<data._first_far_long.c_str()<<std::endl; - - os<<"first_far_long_units:"<<data._first_far_long_units.c_str()<<std::endl; - - os<<"last_near_lat_title:"<<data._last_near_lat_title.c_str()<<std::endl; - - os<<"last_near_lat:"<<data._last_near_lat.c_str()<<std::endl; - - os<<"last_near_lat_units:"<<data._last_near_lat_units.c_str()<<std::endl; - - os<<"last_near_long_title:"<<data._last_near_long_title.c_str()<<std::endl; - - os<<"last_near_long:"<<data._last_near_long.c_str()<<std::endl; - - os<<"last_near_long_units:"<<data._last_near_long_units.c_str()<<std::endl; - - os<<"last_mid_lat_title:"<<data._last_mid_lat_title.c_str()<<std::endl; - - os<<"last_mid_lat:"<<data._last_mid_lat.c_str()<<std::endl; - - os<<"last_mid_lat_units:"<<data._last_mid_lat_units.c_str()<<std::endl; - - os<<"last_mid_long_title:"<<data._last_mid_long_title.c_str()<<std::endl; - - os<<"last_mid_long:"<<data._last_mid_long.c_str()<<std::endl; - - os<<"last_mid_long_units:"<<data._last_mid_long_units.c_str()<<std::endl; - - os<<"last_far_lat_title:"<<data._last_far_lat_title.c_str()<<std::endl; - - os<<"last_far_lat:"<<data._last_far_lat.c_str()<<std::endl; - - os<<"last_far_lat_units:"<<data._last_far_lat_units.c_str()<<std::endl; - - os<<"last_far_long_title:"<<data._last_far_long_title.c_str()<<std::endl; - - os<<"last_far_long:"<<data._last_far_long.c_str()<<std::endl; - - os<<"last_far_long_units:"<<data._last_far_long_units.c_str()<<std::endl; - - os<<"swath_title:"<<data._swath_title.c_str()<<std::endl; - - os<<"swath:"<<data._swath.c_str()<<std::endl; - - os<<"pass_title:"<<data._pass_title.c_str()<<std::endl; - - os<<"pass:"<<data._pass.c_str()<<std::endl; - - os<<"sample_type_title:"<<data._sample_type_title.c_str()<<std::endl; - - os<<"sample_type:"<<data._sample_type.c_str()<<std::endl; - - os<<"algo_title:"<<data._algo_title.c_str()<<std::endl; - - os<<"algorithm:"<<data._algorithm.c_str()<<std::endl; - - os<<"mds1_tx_rx_polar_title:"<<data._mds1_tx_rx_polar_title.c_str()<<std::endl; - - os<<"mds1_tx_rx_polar:"<<data._mds1_tx_rx_polar.c_str()<<std::endl; - - os<<"mds2_tx_rx_polar_title:"<<data._mds2_tx_rx_polar_title.c_str()<<std::endl; - - os<<"mds2_tx_rx_polar:"<<data._mds2_tx_rx_polar.c_str()<<std::endl; - - os<<"compression_title:"<<data._compression_title.c_str()<<std::endl; - - os<<"compression:"<<data._compression.c_str()<<std::endl; - - os<<"azimut_looks_title:"<<data._azimut_looks_title.c_str()<<std::endl; - - os<<"azimut_looks:"<<data._azimut_looks.c_str()<<std::endl; - - os<<"range_looks_title:"<<data._range_looks_title.c_str()<<std::endl; - - os<<"range_looks:"<<data._range_looks.c_str()<<std::endl; - - os<<"range_spacing_title:"<<data._range_spacing_title.c_str()<<std::endl; - - os<<"range_spacing:"<<data._range_spacing.c_str()<<std::endl; - - os<<"range_spacing_unit:"<<data._range_spacing_unit.c_str()<<std::endl; - - os<<"azimut_spacing_title:"<<data._azimut_spacing_title.c_str()<<std::endl; - - os<<"azimut_spacing:"<<data._azimut_spacing.c_str()<<std::endl; - - os<<"azimut_spacing_unit:"<<data._azimut_spacing_unit.c_str()<<std::endl; - - os<<"line_time_interval_title:"<<data._line_time_interval_title.c_str()<<std::endl; - - os<<"line_time_interval:"<<data._line_time_interval.c_str()<<std::endl; - - os<<"line_time_interv_units:"<<data._line_time_interv_units.c_str()<<std::endl; - - os<<"line_length_title:"<<data._line_length_title.c_str()<<std::endl; - - os<<"line_length:"<<data._line_length.c_str()<<std::endl; - - os<<"line_length_units:"<<data._line_length_units.c_str()<<std::endl; - - os<<"data_type_title:"<<data._data_type_title.c_str()<<std::endl; - - os<<"data_type:"<<data._data_type.c_str()<<std::endl; - - return os; - -} - -std::istream& operator>>(std::istream& is, sph& data) -{ - char buf64[65]; - buf64[64] = '\0'; - char buf32[33]; - buf32[32] = '\0'; - char buf27[28]; - buf27[27] = '\0'; - char buf16[17]; - buf16[16]='\0'; - char buf15[16]; - buf15[15] = '\0'; - char buf14[15]; - buf14[14] = '\0'; - char buf13[14]; - buf13[13] = '\0'; - char buf12[13]; - buf12[12] = '\0'; - char buf11[12]; - buf11[11] = '\0'; - char buf10[11]; - buf10[10] = '\0'; - char buf9[10]; - buf9[9] = '\0'; - char buf8[9]; - buf8[8] = '\0'; - char buf7[8]; - buf7[7] = '\0'; - char buf6[7]; - buf6[6] = '\0'; - char buf5[6]; - buf5[5] = '\0'; - char buf4[5]; - buf4[4] = '\0'; - char buf3[4]; - buf3[3] = '\0'; - char buf2[3]; - buf2[2] = '\0'; - char buf1[1]; - - - is.read(buf15,15); - data._sph_desc_title = buf15; - - is.read(buf1,1); - - is.read(buf32,28); - buf32[28] = '\0'; - data._sph_desc = buf32; - - is.read(buf1,1); - - is.read(buf1,1); - - is.read(buf32,31); - buf32[31] = '\0'; - data._strip_cont_ind_title = buf32; - - is.read(buf4,4); - data._strip_cont_ind = buf4; - - is.read(buf1,1); - - is.read(buf15,15); - data._slice_pos_title = buf15; - - is.read(buf4,4); - data._slice_position = buf4; - - is.read(buf1,1); - - is.read(buf11,11); - data._num_slices_title = buf11; - - is.read(buf4,4); - data._num_slices = buf4; - - is.read(buf1,1); - - is.read(buf16,16); - data._first_line_time_title = buf16; - - is.read(buf1,1); - - is.read(buf27,27); - data._first_line_time = buf27; - - is.read(buf1,1); - - is.read(buf1,1); - - is.read(buf15,15); - data._last_line_time_title = buf15; - - is.read(buf1,1); - - is.read(buf27,27); - data._last_line_time = buf27; - - is.read(buf1,1); - - is.read(buf1,1); - - is.read(buf15,15); - data._first_near_lat_title = buf15; - - is.read(buf11,11); - data._first_near_lat = buf11; - - is.read(buf10,10); - data._first_near_lat_units = buf10; - - is.read(buf1,1); - - is.read(buf16,16); - data._first_near_long_title = buf16; - - is.read(buf11,11); - data._first_near_long = buf11; - - is.read(buf10,10); - data._first_near_long_units = buf10; - - is.read(buf1,1); - - is.read(buf14,14); - data._first_mid_lat_title = buf14; - - is.read(buf11,11); - data._first_mid_lat = buf11; - - is.read(buf10,10); - data._first_mid_lat_units = buf10; - - is.read(buf1,1); - - is.read(buf15,15); - data._first_mid_long_title = buf15; - - is.read(buf11,11); - data._first_mid_long = buf11; - - is.read(buf10,10); - data._first_mid_long_units = buf10; - - is.read(buf1,1); - - is.read(buf14,14); - data._first_far_lat_title = buf14; - - is.read(buf11,11); - data._first_far_lat = buf11; - - is.read(buf10,10); - data._first_far_lat_units = buf10; - - is.read(buf1,1); - - is.read(buf15,15); - data._first_far_long_title = buf15; - - is.read(buf11,11); - data._first_far_long = buf11; - - is.read(buf10,10); - data._first_far_long_units = buf10; - - is.read(buf1,1); - - is.read(buf14,14); - data._last_near_lat_title = buf14; - - is.read(buf11,11); - data._last_near_lat = buf11; - - is.read(buf10,10); - data._last_near_lat_units = buf10; - - is.read(buf1,1); - - is.read(buf15,15); - data._last_near_long_title = buf15; - - is.read(buf11,11); - data._last_near_long = buf11; - - is.read(buf10,10); - data._last_near_long_units = buf10; - - is.read(buf1,1); - - is.read(buf13,13); - data._last_mid_lat_title = buf13; - - is.read(buf11,11); - data._last_mid_lat = buf11; - - is.read(buf10,10); - data._last_mid_lat_units = buf10; - - is.read(buf1,1); - - is.read(buf14,14); - data._last_mid_long_title = buf14; - - is.read(buf11,11); - data._last_mid_long = buf11; - - is.read(buf10,10); - data._last_mid_long_units = buf10; - - is.read(buf1,1); - - is.read(buf13,13); - data._last_far_lat_title = buf13; - - is.read(buf11,11); - data._last_far_lat = buf11; - - is.read(buf10,10); - data._last_far_lat_units = buf10; - - is.read(buf1,1); - - is.read(buf14,14); - data._last_far_long_title = buf14; - - is.read(buf11,11); - data._last_far_long = buf11; - - is.read(buf10,10); - data._last_far_long_units = buf10; - - is.read(buf1,1); - - is.read(buf64,35); - - is.read(buf1,1); - - is.read(buf6,6); - data._swath_title = buf6; - - is.read(buf1,1); - - is.read(buf3,3); - data._swath = buf3; - - is.read(buf1,1); - - is.read(buf1,1); - - is.read(buf5,5); - data._pass_title = buf5; - - is.read(buf1,1); - - is.read(buf10,10); - data._pass = buf10; - - is.read(buf1,1); - - is.read(buf1,1); - - is.read(buf12,12); - data._sample_type_title = buf12; - - is.read(buf1,1); - - is.read(buf8,8); - data._sample_type = buf8; - - is.read(buf1,1); - - is.read(buf1,1); - - is.read(buf10,10); - data._algo_title = buf10; - - is.read(buf1,1); - - is.read(buf7,7); - data._algorithm = buf7; - - is.read(buf1,1); - - is.read(buf1,1); - - is.read(buf32,17); - buf32[17] = '\0'; - data._mds1_tx_rx_polar_title = buf32; - - is.read(buf1,1); - - is.read(buf3,3); - data._mds1_tx_rx_polar = buf3; - - is.read(buf1,1); - - is.read(buf1,1); - - is.read(buf32,17); - buf32[17] = '\0'; - data._mds2_tx_rx_polar_title = buf32; - - is.read(buf1,1); - - is.read(buf3,3); - data._mds2_tx_rx_polar = buf3; - - is.read(buf1,1); - - is.read(buf1,1); - - is.read(buf12,12); - data._compression_title = buf12; - - is.read(buf1,1); - - is.read(buf5,5); - data._compression = buf5; - - is.read(buf1,1); - - is.read(buf1,1); - - is.read(buf14,14); - data._azimut_looks_title = buf14; - - is.read(buf4,4); - data._azimut_looks = buf4; - - is.read(buf1,1); - - is.read(buf12,12); - data._range_looks_title = buf12; - - is.read(buf4,4); - data._range_looks = buf4; - - is.read(buf1,1); - - is.read(buf14,14); - data._range_spacing_title = buf14; - - is.read(buf15,15); - data._range_spacing = buf15; - - is.read(buf3,3); - data._range_spacing_unit = buf3; - - is.read(buf1,1); - - is.read(buf16,16); - data._azimut_spacing_title = buf16; - - is.read(buf15,15); - data._azimut_spacing = buf15; - - is.read(buf3,3); - data._azimut_spacing_unit = buf3; - - is.read(buf1,1); - - is.read(buf32,19); - buf32[19] = '\0'; - data._line_time_interval_title = buf32; - - is.read(buf15,15); - data._line_time_interval = buf15; - - is.read(buf3,3); - data._line_time_interv_units = buf3; - - is.read(buf1,1); - - is.read(buf12,12); - data._line_length_title = buf12; - - is.read(buf6,6); - data._line_length = buf6; - - is.read(buf9,9); - data._line_length_units = buf9; - - is.read(buf1,1); - - is.read(buf10,10); - data._data_type_title = buf10; - - is.read(buf1,1); - - is.read(buf5,5); - data._data_type = buf5; - - is.read(buf1,1); - - is.read(buf1,1); - - is.read(buf64,50); - - is.read(buf1,1); - - for (int i = 0; i<data._num_dsd; i++) - { - dsd dsd_rec; - is>>dsd_rec; - data._dsd_vector.push_back(dsd_rec); - } - - //char *buffer = (char* )malloc(data._num_dsd*data._size_dsd); - //is.read(buffer, data._num_dsd*data._size_dsd); - -return is; -} - - -sph::sph(const sph& rhs): - EnvisatAsarRecord(rhs), - _sph_desc_title(rhs._sph_desc_title), - _sph_desc(rhs._sph_desc), - _strip_cont_ind_title(rhs._strip_cont_ind_title), - _strip_cont_ind(rhs._strip_cont_ind), - _slice_pos_title(rhs._slice_pos_title), - _slice_position(rhs._slice_position), - _num_slices_title(rhs._num_slices_title), - _num_slices(rhs._num_slices), - _first_line_time_title(rhs._first_line_time_title), - _first_line_time(rhs._first_line_time), - _last_line_time_title(rhs._last_line_time_title), - _last_line_time(rhs._last_line_time), - _first_near_lat_title(rhs._first_near_lat_title), - _first_near_lat(rhs._first_near_lat), - _first_near_lat_units(rhs._first_near_lat_units), - _first_near_long_title(rhs._first_near_long_title), - _first_near_long(rhs._first_near_long), - _first_near_long_units(rhs._first_near_long_units), - _first_mid_lat_title(rhs._first_mid_lat_title), - _first_mid_lat(rhs._first_mid_lat), - _first_mid_lat_units(rhs._first_mid_lat_units), - _first_mid_long_title(rhs._first_mid_long_title), - _first_mid_long(rhs._first_mid_long), - _first_mid_long_units(rhs._first_mid_long_units), - _first_far_lat_title(rhs._first_far_lat_title), - _first_far_lat(rhs._first_far_lat), - _first_far_lat_units(rhs._first_far_lat_units), - _first_far_long_title(rhs._first_far_long_title), - _first_far_long(rhs._first_far_long), - _first_far_long_units(rhs._first_far_long_units), - _last_near_lat_title(rhs._last_near_lat_title), - _last_near_lat(rhs._last_near_lat), - _last_near_lat_units(rhs._last_near_lat_units), - _last_near_long_title(rhs._last_near_long_title), - _last_near_long(rhs._last_near_long), - _last_near_long_units(rhs._last_near_long_units), - _last_mid_lat_title(rhs._last_mid_lat_title), - _last_mid_lat(rhs._last_mid_lat), - _last_mid_lat_units(rhs._last_mid_lat_units), - _last_mid_long_title(rhs._last_mid_long_title), - _last_mid_long(rhs._last_mid_long), - _last_mid_long_units(rhs._last_mid_long_units), - _last_far_lat_title(rhs._last_far_lat_title), - _last_far_lat(rhs._last_far_lat), - _last_far_lat_units(rhs._last_far_lat_units), - _last_far_long_title(rhs._last_far_long_title), - _last_far_long(rhs._last_far_long), - _last_far_long_units(rhs._last_far_long_units), - _swath_title(rhs._swath_title), - _swath(rhs._swath), - _pass_title(rhs._pass_title), - _pass(rhs._pass), - _sample_type_title(rhs._sample_type_title), - _sample_type(rhs._sample_type), - _algo_title(rhs._algo_title), - _algorithm(rhs._algorithm), - _mds1_tx_rx_polar_title(rhs._mds1_tx_rx_polar_title), - _mds1_tx_rx_polar(rhs._mds1_tx_rx_polar), - _mds2_tx_rx_polar_title(rhs._mds2_tx_rx_polar_title), - _mds2_tx_rx_polar(rhs._mds2_tx_rx_polar), - _compression_title(rhs._compression_title), - _compression(rhs._compression), - _azimut_looks_title(rhs._azimut_looks_title), - _azimut_looks(rhs._azimut_looks), - _range_looks_title(rhs._range_looks_title), - _range_looks(rhs._range_looks), - _range_spacing_title(rhs._range_spacing_title), - _range_spacing(rhs._range_spacing), - _range_spacing_unit(rhs._range_spacing_unit), - _azimut_spacing_title(rhs._azimut_spacing_title), - _azimut_spacing(rhs._azimut_spacing), - _azimut_spacing_unit(rhs._azimut_spacing_unit), - _line_time_interval_title(rhs._line_time_interval_title), - _line_time_interval(rhs._line_time_interval), - _line_time_interv_units(rhs._line_time_interv_units), - _line_length_title(rhs._line_length_title), - _line_length(rhs._line_length), - _line_length_units(rhs._line_length_units), - _data_type_title(rhs._data_type_title), - _data_type(rhs._data_type) - {} - - -sph& sph::operator=(const sph& rhs) -{ - _sph_desc_title = rhs._sph_desc_title; - _sph_desc = rhs._sph_desc; - _strip_cont_ind_title = rhs._strip_cont_ind_title; - _strip_cont_ind = rhs._strip_cont_ind; - _slice_pos_title = rhs._slice_pos_title; - _slice_position = rhs._slice_position; - _num_slices_title = rhs._num_slices_title; - _num_slices = rhs._num_slices; - _first_line_time_title = rhs._first_line_time_title; - _first_line_time = rhs._first_line_time; - _last_line_time_title = rhs._last_line_time_title; - _last_line_time = rhs._last_line_time; - _first_near_lat_title = rhs._first_near_lat_title; - _first_near_lat = rhs._first_near_lat; - _first_near_lat_units = rhs._first_near_lat_units; - _first_near_long_title = rhs._first_near_long_title; - _first_near_long = rhs._first_near_long; - _first_near_long_units = rhs._first_near_long_units; - _first_mid_lat_title = rhs._first_mid_lat_title; - _first_mid_lat = rhs._first_mid_lat; - _first_mid_lat_units = rhs._first_mid_lat_units; - _first_mid_long_title = rhs._first_mid_long_title; - _first_mid_long = rhs._first_mid_long; - _first_mid_long_units = rhs._first_mid_long_units; - _first_far_lat_title = rhs._first_far_lat_title; - _first_far_lat = rhs._first_far_lat; - _first_far_lat_units = rhs._first_far_lat_units; - _first_far_long_title = rhs._first_far_long_title; - _first_far_long = rhs._first_far_long; - _first_far_long_units = rhs._first_far_long_units; - _last_near_lat_title = rhs._last_near_lat_title; - _last_near_lat = rhs._last_near_lat; - _last_near_lat_units = rhs._last_near_lat_units; - _last_near_long_title = rhs._last_near_long_title; - _last_near_long = rhs._last_near_long; - _last_near_long_units = rhs._last_near_long_units; - _last_mid_lat_title = rhs._last_mid_lat_title; - _last_mid_lat = rhs._last_mid_lat; - _last_mid_lat_units = rhs._last_mid_lat_units; - _last_mid_long_title = rhs._last_mid_long_title; - _last_mid_long = rhs._last_mid_long; - _last_mid_long_units = rhs._last_mid_long_units; - _last_far_lat_title = rhs._last_far_lat_title; - _last_far_lat = rhs._last_far_lat; - _last_far_lat_units = rhs._last_far_lat_units; - _last_far_long_title = rhs._last_far_long_title; - _last_far_long = rhs._last_far_long; - _last_far_long_units = rhs._last_far_long_units; - _swath_title = rhs._swath_title; - _swath = rhs._swath; - _pass_title = rhs._pass_title; - _pass = rhs._pass; - _sample_type_title = rhs._sample_type_title; - _sample_type = rhs._sample_type; - _algo_title = rhs._algo_title; - _algorithm = rhs._algorithm; - _mds1_tx_rx_polar_title = rhs._mds1_tx_rx_polar_title; - _mds1_tx_rx_polar = rhs._mds1_tx_rx_polar; - _mds2_tx_rx_polar_title = rhs._mds2_tx_rx_polar_title; - _mds2_tx_rx_polar = rhs._mds2_tx_rx_polar; - _compression_title = rhs._compression_title; - _compression = rhs._compression; - _azimut_looks_title = rhs._azimut_looks_title; - _azimut_looks = rhs._azimut_looks; - _range_looks_title = rhs._range_looks_title; - _range_looks = rhs._range_looks; - _range_spacing_title = rhs._range_spacing_title; - _range_spacing = rhs._range_spacing; - _range_spacing_unit = rhs._range_spacing_unit; - _azimut_spacing_title = rhs._azimut_spacing_title; - _azimut_spacing = rhs._azimut_spacing; - _azimut_spacing_unit = rhs._azimut_spacing_unit; - _line_time_interval_title = rhs._line_time_interval_title; - _line_time_interval = rhs._line_time_interval; - _line_time_interv_units = rhs._line_time_interv_units; - _line_length_title = rhs._line_length_title; - _line_length = rhs._line_length; - _line_length_units = rhs._line_length_units; - _data_type_title = rhs._data_type_title; - _data_type = rhs._data_type; - - return *this; -} \ No newline at end of file diff --git a/Utilities/otbossim/src/ossim/imaging/RadarSat/Data/Data.cpp b/Utilities/otbossim/src/ossim/imaging/RadarSat/Data/Data.cpp deleted file mode 100644 index dd529d7d6148b8603a1009344d38cca46729f1c7..0000000000000000000000000000000000000000 --- a/Utilities/otbossim/src/ossim/imaging/RadarSat/Data/Data.cpp +++ /dev/null @@ -1,205 +0,0 @@ -#include <ossim/imaging/RadarSat/Data/Data.h> -#include <ossim/imaging/RadarSat/Data/DataFactory.h> -#include <ossim/imaging/RadarSat/RadarSatRecordHeader.h> -#include <ossim/imaging/RadarSat/Data/ImageOptionsFileDescriptor.h> - -const int Data::ImageOptionsFileDescriptorID = 1; -const int Data::FirstProcessedDataRecordID = 2; -const int Data::LastProcessedDataRecordID = 3; - -Data::Data() -{ -} - -Data::~Data() -{ - ClearRecords(); -} - -std::ostream& operator<<(std::ostream& os, const Data& data) -{ - std::map<int, RadarSatRecord*>::const_iterator it = data._records.begin(); - while(it != data._records.end()) - { - (*it).second->Write(os); - ++it; - } - return os; - -} - -std::istream& operator>>(std::istream& is, Data& data) -{ - DataFactory factory; - - data.ClearRecords(); - - if (sizeof(int)!=4) std::cout << "RadarSat Data WARNING : (int) not coded over 32 bits, metadata might not be byte swapped correctly"<< std::endl ; - if (sizeof(float)!=4) std::cout << "RadarSat Data WARNING : (float) not coded over 32 bits, metadata might not be byte swapped correctly"<< std::endl ; - if (sizeof(double)!=8) std::cout << "RadarSat Data WARNING : (double) not coded over 64 bits, metadata might not be byte swapped correctly"<< std::endl ; - - RadarSatRecordHeader header; - bool eof = false; - - int nbLin = 0 ; // number of image lines - int lineLength = 0 ; // size of any ProcessedDataRecord - - while(!eof) - { - is>>header; - if(is.eof()) - { - eof = true; - } - else - { - if (header.get_rec_seq() == 1) { // ImageOptionsFileDescriptor - RadarSatRecord* record = factory.Instanciate(header.get_rec_seq()); - if (record != NULL) - { - record->Read(is); - data._records[Data::ImageOptionsFileDescriptorID] = record; - - nbLin = ((ImageOptionsFileDescriptor *) record)->get_nlin() ; - } - else - { - char* buff = new char[header.get_length()-12]; - is.read(buff, header.get_length()-12); - delete buff; - } - } - else if ((header.get_rec_seq() == 2)) { // First line ProcessedDataRecord - RadarSatRecord* record = factory.Instanciate(2); - lineLength = header.get_length() ; - if (record != NULL) - { - record->Read(is); - data._records[Data::FirstProcessedDataRecordID] = record; - - char* buff = new char[header.get_length()-192]; - is.read(buff, header.get_length()-192); // Reads the rest of the line - } - else - { - char* buff = new char[header.get_length()-12]; - is.read(buff, header.get_length()-12); - delete buff; - } - } - else if ((header.get_rec_seq() == (1+nbLin))) { // Last line ProcessedDataRecord - RadarSatRecord* record = factory.Instanciate(2); - if (record != NULL) - { - record->Read(is); - data._records[Data::LastProcessedDataRecordID] = record; - char* buff = new char[header.get_length()-192]; - is.read(buff, header.get_length()-192); // Reads the rest of the line - } - else - { - char* buff = new char[header.get_length()-12]; - is.read(buff, header.get_length()-12); - delete buff; - } - } - else - { - // all lines between the first and last ones are skipped - if (lineLength != 0) - is.seekg((nbLin-2)*lineLength-12, std::ios::cur) ; - else - is.seekg(0, std::ios::end) ; - } - - } -/* - //while(!eof) - { - is>>header; - if(is.eof()) - { - eof = true; - } - else - { - RadarSatRecord* record = factory.Instanciate(header.get_rec_seq()); - if (record != NULL) - { - record->Read(is); - data._records[header.get_rec_seq()] = record; - } - else - { - char* buff = new char[header.get_length()]; - is.read(buff, header.get_length()); - delete buff; - } - } -*/ - - } - return is; -} - - -Data::Data(const Data& rhs) -{ - std::map<int, RadarSatRecord*>::const_iterator it = rhs._records.begin(); - while(it != rhs._records.end()) - { - _records[(*it).first] = (*it).second->Clone(); - ++it; - } -} - -Data& Data::operator=(const Data& rhs) -{ - std::map<int, RadarSatRecord*>::const_iterator it = _records.begin(); - while(it != _records.end()) - { - delete (*it).second; - ++it; - } - _records.clear(); - - it = rhs._records.begin(); - while(it != rhs._records.end()) - { - _records[(*it).first] = (*it).second->Clone(); - ++it; - } - - return *this; -} - -void Data::ClearRecords() -{ - std::map<int, RadarSatRecord*>::const_iterator it = _records.begin(); - while(it != _records.end()) - { - delete (*it).second; - ++it; - } - _records.clear(); -} - -void Data::InsertRecord(int id, RadarSatRecord* record) -{ - _records[id] = record; -} - -ImageOptionsFileDescriptor* Data::get_ImageOptionsFileDescriptor() -{ - return (ImageOptionsFileDescriptor*)_records[ImageOptionsFileDescriptorID]; -} - -ProcessedDataRecord* Data::get_FirstProcessedDataRecord() -{ - return (ProcessedDataRecord*)_records[FirstProcessedDataRecordID]; -} - -ProcessedDataRecord* Data::get_LastProcessedDataRecord() -{ - return (ProcessedDataRecord*)_records[LastProcessedDataRecordID]; -} \ No newline at end of file diff --git a/Utilities/otbossim/src/ossim/imaging/RadarSat/Data/DataFactory.cpp b/Utilities/otbossim/src/ossim/imaging/RadarSat/Data/DataFactory.cpp deleted file mode 100644 index bc47163d8b7d940ecdfb2c0942b4aebc34ed9835..0000000000000000000000000000000000000000 --- a/Utilities/otbossim/src/ossim/imaging/RadarSat/Data/DataFactory.cpp +++ /dev/null @@ -1,16 +0,0 @@ -#include <ossim/imaging/RadarSat/Data/DataFactory.h> - -#include <ossim/imaging/RadarSat/Data/ImageOptionsFileDescriptor.h> -#include <ossim/imaging/RadarSat/Data/ProcessedDataRecord.h> - - -DataFactory::DataFactory() -{ - RegisterRecord(1, new ImageOptionsFileDescriptor()); - RegisterRecord(2, new ProcessedDataRecord()); -} - -DataFactory::~DataFactory() -{ - -} \ No newline at end of file diff --git a/Utilities/otbossim/src/ossim/imaging/RadarSat/Data/ImageOptionsFileDescriptor.cpp b/Utilities/otbossim/src/ossim/imaging/RadarSat/Data/ImageOptionsFileDescriptor.cpp deleted file mode 100644 index 596ade62531029891de1899229d7926a736104c9..0000000000000000000000000000000000000000 --- a/Utilities/otbossim/src/ossim/imaging/RadarSat/Data/ImageOptionsFileDescriptor.cpp +++ /dev/null @@ -1,353 +0,0 @@ -#include <ossim/imaging/RadarSat/Data/ImageOptionsFileDescriptor.h> - - -ImageOptionsFileDescriptor::ImageOptionsFileDescriptor() : RadarSatRecord("imop_desc_rec") -{ -} - -ImageOptionsFileDescriptor::~ImageOptionsFileDescriptor() -{ -} - -std::ostream& operator<<(std::ostream& os, const ImageOptionsFileDescriptor& data) -{ - os<<"ascii_flag:"<<data._ascii_flag.c_str()<<std::endl; - - os<<"format_doc:"<<data._format_doc.c_str()<<std::endl; - - os<<"format_rev:"<<data._format_rev.c_str()<<std::endl; - - os<<"design_rev:"<<data._design_rev.c_str()<<std::endl; - - os<<"software_id:"<<data._software_id.c_str()<<std::endl; - - os<<"file_num:"<<data._file_num<<std::endl; - - os<<"file_name:"<<data._file_name.c_str()<<std::endl; - - os<<"rec_seq:"<<data._rec_seq.c_str()<<std::endl; - - os<<"seq_loc:"<<data._seq_loc<<std::endl; - - os<<"seq_len:"<<data._seq_len<<std::endl; - - os<<"rec_code:"<<data._rec_code.c_str()<<std::endl; - - os<<"code_loc:"<<data._code_loc<<std::endl; - - os<<"code_len:"<<data._code_len<<std::endl; - - os<<"rec_len:"<<data._rec_len.c_str()<<std::endl; - - os<<"rlen_loc:"<<data._rlen_loc<<std::endl; - - os<<"rlen_len:"<<data._rlen_len<<std::endl; - - os<<"n_dataset:"<<data._n_dataset<<std::endl; - - os<<"l_dataset:"<<data._l_dataset<<std::endl; - - os<<"nbit:"<<data._nbit<<std::endl; - - os<<"nsamp:"<<data._nsamp<<std::endl; - - os<<"nbyte:"<<data._nbyte<<std::endl; - - os<<"justify:"<<data._justify.c_str()<<std::endl; - - os<<"nchn:"<<data._nchn<<std::endl; - - os<<"nlin:"<<data._nlin<<std::endl; - - os<<"nleft:"<<data._nleft<<std::endl; - - os<<"ngrp:"<<data._ngrp<<std::endl; - - os<<"nright:"<<data._nright<<std::endl; - - os<<"ntop:"<<data._ntop<<std::endl; - - os<<"nbott:"<<data._nbott<<std::endl; - - os<<"intleav:"<<data._intleav.c_str()<<std::endl; - - os<<"nrec_lin:"<<data._nrec_lin<<std::endl; - - os<<"nrec_chn:"<<data._nrec_chn<<std::endl; - - os<<"n_prefix:"<<data._n_prefix<<std::endl; - - os<<"n_sar:"<<data._n_sar<<std::endl; - - os<<"n_suffix:"<<data._n_suffix<<std::endl; - - os<<"lin_loc:"<<data._lin_loc.c_str()<<std::endl; - - os<<"chn_loc:"<<data._chn_loc.c_str()<<std::endl; - - os<<"tim_loc:"<<data._tim_loc.c_str()<<std::endl; - - os<<"left_loc:"<<data._left_loc.c_str()<<std::endl; - - os<<"right_loc:"<<data._right_loc.c_str()<<std::endl; - - os<<"pad_ind:"<<data._pad_ind.c_str()<<std::endl; - - os<<"qual_loc:"<<data._qual_loc.c_str()<<std::endl; - - os<<"cali_loc:"<<data._cali_loc.c_str()<<std::endl; - - os<<"gain_loc:"<<data._gain_loc.c_str()<<std::endl; - - os<<"bias_loc:"<<data._bias_loc.c_str()<<std::endl; - - os<<"type_id:"<<data._type_id.c_str()<<std::endl; - - os<<"type_code:"<<data._type_code.c_str()<<std::endl; - - os<<"left_fill:"<<data._left_fill<<std::endl; - - os<<"right_fill:"<<data._right_fill<<std::endl; - - os<<"pix_rng:"<<data._pix_rng<<std::endl; - - return os; -} - -std::istream& operator>>(std::istream& is, ImageOptionsFileDescriptor& data) -{ - char buf[15805]; - buf[15804] = '\0'; - - is.read(buf,2); - buf[2] = '\0'; - data._ascii_flag = buf; - - is.read(buf,2); - - is.read(buf,12); - buf[12] = '\0'; - data._format_doc = buf; - - is.read(buf,2); - buf[2] = '\0'; - data._format_rev = buf; - - is.read(buf,2); - buf[2] = '\0'; - data._design_rev = buf; - - is.read(buf,12); - buf[12] = '\0'; - data._software_id = buf; - - is.read(buf,4); - buf[4] = '\0'; - data._file_num = atoi(buf); - - is.read(buf,16); - buf[16] = '\0'; - data._file_name = buf; - - is.read(buf,4); - buf[4] = '\0'; - data._rec_seq = buf; - - is.read(buf,8); - buf[8] = '\0'; - data._seq_loc = atoi(buf); - - is.read(buf,4); - buf[4] = '\0'; - data._seq_len = atoi(buf); - - is.read(buf,4); - buf[4] = '\0'; - data._rec_code = buf; - - is.read(buf,8); - buf[8] = '\0'; - data._code_loc = atoi(buf); - - is.read(buf,4); - buf[4] = '\0'; - data._code_len = atoi(buf); - - is.read(buf,4); - buf[4] = '\0'; - data._rec_len = buf; - - is.read(buf,8); - buf[8] = '\0'; - data._rlen_loc = atoi(buf); - - is.read(buf,4); - buf[4] = '\0'; - data._rlen_len = atoi(buf); - - for (int i=0;i<4;i++) - { - is.read(buf,1); - } - - is.read(buf,64); - - is.read(buf,6); - buf[6] = '\0'; - data._n_dataset = atoi(buf); - - is.read(buf,6); - buf[6] = '\0'; - data._l_dataset = atoi(buf); - - is.read(buf,24); - - is.read(buf,4); - buf[4] = '\0'; - data._nbit = atoi(buf); - - is.read(buf,4); - buf[4] = '\0'; - data._nsamp = atoi(buf); - - is.read(buf,4); - buf[4] = '\0'; - data._nbyte = atoi(buf); - - is.read(buf,4); - buf[4] = '\0'; - data._justify = buf; - - is.read(buf,4); - buf[4] = '\0'; - data._nchn = atoi(buf); - - is.read(buf,8); - buf[8] = '\0'; - data._nlin = atoi(buf); - - is.read(buf,4); - buf[4] = '\0'; - data._nleft = atoi(buf); - - is.read(buf,8); - buf[8] = '\0'; - data._ngrp = atoi(buf); - - is.read(buf,4); - buf[4] = '\0'; - data._nright = atoi(buf); - - is.read(buf,4); - buf[4] = '\0'; - data._ntop = atoi(buf); - - is.read(buf,4); - buf[4] = '\0'; - data._nbott = atoi(buf); - - is.read(buf,4); - buf[4] = '\0'; - data._intleav = buf; - - is.read(buf,2); - buf[2] = '\0'; - data._nrec_lin = atoi(buf); - - is.read(buf,2); - buf[2] = '\0'; - data._nrec_chn = atoi(buf); - - is.read(buf,4); - buf[4] = '\0'; - data._n_prefix = atoi(buf); - - is.read(buf,8); - buf[8] = '\0'; - data._n_sar = atoi(buf); - - is.read(buf,4); - buf[4] = '\0'; - data._n_suffix = atoi(buf); - - is.read(buf,4); - - is.read(buf,8); - buf[8] = '\0'; - data._lin_loc = buf; - - is.read(buf,8); - buf[8] = '\0'; - data._chn_loc = buf; - - is.read(buf,8); - buf[8] = '\0'; - data._tim_loc = buf; - - is.read(buf,8); - buf[8] = '\0'; - data._left_loc = buf; - - is.read(buf,8); - buf[8] = '\0'; - data._right_loc = buf; - - is.read(buf,4); - buf[4] = '\0'; - data._pad_ind = buf; - - is.read(buf,28); - - is.read(buf,8); - buf[8] = '\0'; - data._qual_loc = buf; - - is.read(buf,8); - buf[8] = '\0'; - data._cali_loc = buf; - - is.read(buf,8); - buf[8] = '\0'; - data._gain_loc = buf; - - is.read(buf,8); - buf[8] = '\0'; - data._bias_loc = buf; - - is.read(buf,28); - buf[28] = '\0'; - data._type_id = buf; - - is.read(buf,4); - buf[4] = '\0'; - data._type_code = buf; - - is.read(buf,4); - buf[4] = '\0'; - data._left_fill = atoi(buf); - - is.read(buf,4); - buf[4] = '\0'; - data._right_fill = atoi(buf); - - is.read(buf,8); - buf[8] = '\0'; - data._pix_rng = atoi(buf); - - is.read(buf,15804); - - return is; -} - -ImageOptionsFileDescriptor::ImageOptionsFileDescriptor(const ImageOptionsFileDescriptor& rhs): - RadarSatRecord(rhs) -{ - - -} - -ImageOptionsFileDescriptor& ImageOptionsFileDescriptor::operator=(const ImageOptionsFileDescriptor& rhs) -{ - - return *this; -} \ No newline at end of file diff --git a/Utilities/otbossim/src/ossim/imaging/RadarSat/Data/ProcessedDataRecord.cpp b/Utilities/otbossim/src/ossim/imaging/RadarSat/Data/ProcessedDataRecord.cpp deleted file mode 100644 index abc85a70ae22b99439935ced5f5bb8aaf83dd1d7..0000000000000000000000000000000000000000 --- a/Utilities/otbossim/src/ossim/imaging/RadarSat/Data/ProcessedDataRecord.cpp +++ /dev/null @@ -1,209 +0,0 @@ -#include <ossim/imaging/RadarSat/Data/ProcessedDataRecord.h> - - -ProcessedDataRecord::ProcessedDataRecord() : RadarSatRecord("proc_data_rec") -{ -} - -ProcessedDataRecord::~ProcessedDataRecord() -{ -} - -std::ostream& operator<<(std::ostream& os, const ProcessedDataRecord& data) -{ - os<<"line_num:"<<data._line_num<<std::endl; - os<<"rec_num:"<<data._rec_num<<std::endl; - os<<"n_left_pixel:"<<data._n_left_pixel<<std::endl; - os<<"n_data_pixel:"<<data._n_data_pixel<<std::endl; - os<<"n_right_pixel:"<<data._n_right_pixel<<std::endl; - os<<"sensor_updf:"<<data._sensor_updf<<std::endl; - os<<"acq_year:"<<data._acq_year<<std::endl; - os<<"acq_day:"<<data._acq_day<<std::endl; - os<<"acq_msec:"<<data._acq_msec<<std::endl; - os<<"sar_chan_ind:"<<data._sar_chan_ind<<std::endl; - os<<"sar_chan_code:"<<data._sar_chan_code<<std::endl; - os<<"tran_polar:"<<data._tran_polar<<std::endl; - os<<"recv_polar:"<<data._recv_polar<<std::endl; - os<<"prf:"<<data._prf<<std::endl; - os<<"sr_first:"<<data._sr_first<<std::endl; - os<<"sr_last:"<<data._sr_last<<std::endl; - os<<"fdc_first:"<<data._fdc_first<<std::endl; - os<<"fdc_mid:"<<data._fdc_mid<<std::endl; - os<<"fdc_last:"<<data._fdc_last<<std::endl; - os<<"ka_first:"<<data._ka_first<<std::endl; - os<<"ka_mid:"<<data._ka_mid<<std::endl; - os<<"ka_last:"<<data._ka_last<<std::endl; - os<<"nadir_ang:"<<data._nadir_ang<<std::endl; - os<<"squint_ang:"<<data._squint_ang<<std::endl; - os<<"geo_updf:"<<data._geo_updf<<std::endl; - os<<"lat_first:"<<data._lat_first<<std::endl; - os<<"lat_mid:"<<data._lat_mid<<std::endl; - os<<"lat_last:"<<data._lat_last<<std::endl; - os<<"lon_first:"<<data._lon_first<<std::endl; - os<<"lon_mid:"<<data._lon_mid<<std::endl; - os<<"lon_last:"<<data._lon_last<<std::endl; - os<<"north_first:"<<data._north_first<<std::endl; - os<<"north_last:"<<data._north_last<<std::endl; - os<<"east_first:"<<data._east_first<<std::endl; - os<<"east_last:"<<data._east_last<<std::endl; - os<<"heading:"<<data._heading<<std::endl; - - return os; -} - -void SwitchEndian(int& value) -{ - char buffer[4]; - char res[4]; - - memcpy(buffer,&value,4); - res[0] = buffer[3]; - res[1] = buffer[2]; - res[2] = buffer[1]; - res[3] = buffer[0]; - - memcpy(&value,res,4); -} - -std::istream& operator>>(std::istream& is, ProcessedDataRecord& data) -{ - char buf[193]; - buf[192] = '\0'; - - is.read((char*)&(data._line_num),4); - data.SwitchEndian(data._line_num); - - is.read((char*)&(data._rec_num),4); - data.SwitchEndian(data._rec_num); - - is.read((char*)&(data._n_left_pixel),4); - data.SwitchEndian(data._n_left_pixel); - - is.read((char*)&(data._n_data_pixel),4); - data.SwitchEndian(data._n_data_pixel); - - is.read((char*)&(data._n_right_pixel),4); - data.SwitchEndian(data._n_right_pixel); - - is.read((char*)&(data._sensor_updf),4); - data.SwitchEndian(data._sensor_updf); - - is.read((char*)&(data._acq_year),4); - data.SwitchEndian(data._acq_year); - - is.read((char*)&(data._acq_day),4); - data.SwitchEndian(data._acq_day); - - is.read((char*)&(data._acq_msec),4); - data.SwitchEndian(data._acq_msec); - - is.read((char*)&(data._sar_chan_ind),2); - data.SwitchEndian(data._sar_chan_ind); - - is.read((char*)&(data._sar_chan_code),2); - data.SwitchEndian(data._sar_chan_code); - - is.read((char*)&(data._tran_polar),2); - data.SwitchEndian(data._tran_polar ); - - is.read((char*)&(data._recv_polar),2); - data.SwitchEndian(data._recv_polar); - - is.read((char*)&(data._prf),4); - data.SwitchEndian(data._prf ); - - is.read(buf,4); - - is.read((char*)&(data._sr_first),4); - data.SwitchEndian(data._sr_first); - - is.read((char*)&(data._sr_mid),4); - data.SwitchEndian(data._sr_mid); - - is.read((char*)&(data._sr_last),4); - data.SwitchEndian(data._sr_last); - - is.read((char*)&(data._fdc_first),4); - data.SwitchEndian(data._fdc_first); - - is.read((char*)&(data._fdc_mid),4); - data.SwitchEndian(data._fdc_mid); - - is.read((char*)&(data._fdc_last),4); - data.SwitchEndian(data._fdc_last); - - is.read((char*)&(data._ka_first),4); - data.SwitchEndian(data._ka_first); - - is.read((char*)&(data._ka_mid),4); - data.SwitchEndian(data._ka_mid); - - is.read((char*)&(data._ka_last),4); - data.SwitchEndian(data._ka_last); - - is.read((char*)&(data._nadir_ang),4); - data.SwitchEndian(data._nadir_ang); - - is.read((char*)&(data._squint_ang),4); - data.SwitchEndian(data._squint_ang); - - is.read(buf,4); - is.read(buf,16); - - is.read((char*)&(data._geo_updf),4); - data.SwitchEndian(data._geo_updf); - - is.read((char*)&(data._lat_first),4); - data.SwitchEndian(data._lat_first); - - is.read((char*)&(data._lat_mid),4); - data.SwitchEndian(data._lat_mid); - - is.read((char*)&(data._lat_last),4); - data.SwitchEndian(data._lat_last); - - is.read((char*)&(data._lon_first),4); - data.SwitchEndian(data._lon_first); - - is.read((char*)&(data._lon_mid),4); - data.SwitchEndian(data._lon_mid); - - is.read((char*)&(data._lon_last),4); - data.SwitchEndian(data._lon_last); - - is.read((char*)&(data._north_first),4); - data.SwitchEndian(data._north_first); - - is.read(buf,4); - - is.read((char*)&(data._north_last),4); - data.SwitchEndian(data._north_last); - - is.read((char*)&(data._east_first),4); - data.SwitchEndian(data._east_first); - - is.read(buf,4); - - is.read((char*)&(data._east_last),4); - data.SwitchEndian(data._east_last); - - is.read((char*)&(data._heading),4); - data.SwitchEndian(data._heading); - - is.read(buf,8); - - return is; -} - -ProcessedDataRecord::ProcessedDataRecord(const ProcessedDataRecord& rhs): - RadarSatRecord(rhs) -{ - - -} - -ProcessedDataRecord& ProcessedDataRecord::operator=(const ProcessedDataRecord& rhs) -{ - - return *this; -} \ No newline at end of file diff --git a/Utilities/otbossim/src/ossim/imaging/RadarSat/Leader/AttitudeData.cpp b/Utilities/otbossim/src/ossim/imaging/RadarSat/Leader/AttitudeData.cpp deleted file mode 100644 index 664e1cd1a41ec0866917149e9b079ec31c17d6b6..0000000000000000000000000000000000000000 --- a/Utilities/otbossim/src/ossim/imaging/RadarSat/Leader/AttitudeData.cpp +++ /dev/null @@ -1,79 +0,0 @@ - -#include <ossim/imaging/RadarSat/Leader/AttitudeData.h> - -AttitudeData::AttitudeData() : RadarSatRecord("att_data_rec") -{ -} - -AttitudeData::~AttitudeData() -{ -} - -std::ostream& operator<<(std::ostream& os, const AttitudeData& data) -{ - os<<"npoint:"<<data._npoint<<std::endl; - for (int i=0;i<20;i++) - { - os<<"att_vect["<<i<<"]:"<<data._att_vect[i]<<std::endl; - } - os<<"pitch_bias:"<<data._pitch_bias<<std::endl; - os<<"roll_bias:"<<data._roll_bias<<std::endl; - os<<"yaw_bias:"<<data._yaw_bias<<std::endl; - return os; -} - -std::istream& operator>>(std::istream& is, AttitudeData& data) -{ - char buf[6503]; - buf[6502] = '\0'; - - is.read(buf,4); - buf[4] = '\0'; - data._npoint = atoi(buf); - - for (int i=0;i<20;i++) - { - is>>data._att_vect[i]; - } - is.read(buf,14); - buf[14] = '\0'; - data._pitch_bias = atof(buf); - - is.read(buf,14); - buf[14] = '\0'; - data._roll_bias = atof(buf); - - is.read(buf,14); - buf[14] = '\0'; - data._yaw_bias = atof(buf); - - is.read(buf,6502); - - return is; -} - -AttitudeData::AttitudeData(const AttitudeData& rhs): - RadarSatRecord(rhs) -{ - _npoint = rhs._npoint; - for (int i=0;i<20;i++) - { - _att_vect[i] = rhs._att_vect[i]; - } - _pitch_bias = rhs._pitch_bias; - _roll_bias = rhs._roll_bias; - _yaw_bias = rhs._yaw_bias; -} - -AttitudeData& AttitudeData::operator=(const AttitudeData& rhs) -{ - _npoint = rhs._npoint; - for (int i=0;i<20;i++) - { - _att_vect[i] = rhs._att_vect[i]; - } - _pitch_bias = rhs._pitch_bias; - _roll_bias = rhs._roll_bias; - _yaw_bias = rhs._yaw_bias; - return *this; -} \ No newline at end of file diff --git a/Utilities/otbossim/src/ossim/imaging/RadarSat/Leader/BeamInformationRecord.cpp b/Utilities/otbossim/src/ossim/imaging/RadarSat/Leader/BeamInformationRecord.cpp deleted file mode 100644 index 8be9a8c8916e76d0b8955c731a8e6e1b3bce375d..0000000000000000000000000000000000000000 --- a/Utilities/otbossim/src/ossim/imaging/RadarSat/Leader/BeamInformationRecord.cpp +++ /dev/null @@ -1,64 +0,0 @@ -#include <ossim/imaging/RadarSat/Leader/BeamInformationRecord.h> - -BeamInformationRecord::BeamInformationRecord() -{ -} - -BeamInformationRecord::~BeamInformationRecord() -{ -} - -std::ostream& operator<<(std::ostream& os, const BeamInformationRecord& data) -{ - os<<"beam_type:"<<data._beam_type.c_str()<<std::endl; - - os<<"beam_look_src:"<<data._beam_look_src.c_str()<<std::endl; - - os<<"beam_look_ang:"<<data._beam_look_ang<<std::endl; - - os<<"prf:"<<data._prf<<std::endl; - - return os; -} - -std::istream& operator>>(std::istream& is, BeamInformationRecord& data) -{ - char buf[17]; - buf[16] = '\0'; - - is.read(buf,3); - buf[3] = '\0'; - data._beam_type = buf; - - is.read(buf,9); - buf[9] = '\0'; - data._beam_look_src = buf; - - is.read(buf,16); - buf[16] = '\0'; - data._beam_look_ang = atof(buf); - - is.read(buf,16); - buf[16] = '\0'; - data._prf = atof(buf); - - return is; -} - -BeamInformationRecord::BeamInformationRecord(const BeamInformationRecord& rhs): - _beam_type(rhs._beam_type), - _beam_look_src(rhs._beam_look_src), - _beam_look_ang(rhs._beam_look_ang), - _prf(rhs._prf) -{ - -} - -BeamInformationRecord& BeamInformationRecord::operator=(const BeamInformationRecord& rhs) -{ - _beam_type = rhs._beam_type; - _beam_look_src = rhs._beam_look_src; - _beam_look_ang = rhs._beam_look_ang; - _prf = rhs._prf; - return *this; -} \ No newline at end of file diff --git a/Utilities/otbossim/src/ossim/imaging/RadarSat/Leader/BeamPixelCountRecord.cpp b/Utilities/otbossim/src/ossim/imaging/RadarSat/Leader/BeamPixelCountRecord.cpp deleted file mode 100644 index 9751a38f6069a1686d2eeabd7342f9f2ab6c8153..0000000000000000000000000000000000000000 --- a/Utilities/otbossim/src/ossim/imaging/RadarSat/Leader/BeamPixelCountRecord.cpp +++ /dev/null @@ -1,56 +0,0 @@ -#include <ossim/imaging/RadarSat/Leader/BeamPixelCountRecord.h> - -BeamPixelCountRecord::BeamPixelCountRecord() -{ -} - -BeamPixelCountRecord::~BeamPixelCountRecord() -{ -} - -std::ostream& operator<<(std::ostream& os, const BeamPixelCountRecord& data) -{ - os<<"pix_update:"<<data._pix_update.c_str()<<std::endl; - - for (int i=0;i<4;i++) - { - os<<"crt_m["<<i<<":"<<data._n_pix[i]<<std::endl; - } - return os; -} - -std::istream& operator>>(std::istream& is, BeamPixelCountRecord& data) -{ - char buf[23]; - buf[22] = '\0'; - - is.read(buf,21); - data._pix_update = buf; - - for (int i=0;i<4;i++) - { - is.read(buf,8); - buf[8] = '\0'; - data._n_pix[i] = atoi(buf); - } - return is; -} - -BeamPixelCountRecord::BeamPixelCountRecord(const BeamPixelCountRecord& rhs): - _pix_update(rhs._pix_update) -{ - for (int i=0;i<4;i++) - { - _n_pix[i] = rhs._n_pix[i]; - } -} - -BeamPixelCountRecord& BeamPixelCountRecord::operator=(const BeamPixelCountRecord& rhs) -{ - _pix_update = rhs._pix_update; - for (int i=0;i<4;i++) - { - _n_pix[i] = rhs._n_pix[i]; - } - return *this; -} \ No newline at end of file diff --git a/Utilities/otbossim/src/ossim/imaging/RadarSat/Leader/CompensationDataRecord.cpp b/Utilities/otbossim/src/ossim/imaging/RadarSat/Leader/CompensationDataRecord.cpp deleted file mode 100644 index ee0411406d887cbdc56ecde771a7dee496ae7ebd..0000000000000000000000000000000000000000 --- a/Utilities/otbossim/src/ossim/imaging/RadarSat/Leader/CompensationDataRecord.cpp +++ /dev/null @@ -1,133 +0,0 @@ -#include <ossim/imaging/RadarSat/Leader/CompensationDataRecord.h> - - -CompensationDataRecord::CompensationDataRecord() -{ -} - -CompensationDataRecord::~CompensationDataRecord() -{ -} - -std::ostream& operator<<(std::ostream& os, const CompensationDataRecord& data) -{ - os<<"comp_desig:"<<data._comp_desig.c_str()<<std::endl; - - os<<"comp_descr:"<<data._comp_descr.c_str()<<std::endl; - - os<<"n_comp_rec:"<<data._n_comp_rec<<std::endl; - - os<<"comp_seq_no:"<<data._comp_seq_no<<std::endl; - - os<<"beam_tab_size:"<<data._beam_tab_size<<std::endl; - - for (int i=0;i<256;i++) - { - os<<"beam_tab["<<i<<"]:"<<data._beam_tab[i]<<std::endl; - } - - os<<"beam_type:"<<data._beam_type.c_str()<<std::endl; - - os<<"look_angle:"<<data._look_angle<<std::endl; - - os<<"beam_tab_inc:"<<data._beam_tab_inc<<std::endl; - return os; -} - -std::istream& operator>>(std::istream& is, CompensationDataRecord& data) -{ - char buf[33]; - buf[32] = '\0'; - - - is.read(buf,8); - buf[8] = '\0'; - data._comp_desig = buf; - - is.read(buf,32); - buf[32] = '\0'; - data._comp_descr = buf; - - is.read(buf,4); - buf[4] = '\0'; - data._n_comp_rec = atoi(buf); - - is.read(buf,4); - buf[4] = '\0'; - data._comp_seq_no = atoi(buf); - - is.read(buf,8); - buf[8] = '\0'; - data._beam_tab_size = atoi(buf); - - for (int i=0;i<256;i++) - { - is.read(buf,16); - buf[16] = '\0'; - data._beam_tab[i] = atof(buf); - } - - is.read(buf,16); - buf[16] = '\0'; - data._beam_type = buf; - - is.read(buf,16); - buf[16] = '\0'; - data._look_angle = atof(buf); - - is.read(buf,16); - buf[16] = '\0'; - data._beam_tab_inc = atof(buf); - - return is; -} - -CompensationDataRecord::CompensationDataRecord(const CompensationDataRecord& rhs) -{ - _comp_desig = rhs._comp_desig; - - _comp_descr = rhs._comp_descr; - - _n_comp_rec = rhs._n_comp_rec; - - _comp_seq_no = rhs._comp_seq_no; - - _beam_tab_size = rhs._beam_tab_size; - - for (int i=0;i<256;i++) - { - _beam_tab[i] = rhs._beam_tab[i]; - } - - _beam_type = rhs._beam_type; - - _look_angle = rhs._look_angle; - - _beam_tab_inc = rhs._beam_tab_inc; -} - -CompensationDataRecord& CompensationDataRecord::operator=(const CompensationDataRecord& rhs) -{ - _comp_desig = rhs._comp_desig; - - _comp_descr = rhs._comp_descr; - - _n_comp_rec = rhs._n_comp_rec; - - _comp_seq_no = rhs._comp_seq_no; - - _beam_tab_size = rhs._beam_tab_size; - - for (int i=0;i<256;i++) - { - _beam_tab[i] = rhs._beam_tab[i]; - } - - _beam_type = rhs._beam_type; - - _look_angle = rhs._look_angle; - - _beam_tab_inc = rhs._beam_tab_inc; - - return *this; -} \ No newline at end of file diff --git a/Utilities/otbossim/src/ossim/imaging/RadarSat/Leader/DataHistogramProcessedData.cpp b/Utilities/otbossim/src/ossim/imaging/RadarSat/Leader/DataHistogramProcessedData.cpp deleted file mode 100644 index 295e1883543b7497d54cbd9054d4321036ebee22..0000000000000000000000000000000000000000 --- a/Utilities/otbossim/src/ossim/imaging/RadarSat/Leader/DataHistogramProcessedData.cpp +++ /dev/null @@ -1,81 +0,0 @@ -#include <ossim/imaging/RadarSat/Leader/DataHistogramProcessedData.h> - - -DataHistogramProcessedData::DataHistogramProcessedData() : RadarSatRecord("pdr16_hist_rec") -{ -} - -DataHistogramProcessedData::~DataHistogramProcessedData() -{ -} - -std::ostream& operator<<(std::ostream& os, const DataHistogramProcessedData& data) -{ - os<<"rec_seq:"<<data._rec_seq<<std::endl; - - os<<"sar_chn:"<<data._sar_chn<<std::endl; - - os<<"ntab:"<<data._ntab<<std::endl; - - os<<"ltab:"<<data._ltab<<std::endl; - - os<<data._histogram1<<std::endl; - - os<<data._histogram2<<std::endl; - - return os; -} - -std::istream& operator>>(std::istream& is, DataHistogramProcessedData& data) -{ - char buff[33]; - buff[32] = '\0'; - - is.read(buff,4); - buff[4] = '\0'; - data._rec_seq = atoi(buff); - - is.read(buff,4); - buff[4] = '\0'; - data._sar_chn = atoi(buff); - - is.read(buff,8); - buff[8] = '\0'; - data._ntab = atoi(buff); - - is.read(buff,8); - buff[8] = '\0'; - data._ltab = atoi(buff); - - is>>data._histogram1; - - is>>data._histogram2; - - char tmp[5]; - tmp[4] = '\0'; - is.read(tmp, 4); - return is; -} - -DataHistogramProcessedData::DataHistogramProcessedData(const DataHistogramProcessedData& rhs) : - RadarSatRecord(rhs), - _histogram1(rhs._histogram1), - _histogram2(rhs._histogram2), - _sar_chn(rhs._sar_chn), - _rec_seq(rhs._rec_seq), - _ntab(rhs._ntab), - _ltab(rhs._ltab) -{ - -} - -DataHistogramProcessedData& DataHistogramProcessedData::operator=(const DataHistogramProcessedData& rhs) -{ - _histogram1 = rhs._histogram1; - _histogram2 = rhs._histogram2; - _sar_chn = rhs._sar_chn; - _rec_seq = rhs._rec_seq; - _ntab = rhs._ntab; - _ltab = rhs._ltab; - return *this; -} \ No newline at end of file diff --git a/Utilities/otbossim/src/ossim/imaging/RadarSat/Leader/DataHistogramRecord.cpp b/Utilities/otbossim/src/ossim/imaging/RadarSat/Leader/DataHistogramRecord.cpp deleted file mode 100644 index f7cc4e69c77640016c121f5373bc606eb6d4ce72..0000000000000000000000000000000000000000 --- a/Utilities/otbossim/src/ossim/imaging/RadarSat/Leader/DataHistogramRecord.cpp +++ /dev/null @@ -1,222 +0,0 @@ -#include <ossim/imaging/RadarSat/Leader/DataHistogramRecord.h> - - -DataHistogramRecord::DataHistogramRecord(): - _hist(NULL) -{ -} - -DataHistogramRecord::~DataHistogramRecord() -{ - if (_hist != NULL) - delete[] _hist; -} - -DataHistogramRecord::DataHistogramRecord(const DataHistogramRecord& rhs): - _hist_desc(rhs._hist_desc), - _nrec(rhs._nrec), - _tab_seq(rhs._tab_seq), - _nbin(rhs._nbin), - _ns_lin(rhs._ns_lin), - _ns_pix(rhs._ns_pix), - _ngrp_lin(rhs._ngrp_lin), - _ngrp_pix(rhs._ngrp_pix), - _nsamp_lin(rhs._nsamp_lin), - _nsamp_pix(rhs._nsamp_pix), - _min_smp(rhs._min_smp), - _max_smp(rhs._max_smp), - _mean_smp(rhs._mean_smp), - _std_smp(rhs._std_smp), - _smp_inc(rhs._smp_inc), - _min_hist(rhs._min_hist), - _max_hist(rhs._max_hist), - _mean_hist(rhs._mean_hist), - _std_hist(rhs._std_hist), - _nhist(rhs._nhist) -{ - _hist = new int[rhs._nhist]; - for (int i=0;i<rhs._nhist;i++) - { - _hist[i] = rhs._hist[i]; - } -} - -DataHistogramRecord& DataHistogramRecord::operator=(const DataHistogramRecord& rhs) -{ - _hist_desc = rhs._hist_desc; - _nrec = rhs._nrec; - _tab_seq = rhs._tab_seq; - _nbin = rhs._nbin; - _ns_lin = rhs._ns_lin; - _ns_pix = rhs._ns_pix; - _ngrp_lin = rhs._ngrp_lin; - _ngrp_pix = rhs._ngrp_pix; - _nsamp_lin = rhs._nsamp_lin; - _nsamp_pix = rhs._nsamp_pix; - _min_smp = rhs._min_smp; - _max_smp = rhs._max_smp; - _mean_smp = rhs._mean_smp; - _std_smp = rhs._std_smp; - _smp_inc = rhs._smp_inc; - _min_hist = rhs._min_hist; - _max_hist = rhs._max_hist; - _mean_hist = rhs._mean_hist; - _std_hist = rhs._std_hist; - _nhist = rhs._nhist; - return *this; -} - -std::ostream& operator<<(std::ostream& os, const DataHistogramRecord& data) -{ - os<<"hist_desc:"<<data._hist_desc.c_str()<<std::endl; - - os<<"nrec:"<<data._nrec<<std::endl; - - os<<"tab_seq:"<<data._tab_seq<<std::endl; - - os<<"nbin:"<<data._nbin<<std::endl; - - os<<"ns_lin:"<<data._ns_lin<<std::endl; - - os<<"ns_pix:"<<data._ns_pix<<std::endl; - - os<<"ngrp_lin:"<<data._ngrp_lin<<std::endl; - - os<<"ngrp_pix:"<<data._ngrp_pix<<std::endl; - - os<<"nsamp_lin:"<<data._nsamp_lin<<std::endl; - - os<<"nsamp_pix:"<<data._nsamp_pix<<std::endl; - - os<<"min_smp:"<<data._min_smp<<std::endl; - - os<<"max_smp:"<<data._max_smp<<std::endl; - - os<<"mean_smp:"<<data._mean_smp<<std::endl; - - os<<"std_smp:"<<data._std_smp<<std::endl; - - os<<"smp_inc:"<<data._smp_inc<<std::endl; - - os<<"min_hist:"<<data._min_hist<<std::endl; - - os<<"max_histd:"<<data._max_hist<<std::endl; - - os<<"mean_hist:"<<data._mean_hist<<std::endl; - - os<<"std_hist:"<<data._std_hist<<std::endl; - - os<<"nhist:"<<data._nhist<<std::endl; - - for(int i=0;i<data._nhist;i++) - { - os<<"his["<<i<<"]:"<<data._hist[i]<<std::endl; - } - return os; -} - -std::istream& operator>>(std::istream& is, DataHistogramRecord& data) -{ - char buff[33]; - buff[32] = '\0'; - - is.read(buff,32); - data._hist_desc = buff; - - is.read(buff,4); - buff[4] = '\0'; - data._nrec = atoi(buff); - - is.read(buff,4); - buff[4] = '\0'; - data._tab_seq = atoi(buff); - - is.read(buff,8); - buff[8] = '\0'; - data._nbin = atoi(buff); - - is.read(buff,8); - buff[8] = '\0'; - data._ns_lin = atoi(buff); - - is.read(buff,8); - buff[8] = '\0'; - data._ns_pix = atoi(buff); - - is.read(buff,8); - buff[8] = '\0'; - data._ngrp_lin = atoi(buff); - - is.read(buff,8); - buff[8] = '\0'; - data._ngrp_pix = atoi(buff); - - is.read(buff,8); - buff[8] = '\0'; - data._nsamp_lin = atoi(buff); - - is.read(buff,8); - buff[8] = '\0'; - data._nsamp_pix = atoi(buff); - - is.read(buff,16); - buff[16] = '\0'; - data._min_smp = atof(buff); - - is.read(buff,16); - buff[16] = '\0'; - data._max_smp = atof(buff); - - is.read(buff,16); - buff[16] = '\0'; - data._mean_smp = atof(buff); - - is.read(buff,16); - buff[16] = '\0'; - data._std_smp = atof(buff); - - is.read(buff,16); - buff[16] = '\0'; - data._smp_inc = atof(buff); - - is.read(buff,16); - buff[16] = '\0'; - data._min_hist = atof(buff); - - is.read(buff,16); - buff[16] = '\0'; - data._max_hist = atof(buff); - - is.read(buff,16); - buff[16] = '\0'; - data._mean_hist = atof(buff); - - is.read(buff,16); - buff[16] = '\0'; - data._std_hist = atof(buff); - - is.read(buff,8); - buff[8] = '\0'; - data._nhist = atoi(buff); - - if(data._hist != NULL) - { - delete[] data._hist; - } - - //for (int i=0;i<data._nhist;i++) - int nhist ; - if (data._nhist == 256) - { nhist = 256 ; } // Signal Data - else {nhist = 1024 ; } // Processed Data - - data._hist = new int[nhist]; - for (int i=0;i<nhist;i++) - { - is.read(buff,8); - buff[8] = '\0'; - data._hist[i] = atoi(buff); - } - - return is; -} \ No newline at end of file diff --git a/Utilities/otbossim/src/ossim/imaging/RadarSat/Leader/DataHistogramSignalData.cpp b/Utilities/otbossim/src/ossim/imaging/RadarSat/Leader/DataHistogramSignalData.cpp deleted file mode 100644 index 939640524c8fc443164edca1fbb7250751b87622..0000000000000000000000000000000000000000 --- a/Utilities/otbossim/src/ossim/imaging/RadarSat/Leader/DataHistogramSignalData.cpp +++ /dev/null @@ -1,79 +0,0 @@ -#include <ossim/imaging/RadarSat/Leader/DataHistogramSignalData.h> - - -DataHistogramSignalData::DataHistogramSignalData() : RadarSatRecord("sdr_hist_rec") -{ -} - -DataHistogramSignalData::~DataHistogramSignalData() -{ -} - -std::ostream& operator<<(std::ostream& os, const DataHistogramSignalData& data) -{ - - os<<"rec_seq:"<<data._rec_seq<<std::endl; - - os<<"sar_chn:"<<data._sar_chn<<std::endl; - - os<<"ntab:"<<data._ntab<<std::endl; - - os<<"ltab:"<<data._ltab<<std::endl; - - os<<data._histogram<<std::endl; - - return os; -} - -std::istream& operator>>(std::istream& is, DataHistogramSignalData& data) -{ - char buff[33]; - buff[32] = '\0'; - - - is.read(buff,4); - buff[4] = '\0'; - data._rec_seq = atoi(buff); - - is.read(buff,4); - buff[4] = '\0'; - data._sar_chn = atoi(buff); - - is.read(buff,8); - buff[8] = '\0'; - data._ntab = atoi(buff); - - is.read(buff,8); - buff[8] = '\0'; - data._ltab = atoi(buff); - - is>>data._histogram; - - char tmp[14589]; - tmp[14588] = '\0'; - is.read(tmp, 14588); - - return is; -} - -DataHistogramSignalData::DataHistogramSignalData(const DataHistogramSignalData& rhs) : - RadarSatRecord(rhs), - _histogram(rhs._histogram), - _sar_chn(rhs._sar_chn), - _rec_seq(rhs._rec_seq), - _ntab(rhs._ntab), - _ltab(rhs._ltab) -{ - -} - -DataHistogramSignalData& DataHistogramSignalData::operator=(const DataHistogramSignalData& rhs) -{ - _histogram = rhs._histogram; - _sar_chn = rhs._sar_chn; - _rec_seq = rhs._rec_seq; - _ntab = rhs._ntab; - _ltab = rhs._ltab; - - return *this; -} \ No newline at end of file diff --git a/Utilities/otbossim/src/ossim/imaging/RadarSat/Leader/DataPointDataRecord.cpp b/Utilities/otbossim/src/ossim/imaging/RadarSat/Leader/DataPointDataRecord.cpp deleted file mode 100644 index 37fee14c642b5afd2364da52db490f724efafeda..0000000000000000000000000000000000000000 --- a/Utilities/otbossim/src/ossim/imaging/RadarSat/Leader/DataPointDataRecord.cpp +++ /dev/null @@ -1,130 +0,0 @@ -#include <ossim/imaging/RadarSat/Leader/DataPointDataRecord.h> - - -DataPointDataRecord::DataPointDataRecord() -{ -} - -DataPointDataRecord::~DataPointDataRecord() -{ -} - -std::ostream& operator<<(std::ostream& os, const DataPointDataRecord& data) -{ - os<<"gmt_day:"<<data._gmt_day<<std::endl; - os<<"gmt_sec:"<<data._gmt_sec<<std::endl; - os<<"pitch_flag:"<<data._pitch_flag<<std::endl; - os<<"roll_flag:"<<data._roll_flag<<std::endl; - os<<"yaw_flag:"<<data._yaw_flag<<std::endl; - os<<"pitch:"<<data._pitch<<std::endl; - os<<"roll:"<<data._roll<<std::endl; - os<<"yaw:"<<data._yaw<<std::endl; - os<<"pitch_rate_flag:"<<data._pitch_rate_flag<<std::endl; - os<<"roll_rate_flag:"<<data._roll_rate_flag<<std::endl; - os<<"yaw_rate_flag:"<<data._yaw_rate_flag<<std::endl; - os<<"pitch_rate:"<<data._pitch_rate<<std::endl; - os<<"roll_rate:"<<data._roll_rate<<std::endl; - os<<"yaw_rate:"<<data._yaw_rate<<std::endl; - return os; -} - -std::istream& operator>>(std::istream& is, DataPointDataRecord& data) -{ - char buf[15]; - buf[14] = '\0'; - - is.read(buf,4); - buf[4] = '\0'; - data._gmt_day = atoi(buf); - - is.read(buf,8); - buf[8] = '\0'; - data._gmt_sec = atoi(buf); - - is.read(buf,4); - buf[4] = '\0'; - data._pitch_flag = atoi(buf); - - is.read(buf,4); - buf[4] = '\0'; - data._roll_flag = atoi(buf); - - is.read(buf,4); - buf[4] = '\0'; - data._yaw_flag = atoi(buf); - - is.read(buf,14); - buf[14] = '\0'; - data._pitch = atof(buf); - - is.read(buf,14); - buf[14] = '\0'; - data._roll = atof(buf); - - is.read(buf,14); - buf[14] = '\0'; - data._yaw = atof(buf); - - is.read(buf,4); - buf[4] = '\0'; - data._pitch_rate_flag = atoi(buf); - - is.read(buf,4); - buf[4] = '\0'; - data._roll_rate_flag = atoi(buf); - - is.read(buf,4); - buf[4] = '\0'; - data._yaw_rate_flag = atoi(buf); - - is.read(buf,14); - buf[14] = '\0'; - data._pitch_rate = atof(buf); - - is.read(buf,14); - buf[14] = '\0'; - data._roll_rate = atof(buf); - - is.read(buf,14); - buf[14] = '\0'; - data._yaw_rate = atof(buf); - - return is; -} - -DataPointDataRecord::DataPointDataRecord(const DataPointDataRecord& rhs) -{ - _gmt_day = rhs._gmt_day; - _gmt_sec = rhs._gmt_sec; - _pitch_flag = rhs._pitch_flag; - _roll_flag = rhs._roll_flag; - _yaw_flag = rhs._yaw_flag; - _pitch = rhs._pitch; - _roll = rhs._roll; - _yaw = rhs._yaw; - _pitch_rate_flag = rhs._pitch_rate_flag; - _roll_rate_flag = rhs._roll_rate_flag; - _yaw_rate_flag = rhs._yaw_rate_flag; - _pitch_rate = rhs._pitch_rate; - _roll_rate = rhs._roll_rate; - _yaw_rate = rhs._yaw_rate; -} - -DataPointDataRecord& DataPointDataRecord::operator=(const DataPointDataRecord& rhs) -{ - _gmt_day = rhs._gmt_day; - _gmt_sec = rhs._gmt_sec; - _pitch_flag = rhs._pitch_flag; - _roll_flag = rhs._roll_flag; - _yaw_flag = rhs._yaw_flag; - _pitch = rhs._pitch; - _roll = rhs._roll; - _yaw = rhs._yaw; - _pitch_rate_flag = rhs._pitch_rate_flag; - _roll_rate_flag = rhs._roll_rate_flag; - _yaw_rate_flag = rhs._yaw_rate_flag; - _pitch_rate = rhs._pitch_rate; - _roll_rate = rhs._roll_rate; - _yaw_rate = rhs._yaw_rate; - return *this; -} \ No newline at end of file diff --git a/Utilities/otbossim/src/ossim/imaging/RadarSat/Leader/DataQuality.cpp b/Utilities/otbossim/src/ossim/imaging/RadarSat/Leader/DataQuality.cpp deleted file mode 100644 index 8c86b51ecef2483868d279b5a4b1822ae4d1c3d1..0000000000000000000000000000000000000000 --- a/Utilities/otbossim/src/ossim/imaging/RadarSat/Leader/DataQuality.cpp +++ /dev/null @@ -1,280 +0,0 @@ -#include <ossim/imaging/RadarSat/Leader/DataQuality.h> - - -DataQuality::DataQuality() : RadarSatRecord("qual_sum_rec") -{ -} - -DataQuality::~DataQuality() -{ -} - -std::ostream& operator<<(std::ostream& os, const DataQuality& data) -{ - - os<<"rec_seq:"<<data._rec_seq<<std::endl; - - os<<"sar_chn:"<<data._sar_chn.c_str()<<std::endl; - - os<<"cali_date:"<<data._cali_date.c_str()<<std::endl; - - os<<"nchn:"<<data._nchn<<std::endl; - - os<<"islr:"<<data._islr<<std::endl; - - os<<"pslr:"<<data._pslr<<std::endl; - - os<<"azi_ambig:"<<data._azi_ambig<<std::endl; - - os<<"rng_ambig:"<<data._rng_ambig<<std::endl; - - os<<"snr:"<<data._snr<<std::endl; - - os<<"ber:"<<data._ber<<std::endl; - - os<<"rng_res:"<<data._rng_res<<std::endl; - - os<<"azi_res:"<<data._azi_res<<std::endl; - - os<<"rad_res:"<<data._rad_res<<std::endl; - - os<<"dyn_rng:"<<data._dyn_rng<<std::endl; - - os<<"rad_unc_db:"<<data._rad_unc_db<<std::endl; - - os<<"rad_unc_deg:"<<data._rad_unc_deg<<std::endl; - - for (int i=0;i<16;i++) - { - os<<"rad_unc:"<<data._rad_unc[i]<<std::endl; - } - - os<<"alt_locerr:"<<data._alt_locerr<<std::endl; - - os<<"crt_locerr:"<<data._crt_locerr<<std::endl; - - os<<"alt_scale:"<<data._alt_scale<<std::endl; - - os<<"crt_scale:"<<data._crt_scale<<std::endl; - - os<<"dis_skew:"<<data._dis_skew<<std::endl; - - os<<"ori_err:"<<data._ori_err<<std::endl; - - for (int i=0;i<16;i++) - { - os<<"misreg:"<<data._misreg[i]<<std::endl; - } - - os<<"nesz:"<<data._nesz<<std::endl; - - os<<"enl:"<<data._enl<<std::endl; - - os<<"tb_update:"<<data._tb_update.c_str()<<std::endl; - - - return os; -} - -std::istream& operator>>(std::istream& is, DataQuality& data) -{ - char buf[2149]; - buf[2148] = '\0'; - - - is.read(buf,4); - buf[4] = '\0'; - data._rec_seq = atoi(buf); - - is.read(buf,4); - buf[4] = '\0'; - data._sar_chn = buf; - - is.read(buf,6); - buf[6] = '\0'; - data._cali_date = buf; - - is.read(buf,4); - buf[4] = '\0'; - data._nchn = atoi(buf); - - is.read(buf,16); - buf[16] = '\0'; - data._islr = atof(buf); - - is.read(buf,16); - buf[16] = '\0'; - data._pslr = atof(buf); - - is.read(buf,16); - buf[16] = '\0'; - data._azi_ambig = atof(buf); - - is.read(buf,16); - buf[16] = '\0'; - data._rng_ambig = atof(buf); - - is.read(buf,16); - buf[16] = '\0'; - data._snr = atof(buf); - - is.read(buf,16); - buf[16] = '\0'; - data._ber = atof(buf); - - is.read(buf,16); - buf[16] = '\0'; - data._rng_res = atof(buf); - - is.read(buf,16); - buf[16] = '\0'; - data._azi_res = atof(buf); - - is.read(buf,16); - buf[16] = '\0'; - data._rad_res = atof(buf); - - is.read(buf,16); - buf[16] = '\0'; - data._dyn_rng = atof(buf); - - is.read(buf,16); - buf[16] = '\0'; - data._rad_unc_db = atof(buf); - - is.read(buf,16); - buf[16] = '\0'; - data._rad_unc_deg = atof(buf); - - for (int i=0;i<16;i++) - { - is>>data._rad_unc[i]; - } - - is.read(buf,16); - buf[16] = '\0'; - data._alt_locerr = atof(buf); - - is.read(buf,16); - buf[16] = '\0'; - data._crt_locerr = atof(buf); - - is.read(buf,16); - buf[16] = '\0'; - data._alt_scale = atof(buf); - - is.read(buf,16); - buf[16] = '\0'; - data._crt_scale = atof(buf); - - is.read(buf,16); - buf[16] = '\0'; - data._dis_skew = atof(buf); - - is.read(buf,16); - buf[16] = '\0'; - data._ori_err = atof(buf); - - for (int i=0;i<16;i++) - { - is>>data._misreg[i]; - } - - is.read(buf,16); - buf[16] = '\0'; - data._nesz = atof(buf); - - is.read(buf,16); - buf[16] = '\0'; - data._enl = atof(buf); - - is.read(buf,8); - buf[8] = '\0'; - data._tb_update = buf; - - is.read(buf,238); - - - return is; -} - -DataQuality::DataQuality(const DataQuality& rhs): - RadarSatRecord(rhs), - _rec_seq(rhs._rec_seq), - _sar_chn(rhs._sar_chn), - _cali_date(rhs._cali_date), - _nchn(rhs._nchn), - _islr(rhs._islr), - _pslr(rhs._pslr), - _azi_ambig(rhs._azi_ambig), - _rng_ambig(rhs._rng_ambig), - _snr(rhs._snr), - _ber(rhs._ber), - _rng_res(rhs._rng_res), - _azi_res(rhs._azi_res), - _rad_res(rhs._rad_res), - _dyn_rng(rhs._dyn_rng), - _rad_unc_db(rhs._rad_unc_db), - _rad_unc_deg(rhs._rad_unc_deg), - _alt_locerr(rhs._alt_locerr), - _crt_locerr(rhs._crt_locerr), - _alt_scale(rhs._alt_scale), - _crt_scale(rhs._crt_scale), - _dis_skew(rhs._dis_skew), - _ori_err(rhs._ori_err), - _nesz(rhs._nesz), - _enl(rhs._enl), - _tb_update(rhs._tb_update) -{ - for (int i=0;i<16;i++) - { - _rad_unc[i] = rhs._rad_unc[i]; - } - for (int i=0;i<16;i++) - { - _misreg[i] = rhs._misreg[i]; - } -} - -DataQuality& DataQuality::operator=(const DataQuality& rhs) -{ - _rec_seq = rhs._rec_seq; - _sar_chn = rhs._sar_chn; - _cali_date = rhs._cali_date; - _nchn = rhs._nchn; - _islr = rhs._islr; - _pslr = rhs._pslr; - _azi_ambig = rhs._azi_ambig; - _rng_ambig = rhs._rng_ambig; - _snr = rhs._snr; - _ber = rhs._ber; - _rng_res = rhs._rng_res; - _azi_res = rhs._azi_res; - _rad_res = rhs._rad_res; - _dyn_rng = rhs._dyn_rng; - _rad_unc_db = rhs._rad_unc_db; - _rad_unc_deg = rhs._rad_unc_deg; - - for (int i=0;i<16;i++) - { - _rad_unc[i] = rhs._rad_unc[i]; - } - - _alt_locerr = rhs._alt_locerr; - _crt_locerr = rhs._crt_locerr; - _alt_scale = rhs._alt_scale; - _crt_scale = rhs._crt_scale; - _dis_skew = rhs._dis_skew; - _ori_err = rhs._ori_err; - - for (int i=0;i<16;i++) - { - _misreg[i] = rhs._misreg[i]; - } - - _nesz = rhs._nesz; - _enl = rhs._enl; - _tb_update = rhs._tb_update; - - return *this; -} \ No newline at end of file diff --git a/Utilities/otbossim/src/ossim/imaging/RadarSat/Leader/DataSetSummary.cpp b/Utilities/otbossim/src/ossim/imaging/RadarSat/Leader/DataSetSummary.cpp deleted file mode 100644 index 02da83b89b37082638e3094a10b79f3cee5801ee..0000000000000000000000000000000000000000 --- a/Utilities/otbossim/src/ossim/imaging/RadarSat/Leader/DataSetSummary.cpp +++ /dev/null @@ -1,759 +0,0 @@ -#include <ossim/imaging/RadarSat/Leader/DataSetSummary.h> - -DataSetSummary::DataSetSummary() : RadarSatRecord("dataset_sum_rec") -{ -} - -DataSetSummary::~DataSetSummary() -{ -} - -std::ostream& operator<<(std::ostream& os, const DataSetSummary& data) -{ - os<<"seq_num:"<<data._seq_num<<std::endl; - - os<<"sar_chn:"<<data._sar_chn<<std::endl; - - os<<"scene_id:"<<data._scene_id.c_str()<<std::endl; - - os<<"scene_des:"<<data._scene_des.c_str()<<std::endl; - - os<<"inp_sctim:"<<data._inp_sctim.c_str()<<std::endl; - - os<<"asc_des:"<<data._asc_des.c_str()<<std::endl; - - os<<"pro_lat:"<<data._pro_lat<<std::endl; - - os<<"pro_long:"<<data._pro_long<<std::endl; - - os<<"pro_head:"<<data._pro_head<<std::endl; - - os<<"ellip_des:"<<data._ellip_des.c_str()<<std::endl; - - os<<"ellip_maj:"<<data._ellip_maj<<std::endl; - - os<<"ellip_min:"<<data._ellip_min<<std::endl; - os<<"earth_mass:"<<data._earth_mass<<std::endl; - os<<"grav_const:"<<data._grav_const<<std::endl; - os<<"ellip_j[0]:"<<data._ellip_j[0]<<std::endl; - os<<"ellip_j[1]:"<<data._ellip_j[1]<<std::endl; - os<<"ellip_j[2]:"<<data._ellip_j[2]<<std::endl; - os<<"terrain_h:"<<data._terrain_h<<std::endl; - os<<"sc_lin:"<<data._sc_lin<<std::endl; - os<<"sc_pix:"<<data._sc_pix<<std::endl; - os<<"scene_len:"<<data._scene_len<<std::endl; - os<<"scene_wid:"<<data._scene_wid<<std::endl; - os<<"nchn:"<<data._nchn<<std::endl; - os<<"mission_id:"<<data._mission_id.c_str()<<std::endl; - os<<"sensor_id:"<<data._sensor_id.c_str()<<std::endl; - os<<"orbit_num:"<<data._orbit_num.c_str()<<std::endl; - - os<<"plat_lat:"<<data._plat_lat<<std::endl; - - os<<"plat_long:"<<data._plat_long<<std::endl; - - os<<"plat_head:"<<data._plat_head<<std::endl; - - os<<"clock_ang:"<<data._clock_ang<<std::endl; - - os<<"incident_ang:"<<data._incident_ang<<std::endl; - - - os<<"wave_length:"<<data._wave_length<<std::endl; - - os<<"motion_comp:"<<data._motion_comp.c_str()<<std::endl; - - os<<"pulse_code:"<<data._pulse_code.c_str()<<std::endl; - - for (int i=0;i<5;i++) - { - os<<"ampl_coef["<<i<<"]:"<<data._ampl_coef[i]<<std::endl; - } - - for (int i=0;i<5;i++) - { - os<<"phas_coef["<<i<<"]:"<<data._phas_coef[i]<<std::endl; - } - - os<<"chirp_ext_ind:"<<data._chirp_ext_ind<<std::endl; - - os<<"fr:"<<data._fr<<std::endl; - - os<<"rng_gate:"<<data._rng_gate<<std::endl; - - os<<"rng_length:"<<data._rng_length<<std::endl; - - os<<"baseband_f:"<<data._baseband_f.c_str()<<std::endl; - - os<<"rngcmp_f:"<<data._rngcmp_f.c_str()<<std::endl; - - os<<"gn_polar:"<<data._gn_polar <<std::endl; - - os<<"gn_cross:"<<data._gn_cross <<std::endl; - - os<<"chn_bits:"<<data._chn_bits<<std::endl; - - os<<"quant_desc:"<<data._quant_desc.c_str()<<std::endl; - - os<<"i_bias:"<<data._i_bias<<std::endl; - - os<<"q_bias:"<<data._q_bias<<std::endl; - - os<<"iq_ratio:"<<data._iq_ratio<<std::endl; - - os<<"ele_sight:"<<data._ele_sight<<std::endl; - - os<<"mech_sight:"<<data._mech_sight<<std::endl; - - os<<"echo_track:"<<data._echo_track.c_str()<<std::endl; - - os<<"fa:"<<data._fa<<std::endl; - - os<<"elev_beam:"<<data._elev_beam<<std::endl; - - os<<"azim_beam:"<<data._azim_beam<<std::endl; - - os<<"sat_bintim:"<<data._sat_bintim<<std::endl; - - os<<"sat_clktim:"<<data._sat_clktim<<std::endl; - - os<<"sat_clkinc:"<<data._sat_clkinc<<std::endl; - - os<<"fac_id:"<<data._fac_id.c_str()<<std::endl; - - os<<"sys_id:"<<data._sys_id.c_str()<<std::endl; - - os<<"ver_id:"<<data._ver_id.c_str()<<std::endl; - - os<<"fac_code:"<<data._fac_code.c_str()<<std::endl; - - os<<"lev_code:"<<data._lev_code.c_str()<<std::endl; - - os<<"prod_type:"<<data._prod_type.c_str()<<std::endl; - - os<<"algor_id:"<<data._algor_id.c_str()<<std::endl; - - os<<"n_azilok:"<<data._n_azilok<<std::endl; - - os<<"n_rnglok:"<<data._n_rnglok<<std::endl; - - os<<"bnd_azilok:"<<data._bnd_azilok<<std::endl; - - os<<"bnd_rnglok:"<<data._bnd_rnglok<<std::endl; - - os<<"bnd_azi:"<<data._bnd_azi<<std::endl; - - os<<"bnd_rng:"<<data._bnd_rng<<std::endl; - - os<<"azi_weight:"<<data._azi_weight.c_str()<<std::endl; - - os<<"rng_weight:"<<data._rng_weight.c_str()<<std::endl; - - os<<"data_inpsrc:"<<data._data_inpsrc.c_str()<<std::endl; - - os<<"rng_res:"<<data._rng_res<<std::endl; - - os<<"azi_res:"<<data._azi_res<<std::endl; - - os<<"radi_stretch[0]:"<<data._radi_stretch[0]<<std::endl; - os<<"radi_stretch[1]:"<<data._radi_stretch[1]<<std::endl; - - os<<"alt_dopcen[0]:"<<data._alt_dopcen[0]<<std::endl; - os<<"alt_dopcen[1]:"<<data._alt_dopcen[1]<<std::endl; - os<<"alt_dopcen[2]:"<<data._alt_dopcen[2]<<std::endl; - - os<<"crt_dopcen[0]:"<<data._crt_dopcen[0]<<std::endl; - os<<"crt_dopcen[1]:"<<data._crt_dopcen[1]<<std::endl; - os<<"crt_dopcen[2]:"<<data._crt_dopcen[2]<<std::endl; - - os<<"time_dir_pix:"<<data._time_dir_pix.c_str()<<std::endl; - - os<<"time_dir_lin:"<<data._time_dir_lin.c_str()<<std::endl; - - os<<"alt_rate[0]:"<<data._alt_rate[0]<<std::endl; - os<<"alt_rate[1]:"<<data._alt_rate[1]<<std::endl; - os<<"alt_rate[2]:"<<data._alt_rate[2]<<std::endl; - - os<<"crt_rate[0]:"<<data._crt_rate[0]<<std::endl; - os<<"crt_rate[1]:"<<data._crt_rate[1]<<std::endl; - os<<"crt_rate[2]:"<<data._crt_rate[2]<<std::endl; - - os<<"clutter_lock:"<<data._line_cont.c_str()<<std::endl; - - os<<"clutter_lock:"<<data._clutter_lock.c_str()<<std::endl; - - os<<"auto_focus:"<<data._auto_focus.c_str()<<std::endl; - - os<<"line_spacing:"<<data._line_spacing<<std::endl; - - os<<"pix_spacing:"<<data._pix_spacing<<std::endl; - - os<<"rngcmp_desg:"<<data._rngcmp_desg.c_str()<<std::endl; - - return os; - -} - -std::istream& operator>>(std::istream& is, DataSetSummary& data) -{ - char buf16[17]; - buf16[16]='\0'; - char buf32[33]; - buf32[32] = '\0'; - char buf8[9]; - buf8[8] = '\0'; - char buf4[5]; - buf4[4] = '\0'; - - is.read(buf4,4); - data._seq_num = atoi(buf4); - - is.read(buf4,4); - data._sar_chn = atoi(buf4); - - is.read(buf16,16); - data._scene_id = buf16; - - is.read(buf32,32); - data._scene_des = buf32; - - is.read(buf32,32); - data._inp_sctim = buf32; - - is.read(buf16,16); - data._asc_des = buf16; - - is.read(buf16,16); - data._pro_lat = atof(buf16); - - is.read(buf16,16); - data._pro_long = atof(buf16); - - is.read(buf16,16); - data._pro_head = atof(buf16); - - is.read(buf16,16); - data._ellip_des = buf16; - - is.read(buf16,16); - data._ellip_maj = atof(buf16); - - is.read(buf16,16); - data._ellip_min = atof(buf16); - - is.read(buf16,16); - data._earth_mass = atof(buf16); - - is.read(buf16,16); - data._grav_const = atof(buf16); - - is.read(buf16,16); - data._ellip_j[0] = atof(buf16); - is.read(buf16,16); - data._ellip_j[1] = atof(buf16); - is.read(buf16,16); - data._ellip_j[2] = atof(buf16); - - is.read(buf16,16); - - is.read(buf16,16); - data._terrain_h = atof(buf16); - - is.read(buf8,8); - data._sc_lin = atoi(buf8); - - is.read(buf8,8); - data._sc_pix = atoi(buf8); - - is.read(buf16,16); - data._scene_len = atof(buf16); - - is.read(buf16,16); - data._scene_wid = atof(buf16); - - is.read(buf16,16); - - is.read(buf4,4); - data._nchn = atoi(buf4); - - is.read(buf4,4); - - is.read(buf16,16); - data._mission_id = buf16; - - is.read(buf32,32); - data._sensor_id = buf32; - - is.read(buf8,8); - data._orbit_num = buf8; - - is.read(buf8,8); - data._plat_lat = atof(buf8); - - is.read(buf8,8); - data._plat_long = atof(buf8); - - is.read(buf8,8); - data._plat_head = atof(buf8); - - is.read(buf8,8); - data._clock_ang = atof(buf8); - - is.read(buf8,8); - data._incident_ang = atof(buf8); - - is.read(buf8,8); - - is.read(buf16,16); - data._wave_length = atof(buf16); - - is.read(buf8,2); - buf8[2] = '\0'; - data._motion_comp = buf8; - - is.read(buf16,16); - data._pulse_code = buf16; - - for (int i=0;i<5;i++) - { - is.read(buf16,16); - data._ampl_coef[i] = atof(buf16); - } - - for (int i=0;i<5;i++) - { - is.read(buf16,16); - data._phas_coef[i] = atof(buf16); - } - - is.read(buf8,8); - data._chirp_ext_ind = atoi(buf8); - - is.read(buf8,8); - - is.read(buf16,16); - data._fr = atof(buf16); - - is.read(buf16,16); - data._rng_gate = atof(buf16); - - is.read(buf16,16); - data._rng_length = atof(buf16); - - is.read(buf8,4); - buf8[4] = '\0'; - data._baseband_f = buf8; - - is.read(buf8,4); - buf8[4] = '\0'; - data._rngcmp_f = buf8; - - is.read(buf16,16); - data._gn_polar = atof(buf16); - - is.read(buf16,16); - data._gn_cross = atof(buf16); - - is.read(buf8,8); - data._chn_bits = atoi(buf8); - - is.read(buf16,12); - buf16[12] = '\0'; - data._quant_desc = buf16; - - is.read(buf16,16); - data._i_bias = atof(buf16); - - is.read(buf16,16); - data._q_bias = atof(buf16); - - is.read(buf16,16); - data._iq_ratio = atof(buf16); - - is.read(buf16,16); - - is.read(buf16,16); - - is.read(buf16,16); - data._ele_sight = atof(buf16); - - is.read(buf16,16); - data._mech_sight = atof(buf16); - - is.read(buf4,4); - data._echo_track = buf4; - - is.read(buf16,16); - data._fa = atof(buf16); - - is.read(buf16,16); - data._elev_beam = atof(buf16); - - is.read(buf16,16); - data._azim_beam = atof(buf16); - - is.read(buf16,16); - data._sat_bintim = atoi(buf16); - - is.read(buf32,32); - data._sat_clktim = atoi(buf32); - - is.read(buf8,8); - data._sat_clkinc = atoi(buf8); - - is.read(buf8,8); - - is.read(buf16,16); - data._fac_id = buf16; - - is.read(buf8,8); - data._sys_id = buf8; - - is.read(buf8,8); - data._ver_id = buf8; - - is.read(buf16,16); - data._fac_code = buf16; - - is.read(buf16,16); - data._lev_code = buf16; - - is.read(buf32,32); - data._prod_type = buf32; - - is.read(buf32,32); - data._algor_id = buf32; - - is.read(buf16,16); - data._n_azilok = atof(buf16); - - is.read(buf16,16); - data._n_rnglok = atof(buf16); - - is.read(buf16,16); - data._bnd_azilok = atof(buf16); - - is.read(buf16,16); - data._bnd_rnglok = atof(buf16); - - is.read(buf16,16); - data._bnd_azi = atof(buf16); - - is.read(buf16,16); - data._bnd_rng = atof(buf16); - - is.read(buf32,32); - data._azi_weight = buf32; - - is.read(buf32,32); - data._rng_weight = buf32; - - is.read(buf16,16); - data._data_inpsrc = buf16; - - is.read(buf16,16); - data._rng_res = atof(buf16); - - is.read(buf16,16); - data._azi_res = atof(buf16); - - is.read(buf16,16); - data._radi_stretch[0] = atof(buf16); - is.read(buf16,16); - data._radi_stretch[1] = atof(buf16); - - is.read(buf16,16); - data._alt_dopcen[0] = atof(buf16); - is.read(buf16,16); - data._alt_dopcen[1] = atof(buf16); - is.read(buf16,16); - data._alt_dopcen[2] = atof(buf16); - - is.read(buf16,16); - - is.read(buf16,16); - data._crt_dopcen[0] = atof(buf16); - is.read(buf16,16); - data._crt_dopcen[1] = atof(buf16); - is.read(buf16,16); - data._crt_dopcen[2] = atof(buf16); - - is.read(buf8,8); - data._time_dir_pix = buf8; - - is.read(buf8,8); - data._time_dir_lin = buf8; - - is.read(buf16,16); - data._alt_rate[0] = atof(buf16); - is.read(buf16,16); - data._alt_rate[1] = atof(buf16); - is.read(buf16,16); - data._alt_rate[2] = atof(buf16); - - is.read(buf16,16); - - is.read(buf16,16); - data._crt_rate[0] = atof(buf16); - is.read(buf16,16); - data._crt_rate[1] = atof(buf16); - is.read(buf16,16); - data._crt_rate[2] = atof(buf16); - - is.read(buf16,16); - - is.read(buf8,8); - data._line_cont = buf8; - - is.read(buf4,4); - data._clutter_lock = buf4; - - is.read(buf4,4); - data._auto_focus = buf4; - - is.read(buf16,16); - data._line_spacing = atof(buf16); - - is.read(buf16,16); - data._pix_spacing = atof(buf16); - - is.read(buf16,16); - data._rngcmp_desg = buf16; - - char buf[2363]; - buf[2362] = '\0'; - - is.read(buf,2362); - - return is; -} - - -DataSetSummary::DataSetSummary(const DataSetSummary& rhs): - RadarSatRecord(rhs), - _seq_num(rhs._seq_num), - _sar_chn(rhs._sar_chn), - _scene_id(rhs._scene_id), - _scene_des(rhs._scene_des), - _inp_sctim(rhs._inp_sctim), - _asc_des(rhs._asc_des), - _pro_lat(rhs._pro_lat), - _pro_long(rhs._pro_long), - _pro_head(rhs._pro_head), - _ellip_des(rhs._ellip_des), - _ellip_maj(rhs._ellip_maj), - _ellip_min(rhs._ellip_min), - _earth_mass(rhs._earth_mass), - _grav_const(rhs._grav_const), - _terrain_h(rhs._terrain_h), - _sc_lin(rhs._sc_lin), - _sc_pix(rhs._sc_pix), - _scene_len(rhs._scene_len), - _scene_wid(rhs._scene_wid), - _nchn(rhs._nchn), - _mission_id(rhs._mission_id), - _sensor_id(rhs._sensor_id), - _orbit_num(rhs._orbit_num), - _plat_lat(rhs._plat_lat), - _plat_long(rhs._plat_long), - _plat_head(rhs._plat_head), - _clock_ang(rhs._clock_ang), - _incident_ang(rhs._incident_ang), - _wave_length(rhs._wave_length), - _motion_comp(rhs._motion_comp), - _pulse_code(rhs._pulse_code), - _chirp_ext_ind(rhs._chirp_ext_ind), - _fr(rhs._fr), - _rng_gate(rhs._rng_gate), - _rng_length(rhs._rng_length), - _baseband_f(rhs._baseband_f), - _rngcmp_f(rhs._rngcmp_f), - _gn_polar(rhs._gn_polar), - _gn_cross(rhs._gn_cross), - _chn_bits(rhs._chn_bits), - _quant_desc(rhs._quant_desc), - _i_bias(rhs._i_bias), - _q_bias(rhs._q_bias), - _iq_ratio(rhs._iq_ratio), - _ele_sight(rhs._ele_sight), - _mech_sight(rhs._mech_sight), - _echo_track(rhs._echo_track), - _fa(rhs._fa), - _elev_beam(rhs._elev_beam), - _azim_beam(rhs._azim_beam), - _sat_bintim(rhs._sat_bintim), - _sat_clktim(rhs._sat_clktim), - _sat_clkinc(rhs._sat_clkinc), - _fac_id(rhs._fac_id), - _sys_id(rhs._sys_id), - _ver_id(rhs._ver_id), - _fac_code(rhs._fac_code), - _lev_code(rhs._lev_code), - _prod_type(rhs._prod_type), - _algor_id(rhs._algor_id), - _n_azilok(rhs._n_azilok), - _n_rnglok(rhs._n_rnglok), - _bnd_azilok(rhs._bnd_azilok), - _bnd_rnglok(rhs._bnd_rnglok), - _bnd_azi(rhs._bnd_azi), - _bnd_rng(rhs._bnd_rng), - _azi_weight(rhs._azi_weight), - _rng_weight(rhs._rng_weight), - _data_inpsrc(rhs._data_inpsrc), - _rng_res(rhs._rng_res), - _azi_res(rhs._azi_res), - _time_dir_pix(rhs._time_dir_pix), - _time_dir_lin(rhs._time_dir_lin), - _line_cont(rhs._line_cont), - _clutter_lock(rhs._clutter_lock), - _auto_focus(rhs._auto_focus), - _line_spacing(rhs._line_spacing), - _pix_spacing(rhs._pix_spacing), - _rngcmp_desg(rhs._rngcmp_desg) -{ - _ellip_j[0] = rhs._ellip_j[0]; - _ellip_j[1] = rhs._ellip_j[1]; - _ellip_j[2] = rhs._ellip_j[2]; - _ampl_coef[0] = rhs._ampl_coef[0]; - _ampl_coef[1] = rhs._ampl_coef[1]; - _ampl_coef[2] = rhs._ampl_coef[2]; - _ampl_coef[3] = rhs._ampl_coef[3]; - _ampl_coef[4] = rhs._ampl_coef[4]; - _phas_coef[0] = rhs._phas_coef[0]; - _phas_coef[1] = rhs._phas_coef[1]; - _phas_coef[2] = rhs._phas_coef[2]; - _phas_coef[3] = rhs._phas_coef[3]; - _phas_coef[4] = rhs._phas_coef[4]; - - _radi_stretch[0] = rhs._radi_stretch[0]; - _radi_stretch[1] = rhs._radi_stretch[1]; - _alt_dopcen[0] = rhs._alt_dopcen[0]; - _alt_dopcen[1] = rhs._alt_dopcen[1]; - _alt_dopcen[2] = rhs._alt_dopcen[2]; - - _crt_dopcen[0] = rhs._crt_dopcen[0]; - _crt_dopcen[1] = rhs._crt_dopcen[1]; - _crt_dopcen[2] = rhs._crt_dopcen[2]; - - _alt_rate[0] = rhs._alt_rate[0]; - _alt_rate[1] = rhs._alt_rate[1]; - _alt_rate[2] = rhs._alt_rate[2]; - _crt_rate[0] = rhs._crt_rate[0]; - _crt_rate[1] = rhs._crt_rate[1]; - _crt_rate[2] = rhs._crt_rate[2]; -} - -DataSetSummary& DataSetSummary::operator=(const DataSetSummary& rhs) -{ - _seq_num = rhs._seq_num; - _sar_chn = rhs._sar_chn; - _scene_id = rhs._scene_id; - _scene_des = rhs._scene_des; - _inp_sctim = rhs._inp_sctim; - _asc_des = rhs._asc_des; - _pro_lat = rhs._pro_lat; - _pro_long = rhs._pro_long; - _pro_head = rhs._pro_head; - _ellip_des = rhs._ellip_des; - _ellip_maj = rhs._ellip_maj; - _ellip_min = rhs._ellip_min; - _earth_mass = rhs._earth_mass; - _grav_const = rhs._grav_const; - _terrain_h = rhs._terrain_h; - _sc_lin = rhs._sc_lin; - _sc_pix = rhs._sc_pix; - _scene_len = rhs._scene_len; - _scene_wid = rhs._scene_wid; - _nchn = rhs._nchn; - _mission_id = rhs._mission_id; - _sensor_id = rhs._sensor_id; - _orbit_num = rhs._orbit_num; - _plat_lat = rhs._plat_lat; - _plat_long = rhs._plat_long; - _plat_head = rhs._plat_head; - _clock_ang = rhs._clock_ang; - _incident_ang = rhs._incident_ang; - _wave_length = rhs._wave_length; - _motion_comp = rhs._motion_comp; - _pulse_code = rhs._pulse_code; - _chirp_ext_ind = rhs._chirp_ext_ind; - _fr = rhs._fr; - _rng_gate = rhs._rng_gate; - _rng_length = rhs._rng_length; - _baseband_f = rhs._baseband_f; - _rngcmp_f = rhs._rngcmp_f; - _gn_polar = rhs._gn_polar; - _gn_cross = rhs._gn_cross; - _chn_bits = rhs._chn_bits; - _quant_desc = rhs._quant_desc; - _i_bias = rhs._i_bias; - _q_bias = rhs._q_bias; - _iq_ratio = rhs._iq_ratio; - _ele_sight = rhs._ele_sight; - _mech_sight = rhs._mech_sight; - _echo_track = rhs._echo_track; - _fa = rhs._fa; - _elev_beam = rhs._elev_beam; - _azim_beam = rhs._azim_beam; - _sat_bintim = rhs._sat_bintim; - _sat_clktim = rhs._sat_clktim; - _sat_clkinc = rhs._sat_clkinc; - _fac_id = rhs._fac_id; - _sys_id = rhs._sys_id; - _ver_id = rhs._ver_id; - _fac_code = rhs._fac_code; - _lev_code = rhs._lev_code; - _prod_type = rhs._prod_type; - _algor_id = rhs._algor_id; - _n_azilok = rhs._n_azilok; - _n_rnglok = rhs._n_rnglok; - _bnd_azilok = rhs._bnd_azilok; - _bnd_rnglok = rhs._bnd_rnglok; - _bnd_azi = rhs._bnd_azi; - _bnd_rng = rhs._bnd_rng; - _azi_weight = rhs._azi_weight; - _rng_weight = rhs._rng_weight; - _data_inpsrc = rhs._data_inpsrc; - _rng_res = rhs._rng_res; - _azi_res = rhs._azi_res; - _time_dir_pix = rhs._time_dir_pix; - _time_dir_lin = rhs._time_dir_lin; - _line_cont = rhs._line_cont; - _clutter_lock = rhs._clutter_lock; - _auto_focus = rhs._auto_focus; - _line_spacing = rhs._line_spacing; - _pix_spacing = rhs._pix_spacing; - _rngcmp_desg = rhs._rngcmp_desg; - - _ellip_j[0] = rhs._ellip_j[0]; - _ellip_j[1] = rhs._ellip_j[1]; - _ellip_j[2] = rhs._ellip_j[2]; - _ampl_coef[0] = rhs._ampl_coef[0]; - _ampl_coef[1] = rhs._ampl_coef[1]; - _ampl_coef[2] = rhs._ampl_coef[2]; - _ampl_coef[3] = rhs._ampl_coef[3]; - _ampl_coef[4] = rhs._ampl_coef[4]; - _phas_coef[0] = rhs._phas_coef[0]; - _phas_coef[1] = rhs._phas_coef[1]; - _phas_coef[2] = rhs._phas_coef[2]; - _phas_coef[3] = rhs._phas_coef[3]; - _phas_coef[4] = rhs._phas_coef[4]; - - _radi_stretch[0] = rhs._radi_stretch[0]; - _radi_stretch[1] = rhs._radi_stretch[1]; - _alt_dopcen[0] = rhs._alt_dopcen[0]; - _alt_dopcen[1] = rhs._alt_dopcen[1]; - _alt_dopcen[2] = rhs._alt_dopcen[2]; - - _crt_dopcen[0] = rhs._crt_dopcen[0]; - _crt_dopcen[1] = rhs._crt_dopcen[1]; - _crt_dopcen[2] = rhs._crt_dopcen[2]; - - _alt_rate[0] = rhs._alt_rate[0]; - _alt_rate[1] = rhs._alt_rate[1]; - _alt_rate[2] = rhs._alt_rate[2]; - _crt_rate[0] = rhs._crt_rate[0]; - _crt_rate[1] = rhs._crt_rate[1]; - _crt_rate[2] = rhs._crt_rate[2]; - return *this; -} diff --git a/Utilities/otbossim/src/ossim/imaging/RadarSat/Leader/DopplerCentroidEstimateRecord.cpp b/Utilities/otbossim/src/ossim/imaging/RadarSat/Leader/DopplerCentroidEstimateRecord.cpp deleted file mode 100644 index 6a6a7d405da2332242364c8861f206470bfc6f90..0000000000000000000000000000000000000000 --- a/Utilities/otbossim/src/ossim/imaging/RadarSat/Leader/DopplerCentroidEstimateRecord.cpp +++ /dev/null @@ -1,65 +0,0 @@ -#include <ossim/imaging/RadarSat/Leader/DopplerCentroidEstimateRecord.h> - - -DopplerCentroidEstimateRecord::DopplerCentroidEstimateRecord() -{ -} - -DopplerCentroidEstimateRecord::~DopplerCentroidEstimateRecord() -{ -} - -std::ostream& operator<<(std::ostream& os, const DopplerCentroidEstimateRecord& data) -{ - os<<"dopcen_conf:"<<data._dopcen_conf<<std::endl; - os<<"dopcen_ref_tim:"<<data._dopcen_ref_tim<<std::endl; - for (int i=0;i<4;i++) - { - os<<"dopcen_coef["<<i<<"]:"<<data._dopcen_coef[i]<<std::endl; - } - - return os; -} - -std::istream& operator>>(std::istream& is, DopplerCentroidEstimateRecord& data) -{ - char buf[17]; - buf[16] = '\0'; - - is.read(buf,16); - buf[16] = '\0'; - data._dopcen_conf = atof(buf); - - is.read(buf,16); - buf[16] = '\0'; - data._dopcen_ref_tim = atof(buf); - - for (int i=0;i<4;i++) - { - is.read(buf,16); - buf[16] = '\0'; - data._dopcen_coef[i] = atof(buf); - } - return is; -} - -DopplerCentroidEstimateRecord::DopplerCentroidEstimateRecord(const DopplerCentroidEstimateRecord& rhs): - _dopcen_conf(rhs._dopcen_conf), - _dopcen_ref_tim(rhs._dopcen_ref_tim) -{ - for (int i=0;i<4;i++) - { - _dopcen_coef[i] = rhs._dopcen_coef[i]; - } -} - -DopplerCentroidEstimateRecord& DopplerCentroidEstimateRecord::operator=(const DopplerCentroidEstimateRecord& rhs) -{ - _dopcen_conf = rhs._dopcen_conf; - _dopcen_ref_tim = rhs._dopcen_ref_tim; - for (int i=0;i<4;i++) - { - _dopcen_coef[i] = rhs._dopcen_coef[i]; - } - return *this; -} \ No newline at end of file diff --git a/Utilities/otbossim/src/ossim/imaging/RadarSat/Leader/FileDescriptor.cpp b/Utilities/otbossim/src/ossim/imaging/RadarSat/Leader/FileDescriptor.cpp deleted file mode 100644 index 29c5177da185f6ff291c136f6bad893bafb667f6..0000000000000000000000000000000000000000 --- a/Utilities/otbossim/src/ossim/imaging/RadarSat/Leader/FileDescriptor.cpp +++ /dev/null @@ -1,322 +0,0 @@ -#include <ossim/imaging/RadarSat/Leader/FileDescriptor.h> - - -FileDescriptor::FileDescriptor() : RadarSatRecord("sar_desc_rec") -{ -} - -FileDescriptor::~FileDescriptor() -{ -} - -std::ostream& operator<<(std::ostream& os, const FileDescriptor& data) -{ - os<<"ascii_flag:"<<data._ascii_flag.c_str()<<std::endl; - os<<"format_doc:"<<data._format_doc.c_str()<<std::endl; - os<<"format_ver:"<<data._format_ver.c_str()<<std::endl; - os<<"design_rev:"<<data._design_rev.c_str()<<std::endl; - os<<"software_id:"<<data._software_id.c_str()<<std::endl; - os<<"file_num:"<<data._file_num<<std::endl; - os<<"file_name:"<<data._file_name.c_str()<<std::endl; - os<<"rec_seq:"<<data._rec_seq.c_str()<<std::endl; - os<<"seq_loc:"<<data._seq_loc<<std::endl; - os<<"seq_len:"<<data._seq_len<<std::endl; - os<<"rec_code:"<<data._rec_code.c_str()<<std::endl; - os<<"code_loc:"<<data._code_loc<<std::endl; - os<<"code_len:"<<data._code_len<<std::endl; - os<<"rec_len:"<<data._rec_len.c_str()<<std::endl; - os<<"rlen_loc:"<<data._rlen_loc<<std::endl; - os<<"rlen_len:"<<data._rlen_len<<std::endl; - os<<"n_dataset:"<<data._n_dataset<<std::endl; - os<<"l_dataset:"<<data._l_dataset<<std::endl; - os<<"n_map_proj:"<<data._n_map_proj<<std::endl; - os<<"l_map_proj:"<<data._l_map_proj<<std::endl; - os<<"n_plat_pos:"<<data._n_plat_pos<<std::endl; - os<<"l_plat_pos:"<<data._l_plat_pos<<std::endl; - os<<"n_att_data:"<<data._n_att_data<<std::endl; - os<<"l_att_data:"<<data._l_att_data<<std::endl; - os<<"n_radi_data:"<<data._n_radi_data<<std::endl; - os<<"l_radi_data:"<<data._l_radi_data<<std::endl; - os<<"n_radi_comp:"<<data._n_radi_comp<<std::endl; - os<<"l_radi_comp:"<<data._l_radi_comp<<std::endl; - os<<"n_qual_sum:"<<data._n_qual_sum<<std::endl; - os<<"l_qual_sum:"<<data._l_qual_sum<<std::endl; - os<<"n_data_his:"<<data._n_data_his<<std::endl; - os<<"l_data_his:"<<data._l_data_his<<std::endl; - os<<"n_rang_spec:"<<data._n_rang_spec<<std::endl; - os<<"l_rang_spec:"<<data._l_rang_spec<<std::endl; - os<<"n_dem_desc:"<<data._n_dem_desc<<std::endl; - os<<"l_dem_desc:"<<data._l_dem_desc<<std::endl; - os<<"n_radar_par:"<<data._n_radar_par<<std::endl; - os<<"l_radar_par:"<<data._l_radar_par<<std::endl; - os<<"n_anno_data:"<<data._n_anno_data<<std::endl; - os<<"l_anno_data:"<<data._l_anno_data<<std::endl; - os<<"n_det_proc:"<<data._n_det_proc<<std::endl; - os<<"l_det_proc:"<<data._l_det_proc<<std::endl; - os<<"n_cal:"<<data._n_cal<<std::endl; - os<<"l_cal:"<<data._l_cal<<std::endl; - os<<"n_gcp:"<<data._n_gcp<<std::endl; - os<<"l_gcp:"<<data._l_gcp<<std::endl; - os<<"n_fac_data:"<<data._n_fac_data<<std::endl; - os<<"l_fac_data:"<<data._l_fac_data<<std::endl; - return os; -} - -std::istream& operator>>(std::istream& is, FileDescriptor& data) -{ - char buf2[3]; - buf2[2] = '\0'; - char buf12[13]; - buf12[12] = '\0'; - char buf16[17]; - buf16[16] = '\0'; - char buf4[5]; - buf4[4] = '\0'; - char buf6[7]; - buf6[6] = '\0'; - char buf8[9]; - buf8[8] = '\0'; - char buf64[65]; - buf64[64] = '\0'; - - char buf60[61]; - buf60[60] = '\0'; - - char buf288[289]; - buf288[288] = '\0'; - - is.read(buf2,2); - data._ascii_flag = buf2; - - is.read(buf2,2); - - is.read(buf12,12); - data._format_doc = buf12; - - is.read(buf2,2); - data._format_ver = buf2; - - is.read(buf2,2); - data._design_rev = buf2; - - is.read(buf12,12); - data._software_id = buf12; - - is.read(buf4,4); - data._file_num = atoi(buf4); - - is.read(buf16,16); - data._file_name = buf16; - - is.read(buf4,4); - data._rec_seq = buf4; - - is.read(buf8,8); - data._seq_loc = atoi(buf8); - - is.read(buf4,4); - data._seq_len = atoi(buf4); - - is.read(buf4,4); - data._rec_code = buf4; - - is.read(buf8,8); - data._code_loc = atoi(buf8); - - is.read(buf4,4); - data._code_len = atoi(buf4); - - is.read(buf4,4); - data._rec_len = buf4; - - is.read(buf8,8); - data._rlen_loc = atoi(buf8); - - is.read(buf4,4); - data._rlen_len = atoi(buf4); - - is.read(buf4,4); - - is.read(buf64,64); - - is.read(buf6,6); - data._n_dataset = atoi(buf6); - - is.read(buf6,6); - data._l_dataset = atoi(buf6); - - is.read(buf6,6); - data._n_map_proj = atoi(buf6); - - is.read(buf6,6); - data._l_map_proj = atoi(buf6); - - is.read(buf6,6); - data._n_plat_pos = atoi(buf6); - is.read(buf6,6); - data._l_plat_pos = atoi(buf6); - is.read(buf6,6); - data._n_att_data = atoi(buf6); - is.read(buf6,6); - data._l_att_data = atoi(buf6); - is.read(buf6,6); - data._n_radi_data = atoi(buf6); - is.read(buf6,6); - data._l_radi_data = atoi(buf6); - is.read(buf6,6); - data._n_radi_comp = atoi(buf6); - is.read(buf6,6); - data._l_radi_comp = atoi(buf6); - is.read(buf6,6); - data._n_qual_sum = atoi(buf6); - is.read(buf6,6); - data._l_qual_sum = atoi(buf6); - is.read(buf6,6); - data._n_data_his = atoi(buf6); - is.read(buf6,6); - data._l_data_his = atoi(buf6); - - - - is.read(buf6,6); - data._n_rang_spec = atoi(buf6); - is.read(buf6,6); - data._l_rang_spec = atoi(buf6); - is.read(buf6,6); - data._n_dem_desc = atoi(buf6); - is.read(buf6,6); - data._l_dem_desc = atoi(buf6); - is.read(buf6,6); - data._n_radar_par = atoi(buf6); - is.read(buf6,6); - data._l_radar_par = atoi(buf6); - is.read(buf6,6); - data._n_anno_data = atoi(buf6); - is.read(buf6,6); - data._l_anno_data = atoi(buf6); - is.read(buf6,6); - data._n_det_proc = atoi(buf6); - is.read(buf6,6); - data._l_det_proc = atoi(buf6); - is.read(buf6,6); - data._n_cal = atoi(buf6); - is.read(buf6,6); - data._l_cal = atoi(buf6); - is.read(buf6,6); - data._n_gcp = atoi(buf6); - is.read(buf6,6); - data._l_gcp = atoi(buf6); - is.read(buf60,60); - is.read(buf6,6); - data._n_fac_data = atoi(buf6); - is.read(buf6,6); - data._l_fac_data = atoi(buf6); - is.read(buf288,288); - return is; -} - -FileDescriptor::FileDescriptor(const FileDescriptor& rhs): - RadarSatRecord(rhs), - _ascii_flag(rhs._ascii_flag), - _format_doc(rhs._format_doc), - _format_ver(rhs._format_ver), - _design_rev(rhs._design_rev), - _software_id(rhs._software_id), - _file_num(rhs._file_num), - _file_name(rhs._file_name), - _rec_seq(rhs._rec_seq), - _seq_loc(rhs._seq_loc), - _seq_len(rhs._seq_len), - _rec_code(rhs._rec_code), - _code_loc(rhs._code_loc), - _code_len(rhs._code_len), - _rec_len(rhs._rec_len), - _rlen_loc(rhs._rlen_loc), - _rlen_len(rhs._rlen_len), - _n_dataset(rhs._n_dataset), - _l_dataset(rhs._l_dataset), - _n_map_proj(rhs._n_map_proj), - _l_map_proj(rhs._l_map_proj), - _n_plat_pos(rhs._n_plat_pos), - _l_plat_pos(rhs._l_plat_pos), - _n_att_data(rhs._n_att_data), - _l_att_data(rhs._l_att_data), - _n_radi_data(rhs._n_radi_data), - _l_radi_data(rhs._l_radi_data), - _n_radi_comp(rhs._n_radi_comp), - _l_radi_comp(rhs._l_radi_comp), - _n_qual_sum(rhs._n_qual_sum), - _l_qual_sum(rhs._l_qual_sum), - _n_data_his(rhs._n_data_his), - _l_data_his(rhs._l_data_his), - _n_rang_spec(rhs._n_rang_spec), - _l_rang_spec(rhs._l_rang_spec), - _n_dem_desc(rhs._n_dem_desc), - _l_dem_desc(rhs._l_dem_desc), - _n_radar_par(rhs._n_radar_par), - _l_radar_par(rhs._l_radar_par), - _n_anno_data(rhs._n_anno_data), - _l_anno_data(rhs._l_anno_data), - _n_det_proc(rhs._n_det_proc), - _l_det_proc(rhs._l_det_proc), - _n_cal(rhs._n_cal), - _l_cal(rhs._l_cal), - _n_gcp(rhs._n_gcp), - _l_gcp(rhs._l_gcp), - _n_fac_data(rhs._n_fac_data), - _l_fac_data(rhs._l_fac_data) -{ -} - -FileDescriptor& FileDescriptor::operator=(const FileDescriptor& rhs) -{ - _ascii_flag = rhs._ascii_flag; - _format_doc = rhs._format_doc; - _format_ver = rhs._format_ver; - _design_rev = rhs._design_rev; - _software_id = rhs._software_id; - _file_num = rhs._file_num; - _file_name = rhs._file_name; - _rec_seq = rhs._rec_seq; - _seq_loc = rhs._seq_loc; - _seq_len = rhs._seq_len; - _rec_code = rhs._rec_code; - _code_loc = rhs._code_loc; - _code_len = rhs._code_len; - _rec_len = rhs._rec_len; - _rlen_loc = rhs._rlen_loc; - _rlen_len = rhs._rlen_len; - _n_dataset = rhs._n_dataset; - _l_dataset = rhs._l_dataset; - _n_map_proj = rhs._n_map_proj; - _l_map_proj = rhs._l_map_proj; - _n_plat_pos = rhs._n_plat_pos; - _l_plat_pos = rhs._l_plat_pos; - _n_att_data = rhs._n_att_data; - _l_att_data = rhs._l_att_data; - _n_radi_data = rhs._n_radi_data; - _l_radi_data = rhs._l_radi_data; - _n_radi_comp = rhs._n_radi_comp; - _l_radi_comp = rhs._l_radi_comp; - _n_qual_sum = rhs._n_qual_sum ; - _l_qual_sum = rhs._l_qual_sum; - _n_data_his = rhs._n_data_his; - _l_data_his = rhs._l_data_his; - _n_rang_spec = rhs._n_rang_spec; - _l_rang_spec = rhs._l_rang_spec; - _n_dem_desc = rhs._n_dem_desc; - _l_dem_desc = rhs._l_dem_desc; - _n_radar_par = rhs._n_radar_par; - _l_radar_par = rhs._l_radar_par; - _n_anno_data = rhs._n_anno_data; - _l_anno_data = rhs._l_anno_data; - _n_det_proc = rhs._n_det_proc; - _l_det_proc = rhs._l_det_proc; - _n_cal = rhs._n_cal; - _l_cal = rhs._l_cal; - _n_gcp = rhs._n_gcp; - _l_gcp = rhs._l_gcp; - _n_fac_data = rhs._n_fac_data; - _l_fac_data = rhs._l_fac_data; - return *this; -} \ No newline at end of file diff --git a/Utilities/otbossim/src/ossim/imaging/RadarSat/Leader/Leader.cpp b/Utilities/otbossim/src/ossim/imaging/RadarSat/Leader/Leader.cpp deleted file mode 100644 index 674a26f7e0c2e6882b3899c151288299a999ad06..0000000000000000000000000000000000000000 --- a/Utilities/otbossim/src/ossim/imaging/RadarSat/Leader/Leader.cpp +++ /dev/null @@ -1,165 +0,0 @@ -#include <ossim/imaging/RadarSat/Leader/Leader.h> -#include <ossim/imaging/RadarSat/Leader/LeaderFactory.h> -#include <ossim/imaging/RadarSat/RadarSatRecordHeader.h> - -#include <ossim/imaging/RadarSat/Leader/DataHistogramSignalData.h> -#include <ossim/imaging/RadarSat/Leader/DataQuality.h> -#include <ossim/imaging/RadarSat/Leader/DataSetSummary.h> -#include <ossim/imaging/RadarSat/Leader/FileDescriptor.h> -#include <ossim/imaging/RadarSat/Leader/DataHistogramProcessedData.h> -#include <ossim/imaging/RadarSat/Leader/ProcessingParameters.h> -#include <ossim/imaging/RadarSat/Leader/PlatformPositionData.h> -#include <ossim/imaging/RadarSat/Leader/AttitudeData.h> -#include <ossim/imaging/RadarSat/Leader/RadiometricData.h> -#include <ossim/imaging/RadarSat/Leader/RadiometricCompensationData.h> - -const int Leader::RadiometricDataID = 9; -const int Leader::RadiometricCompensationDataID = 10; -const int Leader::AttitudeDataID = 8; -const int Leader::PlatformPositionDataID = 7; -const int Leader::ProcessingParametersID = 6; -const int Leader::DataHistogramProcessedDataID = 5; -const int Leader::DataHistogramSignalDataID = 4; -const int Leader::DataQualityID = 3; -const int Leader::DataSetSummaryID = 2; -const int Leader::FileDescriptorID = 1; - -Leader::Leader() -{ -} - -Leader::~Leader() -{ - ClearRecords(); -} - -std::ostream& operator<<(std::ostream& os, const Leader& data) -{ - std::map<int, RadarSatRecord*>::const_iterator it = data._records.begin(); - while(it != data._records.end()) - { - (*it).second->Write(os); - ++it; - } - return os; - -} - -std::istream& operator>>(std::istream& is, Leader& data) -{ - LeaderFactory factory; - - data.ClearRecords(); - - RadarSatRecordHeader header; - bool eof = false; - while(!eof) - { - is>>header; - if(is.eof()) - { - eof = true; - } - else - { - RadarSatRecord* record = factory.Instanciate(header.get_rec_seq()); - if (record != NULL) - { - record->Read(is); - data._records[header.get_rec_seq()] = record; - } - else - { - char* buff = new char[header.get_length()-12]; - is.read(buff, header.get_length()-12); - delete buff; - } - } - } - return is; -} - - -Leader::Leader(const Leader& rhs) -{ - std::map<int, RadarSatRecord*>::const_iterator it = rhs._records.begin(); - while(it != rhs._records.end()) - { - _records[(*it).first] = (*it).second->Clone(); - ++it; - } -} - -Leader& Leader::operator=(const Leader& rhs) -{ - ClearRecords(); - std::map<int, RadarSatRecord*>::const_iterator it = rhs._records.begin(); - while(it != rhs._records.end()) - { - _records[(*it).first] = (*it).second->Clone(); - ++it; - } - - return *this; -} - -void Leader::ClearRecords() -{ - std::map<int, RadarSatRecord*>::const_iterator it = _records.begin(); - while(it != _records.end()) - { - delete (*it).second; - ++it; - } - _records.clear(); -} - -RadiometricData * Leader::get_RadiometricData() -{ - return (RadiometricData*)_records[RadiometricDataID]; -} - -RadiometricCompensationData * Leader::get_RadiometricCompensationData() -{ - return (RadiometricCompensationData*)_records[RadiometricCompensationDataID]; -} - -AttitudeData * Leader::get_AttitudeData() -{ - return (AttitudeData*)_records[AttitudeDataID]; -} - -PlatformPositionData * Leader::get_PlatformPositionData() -{ - return (PlatformPositionData*)_records[PlatformPositionDataID]; -} - -ProcessingParameters * Leader::get_ProcessingParameters() -{ - return (ProcessingParameters*)_records[ProcessingParametersID]; -} - -DataHistogramProcessedData * Leader::get_DataHistogramProcessedData() -{ - return (DataHistogramProcessedData*)_records[DataHistogramProcessedDataID]; -} - -DataHistogramSignalData * Leader::get_DataHistogramSignalData() -{ - return (DataHistogramSignalData*)_records[DataHistogramSignalDataID]; -} - -DataQuality * Leader::get_DataQuality() -{ - return (DataQuality*)_records[DataQualityID]; -} - -DataSetSummary * Leader::get_DataSetSummary() -{ - return (DataSetSummary*)_records[DataSetSummaryID]; -} - -FileDescriptor * Leader::get_FileDescriptor() -{ - return (FileDescriptor*)_records[FileDescriptorID]; -} diff --git a/Utilities/otbossim/src/ossim/imaging/RadarSat/Leader/LeaderFactory.cpp b/Utilities/otbossim/src/ossim/imaging/RadarSat/Leader/LeaderFactory.cpp deleted file mode 100644 index e90893d668a7643e9cfd48a149d9fef9731ad718..0000000000000000000000000000000000000000 --- a/Utilities/otbossim/src/ossim/imaging/RadarSat/Leader/LeaderFactory.cpp +++ /dev/null @@ -1,31 +0,0 @@ -#include <ossim/imaging/RadarSat/Leader/LeaderFactory.h> - -#include <ossim/imaging/RadarSat/Leader/DataHistogramSignalData.h> -#include <ossim/imaging/RadarSat/Leader/DataQuality.h> -#include <ossim/imaging/RadarSat/Leader/DataSetSummary.h> -#include <ossim/imaging/RadarSat/Leader/FileDescriptor.h> -#include <ossim/imaging/RadarSat/Leader/DataHistogramProcessedData.h> -#include <ossim/imaging/RadarSat/Leader/ProcessingParameters.h> -#include <ossim/imaging/RadarSat/Leader/PlatformPositionData.h> -#include <ossim/imaging/RadarSat/Leader/AttitudeData.h> -#include <ossim/imaging/RadarSat/Leader/RadiometricData.h> -#include <ossim/imaging/RadarSat/Leader/RadiometricCompensationData.h> - -LeaderFactory::LeaderFactory() -{ - RegisterRecord(9, new RadiometricData()); - RegisterRecord(10, new RadiometricCompensationData()); - RegisterRecord(8, new AttitudeData()); - RegisterRecord(7, new PlatformPositionData()); - RegisterRecord(6, new ProcessingParameters()); - RegisterRecord(5, new DataHistogramProcessedData()); - RegisterRecord(4, new DataHistogramSignalData()); - RegisterRecord(3, new DataQuality()); - RegisterRecord(2, new DataSetSummary()); - RegisterRecord(1, new FileDescriptor()); -} - -LeaderFactory::~LeaderFactory() -{ - -} \ No newline at end of file diff --git a/Utilities/otbossim/src/ossim/imaging/RadarSat/Leader/MisregistrationRecord.cpp b/Utilities/otbossim/src/ossim/imaging/RadarSat/Leader/MisregistrationRecord.cpp deleted file mode 100644 index 9a45e575cf0698329e5850ad4f89b48a8a86abd6..0000000000000000000000000000000000000000 --- a/Utilities/otbossim/src/ossim/imaging/RadarSat/Leader/MisregistrationRecord.cpp +++ /dev/null @@ -1,43 +0,0 @@ -#include <ossim/imaging/RadarSat/Leader/MisregistrationRecord.h> - - -MisregistrationRecord::MisregistrationRecord() -{ -} - -MisregistrationRecord::~MisregistrationRecord() -{ -} - -std::ostream& operator<<(std::ostream& os, const MisregistrationRecord& data) -{ - os<<"alt_m:"<<data._alt_m<<std::endl; - os<<"crt_m:"<<data._crt_m<<std::endl; - return os; -} - -std::istream& operator>>(std::istream& is, MisregistrationRecord& data) -{ - char buf16[17]; - buf16[16] = '\0'; - - is.read(buf16,16); - data._alt_m = atof(buf16); - - is.read(buf16,16); - data._crt_m = atof(buf16); - return is; -} - -MisregistrationRecord::MisregistrationRecord(const MisregistrationRecord& rhs): - _alt_m(rhs._alt_m), - _crt_m(rhs._crt_m) -{ -} - -MisregistrationRecord& MisregistrationRecord::operator=(const MisregistrationRecord& rhs) -{ - _alt_m = rhs._alt_m; - _crt_m = rhs._crt_m; - return *this; -} \ No newline at end of file diff --git a/Utilities/otbossim/src/ossim/imaging/RadarSat/Leader/PlatformPositionData.cpp b/Utilities/otbossim/src/ossim/imaging/RadarSat/Leader/PlatformPositionData.cpp deleted file mode 100644 index 3706148edade9fa52d9923f56374547ec38f1796..0000000000000000000000000000000000000000 --- a/Utilities/otbossim/src/ossim/imaging/RadarSat/Leader/PlatformPositionData.cpp +++ /dev/null @@ -1,238 +0,0 @@ -#include <ossim/imaging/RadarSat/Leader/PlatformPositionData.h> - - -PlatformPositionData::PlatformPositionData() : RadarSatRecord("pos_data_rec") -{ -} - -PlatformPositionData::~PlatformPositionData() -{ -} - -std::ostream& operator<<(std::ostream& os, const PlatformPositionData& data) -{ - os<<"orbit_ele_desg:"<<data._orbit_ele_desg.c_str()<<std::endl; - - for(int i=0;i<6;i++) - { - os<<"orbit_ele["<<i<<"]:"<<data._orbit_ele[i]<<std::endl; - } - - os<<"ndata:"<<data._ndata<<std::endl; - - os<<"year:"<<data._year<<std::endl; - - os<<"month:"<<data._month<<std::endl; - - os<<"day:"<<data._day<<std::endl; - - os<<"gmt_day:"<<data._gmt_day<<std::endl; - - os<<"gmt_sec:"<<data._gmt_sec<<std::endl; - - os<<"data_int:"<<data._data_int<<std::endl; - - os<<"ref_coord:"<<data._ref_coord.c_str()<<std::endl; - - os<<"hr_angle:"<<data._hr_angle<<std::endl; - - os<<"alt_poserr:"<<data._alt_poserr<<std::endl; - - os<<"crt_poserr:"<<data._crt_poserr<<std::endl; - - os<<"rad_poserr:"<<data._rad_poserr<<std::endl; - - os<<"alt_velerr:"<<data._alt_velerr<<std::endl; - - os<<"crt_velerr:"<<data._crt_velerr<<std::endl; - - os<<"rad_velerr:"<<data._rad_velerr<<std::endl; - - for (int i=0;i<64;i++) - { - os<<"pos_vect["<<i<<"]:"<<data._pos_vect[i]<<std::endl; - } - - return os; -} - -std::istream& operator>>(std::istream& is, PlatformPositionData& data) -{ - char buf[1207]; - buf[1206] = '\0'; - - is.read(buf,32); - buf[32] = '\0'; - data._orbit_ele_desg = buf; - - for(int i=0;i<6;i++) - { - is.read(buf,16); - buf[16] = '\0'; - data._orbit_ele[i] = atof(buf); - } - - is.read(buf,4); - buf[4] = '\0'; - data._ndata = atoi(buf); - - is.read(buf,4); - buf[4] = '\0'; - data._year = atoi(buf); - - is.read(buf,4); - buf[4] = '\0'; - data._month = atoi(buf); - - is.read(buf,4); - buf[4] = '\0'; - data._day = atoi(buf); - - is.read(buf,4); - buf[4] = '\0'; - data._gmt_day = atoi(buf); - - is.read(buf,22); - buf[22] = '\0'; - data._gmt_sec = atof(buf); - - is.read(buf,22); - buf[22] = '\0'; - data._data_int = atof(buf); - - is.read(buf,64); - buf[64] = '\0'; - data._ref_coord = buf; - - is.read(buf,22); - buf[22] = '\0'; - data._hr_angle = atof(buf); - - is.read(buf,16); - buf[16] = '\0'; - data._alt_poserr = atof(buf); - - is.read(buf,16); - buf[16] = '\0'; - data._crt_poserr = atof(buf); - - is.read(buf,16); - buf[16] = '\0'; - data._rad_poserr = atof(buf); - - is.read(buf,16); - buf[16] = '\0'; - data._alt_velerr = atof(buf); - - is.read(buf,16); - buf[16] = '\0'; - data._crt_velerr = atof(buf); - - is.read(buf,16); - buf[16] = '\0'; - data._rad_velerr = atof(buf); - - for (int i=0;i<64;i++) - { - is>>data._pos_vect[i]; - } - - is.read(buf,126); - - - return is; -} - -PlatformPositionData::PlatformPositionData(const PlatformPositionData& rhs): - RadarSatRecord(rhs) -{ - _orbit_ele_desg = rhs._orbit_ele_desg; - - for(int i=0;i<6;i++) - { - _orbit_ele[i] = rhs._orbit_ele[i]; - } - - _ndata = rhs._ndata; - - _year = rhs._year; - - _month = rhs._month; - - _day = rhs._day; - - _gmt_day = rhs._gmt_day; - - _gmt_sec = rhs._gmt_sec; - - _data_int = rhs._data_int; - - _ref_coord = rhs._ref_coord; - - _hr_angle = rhs._hr_angle; - - _alt_poserr = rhs._alt_poserr; - - _crt_poserr = rhs._crt_poserr; - - _rad_poserr = rhs._rad_poserr; - - _alt_velerr = rhs._alt_velerr; - - _crt_velerr = rhs._crt_velerr; - - _rad_velerr = rhs._rad_velerr; - - for (int i=0;i<64;i++) - { - _pos_vect[i] = rhs._pos_vect[i]; - } - -} - -PlatformPositionData& PlatformPositionData::operator=(const PlatformPositionData& rhs) -{ - _orbit_ele_desg = rhs._orbit_ele_desg; - - for(int i=0;i<6;i++) - { - _orbit_ele[i] = rhs._orbit_ele[i]; - } - - _ndata = rhs._ndata; - - _year = rhs._year; - - _month = rhs._month; - - _day = rhs._day; - - _gmt_day = rhs._gmt_day; - - _gmt_sec = rhs._gmt_sec; - - _data_int = rhs._data_int; - - _ref_coord = rhs._ref_coord; - - _hr_angle = rhs._hr_angle; - - _alt_poserr = rhs._alt_poserr; - - _crt_poserr = rhs._crt_poserr; - - _rad_poserr = rhs._rad_poserr; - - _alt_velerr = rhs._alt_velerr; - - _crt_velerr = rhs._crt_velerr; - - _rad_velerr = rhs._rad_velerr; - - for (int i=0;i<64;i++) - { - _pos_vect[i] = rhs._pos_vect[i]; - } - - return *this; -} \ No newline at end of file diff --git a/Utilities/otbossim/src/ossim/imaging/RadarSat/Leader/PositionVectorRecord.cpp b/Utilities/otbossim/src/ossim/imaging/RadarSat/Leader/PositionVectorRecord.cpp deleted file mode 100644 index a042e47cd428e7b9a970c2ef9d99036d218d0fa1..0000000000000000000000000000000000000000 --- a/Utilities/otbossim/src/ossim/imaging/RadarSat/Leader/PositionVectorRecord.cpp +++ /dev/null @@ -1,70 +0,0 @@ -#include <ossim/imaging/RadarSat/Leader/PositionVectorRecord.h> - - -PositionVectorRecord::PositionVectorRecord() -{ -} - -PositionVectorRecord::~PositionVectorRecord() -{ -} - -std::ostream& operator<<(std::ostream& os, const PositionVectorRecord& data) -{ - for (int i=0;i<3;i++) - { - os<<"pos["<<i<<"]:"<<data._pos[i]<<std::endl; - } - - for (int i=0;i<3;i++) - { - os<<"vel["<<i<<"]:"<<data._vel[i]<<std::endl; - } - return os; -} - -std::istream& operator>>(std::istream& is, PositionVectorRecord& data) -{ - char buf[23]; - buf[22] = '\0'; - - for (int i=0;i<3;i++) - { - is.read(buf,22); - data._pos[i] = atof(buf); - } - - for (int i=0;i<3;i++) - { - is.read(buf,22); - data._vel[i] = atof(buf); - } - return is; -} - -PositionVectorRecord::PositionVectorRecord(const PositionVectorRecord& rhs) -{ - for (int i=0;i<3;i++) - { - _pos[i] = rhs._pos[i]; - } - - for (int i=0;i<3;i++) - { - _vel[i] = rhs._vel[i]; - } -} - -PositionVectorRecord& PositionVectorRecord::operator=(const PositionVectorRecord& rhs) -{ - for (int i=0;i<3;i++) - { - _pos[i] = rhs._pos[i]; - } - - for (int i=0;i<3;i++) - { - _vel[i] = rhs._vel[i]; - } - return *this; -} \ No newline at end of file diff --git a/Utilities/otbossim/src/ossim/imaging/RadarSat/Leader/ProcessingParameters.cpp b/Utilities/otbossim/src/ossim/imaging/RadarSat/Leader/ProcessingParameters.cpp deleted file mode 100644 index c5665da2b9a9da44176a2ee3422fdf659068885f..0000000000000000000000000000000000000000 --- a/Utilities/otbossim/src/ossim/imaging/RadarSat/Leader/ProcessingParameters.cpp +++ /dev/null @@ -1,888 +0,0 @@ -#include <ossim/imaging/RadarSat/Leader/ProcessingParameters.h> - - -ProcessingParameters::ProcessingParameters() : RadarSatRecord("proc_param_rec") -{ -} - -ProcessingParameters::~ProcessingParameters() -{ -} - -std::ostream& operator<<(std::ostream& os, const ProcessingParameters& data) -{ - os<<"rec_seq:"<<data._rec_seq<<std::endl; - - os<<"inp_media:"<<data._inp_media.c_str()<<std::endl; - - os<<"n_tape_id:"<<data._n_tape_id<<std::endl; - - for (int i=0;i<10;i++) - { - os<<"tape_id["<<i<<"]:"<<data._tape_id[i].c_str()<<std::endl; - } - - os<<"exp_ing_start:"<<data._exp_ing_start.c_str()<<std::endl; - - os<<"exp_ing_stop:"<<data._exp_ing_stop.c_str()<<std::endl; - - os<<"act_ing_start:"<<data._act_ing_start.c_str()<<std::endl; - - os<<"act_ing_stop:"<<data._act_ing_stop.c_str()<<std::endl; - - os<<"proc_start:"<<data._proc_start.c_str()<<std::endl; - - os<<"proc_stop:"<<data._proc_stop.c_str()<<std::endl; - - for (int i=0;i<10;i++) - { - os<<"mn_sig_lev["<<i<<"]:"<<data._mn_sig_lev[i]<<std::endl; - } - - os<<"scr_data_ind:"<<data._scr_data_ind<<std::endl; - - os<<"miss_ln:"<<data._miss_ln<<std::endl; - - os<<"rej_ln:"<<data._rej_ln<<std::endl; - - os<<"large_gap:"<<data._large_gap<<std::endl; - - os<<"bit_err_rate:"<<data._bit_err_rate<<std::endl; - - os<<"fm_crc_err:"<<data._fm_crc_err<<std::endl; - - os<<"date_incons:"<<data._date_incons<<std::endl; - - os<<"prf_changes:"<<data._prf_changes<<std::endl; - - os<<"delay_changes:"<<data._delay_changes<<std::endl; - - os<<"skipd_frams:"<<data._skipd_frams<<std::endl; - - os<<"rej_bf_start:"<<data._rej_bf_start<<std::endl; - - os<<"rej_few_fram:"<<data._rej_few_fram<<std::endl; - - os<<"rej_many_fram:"<<data._rej_many_fram<<std::endl; - - os<<"rej_mchn_err:"<<data._rej_mchn_err<<std::endl; - - os<<"rej_vchn_err:"<<data._rej_vchn_err<<std::endl; - - os<<"rej_rec_type:"<<data._rej_rec_type<<std::endl; - - os<<"sens_config:"<<data._sens_config.c_str()<<std::endl; - - os<<"sens_orient:"<<data._sens_orient.c_str()<<std::endl; - - os<<"sych_marker:"<<data._sych_marker.c_str()<<std::endl; - - os<<"rng_ref_src:"<<data._rng_ref_src.c_str()<<std::endl; - - for (int i=0;i<4;i++) - { - os<<"rng_amp_coef["<<i<<"]:"<<data._rng_amp_coef[i]<<std::endl; - } - - for (int i=0;i<4;i++) - { - os<<"rng_phas_coef["<<i<<"]:"<<data._rng_phas_coef[i]<<std::endl; - } - - for (int i=0;i<4;i++) - { - os<<"err_amp_coef["<<i<<"]:"<<data._err_amp_coef[i]<<std::endl; - } - - for (int i=0;i<4;i++) - { - os<<"err_phas_coef["<<i<<"]:"<<data._err_phas_coef[i]<<std::endl; - } - - os<<"pulse_bandw:"<<data._pulse_bandw<<std::endl; - - - os<<"adc_samp_rate:"<<data._adc_samp_rate.c_str()<<std::endl; - - os<<"rep_agc_attn:"<<data._rep_agc_attn<<std::endl; - - os<<"gn_corctn_fctr:"<<data._gn_corctn_fctr<<std::endl; - - os<<"rep_energy_gn:"<<data._rep_energy_gn<<std::endl; - - os<<"orb_data_src:"<<data._orb_data_src.c_str()<<std::endl; - - os<<"pulse_cnt_1:"<<data._pulse_cnt_1<<std::endl; - - os<<"pulse_cnt_2:"<<data._pulse_cnt_2<<std::endl; - - os<<"beam_edge_rqd:"<<data._beam_edge_rqd.c_str()<<std::endl; - - os<<"beam_edge_conf:"<<data._beam_edge_conf<<std::endl; - - os<<"pix_overlap:"<<data._pix_overlap<<std::endl; - - os<<"n_beams:"<<data._n_beams<<std::endl; - - for (int i=0;i<4;i++) - { - os<<"beam_info["<<i<<"]:"<<data._beam_info[i]<<std::endl; - } - - os<<"n_pix_updates:"<<data._n_pix_updates<<std::endl; - - for (int i=0;i<4;i++) - { - os<<"pix_count["<<i<<"]:"<<data._pix_count[i]<<std::endl; - } - - os<<"pwin_start:"<<data._pwin_start<<std::endl; - - os<<"pwin_end:"<<data._pwin_end<<std::endl; - - os<<"recd_type:"<<data._recd_type.c_str()<<std::endl; - - os<<"temp_set_inc:"<<data._temp_set_inc<<std::endl; - - os<<"n_temp_set:"<<data._n_temp_set<<std::endl; - - for (int i=0;i<20;i++) - { - os<<"temp["<<i<<"]:"<<data._temp[i]<<std::endl; - } - - os<<"n_image_pix:"<<data._n_image_pix<<std::endl; - - os<<"prc_zero_pix:"<<data._prc_zero_pix<<std::endl; - - os<<"prc_satur_pix:"<<data._prc_satur_pix<<std::endl; - - os<<"img_hist_mean:"<<data._img_hist_mean<<std::endl; - - for (int i=0;i<3;i++) - { - os<<"img_cumu_dist["<<i<<"]:"<<data._img_cumu_dist[i]<<std::endl; - } - - os<<"pre_img_gn:"<<data._pre_img_gn<<std::endl; - - os<<"post_img_gn:"<<data._post_img_gn<<std::endl; - - os<<"dopcen_inc:"<<data._dopcen_inc<<std::endl; - - os<<"n_dopcen:"<<data._n_dopcen<<std::endl; - - for (int i=0;i<20;i++) - { - os<<"dopcen_est["<<i<<"]:"<<data._dopcen_est[i]<<std::endl; - } - - os<<"dop_amb_err:"<<data._dop_amb_err<<std::endl; - - os<<"dopamb_conf:"<<data._dopamb_conf<<std::endl; - - for (int i=0;i<7;i++) - { - os<<"eph_orb_data["<<i<<"]:"<<data._eph_orb_data[i]<<std::endl; - } - - os<<"appl_type:"<<data._appl_type.c_str()<<std::endl; - - for (int i=0;i<5;i++) - { - os<<"slow_time_coef["<<i<<"]:"<<data._slow_time_coef[i]<<std::endl; - } - - os<<"n_srgr:"<<data._n_srgr<<std::endl; - - for (int i=0;i<20;i++) - { - os<<"srgr_coefset["<<i<<"]:"<<data._srgr_coefset[i]<<std::endl; - } - - os<<"pixel_spacing:"<<data._pixel_spacing<<std::endl; - - os<<"gics_reqd:"<<data._gics_reqd.c_str()<<std::endl; - - os<<"wo_number:"<<data._wo_number.c_str()<<std::endl; - - os<<"wo_date:"<<data._wo_date.c_str()<<std::endl; - - os<<"satellite_id:"<<data._satellite_id.c_str()<<std::endl; - - os<<"user_id:"<<data._user_id.c_str()<<std::endl; - - os<<"complete_msg:"<<data._complete_msg.c_str()<<std::endl; - - os<<"scene_id:"<<data._scene_id.c_str()<<std::endl; - - os<<"density_in:"<<data._density_in.c_str()<<std::endl; - - os<<"media_id:"<<data._media_id.c_str()<<std::endl; - - os<<"angle_first:"<<data._angle_first<<std::endl; - - os<<"angle_last:"<<data._angle_last<<std::endl; - - os<<"prod_type:"<<data._prod_type.c_str()<<std::endl; - - os<<"map_system:"<<data._map_system.c_str()<<std::endl; - - os<<"centre_lat:"<<data._centre_lat<<std::endl; - - os<<"centre_long:"<<data._centre_long<<std::endl; - - os<<"span_x:"<<data._span_x<<std::endl; - - os<<"span_y:"<<data._span_y<<std::endl; - - os<<"apply_dtm:"<<data._apply_dtm.c_str()<<std::endl; - - os<<"density_out:"<<data._density_out.c_str()<<std::endl; - - os<<"state_time:"<<data._state_time.c_str()<<std::endl; - - os<<"num_state_vectors:"<<data._num_state_vectors<<std::endl; - - os<<"state_time_inc:"<<data._state_time_inc<<std::endl; - - return os; -} - -std::istream& operator>>(std::istream& is, ProcessingParameters& data) -{ - char buf[2407]; - buf[2406] = '\0'; - - is.read(buf,4); - buf[4] = '\0'; - data._rec_seq = atoi(buf); - - is.read(buf,4); - buf[4] = '\0'; - - is.read(buf,3); - buf[3] = '\0'; - data._inp_media = buf; - - is.read(buf,4); - buf[4] = '\0'; - data._n_tape_id = atoi(buf); - - for (int i=0;i<10;i++) - { - is.read(buf,8); - buf[8] = '\0'; - data._tape_id[i] = buf; - } - - is.read(buf,21); - buf[21] = '\0'; - data._exp_ing_start = buf; - - is.read(buf,21); - buf[21] = '\0'; - data._exp_ing_stop = buf; - - is.read(buf,21); - buf[21] = '\0'; - data._act_ing_start = buf; - - is.read(buf,21); - buf[21] = '\0'; - data._act_ing_stop = buf; - - is.read(buf,21); - buf[21] = '\0'; - data._proc_start = buf; - - is.read(buf,21); - buf[21] = '\0'; - data._proc_stop = buf; - - for (int i=0;i<10;i++) - { - is.read(buf,16); - buf[16] = '\0'; - data._mn_sig_lev[i] = atof(buf); - } - - is.read(buf,4); - buf[4] = '\0'; - data._scr_data_ind = atoi(buf); - - is.read(buf,8); - buf[8] = '\0'; - data._miss_ln = atoi(buf); - - is.read(buf,8); - buf[8] = '\0'; - data._rej_ln = atoi(buf); - - is.read(buf,8); - buf[8] = '\0'; - data._large_gap = atoi(buf); - - is.read(buf,16); - buf[16] = '\0'; - data._bit_err_rate = atof(buf); - - is.read(buf,16); - buf[16] = '\0'; - data._fm_crc_err = atof(buf); - - is.read(buf,8); - buf[8] = '\0'; - data._date_incons = atoi(buf); - - is.read(buf,8); - buf[8] = '\0'; - data._prf_changes = atoi(buf); - - is.read(buf,8); - buf[8] = '\0'; - data._delay_changes = atoi(buf); - - is.read(buf,8); - buf[8] = '\0'; - data._skipd_frams = atoi(buf); - - is.read(buf,8); - buf[8] = '\0'; - data._rej_bf_start = atoi(buf); - - is.read(buf,8); - buf[8] = '\0'; - data._rej_few_fram = atoi(buf); - - is.read(buf,8); - buf[8] = '\0'; - data._rej_many_fram = atoi(buf); - - is.read(buf,8); - buf[8] = '\0'; - data._rej_mchn_err = atoi(buf); - - is.read(buf,8); - buf[8] = '\0'; - data._rej_vchn_err = atoi(buf); - - is.read(buf,8); - buf[8] = '\0'; - data._rej_rec_type = atoi(buf); - - is.read(buf,10); - buf[10] = '\0'; - data._sens_config = buf; - - is.read(buf,9); - buf[9] = '\0'; - data._sens_orient = buf; - - is.read(buf,8); - buf[8] = '\0'; - data._sych_marker = buf; - - is.read(buf,12); - buf[12] = '\0'; - data._rng_ref_src = buf; - - for (int i=0;i<4;i++) - { - is.read(buf,16); - buf[16] = '\0'; - data._rng_amp_coef[i] = atof(buf); - } - - for (int i=0;i<4;i++) - { - is.read(buf,16); - buf[16] = '\0'; - data._rng_phas_coef[i] = atof(buf); - } - - for (int i=0;i<4;i++) - { - is.read(buf,16); - buf[16] = '\0'; - data._err_amp_coef[i] = atof(buf); - } - - for (int i=0;i<4;i++) - { - is.read(buf,16); - buf[16] = '\0'; - data._err_phas_coef[i] = atof(buf); - } - - is.read(buf,4); - buf[4] = '\0'; - data._pulse_bandw = atoi(buf); - - - is.read(buf,5); - buf[5] = '\0'; - data._adc_samp_rate = buf; - - is.read(buf,16); - buf[16] = '\0'; - data._rep_agc_attn = atof(buf); - - is.read(buf,16); - buf[16] = '\0'; - data._gn_corctn_fctr = atof(buf); - - is.read(buf,16); - buf[16] = '\0'; - data._rep_energy_gn = atof(buf); - - is.read(buf,11); - buf[11] = '\0'; - data._orb_data_src = buf; - - is.read(buf,4); - buf[4] = '\0'; - data._pulse_cnt_1 = atoi(buf); - - is.read(buf,4); - buf[4] = '\0'; - data._pulse_cnt_2 = atoi(buf); - - is.read(buf,3); - buf[3] = '\0'; - data._beam_edge_rqd = buf; - - is.read(buf,16); - buf[16] = '\0'; - data._beam_edge_conf = atof(buf); - - is.read(buf,4); - buf[4] = '\0'; - data._pix_overlap = atoi(buf); - - is.read(buf,4); - buf[4] = '\0'; - data._n_beams = atoi(buf); - - for (int i=0;i<4;i++) - { - is>>data._beam_info[i]; - } - - is.read(buf,4); - buf[4] = '\0'; - data._n_pix_updates = atoi(buf); - - for (int i=0;i<20;i++) - { - is>>data._pix_count[i]; - } - - is.read(buf,16); - buf[16] = '\0'; - data._pwin_start = atof(buf); - - is.read(buf,16); - buf[16] = '\0'; - data._pwin_end = atof(buf); - - is.read(buf,9); - buf[9] = '\0'; - data._recd_type = buf; - - is.read(buf,16); - buf[16] = '\0'; - data._temp_set_inc = atof(buf); - - is.read(buf,4); - buf[4] = '\0'; - data._n_temp_set = atoi(buf); - - for (int i=0;i<20;i++) - { - is>>data._temp[i]; - } - - is.read(buf,8); - buf[8] = '\0'; - data._n_image_pix = atoi(buf); - - is.read(buf,16); - buf[16] = '\0'; - data._prc_zero_pix = atof(buf); - - is.read(buf,16); - buf[16] = '\0'; - data._prc_satur_pix = atof(buf); - - is.read(buf,16); - buf[16] = '\0'; - data._img_hist_mean = atof(buf); - - for (int i=0;i<3;i++) - { - is.read(buf,16); - buf[16] = '\0'; - data._img_cumu_dist[i] = atof(buf); - } - - is.read(buf,16); - buf[16] = '\0'; - data._pre_img_gn = atof(buf); - - is.read(buf,16); - buf[16] = '\0'; - data._post_img_gn = atof(buf); - - is.read(buf,16); - buf[16] = '\0'; - data._dopcen_inc = atof(buf); - - is.read(buf,4); - buf[4] = '\0'; - data._n_dopcen = atoi(buf); - - for (int i=0;i<20;i++) - { - is>>data._dopcen_est[i]; - } - - is.read(buf,4); - buf[4] = '\0'; - data._dop_amb_err = atoi(buf); - - is.read(buf,16); - buf[16] = '\0'; - data._dopamb_conf = atof(buf); - - for (int i=0;i<7;i++) - { - is.read(buf,16); - buf[16] = '\0'; - data._eph_orb_data[i] = atof(buf); - } - - is.read(buf,12); - buf[12] = '\0'; - data._appl_type = buf; - - for (int i=0;i<5;i++) - { - is.read(buf,22); - buf[22] = '\0'; - data._slow_time_coef[i] = atof(buf); - } - - is.read(buf,4); - buf[4] = '\0'; - data._n_srgr = atoi(buf); - - for (int i=0;i<20;i++) - { - is>>data._srgr_coefset[i]; - } - - is.read(buf,16); - buf[16] = '\0'; - data._pixel_spacing = atof(buf); - - is.read(buf,3); - buf[3] = '\0'; - data._gics_reqd = buf; - - is.read(buf,8); - buf[8] = '\0'; - data._wo_number = buf; - - is.read(buf,20); - buf[20] = '\0'; - data._wo_date = buf; - - is.read(buf,10); - buf[10] = '\0'; - data._satellite_id = buf; - - is.read(buf,20); - buf[20] = '\0'; - data._user_id = buf; - - is.read(buf,3); - buf[3] = '\0'; - data._complete_msg = buf; - - is.read(buf,15); - buf[15] = '\0'; - data._scene_id = buf; - - is.read(buf,4); - buf[4] = '\0'; - data._density_in = buf; - - is.read(buf,8); - buf[8] = '\0'; - data._media_id = buf; - - is.read(buf,16); - buf[16] = '\0'; - data._angle_first = atof(buf); - - is.read(buf,16); - buf[16] = '\0'; - data._angle_last = atof(buf); - - is.read(buf,3); - buf[3] = '\0'; - data._prod_type = buf; - - is.read(buf,16); - buf[16] = '\0'; - data._map_system = buf; - - is.read(buf,22); - buf[22] = '\0'; - data._centre_lat = atof(buf); - - is.read(buf,22); - buf[22] = '\0'; - data._centre_long = atof(buf); - - is.read(buf,22); - buf[22] = '\0'; - data._span_x = atof(buf); - - is.read(buf,22); - buf[22] = '\0'; - data._span_y = atof(buf); - - is.read(buf,3); - buf[3] = '\0'; - data._apply_dtm = buf; - - is.read(buf,4); - buf[4] = '\0'; - data._density_out = buf; - - is.read(buf,21); - buf[21] = '\0'; - data._state_time = buf; - - is.read(buf,4); - buf[4] = '\0'; - data._num_state_vectors = atoi(buf); - - is.read(buf,16); - buf[16] = '\0'; - data._state_time_inc = atof(buf); - - is.read(buf,206); - buf[206] = '\0'; - - return is; -} - -ProcessingParameters::ProcessingParameters(const ProcessingParameters& rhs): - RadarSatRecord(rhs) -{ - -} - -ProcessingParameters& ProcessingParameters::operator=(const ProcessingParameters& rhs) -{ - /* - int _rec_seq - - std::string _spare1 - - std::string _inp_media - - int _n_tape_id - - std::string _tape_id - - std::string _exp_ing_start - - std::string _exp_ing_stop - - std::string _act_ing_start - - std::string _act_ing_stop - - std::string _proc_start - - std::string _proc_stop - - double* _mn_sig_lev - - int _scr_data_ind - - int _miss_ln - - int _rej_ln - - int _large_gap - - double _bit_err_rate - - double _fm_crc_err - - int _date_incons - - int _prf_changes - - int _delay_changes - - int _skipd_frams - - int _rej_bf_start - - int _rej_few_fram - - int _rej_many_fram - - int _rej_mchn_err - - int _rej_vchn_err - - int _rej_rec_type - - std::string _sens_config - - std::string _sens_orient - - int _sych_marker - - std::string _rng_ref_src - - double* _rng_amp_coef - - double* _rng_phas_coef - - double* _err_amp_coef - - double* _err_phas_coef - - int _pulse_bandw - - int _adc_samp_rate - - double _rep_agc_attn - - double _gn_corctn_fctr - - double _rep_energy_gn - - std::string _orb_data_src - - int _pulse_cnt_1 - - int _pulse_cnt_2 - - std::string _beam_edge_rqd - - double _beam_edge_conf - - int _pix_overlap - - int _n_beams - - BeamInformationRecord* _beam_info - - int _n_pix_updates - - BeamPixelCountRecord* _pix_count - - double _pwin_start - - double _pwin_end - - std::string _recd_type - - double _temp_set_inc - - int* _n_temp_set - - TemperatureSettingsRecord* _temp - - int _n_image_pix - - double _prc_zero_pix - - double _prc_satur_pix - - double _img_hist_mean - - double* _img_cumu_dist - - double _pre_img_gn - - double _post_img_gn - - double _dopcen_inc - - int _n_dopcen - - DopplerCentroidEstimateRecord* _dopcen_est - - int _dop_amb_err - - double _dopamb_conf - - double* _eph_orb_data - - std::string _appl_type - - double* _slow_time_coef - - int _n_srgr - - SRGRCoefficientSetRecord* _srgr_coefset - - double _pixel_spacing - - std::string _gics_reqd - - std::string _wo_number - - std::string _wo_date - - std::string _satellite_id - - std::string _user_id - - std::string _complete_msg - - std::string _scene_id - - std::string _density_in - - std::string _media_id - - double _angle_first - - double _angle_last - - std::string _prod_type - - std::string _map_system - - double _centre_lat - - double _centre_long - - double _span_x - - double _span_y - - std::string _apply_dtm - - std::string _density_out - - std::string _state_time - - int _num_state_vectors - - double _state_time_inc - - std::string _spare2*/ - return *this; -} \ No newline at end of file diff --git a/Utilities/otbossim/src/ossim/imaging/RadarSat/Leader/RadiometricCompensationData.cpp b/Utilities/otbossim/src/ossim/imaging/RadarSat/Leader/RadiometricCompensationData.cpp deleted file mode 100644 index 25ba0bd891d90e5a7d29d39e8f05d74ca3aee219..0000000000000000000000000000000000000000 --- a/Utilities/otbossim/src/ossim/imaging/RadarSat/Leader/RadiometricCompensationData.cpp +++ /dev/null @@ -1,78 +0,0 @@ -#include <ossim/imaging/RadarSat/Leader/RadiometricCompensationData.h> - - -RadiometricCompensationData::RadiometricCompensationData() : RadarSatRecord("radi_comp_rec") -{ -} - -RadiometricCompensationData::~RadiometricCompensationData() -{ -} - -std::ostream& operator<<(std::ostream& os, const RadiometricCompensationData& data) -{ - os<<"seq_num:"<<data._seq_num<<std::endl; - - os<<"chan_ind:"<<data._chan_ind<<std::endl; - - os<<"n_dset:"<<data._n_dset<<std::endl; - - os<<"dset_size:"<<data._dset_size<<std::endl; - - for (int i=0;i<4;i++) - { - os<<"dset["<<i<<"]:"<<data._dset[i]<<std::endl; - } - return os; -} - -std::istream& operator>>(std::istream& is, RadiometricCompensationData& data) -{ - char buf[9]; - buf[8] = '\0'; - - is.read(buf,4); - buf[4] = '\0'; - data._seq_num = atoi(buf); - - is.read(buf,4); - buf[4] = '\0'; - data._chan_ind = atoi(buf); - - is.read(buf,8); - buf[8] = '\0'; - data._n_dset = atoi(buf); - - is.read(buf,8); - buf[8] = '\0'; - data._dset_size = atoi(buf); - - for (int i=0;i<4;i++) - { - is>> data._dset[i]; - } - - return is; -} - -RadiometricCompensationData::RadiometricCompensationData(const RadiometricCompensationData& rhs): - RadarSatRecord(rhs) -{ - _seq_num = rhs._seq_num; - - _chan_ind = rhs._chan_ind; - - _n_dset = rhs._n_dset; - - _dset_size = rhs._dset_size; - - for (int i=0;i<4;i++) - { - _dset[i] = rhs._dset[i]; - } -} - -RadiometricCompensationData& RadiometricCompensationData::operator=(const RadiometricCompensationData& rhs) -{ - return *this; -} \ No newline at end of file diff --git a/Utilities/otbossim/src/ossim/imaging/RadarSat/Leader/RadiometricData.cpp b/Utilities/otbossim/src/ossim/imaging/RadarSat/Leader/RadiometricData.cpp deleted file mode 100644 index 478e0ac7f3a791c80768f9b2379fc7735c772031..0000000000000000000000000000000000000000 --- a/Utilities/otbossim/src/ossim/imaging/RadarSat/Leader/RadiometricData.cpp +++ /dev/null @@ -1,174 +0,0 @@ -#include <ossim/imaging/RadarSat/Leader/RadiometricData.h> - - -RadiometricData::RadiometricData() : RadarSatRecord("radi_data_rec") -{ -} - -RadiometricData::~RadiometricData() -{ -} - -std::ostream& operator<<(std::ostream& os, const RadiometricData& data) -{ - os<<"seq_num:"<<data._seq_num<<std::endl; - - os<<"n_data:"<<data._n_data<<std::endl; - - os<<"field_size:"<<data._field_size<<std::endl; - - os<<"chan_ind:"<<data._chan_ind.c_str()<<std::endl; - - os<<"table_desig:"<<data._table_desig.c_str()<<std::endl; - - os<<"n_samp:"<<data._n_samp<<std::endl; - - os<<"samp_type:"<<data._samp_type.c_str()<<std::endl; - - os<<"samp_inc:"<<data._samp_inc<<std::endl; - - for (int i=0;i<512;i++) - { - os<<"lookup_tab["<<i<<"]:"<<data._lookup_tab[i]<<std::endl; - } - - os<<"noise_scale:"<<data._noise_scale<<std::endl; - - os<<"offset:"<<data._offset<<std::endl; - - os<<"calib_const:"<<data._calib_const<<std::endl; - - return os; -} - -std::istream& operator>>(std::istream& is, RadiometricData& data) -{ - char buf[1513]; - buf[1512] = '\0'; - - - is.read(buf,4); - buf[4] = '\0'; - data._seq_num = atoi(buf); - - is.read(buf,4); - buf[4] = '\0'; - data._n_data = atoi(buf); - - is.read(buf,8); - buf[8] = '\0'; - data._field_size = atoi(buf); - - is.read(buf,4); - buf[4] = '\0'; - data._chan_ind = buf; - - is.read(buf,4); - - is.read(buf,24); - buf[24] = '\0'; - data._table_desig = buf; - - is.read(buf,8); - buf[8] = '\0'; - data._n_samp = atoi(buf); - - is.read(buf,16); - buf[16] = '\0'; - data._samp_type = buf; - - is.read(buf,4); - buf[4] = '\0'; - data._samp_inc = atoi(buf); - - for (int i=0;i<512;i++) - { - is.read(buf,16); - buf[16] = '\0'; - data._lookup_tab[i] = atof(buf); - } - - is.read(buf,4); - - is.read(buf,16); - buf[16] = '\0'; - data._noise_scale = atof(buf); - - is.read(buf,16); - - is.read(buf,16); - buf[16] = '\0'; - data._offset = atof(buf); - - is.read(buf,16); - buf[16] = '\0'; - data._calib_const = atof(buf); - - is.read(buf,1512); - - return is; -} - -RadiometricData::RadiometricData(const RadiometricData& rhs): - RadarSatRecord(rhs) -{ - - _seq_num = rhs._seq_num; - - _n_data = rhs._n_data; - - _field_size = rhs._field_size; - - _chan_ind = rhs._chan_ind; - - _table_desig = rhs._table_desig; - - _n_samp = rhs._n_samp; - - _samp_type = rhs._samp_type; - - _samp_inc = rhs._samp_inc; - - for (int i=0;i<512;i++) - { - _lookup_tab[i] = rhs._lookup_tab[i]; - } - - _noise_scale = rhs._noise_scale; - - _offset = rhs._offset; - - _calib_const = rhs._calib_const; -} - -RadiometricData& RadiometricData::operator=(const RadiometricData& rhs) -{ - _seq_num = rhs._seq_num; - - _n_data = rhs._n_data; - - _field_size = _field_size; - - _chan_ind = rhs._chan_ind; - - _table_desig = rhs._table_desig; - - _n_samp = rhs._n_samp; - - _samp_type = rhs._samp_type; - - _samp_inc = rhs._samp_inc; - - for (int i=0;i<512;i++) - { - _lookup_tab[i] = rhs._lookup_tab[i]; - } - - _noise_scale = rhs._noise_scale; - - _offset = rhs._offset; - - _calib_const = rhs._calib_const; - - return *this; -} \ No newline at end of file diff --git a/Utilities/otbossim/src/ossim/imaging/RadarSat/Leader/RadiometryUncertaintyRecord.cpp b/Utilities/otbossim/src/ossim/imaging/RadarSat/Leader/RadiometryUncertaintyRecord.cpp deleted file mode 100644 index 3fa6f60add62c71842e089f496eff00ecbf52f3d..0000000000000000000000000000000000000000 --- a/Utilities/otbossim/src/ossim/imaging/RadarSat/Leader/RadiometryUncertaintyRecord.cpp +++ /dev/null @@ -1,43 +0,0 @@ -#include <ossim/imaging/RadarSat/Leader/RadiometryUncertaintyRecord.h> - - -RadiometryUncertaintyRecord::RadiometryUncertaintyRecord() -{ -} - -RadiometryUncertaintyRecord::~RadiometryUncertaintyRecord() -{ -} - -std::ostream& operator<<(std::ostream& os, const RadiometryUncertaintyRecord& data) -{ - os<<"db:"<<data._db<<std::endl; - os<<"deg:"<<data._deg<<std::endl; - return os; -} - -std::istream& operator>>(std::istream& is, RadiometryUncertaintyRecord& data) -{ - char buf16[17]; - buf16[16] = '\0'; - - is.read(buf16,16); - data._db = atof(buf16); - - is.read(buf16,16); - data._deg = atof(buf16); - return is; -} - -RadiometryUncertaintyRecord::RadiometryUncertaintyRecord(const RadiometryUncertaintyRecord& rhs): - _db(rhs._db), - _deg(rhs._deg) -{ -} - -RadiometryUncertaintyRecord& RadiometryUncertaintyRecord::operator=(const RadiometryUncertaintyRecord& rhs) -{ - _db = rhs._db; - _deg = rhs._deg; - return *this; -} \ No newline at end of file diff --git a/Utilities/otbossim/src/ossim/imaging/RadarSat/Leader/SRGRCoefficientSetRecord.cpp b/Utilities/otbossim/src/ossim/imaging/RadarSat/Leader/SRGRCoefficientSetRecord.cpp deleted file mode 100644 index 9bd5a6f640b2335d56512e0d4bf4900c062348f6..0000000000000000000000000000000000000000 --- a/Utilities/otbossim/src/ossim/imaging/RadarSat/Leader/SRGRCoefficientSetRecord.cpp +++ /dev/null @@ -1,58 +0,0 @@ -#include <ossim/imaging/RadarSat/Leader/SRGRCoefficientSetRecord.h> - - -SRGRCoefficientSetRecord::SRGRCoefficientSetRecord() -{ -} - -SRGRCoefficientSetRecord::~SRGRCoefficientSetRecord() -{ -} - -std::ostream& operator<<(std::ostream& os, const SRGRCoefficientSetRecord& data) -{ - os<<"srgr_update:"<<data._srgr_update.c_str()<<std::endl; - for (int i=0;i<6;i++) - { - os<<"srgr_coef["<<i<<"]:"<<data._srgr_coef[i]<<std::endl; - } - - return os; -} - -std::istream& operator>>(std::istream& is, SRGRCoefficientSetRecord& data) -{ - char buf[22]; - buf[21] = '\0'; - - is.read(buf,21); - buf[21] = '\0'; - data._srgr_update = buf; - - for (int i=0;i<6;i++) - { - is.read(buf,16); - buf[16] = '\0'; - data._srgr_coef[i] = atof(buf); - } - return is; -} - -SRGRCoefficientSetRecord::SRGRCoefficientSetRecord(const SRGRCoefficientSetRecord& rhs): - _srgr_update(rhs._srgr_update) -{ - for (int i=0;i<6;i++) - { - _srgr_coef[i] = rhs._srgr_coef[i]; - } -} - -SRGRCoefficientSetRecord& SRGRCoefficientSetRecord::operator=(const SRGRCoefficientSetRecord& rhs) -{ - _srgr_update = rhs._srgr_update; - for (int i=0;i<6;i++) - { - _srgr_coef[i] = rhs._srgr_coef[i]; - } - return *this; -} \ No newline at end of file diff --git a/Utilities/otbossim/src/ossim/imaging/RadarSat/Leader/TemperatureSettingsRecord.cpp b/Utilities/otbossim/src/ossim/imaging/RadarSat/Leader/TemperatureSettingsRecord.cpp deleted file mode 100644 index ea6da1e4325f665bfc264892621081b6379e77af..0000000000000000000000000000000000000000 --- a/Utilities/otbossim/src/ossim/imaging/RadarSat/Leader/TemperatureSettingsRecord.cpp +++ /dev/null @@ -1,51 +0,0 @@ -#include <ossim/imaging/RadarSat/Leader/TemperatureSettingsRecord.h> - - -TemperatureSettingsRecord::TemperatureSettingsRecord() -{ -} - -TemperatureSettingsRecord::~TemperatureSettingsRecord() -{ -} - -std::ostream& operator<<(std::ostream& os, const TemperatureSettingsRecord& data) -{ - for (int i=0;i<4;i++) - { - os<<"temp_set["<<i<<"]:"<<data._temp_set[i]<<std::endl; - } - - return os; -} - -std::istream& operator>>(std::istream& is, TemperatureSettingsRecord& data) -{ - char buf[5]; - buf[4] = '\0'; - - for (int i=0;i<4;i++) - { - is.read(buf,4); - buf[4] = '\0'; - data._temp_set[i] = atoi(buf); - } - return is; -} - -TemperatureSettingsRecord::TemperatureSettingsRecord(const TemperatureSettingsRecord& rhs) -{ - for (int i=0;i<4;i++) - { - _temp_set[i] = rhs._temp_set[i]; - } -} - -TemperatureSettingsRecord& TemperatureSettingsRecord::operator=(const TemperatureSettingsRecord& rhs) -{ - for (int i=0;i<4;i++) - { - _temp_set[i] = rhs._temp_set[i]; - } - return *this; -} \ No newline at end of file diff --git a/Utilities/otbossim/src/ossim/imaging/RadarSat/RadarSatRecord.cpp b/Utilities/otbossim/src/ossim/imaging/RadarSat/RadarSatRecord.cpp deleted file mode 100644 index 7eef1648da358d4b6783b5acc7d4305af92c7bd5..0000000000000000000000000000000000000000 --- a/Utilities/otbossim/src/ossim/imaging/RadarSat/RadarSatRecord.cpp +++ /dev/null @@ -1,16 +0,0 @@ -#include <ossim/imaging/RadarSat/RadarSatRecord.h> -#include <memory.h> - -RadarSatRecord::RadarSatRecord(std::string mnemonic): - _mnemonic(mnemonic) -{ -} - -RadarSatRecord::~RadarSatRecord() -{ -} - -RadarSatRecord::RadarSatRecord(const RadarSatRecord& rhs): - _mnemonic(rhs._mnemonic) -{ -} \ No newline at end of file diff --git a/Utilities/otbossim/src/ossim/imaging/RadarSat/RadarSatRecordFactory.cpp b/Utilities/otbossim/src/ossim/imaging/RadarSat/RadarSatRecordFactory.cpp deleted file mode 100644 index e69ce23e8aa5ae5fb33e21bf9037a586f182f8fa..0000000000000000000000000000000000000000 --- a/Utilities/otbossim/src/ossim/imaging/RadarSat/RadarSatRecordFactory.cpp +++ /dev/null @@ -1,27 +0,0 @@ -#include <ossim/imaging/RadarSat/RadarSatRecordFactory.h> - -RadarSatRecordFactory::RadarSatRecordFactory() -{ -} - -RadarSatRecordFactory::~RadarSatRecordFactory() -{ -} - -RadarSatRecord* RadarSatRecordFactory::Instanciate(int id) -{ - RadarSatRecord* record = _availableRecords[id]; - if(record == NULL) - { - return NULL; - } - else - { - return record->Instanciate(); - } -} - -void RadarSatRecordFactory::RegisterRecord(int id, RadarSatRecord * record) -{ - _availableRecords[id] = record; -} \ No newline at end of file diff --git a/Utilities/otbossim/src/ossim/imaging/RadarSat/RadarSatRecordHeader.cpp b/Utilities/otbossim/src/ossim/imaging/RadarSat/RadarSatRecordHeader.cpp deleted file mode 100644 index 6949b059cc595b8773b080b7720e1d8f3b47531c..0000000000000000000000000000000000000000 --- a/Utilities/otbossim/src/ossim/imaging/RadarSat/RadarSatRecordHeader.cpp +++ /dev/null @@ -1,67 +0,0 @@ -#include <ossim/imaging/RadarSat/RadarSatRecordHeader.h> - - -RadarSatRecordHeader::RadarSatRecordHeader() -{ -} - -RadarSatRecordHeader::~RadarSatRecordHeader() -{ -} - -std::ostream& operator<<(std::ostream& os, const RadarSatRecordHeader& data) -{ - os<<"record_sequence_number:"<<data._rec_seq<<std::endl; - os<<"first_record_sub-type:"<<(int)data._rec_sub1<<std::endl; - os<<"record_type_code:"<<(int)data._rec_type<<std::endl; - os<<"second_record_sub-type:"<<(int)data._rec_sub2<<std::endl; - os<<"third_record_sub-type:"<<(int)data._rec_sub3<<std::endl; - os<<"length:"<<data._length<<std::endl; - return os; -} - -std::istream& operator>>(std::istream& is, RadarSatRecordHeader& data) -{ - is.read((char*)&(data._rec_seq),4); - data.SwitchEndian(data._rec_seq); - is.read((char*)&(data._rec_sub1),1); - is.read((char*)&(data._rec_type),1); - is.read((char*)&(data._rec_sub2),1); - is.read((char*)&(data._rec_sub3),1); - is.read((char*)&(data._length),4); - data.SwitchEndian(data._length); - return is; -} - -RadarSatRecordHeader::RadarSatRecordHeader(const RadarSatRecordHeader& rhs): - _rec_seq(rhs._rec_seq), - _rec_sub1(rhs._rec_sub1), - _rec_type(rhs._rec_type), - _rec_sub2(rhs._rec_sub2), - _rec_sub3(rhs._rec_sub3) -{ -} - -RadarSatRecordHeader& RadarSatRecordHeader::operator=(const RadarSatRecordHeader& rhs) -{ - _rec_seq=rhs._rec_seq; - _rec_sub1=rhs._rec_sub1; - _rec_type=rhs._rec_type; - _rec_sub2=rhs._rec_sub2; - _rec_sub3=rhs._rec_sub3; - return *this; -} - -void RadarSatRecordHeader::SwitchEndian(int& value) -{ - char buffer[4]; - char res[4]; - - memcpy(buffer,&value,4); - res[0] = buffer[3]; - res[1] = buffer[2]; - res[2] = buffer[1]; - res[3] = buffer[0]; - - memcpy(&value,res,4); -} \ No newline at end of file diff --git a/Utilities/otbossim/src/ossim/imaging/ossimEnvisatAsarTileSource.cpp b/Utilities/otbossim/src/ossim/imaging/ossimEnvisatAsarTileSource.cpp deleted file mode 100644 index 22709d280c44959e641023212d75c8440fdea0b8..0000000000000000000000000000000000000000 --- a/Utilities/otbossim/src/ossim/imaging/ossimEnvisatAsarTileSource.cpp +++ /dev/null @@ -1,350 +0,0 @@ -#include <ossim/base/ossimTrace.h> -#include <ossim/base/ossimIpt.h> -#include <ossim/base/ossimDpt.h> -#include <ossim/base/ossimFilename.h> -#include <ossim/base/ossimKeywordlist.h> -#include <ossim/base/ossimEllipsoid.h> -#include <ossim/base/ossimDatum.h> -#include <ossim/base/ossimBooleanProperty.h> -#include <ossim/imaging/ossimImageDataFactory.h> -#include <ossim/imaging/ossimEnvisatAsarTileSource.h> -#include <ossim/projection/ossimEquDistCylProjection.h> -#include <ossim/projection/ossimAlbersProjection.h> -#include <ossim/projection/ossimCylEquAreaProjection.h> -#include <ossim/projection/ossimEquDistCylProjection.h> -#include <ossim/projection/ossimVanDerGrintenProjection.h> -#include <ossim/projection/ossimLambertConformalConicProjection.h> -#include <ossim/projection/ossimMercatorProjection.h> -#include <ossim/projection/ossimMillerProjection.h> -#include <ossim/projection/ossimOrthoGraphicProjection.h> -#include <ossim/projection/ossimPolyconicProjection.h> -#include <ossim/projection/ossimSinusoidalProjection.h> -#include <ossim/projection/ossimTransMercatorProjection.h> -#include <ossim/projection/ossimCassiniProjection.h> -#include <ossim/projection/ossimUtmProjection.h> -#include <ossim/base/ossimConstants.h> -#include <ossim/base/ossimCommon.h> -#include <ossim/base/ossimKeywordNames.h> -#include <ossim/base/ossimTrace.h> -#include <ossim/base/ossimKeywordlist.h> -#include <ossim/base/ossimEllipsoid.h> -#include <ossim/base/ossimDatum.h> - -#include <ossim/imaging/EnvisatAsar/EnvisatAsarDataFactory.h> -#include <ossim/imaging/EnvisatAsar/sph.h> -#include <ossim/imaging/EnvisatAsar/mph.h> -#include <ossim/imaging/EnvisatAsar/SQ_ADSR.h> -#include <ossim/imaging/EnvisatAsar/MainProcessingParameters.h> -#include <ossim/imaging/EnvisatAsar/SRGRConversionParameters.h> -#include <ossim/imaging/EnvisatAsar/DopplerCentroidParameters.h> -#include <ossim/imaging/EnvisatAsar/ChirpParameters.h> -#include <ossim/imaging/EnvisatAsar/AntennaElevationPatterns.h> -#include <ossim/imaging/EnvisatAsar/GeolocationGrid.h> - -#include <iostream> -#include <fstream> -#include <ios> -#include <vector> - -RTTI_DEF1(ossimEnvisatAsarTileSource, "ossimEnvisatAsarTileSource", ossimImageHandler) - -static ossimTrace traceDebug("ossimEnvisatAsarTileSource:debug"); - -ossimEnvisatAsarTileSource::ossimEnvisatAsarTileSource(): - _EnvisatAsarData(NULL) -{ -} - -ossimEnvisatAsarTileSource::~ossimEnvisatAsarTileSource() -{ - if(_EnvisatAsarData != NULL) - { - delete _EnvisatAsarData; - } -} - -ossimString ossimEnvisatAsarTileSource::getLongName()const -{ - return ossimString("EnvisatAsar Image Handler"); -} - -ossimString ossimEnvisatAsarTileSource::getShortName()const -{ - return ossimString("EnvisatAsar Image Handler"); -} - -bool ossimEnvisatAsarTileSource::saveState(ossimKeywordlist& kwl, const char* prefix)const -{ - return false; -} - -bool ossimEnvisatAsarTileSource::loadState(const ossimKeywordlist& kwl, const char* prefix) -{ - return false; -} - -bool ossimEnvisatAsarTileSource::open() -{ - bool retValue = true; - - if(traceDebug()) - { - ossimNotify(ossimNotifyLevel_DEBUG) - << "ossimEnvisatAsarTileSource::open(filename) DEBUG: entered..." - << std::endl - << "Attempting to open file " << theImageFile << std::endl; - } - - /* - * Creation of the class allowing to store EnvisatAsarData file metadata - */ - if(_EnvisatAsarData != NULL) - { - delete _EnvisatAsarData; - _EnvisatAsarData = NULL; - } - - /* - * Opening and test of the file - */ - ossimFilename Filename = theImageFile; - ifstream dataFile (Filename, ios::in|ios::binary); - if(dataFile.eof()) - { - dataFile.close(); - retValue = false; - } - else - { - mph mph_rec; - dataFile>>mph_rec; - - // test if it is an ENVISAT Data file - if (mph_rec.is_valid()) - { - if(traceDebug()) - { - ossimNotify(ossimNotifyLevel_DEBUG) - << "Begin reading EnvisatAsar file" << std::endl; - } - /* - * Reading EnvisatAsarData file data - */ - dataFile.seekg(0); - _EnvisatAsarData = new EnvisatAsarData(); - dataFile>>*_EnvisatAsarData; - dataFile.close(); - if(traceDebug()) - { - ossimNotify(ossimNotifyLevel_DEBUG) - << "End reading EnvisatAsar file" << std::endl; - } - } - else - { - dataFile.close(); - retValue = false; - } - } - - if(traceDebug()) - { - ossimNotify(ossimNotifyLevel_DEBUG) - << "ossimEnvisatAsarTileSource::open() DEBUG: returning..." << std::endl; - } - - - return retValue; -} - -void ossimEnvisatAsarTileSource::close() -{ -} - -bool ossimEnvisatAsarTileSource::isOpen()const -{ - return false; -} - - -bool ossimEnvisatAsarTileSource::getImageGeometry(ossimKeywordlist& kwl,const char* prefix) -{ - char name[64]; - - kwl.add(prefix, ossimKeywordNames::TYPE_KW, "ossimEnvisatAsarModel", true); - - /* - * Adding metadata necessary to the sensor model into the keywordlist - * Data derived from the SPH record - */ - sph* sph_rec = _EnvisatAsarData->get_sph(); - if(sph_rec != NULL) - { - kwl.add(prefix, "pixel_spacing", sph_rec->get_range_spacing().c_str(), true ); - kwl.add(prefix, "line_time_interval", sph_rec->get_line_time_interval().c_str(), true ); - } - else - { - return false; - } - /* - * Adding metadata necessary to the sensor model into the keywordlist - * Data derived from the Main Processing Parameters record - */ - MainProcessingParameters* MPP_rec = _EnvisatAsarData->get_MainProcessingParameters(); - if(MPP_rec != NULL) - { - kwl.add(prefix, "num_pix", (double)MPP_rec->get_num_samples_per_line(), true ); - kwl.add(prefix, "num_lines", (double)MPP_rec->get_num_output_lines(), true ); - kwl.add(prefix, "wave_length", MPP_rec->get_radar_freq(), true ); - kwl.add(prefix, "range_sampling_rate", MPP_rec->get_range_samp_rate(), true ); - kwl.add(prefix, "prf", MPP_rec->get_prf(), true ); - kwl.add(prefix, "avg_scene_height", MPP_rec->get_avg_scene_height_ellpsoid(), true ); - kwl.add(prefix, "is_groundrange", MPP_rec->get_srgr_flag(), true ); - kwl.add(prefix, "state_vector_time_1_day", (double)MPP_rec->get_state_vector_time_1_day(), true ); - kwl.add(prefix, "state_vector_time_1_sec", (double)MPP_rec->get_state_vector_time_1_sec(), true ); - kwl.add(prefix, "state_vector_time_1_microsec", (double)MPP_rec->get_state_vector_time_1_microsec(), true ); - kwl.add(prefix, "x_pos_1", (double)MPP_rec->get_x_pos_1(), true ); - kwl.add(prefix, "y_pos_1", (double)MPP_rec->get_y_pos_1(), true ); - kwl.add(prefix, "z_pos_1", (double)MPP_rec->get_z_pos_1(), true ); - kwl.add(prefix, "x_vel_1", (double)MPP_rec->get_x_vel_1(), true ); - kwl.add(prefix, "y_vel_1", (double)MPP_rec->get_y_vel_1(), true ); - kwl.add(prefix, "z_vel_1", (double)MPP_rec->get_z_vel_1(), true ); - kwl.add(prefix, "state_vector_time_2_day",(double) MPP_rec->get_state_vector_time_2_day(), true ); - kwl.add(prefix, "state_vector_time_2_sec", (double)MPP_rec->get_state_vector_time_2_sec(), true ); - kwl.add(prefix, "state_vector_time_2_microsec", (double)MPP_rec->get_state_vector_time_2_microsec(), true ); - kwl.add(prefix, "x_pos_2", (double)MPP_rec->get_x_pos_2(), true ); - kwl.add(prefix, "y_pos_2", (double)MPP_rec->get_y_pos_2(), true ); - kwl.add(prefix, "z_pos_2", (double)MPP_rec->get_z_pos_2(), true ); - kwl.add(prefix, "x_vel_2", (double)MPP_rec->get_x_vel_2(), true ); - kwl.add(prefix, "y_vel_2", (double)MPP_rec->get_y_vel_2(), true ); - kwl.add(prefix, "z_vel_2", (double)MPP_rec->get_z_vel_2(), true ); - kwl.add(prefix, "state_vector_time_3_day", (double)MPP_rec->get_state_vector_time_3_day(), true ); - kwl.add(prefix, "state_vector_time_3_sec", (double)MPP_rec->get_state_vector_time_3_sec(), true ); - kwl.add(prefix, "state_vector_time_3_microsec", (double)MPP_rec->get_state_vector_time_3_microsec(), true ); - kwl.add(prefix, "x_pos_3", (double)MPP_rec->get_x_pos_3(), true ); - kwl.add(prefix, "y_pos_3", (double)MPP_rec->get_y_pos_3(), true ); - kwl.add(prefix, "z_pos_3", (double)MPP_rec->get_z_pos_3(), true ); - kwl.add(prefix, "x_vel_3", (double)MPP_rec->get_x_vel_3(), true ); - kwl.add(prefix, "y_vel_3", (double)MPP_rec->get_y_vel_3(), true ); - kwl.add(prefix, "z_vel_3", (double)MPP_rec->get_z_vel_3(), true ); - kwl.add(prefix, "state_vector_time_4_day", (double)MPP_rec->get_state_vector_time_4_day(), true ); - kwl.add(prefix, "state_vector_time_4_sec", (double)MPP_rec->get_state_vector_time_4_sec(), true ); - kwl.add(prefix, "state_vector_time_4_microsec", (double)MPP_rec->get_state_vector_time_4_microsec(), true ); - kwl.add(prefix, "x_pos_4", (double)MPP_rec->get_x_pos_4(), true ); - kwl.add(prefix, "y_pos_4", (double)MPP_rec->get_y_pos_4(), true ); - kwl.add(prefix, "z_pos_4", (double)MPP_rec->get_z_pos_4(), true ); - kwl.add(prefix, "x_vel_4", (double)MPP_rec->get_x_vel_4(), true ); - kwl.add(prefix, "y_vel_4", (double)MPP_rec->get_y_vel_4(), true ); - kwl.add(prefix, "z_vel_4", (double)MPP_rec->get_z_vel_4(), true ); - kwl.add(prefix, "state_vector_time_5_day", (double)MPP_rec->get_state_vector_time_5_day(), true ); - kwl.add(prefix, "state_vector_time_5_sec", (double)MPP_rec->get_state_vector_time_5_sec(), true ); - kwl.add(prefix, "state_vector_time_5_microsec", (double)MPP_rec->get_state_vector_time_5_microsec(), true ); - kwl.add(prefix, "x_pos_5", (double)MPP_rec->get_x_pos_5(), true ); - kwl.add(prefix, "y_pos_5",(double) MPP_rec->get_y_pos_5(), true ); - kwl.add(prefix, "z_pos_5", (double)MPP_rec->get_z_pos_5(), true ); - kwl.add(prefix, "x_vel_5", (double)MPP_rec->get_x_vel_5(), true ); - kwl.add(prefix, "y_vel_5", (double)MPP_rec->get_y_vel_5(), true ); - kwl.add(prefix, "z_vel_5", (double)MPP_rec->get_z_vel_5(), true ); - } - else - { - return false; - } - /* - * Adding metadata necessary to the sensor model into the keywordlist - * Data derived from the Geolocation Grid record - Reference Point - */ - GeolocationGrid* GG_rec = _EnvisatAsarData->get_GeolocationGrid(0); - if(GG_rec != NULL) - { - kwl.add(prefix, "first_zero_doppler_time_day", (double)GG_rec->get_first_zero_doppler_time_day(), true ); - kwl.add(prefix, "first_zero_doppler_time_sec", (double)GG_rec->get_first_zero_doppler_time_sec(), true ); - kwl.add(prefix, "first_zero_doppler_time_microsec", (double)GG_rec->get_first_zero_doppler_time_microsec(), true ); - kwl.add(prefix, "line_num", (double)GG_rec->get_line_num(), true ); - kwl.add(prefix, "samp_num", (double)(GG_rec->get_samp_numbers())[0], true ); - kwl.add(prefix, "slant_range_time", (double)(GG_rec->get_slant_range_times())[0], true ); - } - else - { - return false; - } - /* - * Adding metadata necessary to the sensor model into the keywordlist - * Data derived from the Geolocation Grid record - Corners - */ - GG_rec = _EnvisatAsarData->get_GeolocationGrid(0); - if(GG_rec != NULL) - { - kwl.add(prefix, "UL_line", (double)GG_rec->get_line_num(), true ); - kwl.add(prefix, "UL_col", (double)(GG_rec->get_samp_numbers())[0], true ); - kwl.add(prefix, "UL_lat", (double)(GG_rec->get_lats())[0], true ); - kwl.add(prefix, "UL_lon", (double)(GG_rec->get_longs())[0], true ); - kwl.add(prefix, "UR_line", (double)GG_rec->get_line_num(), true ); - kwl.add(prefix, "UR_col", (double)(GG_rec->get_samp_numbers())[10], true ); - kwl.add(prefix, "UR_lat", (double)(GG_rec->get_lats())[10], true ); - kwl.add(prefix, "UR_lon", (double)(GG_rec->get_longs())[10], true ); - } - else - { - return false; - } - GG_rec = _EnvisatAsarData->get_GeolocationGrid(10); - if(GG_rec != NULL) - { - kwl.add(prefix, "LL_line", (double)GG_rec->get_line_num(), true ); - kwl.add(prefix, "LL_col", (double)(GG_rec->get_samp_numbers())[0], true ); - kwl.add(prefix, "LL_lat", (double)(GG_rec->get_lats())[0], true ); - kwl.add(prefix, "LL_lon", (double)(GG_rec->get_longs())[0], true ); - kwl.add(prefix, "LR_line", (double)GG_rec->get_line_num(), true ); - kwl.add(prefix, "LR_col", (double)(GG_rec->get_samp_numbers())[10], true ); - kwl.add(prefix, "LR_lat", (double)(GG_rec->get_lats())[10], true ); - kwl.add(prefix, "LR_lon", (double)(GG_rec->get_longs())[10], true ); - } - else - { - return false; - } - - /* - * Adding metadata necessary to the sensor model into the keywordlist - */ - int n_srgr = 0; - SRGRConversionParameters * SRGRParameters = _EnvisatAsarData->get_SRGRConversionParameters(0); - if(SRGRParameters != NULL) - { - n_srgr = _EnvisatAsarData->get_num_ds(SRGRParameters); - - for (int i=0;i<n_srgr;i++) - { - SRGRConversionParameters * SRGR = _EnvisatAsarData->get_SRGRConversionParameters(i); - - sprintf(name,"srgr_update_day%i",i); - kwl.add(prefix, name, (double)SRGR->get_first_zero_doppler_time_day(),true); - - sprintf(name,"srgr_update_sec%i",i); - kwl.add(prefix, name, (double)SRGR->get_first_zero_doppler_time_sec(),true); - - sprintf(name,"srgr_update_microsec%i",i); - kwl.add(prefix, name, (double)SRGR->get_first_zero_doppler_time_microsec(),true); - - sprintf(name,"srgr_coef%iA",i); - kwl.add(prefix, name,(double)SRGR->get_ground_range_origin(),true); - - sprintf(name,"srgr_coef%iB",i); - kwl.add(prefix, name,(double)SRGR->get_srgr_coef()[0],true); - sprintf(name,"srgr_coef%iC",i); - kwl.add(prefix, name,(double)SRGR->get_srgr_coef()[1],true); - sprintf(name,"srgr_coef%iD",i); - kwl.add(prefix, name,(double)SRGR->get_srgr_coef()[2],true); - sprintf(name,"srgr_coef%iE",i); - kwl.add(prefix, name,(double)SRGR->get_srgr_coef()[3]*1e10,true); - sprintf(name,"srgr_coef%iF",i); - kwl.add(prefix, name,(double)SRGR->get_srgr_coef()[4]*1e10,true); - } - } - - kwl.add(prefix, "n_srgr" , n_srgr,true); - - return true; -} diff --git a/Utilities/otbossim/src/ossim/imaging/ossimRadarSatTileSource.cpp b/Utilities/otbossim/src/ossim/imaging/ossimRadarSatTileSource.cpp deleted file mode 100644 index e09bdd4707b861181b15504f24f01039f1caf164..0000000000000000000000000000000000000000 --- a/Utilities/otbossim/src/ossim/imaging/ossimRadarSatTileSource.cpp +++ /dev/null @@ -1,440 +0,0 @@ -#include <ossim/base/ossimTrace.h> -#include <ossim/base/ossimIpt.h> -#include <ossim/base/ossimDpt.h> -#include <ossim/base/ossimFilename.h> -#include <ossim/base/ossimKeywordlist.h> -#include <ossim/base/ossimEllipsoid.h> -#include <ossim/base/ossimDatum.h> -#include <ossim/base/ossimBooleanProperty.h> -#include <ossim/imaging/ossimImageDataFactory.h> -#include <ossim/imaging/ossimRadarSatTileSource.h> -#include <ossim/projection/ossimEquDistCylProjection.h> -#include <ossim/projection/ossimAlbersProjection.h> -#include <ossim/projection/ossimCylEquAreaProjection.h> -#include <ossim/projection/ossimEquDistCylProjection.h> -#include <ossim/projection/ossimVanDerGrintenProjection.h> -#include <ossim/projection/ossimLambertConformalConicProjection.h> -#include <ossim/projection/ossimMercatorProjection.h> -#include <ossim/projection/ossimMillerProjection.h> -#include <ossim/projection/ossimOrthoGraphicProjection.h> -#include <ossim/projection/ossimPolyconicProjection.h> -#include <ossim/projection/ossimSinusoidalProjection.h> -#include <ossim/projection/ossimTransMercatorProjection.h> -#include <ossim/projection/ossimCassiniProjection.h> -#include <ossim/projection/ossimUtmProjection.h> -#include <ossim/base/ossimConstants.h> -#include <ossim/base/ossimCommon.h> -#include <ossim/base/ossimKeywordNames.h> -#include <ossim/base/ossimTrace.h> -#include <ossim/base/ossimKeywordlist.h> -#include <ossim/base/ossimEllipsoid.h> -#include <ossim/base/ossimDatum.h> - -#include <ossim/imaging/RadarSat/RadarSatRecordHeader.h> - -#include <ossim/imaging/RadarSat/Data/DataFactory.h> -#include <ossim/imaging/RadarSat/Data/ImageOptionsFileDescriptor.h> -#include <ossim/imaging/RadarSat/Data/ProcessedDataRecord.h> - -#include <ossim/imaging/RadarSat/Leader/DataHistogramSignalData.h> -#include <ossim/imaging/RadarSat/Leader/DataQuality.h> -#include <ossim/imaging/RadarSat/Leader/DataSetSummary.h> -#include <ossim/imaging/RadarSat/Leader/FileDescriptor.h> -#include <ossim/imaging/RadarSat/Leader/DataHistogramProcessedData.h> -#include <ossim/imaging/RadarSat/Leader/ProcessingParameters.h> -#include <ossim/imaging/RadarSat/Leader/PlatformPositionData.h> -#include <ossim/imaging/RadarSat/Leader/AttitudeData.h> -#include <ossim/imaging/RadarSat/Leader/RadiometricData.h> -#include <ossim/imaging/RadarSat/Leader/RadiometricCompensationData.h> - -#include <iostream> -#include <fstream> -#include <ios> - - -RTTI_DEF1(ossimRadarSatTileSource, "ossimRadarSatTileSource", ossimImageHandler) - -static ossimTrace traceDebug("ossimRadarSatTileSource:debug"); - -ossimRadarSatTileSource::ossimRadarSatTileSource(): - _data(NULL), - _leader(NULL) -{ -} - -ossimRadarSatTileSource::~ossimRadarSatTileSource() -{ - if (_data != NULL) - { - delete _data; - } - if(_leader != NULL) - { - delete _leader; - } -} - -ossimString ossimRadarSatTileSource::getLongName()const -{ - return ossimString("RadarSat Image Handler"); -} - -ossimString ossimRadarSatTileSource::getShortName()const -{ - return ossimString("RadarSat Image Handler"); -} - -bool ossimRadarSatTileSource::saveState(ossimKeywordlist& kwl, const char* prefix)const -{ - return false; -} - -bool ossimRadarSatTileSource::loadState(const ossimKeywordlist& kwl, const char* prefix) -{ - return false; -} - -bool ossimRadarSatTileSource::open() -{ - if(traceDebug()) - { - ossimNotify(ossimNotifyLevel_DEBUG) - << "ossimRadarSatTileSource::open(filename) DEBUG: entered..." - << std::endl - << "Attempting to open file " << theImageFile << std::endl; - } - - bool retValue = true; - ossimFilename tempFilename = theImageFile; - - /* - * Creation of the class allowing to store the metadata from the Data file - */ - if (_data != NULL) - { - delete _data; - _data = NULL; - } - _data = new Data(); - - /* - * Creation of the class allowing to store the metadata from the Leader file - */ - if(_leader != NULL) - { - delete _leader; - _leader = NULL; - } - - _leader = new Leader(); - - RadarSatRecordHeader header; - DataFactory factory; - ifstream dataFile (tempFilename, ios::in|ios::binary); - dataFile>>header; - if(dataFile.eof()) - { - dataFile.close(); - retValue = false; - } - else - { - if(traceDebug()) - { - ossimNotify(ossimNotifyLevel_DEBUG) - << "Begin reading DAT file" << std::endl; - } - RadarSatRecord* record = factory.Instanciate(header.get_rec_seq()); - if (record != NULL && header.get_rec_seq() == 1) - { - record->Read(dataFile); - /* - * Tests if the input File is a Radarsat DAT file - */ - if ( (((ImageOptionsFileDescriptor*)record)->get_file_name()).substr(0,10) == "RSAT-1-SAR") - { - /* - * Reading of the remaining of the data file - */ - dataFile.close(); - dataFile.open(tempFilename, ios::in|ios::binary); - - dataFile>>*_data; - _data->InsertRecord(header.get_rec_seq(), record); - dataFile.close(); - - if(traceDebug()) - { - ossimNotify(ossimNotifyLevel_DEBUG) - << "End reading DAT file" << std::endl; - } - /* - * Leader file path construction from the DAT file path - * Warning : the filename case has to be homogenous - */ - std::string leader_file = theImageFile; - string::size_type loc = leader_file.find( "DAT_01", 0 ); - if( loc != string::npos ) leader_file.replace(loc, 6, "LEA_01" ); // upper case test - else { - loc = leader_file.find( "dat_01", 0 ); - if( loc != string::npos ) leader_file.replace(loc, 6, "lea_01" ); // lower case test - else { - ossimNotify(ossimNotifyLevel_DEBUG) - << "File Name not coherent (searching for *DAT_01* or *dat_01*) : " << theImageFile << std::endl; - } - } - ossimFilename leaderFilePath(leader_file); - - if (!leaderFilePath.exists()){ - ossimNotify(ossimNotifyLevel_DEBUG) - << "Leader file not found (searching for *lea_01* coherent with *dat_01*) : " << theImageFile << std::endl; - retValue = false; - } - else - { - if(traceDebug()) - { - ossimNotify(ossimNotifyLevel_DEBUG) - << "Begin reading Leader file" << std::endl; - } - /* - * Leader file data reading - */ - ifstream leaderFile (leaderFilePath, ios::in|ios::binary); - leaderFile>>*_leader; - leaderFile.close(); - if(traceDebug()) - { - ossimNotify(ossimNotifyLevel_DEBUG) - << "End reading Leader file" << std::endl; - } - } - } - else - { - dataFile.close(); - retValue = false; - } - } - else - { - dataFile.close(); - retValue = false; - } - } - - if(traceDebug()) - { - ossimNotify(ossimNotifyLevel_DEBUG) - << "ossimRadarSatTileSource::open() DEBUG: returning..." << std::endl; - } - return retValue; -} - -void ossimRadarSatTileSource::close() -{ -} - -bool ossimRadarSatTileSource::isOpen()const -{ - return false; -} - -bool ossimRadarSatTileSource::getImageGeometry(ossimKeywordlist& kwl,const char* prefix) -{ - char name[64]; - - kwl.add(prefix, ossimKeywordNames::TYPE_KW, "ossimRadarSatModel", true); - - FileDescriptor * fileDescriptor = _leader->get_FileDescriptor() ; - if(fileDescriptor != NULL) - { - kwl.add(prefix, "file_name",fileDescriptor->get_file_name().c_str(),true); - } - else - { - return false; - } - - /* - * Ajout des donn�es n�cessaires au mod�le de capteur dans la liste des mots clefs - */ - DataSetSummary * datasetSummary = _leader->get_DataSetSummary(); - if(datasetSummary != NULL) - { - kwl.add(prefix, "inp_sctim",datasetSummary->get_inp_sctim().c_str(),true); - - kwl.add(prefix, "asc_des",datasetSummary->get_asc_des().c_str(),true); - - kwl.add(prefix, "pro_lat",datasetSummary->get_pro_lat(),true); - kwl.add(prefix, "pro_long",datasetSummary->get_pro_long(),true); - kwl.add(prefix, "pro_head",datasetSummary->get_pro_head(),true); - - kwl.add(prefix, "ellip_des",datasetSummary->get_ellip_des().c_str(),true); - kwl.add(prefix, "ellip_maj",datasetSummary->get_ellip_maj(),true); - kwl.add(prefix, "ellip_min",datasetSummary->get_ellip_min(),true); - - kwl.add(prefix, "sc_lin",datasetSummary->get_sc_lin(),true); - kwl.add(prefix, "sc_pix",datasetSummary->get_sc_pix(),true); - - kwl.add(prefix, "plat_lat",datasetSummary->get_plat_lat(),true); - kwl.add(prefix, "plat_long",datasetSummary->get_plat_long(),true); - kwl.add(prefix, "plat_head",datasetSummary->get_plat_head(),true); - - kwl.add(prefix, "wave_length",datasetSummary->get_wave_length(),true); - - kwl.add(prefix, "fr",datasetSummary->get_fr(),true); - - kwl.add(prefix, "rng_gate",datasetSummary->get_rng_gate(),true); - - kwl.add(prefix, "fa",datasetSummary->get_fa(),true); - - kwl.add(prefix, "n_azilok",datasetSummary->get_n_azilok(),true); - kwl.add(prefix, "n_rnglok",datasetSummary->get_n_rnglok(),true); - kwl.add(prefix, "bnd_azilok",datasetSummary->get_bnd_azilok(),true); - kwl.add(prefix, "bnd_rnglok",datasetSummary->get_bnd_rnglok(),true); - kwl.add(prefix, "bnd_azi",datasetSummary->get_bnd_azi(),true); - kwl.add(prefix, "bnd_rng",datasetSummary->get_bnd_rng(),true); - - kwl.add(prefix, "alt_dopcen0",datasetSummary->get_alt_dopcen()[0],true); - kwl.add(prefix, "alt_dopcen1",datasetSummary->get_alt_dopcen()[1],true); - kwl.add(prefix, "alt_dopcen2",datasetSummary->get_alt_dopcen()[2],true); - - kwl.add(prefix, "crt_dopcen0",datasetSummary->get_crt_dopcen()[0],true); - kwl.add(prefix, "crt_dopcen1",datasetSummary->get_crt_dopcen()[1],true); - kwl.add(prefix, "crt_dopcen2",datasetSummary->get_crt_dopcen()[2],true); - - kwl.add(prefix, "time_dir_pix",datasetSummary->get_time_dir_pix().c_str(),true); - kwl.add(prefix, "time_dir_lin",datasetSummary->get_time_dir_lin().c_str(),true); - - kwl.add(prefix, "terrain_height",datasetSummary->get_terrain_h(),true); - - kwl.add(prefix, "line_spacing",datasetSummary->get_line_spacing(),true); - } - else - { - return false; - } - - /* - * Ajout des donn�es n�cessaires au mod�le de capteur dans la liste des mots clefs - */ - ProcessingParameters * processingParameters = _leader->get_ProcessingParameters(); - if(processingParameters != NULL) - { - kwl.add(prefix, "n_srgr",processingParameters->get_n_srgr(),true); - - for (int i=0;i<processingParameters->get_n_srgr();i++) - { - sprintf(name,"srgr_update%i",i); - kwl.add(prefix, name,((processingParameters->get_srgr_coefset()[i]).get_srgr_update()).c_str(),true); - - sprintf(name,"srgr_coef%iA",i); - kwl.add(prefix, name,(processingParameters->get_srgr_coefset()[i]).get_srgr_coef()[0],true); - sprintf(name,"srgr_coef%iB",i); - kwl.add(prefix, name,(processingParameters->get_srgr_coefset()[i]).get_srgr_coef()[1],true); - sprintf(name,"srgr_coef%iC",i); - kwl.add(prefix, name,(processingParameters->get_srgr_coefset()[i]).get_srgr_coef()[2],true); - sprintf(name,"srgr_coef%iD",i); - kwl.add(prefix, name,(processingParameters->get_srgr_coefset()[i]).get_srgr_coef()[3],true); - sprintf(name,"srgr_coef%iE",i); - kwl.add(prefix, name,(processingParameters->get_srgr_coefset()[i]).get_srgr_coef()[4],true); - sprintf(name,"srgr_coef%iF",i); - kwl.add(prefix, name,(processingParameters->get_srgr_coefset()[i]).get_srgr_coef()[5],true); - } - - kwl.add(prefix, "pixel_spacing",processingParameters->get_pixel_spacing(),true); - - kwl.add(prefix, "lookDirection",(processingParameters->get_sens_orient()).c_str(),true); - } - else - { - return false; - } - - /* - * Ajout des donn�es n�cessaires au mod�le de capteur dans la liste des mots clefs - */ - PlatformPositionData * platformPositionData = _leader->get_PlatformPositionData(); - if(platformPositionData != NULL) - { - kwl.add(prefix, "neph",platformPositionData->get_ndata(),true); - kwl.add(prefix, "eph_int",platformPositionData->get_data_int(),true); - - kwl.add(prefix, "eph_year",platformPositionData->get_year(),true); - kwl.add(prefix, "eph_month",platformPositionData->get_month(),true); - kwl.add(prefix, "eph_day",platformPositionData->get_day(),true); - kwl.add(prefix, "eph_sec",platformPositionData->get_gmt_sec(),true); - kwl.add(prefix, "hr_angle",platformPositionData->get_hr_angle(),true); - - for(int i=0;i<platformPositionData->get_ndata();i++) - { - sprintf(name,"eph%i_posX",i); - kwl.add(prefix, name,(platformPositionData->get_pos_vect()[i]).get_pos()[0],true); - sprintf(name,"eph%i_posY",i); - kwl.add(prefix, name,(platformPositionData->get_pos_vect()[i]).get_pos()[1],true); - sprintf(name,"eph%i_posZ",i); - kwl.add(prefix, name,(platformPositionData->get_pos_vect()[i]).get_pos()[2],true); - - sprintf(name,"eph%i_velX",i); - kwl.add(prefix, name,(platformPositionData->get_pos_vect()[i]).get_vel()[0],true); - sprintf(name,"eph%i_velY",i); - kwl.add(prefix, name,(platformPositionData->get_pos_vect()[i]).get_vel()[1],true); - sprintf(name,"eph%i_velZ",i); - kwl.add(prefix, name,(platformPositionData->get_pos_vect()[i]).get_vel()[2],true); - } - } - else - { - return false; - } - - ImageOptionsFileDescriptor * imageOptionsFileDescriptor = _data->get_ImageOptionsFileDescriptor(); - if(imageOptionsFileDescriptor != NULL) - { - kwl.add(prefix, "nbLin",imageOptionsFileDescriptor->get_nlin(),true); - kwl.add(prefix, "nbCol",imageOptionsFileDescriptor->get_ngrp(),true); - } - else - { - return false; - } - - ProcessedDataRecord * firstProcessedDataRecord = _data->get_FirstProcessedDataRecord(); - if(firstProcessedDataRecord != NULL) - { - sprintf(name,"cornersLon%i",0); - kwl.add(prefix, name,((float) (firstProcessedDataRecord->get_lon_first()))/1000000.0,true); - sprintf(name,"cornersLat%i",0); - kwl.add(prefix, name,((float) (firstProcessedDataRecord->get_lat_first()))/1000000.0,true); - sprintf(name,"cornersLon%i",1); - kwl.add(prefix, name,((float) (firstProcessedDataRecord->get_lon_last()))/1000000.0,true); - sprintf(name,"cornersLat%i",1); - kwl.add(prefix, name,((float) (firstProcessedDataRecord->get_lat_last()))/1000000.0,true); - kwl.add(prefix, "acq_msec_first",firstProcessedDataRecord->get_acq_msec(),true); - } - else - { - return false; - } - - ProcessedDataRecord * lastProcessedDataRecord = _data->get_LastProcessedDataRecord(); - if(firstProcessedDataRecord != NULL) - { - sprintf(name,"cornersLon%i",2); - kwl.add(prefix, name,((float) (lastProcessedDataRecord->get_lon_first()))/1000000.0,true); - sprintf(name,"cornersLat%i",2); - kwl.add(prefix, name,((float) (lastProcessedDataRecord->get_lat_first()))/1000000.0,true); - sprintf(name,"cornersLon%i",3); - kwl.add(prefix, name,(((float) lastProcessedDataRecord->get_lon_last()))/1000000.0,true); - sprintf(name,"cornersLat%i",3); - kwl.add(prefix, name,((float) (lastProcessedDataRecord->get_lat_last()))/1000000.0,true); - kwl.add(prefix, "acq_msec_last",lastProcessedDataRecord->get_acq_msec(),true); - } - else - { - return false; - } - - return true; -} \ No newline at end of file diff --git a/Utilities/otbossim/src/ossim/projection/ossimEnvisatAsarModel.cpp b/Utilities/otbossim/src/ossim/projection/ossimEnvisatAsarModel.cpp deleted file mode 100644 index c58f5290971552507a309fa689a91a00d114943c..0000000000000000000000000000000000000000 --- a/Utilities/otbossim/src/ossim/projection/ossimEnvisatAsarModel.cpp +++ /dev/null @@ -1,355 +0,0 @@ -#include <ossim/projection/ossimEnvisatAsarModel.h> -#include <ossim/projection/SARModel/Ephemeris/GalileanEphemeris.h> -#include <ossim/projection/SARModel/Ephemeris/GeographicEphemeris.h> - -#include <ossim/projection/SARModel/DateTime/GMSTDateTime.h> -#include <ossim/projection/SARModel/DateTime/CivilDateTime.h> -#include <ossim/projection/SARModel/DateTime/MJDDateTime.h> - -#include <ossim/projection/SARModel/PlatformPosition.h> -#include <ossim/projection/SARModel/SensorParams.h> -#include <ossim/projection/SARModel/RefPoint.h> -#include <ossim/projection/SARModel/SarSensor.h> - -#include <math.h> - -RTTI_DEF1(ossimEnvisatAsarModel, "ossimEnvisatAsarModel", ossimGeometricSarSensorModel); - -ossimEnvisatAsarModel::ossimEnvisatAsarModel(): - _n_srgr(0), - _pixel_spacing(0) -{ -} - -ossimEnvisatAsarModel::~ossimEnvisatAsarModel() -{ -} - -double ossimEnvisatAsarModel::getSlantRangeFromGeoreferenced(double col) const -{ - const double CLUM = 2.99792458e+8 ; - - double GR, GR0, relativeGroundRange, slantRange, slantrangetime; - - if (_n_srgr==0) return(-1) ; - - std::vector<double> coefset = FindSRGRSetNumber((_refPoint->get_ephemeris())->get_date()) ; - - GR = _sensor->get_col_direction() * (col)* _pixel_spacing ; - GR0 = coefset[0]; - relativeGroundRange = GR-GR0; - slantRange = coefset[1] - + coefset[2]*relativeGroundRange - + coefset[3]*pow(relativeGroundRange,2) - + coefset[4]*pow(relativeGroundRange,3) - + coefset[5]*pow(relativeGroundRange,4); - - slantrangetime = 2.0*slantRange / (CLUM); - return slantRange ; -} - -bool ossimEnvisatAsarModel::InitSensorParams(const ossimKeywordlist &kwl, const char *prefix) -{ - const double CLUM = 2.99792458e+8; - const char* wave_length_str = kwl.find(prefix,"wave_length"); - double wave_length = CLUM / atof(wave_length_str); - const char* fr_str = kwl.find(prefix,"range_sampling_rate"); - double fr = atof(fr_str); - - // product type : Slant Range or Ground Range - _isProductGeoreferenced = atoi(kwl.find(prefix,"is_groundrange")); - double fa; - if (!_isProductGeoreferenced) - { - const char* fa_str = kwl.find(prefix,"prf"); - fa = atof(fa_str); - } - else - { - const char* fa_str = kwl.find(prefix,"line_time_interval"); - fa = 1.0/atof(fa_str); - } - - // TODO : v�rifier que ceci est ok pour les produits IMP - const char* time_dir_pix = "INCREASE"; - const char* time_dir_lin = "INCREASE"; - - if(_sensor != NULL) - { - delete _sensor; - } - - _sensor = new SensorParams(); - - if(strcmp(time_dir_pix, "INCREASE") == 0) - { - _sensor->set_col_direction(1); - } - else - { - _sensor->set_col_direction(-1); - } - - if(strcmp(time_dir_lin, "INCREASE") == 0) - { - _sensor->set_lin_direction(1); - } - else - { - _sensor->set_lin_direction(-1); - } - - _sensor->set_prf(fa); - _sensor->set_sf(fr); - _sensor->set_rwl(wave_length); - - return true; -} - -bool ossimEnvisatAsarModel::InitPlatformPosition(const ossimKeywordlist &kwl, const char *prefix) -{ - const int neph = 5; - long val_long; - unsigned long val_ulong1; - unsigned long val_ulong2; - CivilDateTime ref_civil_date; - - Ephemeris** ephemeris = new Ephemeris*[neph]; - - for (int i=1;i<=neph;i++) - { - double pos[3]; - double vel[3]; - char name[64]; - - /* - * Date de l'ephemeride - */ - sprintf(name,"state_vector_time_%i_day",i); - long day = (long) atof(kwl.find(prefix,name)); - sprintf(name,"state_vector_time_%i_sec",i); - unsigned long sec = (unsigned long) atof(kwl.find(prefix,name)); - sprintf(name,"state_vector_time_%i_microsec",i); - unsigned long microsec = (unsigned long) atof(kwl.find(prefix,name)); - MJDDateTime mjdDate(day, sec, microsec); - JSDDateTime jsd_date(mjdDate); - /* - * Position de l'ephemeride - */ - sprintf(name,"x_pos_%i",i); - pos[0] = (double) atoi(kwl.find(prefix,name)) * 1.0e-2; - sprintf(name,"y_pos_%i",i); - pos[1] = (double) atoi(kwl.find(prefix,name)) * 1.0e-2; - sprintf(name,"z_pos_%i",i); - pos[2] = (double) atoi(kwl.find(prefix,name)) * 1.0e-2; - /* - * Vitesse de l'ephemeride - */ - sprintf(name,"x_vel_%i",i); - vel[0] = (double) atoi(kwl.find(prefix,name)) * 1.0e-5; - sprintf(name,"y_vel_%i",i); - vel[1] = (double) atoi(kwl.find(prefix,name)) * 1.0e-5; - sprintf(name,"z_vel_%i",i); - vel[2] = (double) atoi(kwl.find(prefix,name)) * 1.0e-5; - - GeographicEphemeris* eph = new GeographicEphemeris(jsd_date, pos, vel); - - ephemeris[i-1] = eph; - } - - if (_platformPosition != NULL) - { - delete _platformPosition; - } - _platformPosition = new PlatformPosition(ephemeris,neph); - - /* - * Liberation de la memoire utilis�e par la liste des ephemerides - * ->Le constructeur effectue une copie des ephemerides - */ - for (int i=0;i<neph;i++) - { - delete ephemeris[i]; - } - delete[] ephemeris; - - return true; -} - - - -bool ossimEnvisatAsarModel::InitRefPoint(const ossimKeywordlist &kwl, const char *prefix) -{ - - // Reference image position - if(_refPoint == NULL) - { - _refPoint = new RefPoint(); - } - double sc_pix = atof(kwl.find(prefix,"samp_num")) - 1.0; - _refPoint->set_pix_col(sc_pix); - double sc_lin = atof(kwl.find(prefix,"line_num")) - 1.0; - _refPoint->set_pix_line(sc_lin); - - // Reference Point distance - double c = 2.99792458e+8; - double distance = atof(kwl.find(prefix,"slant_range_time")) * (c/2.0) * 1.0e-9; - _refPoint->set_distance(distance); - - - // Reference Point Ephemeris - long day_ref = (long)atof(kwl.find(prefix,"first_zero_doppler_time_day")); - unsigned long sec_ref = (unsigned long)atof(kwl.find(prefix,"first_zero_doppler_time_sec")); - unsigned long microsec_ref = (unsigned long)atof(kwl.find(prefix,"first_zero_doppler_time_microsec")); - - MJDDateTime mjdDate_ref(day_ref, sec_ref, microsec_ref); - JSDDateTime jsd_date_ref(mjdDate_ref); - - if(_platformPosition != NULL) - { - Ephemeris * ephemeris = _platformPosition->Interpolate(jsd_date_ref); - if (ephemeris == NULL) return false ; - _refPoint->set_ephemeris(ephemeris); - delete ephemeris; - } - else return false; - - // Adjustement of the model using the four corner points - // in order to use ossimSensorModel::lineSampleToWorld - const char* nbCol_str = kwl.find(prefix,"num_pix"); - const char* nbLin_str = kwl.find(prefix,"num_lines"); - theImageSize.x = atoi(nbCol_str); - theImageSize.y = atoi(nbLin_str); - theImageClipRect = ossimDrect(0, 0, theImageSize.x-1, theImageSize.y-1); - - // Ground Control Points extracted from the model : corner points - std::list<ossimGpt> groundGcpCoordinates ; - std::list<ossimDpt> imageGcpCoordinates ; - double h = atof(kwl.find("avg_scene_height")); - - // first line first pix - double line = atof(kwl.find("UL_line")) - 1; - double col = atof(kwl.find("UL_col")) - 1; - double lon = atof(kwl.find("UL_lon")) * 1e-6; - double lat = atof(kwl.find("UL_lat")) * 1e-6; - if (lon > 180.0) lon -= 360.0; - ossimDpt imageGCP1(col,line); - ossimGpt groundGCP1(lat, lon, h); - groundGcpCoordinates.push_back(groundGCP1) ; - imageGcpCoordinates.push_back(imageGCP1) ; - // first line last pix - line = atof(kwl.find("UR_line")) - 1; - col = atof(kwl.find("UR_col")) - 1; - lon = atof(kwl.find("UR_lon")) * 1e-6; - lat = atof(kwl.find("UR_lat")) * 1e-6; - if (lon > 180.0) lon -= 360.0; - ossimDpt imageGCP2(col,line); - ossimGpt groundGCP2(lat, lon, h); - groundGcpCoordinates.push_back(groundGCP2) ; - imageGcpCoordinates.push_back(imageGCP2) ; - // last line last pix - line = atof(kwl.find("LR_line")) - 1; - col = atof(kwl.find("LR_col")) - 1; - lon = atof(kwl.find("LR_lon")) * 1e-6; - lat = atof(kwl.find("LR_lat")) * 1e-6; - if (lon > 180.0) lon -= 360.0; - ossimDpt imageGCP3(col,line); - ossimGpt groundGCP3(lat, lon, h); - groundGcpCoordinates.push_back(groundGCP3) ; - imageGcpCoordinates.push_back(imageGCP3) ; - // last line first pix - line = atof(kwl.find("LL_line")) - 1; - col = atof(kwl.find("LL_col")) - 1; - lon = atof(kwl.find("LL_lon")) * 1e-6; - lat = atof(kwl.find("LL_lat")) * 1e-6; - if (lon > 180.0) lon -= 360.0; - ossimDpt imageGCP4(col,line); - ossimGpt groundGCP4(lat, lon, h); - groundGcpCoordinates.push_back(groundGCP4) ; - imageGcpCoordinates.push_back(imageGCP4) ; - - // Default optimization - optimizeModel(groundGcpCoordinates, imageGcpCoordinates) ; - - return true; -} -bool ossimEnvisatAsarModel::InitSRGR(const ossimKeywordlist &kwl, const char *prefix) -{ - // product type : Slant Range or Ground Range - _isProductGeoreferenced = atoi(kwl.find(prefix,"is_groundrange")); - - // pixel spacing - _pixel_spacing = atof(kwl.find(prefix,"pixel_spacing")); - - // number of SRGR sets - _n_srgr = atoi(kwl.find(prefix,"n_srgr")); - - - char name[64]; - for (int i=0;i<_n_srgr;i++) - { - // SRGR update time - sprintf(name,"srgr_update_day%i",i); - long day_ref = (long)atof(kwl.find(prefix,name)); - sprintf(name,"srgr_update_sec%i",i); - unsigned long sec_ref = (unsigned long)atof(kwl.find(prefix,name)); - sprintf(name,"srgr_update_microsec%i",i); - unsigned long microsec_ref = (unsigned long)atof(kwl.find(prefix,name)); - MJDDateTime mjdDate_ref(day_ref, sec_ref, microsec_ref); - JSDDateTime jsd_date_ref(mjdDate_ref); - _srgr_update.push_back(jsd_date_ref); - - std::vector<double> srgr_set; - // SRGR coefficients - sprintf(name,"srgr_coef%iA",i); - const char* srgr_coef_strA = kwl.find(prefix,name); - srgr_set.push_back(atof(srgr_coef_strA)); - sprintf(name,"srgr_coef%iB",i); - const char* srgr_coef_strB = kwl.find(prefix,name); - srgr_set.push_back(atof(srgr_coef_strB)); - sprintf(name,"srgr_coef%iC",i); - const char* srgr_coef_strC = kwl.find(prefix,name); - srgr_set.push_back(atof(srgr_coef_strC)); - sprintf(name,"srgr_coef%iD",i); - const char* srgr_coef_strD = kwl.find(prefix,name); - srgr_set.push_back(atof(srgr_coef_strD)); - sprintf(name,"srgr_coef%iE",i); - const char* srgr_coef_strE = kwl.find(prefix,name); - srgr_set.push_back(atof(srgr_coef_strE)*1e-10); - sprintf(name,"srgr_coef%iF",i); - const char* srgr_coef_strF = kwl.find(prefix,name); - srgr_set.push_back(atof(srgr_coef_strF)*1e-10); - - _srgr_coefset.push_back(srgr_set); - } - - - return true; -} - - -std::vector<double> ossimEnvisatAsarModel::FindSRGRSetNumber(JSDDateTime date) const -{ - //if (_n_srgr==0) return NULL ; - - std::vector<double> delays; - double delay; - for (int i=0;i<_n_srgr;i++) - { - JSDDateTime datetmp(_srgr_update.at(i)); - delay = date.get_second()+date.get_decimal() - (datetmp.get_second() + datetmp.get_decimal()); - delays.push_back( fabs(delay) ); - } - - int setNumber = 0 ; - double min_delay = delays[0] ; - for (int i=1;i<_n_srgr;i++) - { - if (delays[i]<min_delay) { - setNumber = i ; - min_delay = delays[i] ; - } - } - - return _srgr_coefset[setNumber]; -} diff --git a/Utilities/otbossim/src/ossim/projection/ossimRadarSatModel.cpp b/Utilities/otbossim/src/ossim/projection/ossimRadarSatModel.cpp deleted file mode 100644 index a0581cd15c49231eacf9277c88e1714900875b41..0000000000000000000000000000000000000000 --- a/Utilities/otbossim/src/ossim/projection/ossimRadarSatModel.cpp +++ /dev/null @@ -1,560 +0,0 @@ -#include <ossim/projection/ossimRadarSatModel.h> -#include <ossim/projection/SARModel/Ephemeris/GalileanEphemeris.h> -#include <ossim/projection/SARModel/Ephemeris/GeographicEphemeris.h> - -#include <ossim/projection/SARModel/DateTime/JSDDateTime.h> -#include <ossim/projection/SARModel/DateTime/GMSTDateTime.h> -#include <ossim/projection/SARModel/DateTime/CivilDateTime.h> - -#include <ossim/projection/SARModel/PlatformPosition.h> -#include <ossim/projection/SARModel/SensorParams.h> -#include <ossim/projection/SARModel/RefPoint.h> -#include <ossim/projection/SARModel/SarSensor.h> - -#include <math.h> - -RTTI_DEF1(ossimRadarSatModel, "ossimRadarSatModel", ossimGeometricSarSensorModel); - -ossimRadarSatModel::ossimRadarSatModel(): - _n_srgr(0), - _pixel_spacing(0) -{ -} - -ossimRadarSatModel::~ossimRadarSatModel() -{ -} - -double ossimRadarSatModel::getSlantRangeFromGeoreferenced(double col) const -{ - if (_n_srgr==0) return(-1) ; - - double relativeGroundRange ; - - // in the case of Georeferenced images, _refPoint->get_distance() contains the ground range - relativeGroundRange = _refPoint->get_distance() + _sensor->get_col_direction() * (col-_refPoint->get_pix_col())* _pixel_spacing ; - - int numSet = FindSRGRSetNumber((_refPoint->get_ephemeris())->get_date()) ; - /** - * @todo : could be improved (date choice) - */ - - double slantRange = _srgr_coefset[numSet][0] - + _srgr_coefset[numSet][1]*relativeGroundRange - + _srgr_coefset[numSet][2]*pow(relativeGroundRange,2) - + _srgr_coefset[numSet][3]*pow(relativeGroundRange,3) - + _srgr_coefset[numSet][4]*pow(relativeGroundRange,4) - + _srgr_coefset[numSet][5]*pow(relativeGroundRange,5); - - return slantRange ; -} - -bool ossimRadarSatModel::InitSensorParams(const ossimKeywordlist &kwl, const char *prefix) -{ - const char* wave_length_str = kwl.find(prefix,"wave_length"); - double wave_length = atof(wave_length_str); - const char* fr_str = kwl.find(prefix,"fr"); - double fr = atof(fr_str); - const char* fa_str = kwl.find(prefix,"fa"); - double fa = atof(fa_str); - - /* //number of different looks - const char* n_azilok_str = kwl.find(prefix,"n_azilok"); - double n_azilok = atof(n_azilok_str); - const char* n_rnglok_str = kwl.find(prefix,"n_rnglok"); - double n_rnglok = atof(n_rnglok_str); - */ - - // look bandwidth rate (for localisation purpose) - const char* bnd_azilok_str = kwl.find(prefix,"bnd_azilok"); - double bnd_azilok = atof(bnd_azilok_str); - const char* bnd_rnglok_str = kwl.find(prefix,"bnd_rnglok"); - double bnd_rnglok = atof(bnd_rnglok_str); - const char* bnd_azi_str = kwl.find(prefix,"bnd_azi"); - double bnd_azi = atof(bnd_azi_str); - const char* bnd_rng_str = kwl.find(prefix,"bnd_rng"); - double bnd_rng = atof(bnd_rng_str); - - double n_azilok = bnd_azi/bnd_azilok; - double n_rnglok = bnd_rng/bnd_rnglok; - - const char* time_dir_pix = kwl.find(prefix,"time_dir_pix"); - const char* time_dir_lin = kwl.find(prefix,"time_dir_lin"); - - //ellipsoid parameters - const char* ellip_maj_str = kwl.find(prefix,"ellip_maj"); - double ellip_maj = atof(ellip_maj_str) * 1000.0; // km -> m - const char* ellip_min_str = kwl.find(prefix,"ellip_min"); - double ellip_min = atof(ellip_min_str) * 1000.0; // km -> m - - if(_sensor != NULL) - { - delete _sensor; - } - - _sensor = new SensorParams(); - - if(strcmp(time_dir_pix, "INCREASE") == 0) - { - _sensor->set_col_direction(1); - } - else - { - _sensor->set_col_direction(-1); - } - - if(strcmp(time_dir_lin, "INCREASE") == 0) - { - _sensor->set_lin_direction(1); - } - else - { - _sensor->set_lin_direction(-1); - } - - const char* lookDirection_str = kwl.find(prefix,"lookDirection"); - ossimString lookDirection(lookDirection_str) ; - lookDirection.trim(" ") ; // eliminates trailing blanks - if (lookDirection == "NORMAL") _sensor->set_sightDirection(SensorParams::Right) ; - else _sensor->set_sightDirection(SensorParams::Left) ; - - _sensor->set_prf(fa); - _sensor->set_sf(fr); - _sensor->set_rwl(wave_length); - _sensor->set_nAzimuthLook(n_azilok); - _sensor->set_nRangeLook(n_rnglok); - - _sensor->set_semiMajorAxis(ellip_maj) ; - _sensor->set_semiMinorAxis(ellip_min) ; - - return true; -} - -bool ossimRadarSatModel::InitPlatformPosition(const ossimKeywordlist &kwl, const char *prefix) -{ - const double _PI = 3.14159265358979323846 ; - CivilDateTime ref_civil_date; - /* - * Ephemerisis reference date retrieval - */ - const char* eph_year_str = kwl.find(prefix,"eph_year"); - int eph_year = atoi(eph_year_str); - const char* eph_month_str = kwl.find(prefix,"eph_month"); - int eph_month = atoi(eph_month_str); - const char* eph_day_str = kwl.find(prefix,"eph_day"); - int eph_day = atoi(eph_day_str); - const char* eph_sec_str = kwl.find(prefix,"eph_sec"); - double eph_sec = atof(eph_sec_str); - - ref_civil_date.set_year(eph_year); - ref_civil_date.set_month(eph_month); - ref_civil_date.set_day(eph_day); - ref_civil_date.set_second((int)eph_sec); - ref_civil_date.set_decimal( eph_sec-(double)((int)eph_sec)); - - - JSDDateTime ref_jsd_date(ref_civil_date); - - const char* eph_int_str = kwl.find(prefix, "eph_int"); - double eph_int = atof(eph_int_str); - /* - * Ephemerisis number retrieval - */ - const char* neph_str = kwl.find(prefix,"neph"); - int neph = atoi(neph_str); - - Ephemeris** ephemeris = new Ephemeris*[neph]; - - const char* hr_angle_str = kwl.find(prefix,"hr_angle"); - double greenwich_mha_ref = atof(hr_angle_str); - - GMSTDateTime * greenwich_mha_ref2000 = new GMSTDateTime(); - greenwich_mha_ref2000->set_origine(GMSTDateTime::AN2000); - ref_civil_date.AsGMSTDateTime(greenwich_mha_ref2000); - - /* - * Ephemerisis retrieval - */ - for (int i=0;i<neph;i++) - { - double pos[3]; - double vit[3]; - char name[64]; - - - sprintf(name,"eph%i_posX",i); - const char* px_str = kwl.find(prefix,name); - pos[0] = atof(px_str); - - sprintf(name,"eph%i_posY",i); - const char* py_str = kwl.find(prefix,name); - pos[1] = atof(py_str); - - sprintf(name,"eph%i_posZ",i); - const char* pz_str = kwl.find(prefix,name); - pos[2] = atof(pz_str); - - - sprintf(name,"eph%i_velX",i); - const char* vx_str = kwl.find(prefix,name); - vit[0] = atof(vx_str) * 1.0e-3;; - - sprintf(name,"eph%i_velY",i); - const char* vy_str = kwl.find(prefix,name); - vit[1] = atof(vy_str) * 1.0e-3;; - - sprintf(name,"eph%i_velZ",i); - const char* vz_str = kwl.find(prefix,name); - vit[2] = atof(vz_str) * 1.0e-3;; - - /* - * Ephemerisis date - */ - JSDDateTime date(ref_jsd_date); - date.set_second(date.get_second() + i * eph_int); - date.NormDate(); - - /* - * Date creation for referential change - */ - GMSTDateTime * greenwich_mha = new GMSTDateTime(); - greenwich_mha->set_origine(GMSTDateTime::AN2000); - date.AsGMSTDateTime(greenwich_mha); - - double angle = greenwich_mha_ref+(greenwich_mha->get_tms()-greenwich_mha_ref2000->get_tms())*180.0/_PI; - angle = fmod(angle,360.0); - - /* - * Referential change - */ - GalileanEphemeris * tmpEphemeris = new GalileanEphemeris(date,pos,vit); - GeographicEphemeris* eph = new GeographicEphemeris(); - - tmpEphemeris->ToGeographic(angle,eph); - ephemeris[i] = eph; - - delete tmpEphemeris; - - } - - /* - * Antenna position interpolator creation - */ - if (_platformPosition != NULL) - { - delete _platformPosition; - } - _platformPosition = new PlatformPosition(ephemeris,neph); - - /* - * Free of memory used by the ephemerisis list - */ - for (int i=0;i<neph;i++) - { - delete ephemeris[i]; - } - delete[] ephemeris; - - return true; -} - -bool ossimRadarSatModel::InitRefPoint(const ossimKeywordlist &kwl, const char *prefix) -{ - const char* sc_lin_str = kwl.find(prefix,"sc_lin"); - double sc_lin = atof(sc_lin_str); - - const char* sc_pix_str = kwl.find(prefix,"sc_pix"); - double sc_pix = atof(sc_pix_str); - - const char* inp_sctim_str = kwl.find(prefix,"inp_sctim"); - - const char* rng_gate_str = kwl.find(prefix,"rng_gate"); - double rng_gate = atof(rng_gate_str); - - if(_refPoint == NULL) - { - _refPoint = new RefPoint(); - } - - _refPoint->set_pix_col(sc_pix); - _refPoint->set_pix_line(sc_lin); - - char year_str[5]; - for (int i=0;i<4;i++) - { - year_str[i] = inp_sctim_str[i]; - } - year_str[4] = '\0'; - - char month_str[3]; - for (int i=4;i<6;i++) - { - month_str[i-4] = inp_sctim_str[i]; - } - month_str[2] = '\0'; - - char day_str[3]; - for (int i=6;i<8;i++) - { - day_str[i-6] = inp_sctim_str[i]; - } - day_str[2] = '\0'; - - char hour_str[3]; - for (int i=8;i<10;i++) - { - hour_str[i-8] = inp_sctim_str[i]; - } - hour_str[2] = '\0'; - - char min_str[3]; - for (int i=10;i<12;i++) - { - min_str[i-10] = inp_sctim_str[i]; - } - min_str[2] = '\0'; - - char sec_str[3]; - for (int i=12;i<14;i++) - { - sec_str[i-12] = inp_sctim_str[i]; - } - sec_str[2] = '\0'; - - char mili_str[4]; - for (int i=14;i<17;i++) - { - mili_str[i-14] = inp_sctim_str[i]; - } - mili_str[3] = '\0'; - - int year = atoi(year_str); - int month = atoi(month_str); - int day = atoi(day_str); - int hour = atoi(hour_str); - int min = atoi(min_str); - int sec = atoi(sec_str); - double mili = atof(mili_str); - - - CivilDateTime date(year, month, day, hour * 3600 + min * 60 + sec, mili/1000.0); - - if(_platformPosition != NULL) - { - Ephemeris * ephemeris = _platformPosition->Interpolate((JSDDateTime)date); - if (ephemeris == NULL) return false ; - - _refPoint->set_ephemeris(ephemeris); - - delete ephemeris; - } - else - { - return false; - } - - double c = 2.99792458e+8; - - double distance = (rng_gate + ((double)sc_pix)*_sensor->get_nRangeLook()/_sensor->get_sf()) * (c/2.0); - - // in the case of Georeferenced images, the "relative" ground range is stored in place of the slant range - // (used for SlantRange computation relative to reference point, necessary for optimization) - // here, the pixelDirection is ignored since the RDS reference point is always at the scene centre - if (_isProductGeoreferenced) { - distance = _refPoint->get_pix_col() * _pixel_spacing ; - } - - _refPoint->set_distance(distance); - - -//// essai : line spacing et vitesse satellite -// const char* line_spacing_str = kwl.find(prefix,"line_spacing"); -// double line_spacing = atof(line_spacing_str); -// Ephemeris * ephemeris = _refPoint->get_ephemeris() ; -// double velSat = sqrt(pow(ephemeris->get_vitesse()[0], 2)+ pow(ephemeris->get_vitesse()[1], 2)+ pow(ephemeris->get_vitesse()[2], 2)); -// double prfeq = velSat / line_spacing ; -// _sensor->set_prf(prfeq); -// _sensor->set_nAzimuthLook(1.0); -///** -// * @todo : effacer -// */ - - // in order to use ossimSensorModel::lineSampleToWorld - const char* nbCol_str = kwl.find(prefix,"nbCol"); - const char* nbLin_str = kwl.find(prefix,"nbLin"); - theImageSize.x = atoi(nbCol_str); - theImageSize.y = atoi(nbLin_str); - theImageClipRect = ossimDrect(0, 0, theImageSize.x-1, theImageSize.y-1); - - // sensor PRF update in the case of ground projected products - if (_isProductGeoreferenced) { - const char* acq_msec_first_str = kwl.find("acq_msec_first"); - double acq_msec_first = atof(acq_msec_first_str); - const char* acq_msec_last_str = kwl.find("acq_msec_last"); - double acq_msec_last = atof(acq_msec_last_str); - - double actualPRF = 1000.0*theImageSize.y/(acq_msec_last-acq_msec_first) ; - _sensor->set_nAzimuthLook(_sensor->get_prf()/actualPRF); - } - - // Ground Control Points extracted from the model : scene center - std::list<ossimGpt> groundGcpCoordinates ; - std::list<ossimDpt> imageGcpCoordinates ; - const char* lon_str = kwl.find("pro_long"); - double lon = atof(lon_str); - const char* lat_str = kwl.find("pro_lat"); - double lat = atof(lat_str); - const char* height_str = kwl.find("terrain_height"); - double height = 0 ; //atof(height_str) ; - - ossimDpt imageGCP(sc_pix,sc_lin); - ossimGpt groundGCP(lat, lon, height); - groundGcpCoordinates.push_back(groundGCP) ; - imageGcpCoordinates.push_back(imageGCP) ; - - // Ground Control Points extracted from the model : scene corners - // upper left corner - lon = atof(kwl.find("cornersLon0")); - lat = atof(kwl.find("cornersLat0")); - ossimDpt imageGCP0(0,0); - ossimGpt groundGCP0(lat, lon, height); - groundGcpCoordinates.push_back(groundGCP0) ; - imageGcpCoordinates.push_back(imageGCP0) ; - // upper right corner - lon = atof(kwl.find("cornersLon1")); - lat = atof(kwl.find("cornersLat1")); - ossimDpt imageGCP1(theImageSize.x-1,0); - ossimGpt groundGCP1(lat, lon, height); - groundGcpCoordinates.push_back(groundGCP1) ; - imageGcpCoordinates.push_back(imageGCP1) ; - // lower left corner - lon = atof(kwl.find("cornersLon2")); - lat = atof(kwl.find("cornersLat2")); - ossimDpt imageGCP2(0,theImageSize.y-1); - ossimGpt groundGCP2(lat, lon, height); - groundGcpCoordinates.push_back(groundGCP2) ; - imageGcpCoordinates.push_back(imageGCP2) ; - // lower right corner - lon = atof(kwl.find("cornersLon3")); - lat = atof(kwl.find("cornersLat3")); - ossimDpt imageGCP3(theImageSize.x-1,theImageSize.y-1); - ossimGpt groundGCP3(lat, lon, height); - groundGcpCoordinates.push_back(groundGCP3) ; - imageGcpCoordinates.push_back(imageGCP3) ; - - // Default optimization - optimizeModel(groundGcpCoordinates, imageGcpCoordinates) ; - - return true; -} - -bool ossimRadarSatModel::InitSRGR(const ossimKeywordlist &kwl, const char *prefix) -{ - // product type : format "RSAT-1-SAR-{SLC,SGG,SGC,...}-..." - const char* file_name_str = kwl.find(prefix,"file_name"); - char format[4] ; - // product type (SLC,SGG,SGC,...) extraction - for (int j=11;j<14;j++) - { - format[j-11] = file_name_str[j]; - } - format[3] = '\0'; - std::string format_str(format); - - _isProductGeoreferenced = (format_str=="SGX") || (format_str=="SGF"); - - // pixel spacing - const char* pixel_spacing_str = kwl.find(prefix,"pixel_spacing"); - _pixel_spacing = atof(pixel_spacing_str); - - // number of SRGR sets - const char* n_srgr_str = kwl.find(prefix,"n_srgr"); - _n_srgr = atoi(n_srgr_str); - - char name[64]; - for (int i=0;i<_n_srgr;i++) - { - // SRGR update time, format : YYYY-DDD-HH:MM:SS.SSS - sprintf(name,"srgr_update%i",i); - const char* srgr_update_str = kwl.find(prefix,name); - - // years and days are ignored in the following (conversion from CivilDate to JSDDate requires a YYYY-MM-DD format) - // could be improved - char hour_str[3]; - for (int j=9;j<11;j++) - { - hour_str[j-9] = srgr_update_str[j]; - } - hour_str[2] = '\0'; - - char min_str[3]; - for (int j=12;j<14;j++) - { - min_str[j-12] = srgr_update_str[j]; - } - min_str[2] = '\0'; - - char sec_str[3]; - for (int j=15;j<17;j++) - { - sec_str[j-15] = srgr_update_str[j]; - } - sec_str[2] = '\0'; - - char mili_str[4]; - for (int j=18;j<21;j++) - { - mili_str[j-18] = srgr_update_str[j]; - } - mili_str[3] = '\0'; - - int hour = atoi(hour_str); - int min = atoi(min_str); - int sec = atoi(sec_str); - double mili = atof(mili_str); - _srgr_update[i] = hour * 3600 + min * 60 + sec + mili/1000.0 ; - - // SRGR coefficients - sprintf(name,"srgr_coef%iA",i); - const char* srgr_coef_strA = kwl.find(prefix,name); - _srgr_coefset[i][0] = atof(srgr_coef_strA); - sprintf(name,"srgr_coef%iB",i); - const char* srgr_coef_strB = kwl.find(prefix,name); - _srgr_coefset[i][1] = atof(srgr_coef_strB); - sprintf(name,"srgr_coef%iC",i); - const char* srgr_coef_strC = kwl.find(prefix,name); - _srgr_coefset[i][2] = atof(srgr_coef_strC); - sprintf(name,"srgr_coef%iD",i); - const char* srgr_coef_strD = kwl.find(prefix,name); - _srgr_coefset[i][3] = atof(srgr_coef_strD); - sprintf(name,"srgr_coef%iE",i); - const char* srgr_coef_strE = kwl.find(prefix,name); - _srgr_coefset[i][4] = atof(srgr_coef_strE); - sprintf(name,"srgr_coef%iF",i); - const char* srgr_coef_strF = kwl.find(prefix,name); - _srgr_coefset[i][5] = atof(srgr_coef_strF); - } - return true; -} - -int ossimRadarSatModel::FindSRGRSetNumber(JSDDateTime date) const -{ - if (_n_srgr==0) return(-1) ; - - double delays[20]; - for (int i=0;i<_n_srgr;i++) - { - delays[i] = fabs(date.get_second()+date.get_decimal()-_srgr_update[i]) ; - } - - int setNumber = 0 ; - double min_delay = delays[0] ; - for (int i=1;i<_n_srgr;i++) - { - if (delays[i]<min_delay) { - setNumber = i ; - min_delay = delays[i] ; - } - } - return setNumber ; -} \ No newline at end of file diff --git a/Utilities/otbossimplugins/ossim/ossimEnvisatAsarModel.cpp b/Utilities/otbossimplugins/ossim/ossimEnvisatAsarModel.cpp index 9f04261e16d63990a171567a4af42562d46cccd3..d96ffe40e7d9a7c81dd8d9aab677bd80f9add0bc 100644 --- a/Utilities/otbossimplugins/ossim/ossimEnvisatAsarModel.cpp +++ b/Utilities/otbossimplugins/ossim/ossimEnvisatAsarModel.cpp @@ -346,6 +346,7 @@ bool ossimEnvisatAsarModel::loadState (const ossimKeywordlist &kwl, InitPlatformPosition(kwl, prefix); InitRefPoint(kwl, prefix); InitSRGR(kwl, prefix); + return true; } std::ostream& ossimEnvisatAsarModel::print(std::ostream& out) const diff --git a/Utilities/otbossimplugins/ossim/ossimRadarSatModel.cpp b/Utilities/otbossimplugins/ossim/ossimRadarSatModel.cpp index 178a5dd84d2e39d3b91346871de2fa6a213d9d80..32e6708bc130b260b11e536b4d9920945f52f3b6 100644 --- a/Utilities/otbossimplugins/ossim/ossimRadarSatModel.cpp +++ b/Utilities/otbossimplugins/ossim/ossimRadarSatModel.cpp @@ -433,6 +433,7 @@ bool ossimRadarSatModel::loadState (const ossimKeywordlist &kwl, InitPlatformPosition(kwl, prefix); InitRefPoint(kwl, prefix); InitSRGR(kwl, prefix); + return true } bool ossimRadarSatModel::InitSensorParams(const ossimKeywordlist &kwl, const char *prefix)