LCOV - code coverage report
Current view: directory - frmts/pcidsk/sdk/segment - toutinstructures.h (source / functions) Found Hit Coverage
Test: gdal_filtered.info Lines: 64 0 0.0 %
Date: 2012-12-26 Functions: 4 0 0.0 %

       1                 : /******************************************************************************
       2                 :  *
       3                 :  * Purpose: Support for storing and manipulating Toutin information
       4                 :  * 
       5                 :  ******************************************************************************
       6                 :  * Copyright (c) 2009
       7                 :  * PCI Geomatics, 50 West Wilmot Street, Richmond Hill, Ont, Canada
       8                 :  *
       9                 :  * Permission is hereby granted, free of charge, to any person obtaining a
      10                 :  * copy of this software and associated documentation files (the "Software"),
      11                 :  * to deal in the Software without restriction, including without limitation
      12                 :  * the rights to use, copy, modify, merge, publish, distribute, sublicense,
      13                 :  * and/or sell copies of the Software, and to permit persons to whom the
      14                 :  * Software is furnished to do so, subject to the following conditions:
      15                 :  *
      16                 :  * The above copyright notice and this permission notice shall be included
      17                 :  * in all copies or substantial portions of the Software.
      18                 :  *
      19                 :  * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
      20                 :  * OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
      21                 :  * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
      22                 :  * THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
      23                 :  * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
      24                 :  * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
      25                 :  * DEALINGS IN THE SOFTWARE.
      26                 :  ****************************************************************************/
      27                 : #ifndef __INCLUDE_PCIDSK_TOUTIN_INFORMATION_H
      28                 : #define __INCLUDE_PCIDSK_TOUTIN_INFORMATION_H
      29                 : 
      30                 : #include "segment/orbitstructures.h"
      31                 : 
      32                 : namespace PCIDSK
      33                 : {
      34                 : /* -------------------------------------------------------------------- */
      35                 : /*      SRITInfo_t - Satellite Model structure.                         */
      36                 : /* -------------------------------------------------------------------- */
      37                 : #define AP_MDL   1
      38                 : #define SRIT_MDL 2
      39                 : #define RF_MDL   6
      40                 : #define RTCS_MDL 7
      41                 : #define ADS_MDL  9
      42                 : #define SRITModele 0
      43                 : #define SRITModele1A 1
      44                 : #define SRITModele1B 2
      45                 : #define SRITModeleSAR 3
      46                 : #define SRITModele1AHR 4
      47                 : #define SRITModeleEros 5
      48                 : 
      49                 : #define MAX_SPOT_LINES 30000
      50                 : 
      51                 :     /**
      52                 :      * the SRITInfo_t struct contains all information
      53                 :      * for the Toutin Math Model.
      54                 :      */
      55                 :     struct SRITInfo_t
      56                 :     {
      57                 :         /**
      58                 :          * default constructor
      59                 :          */
      60               0 :         SRITInfo_t()
      61               0 :         {
      62               0 :             OrbitPtr = NULL;
      63               0 :         }
      64                 :         /**
      65                 :          * destructor
      66                 :          */
      67               0 :         ~SRITInfo_t()
      68                 :         {
      69               0 :             delete OrbitPtr;
      70               0 :         }
      71                 : 
      72                 :         /**
      73                 :          * Copy constructor.
      74                 :          * @param oSI the SRITInfo_t to copy
      75                 :          */
      76               0 :         SRITInfo_t(const SRITInfo_t& oSI)
      77               0 :         {
      78               0 :             OrbitPtr = NULL;
      79               0 :             Copy(oSI);
      80               0 :         }
      81                 : 
      82                 :         /**
      83                 :          * Assignment operator
      84                 :          * @param oSI the SRITInfo_t to assign
      85                 :          */
      86                 :         SRITInfo_t& operator=(const SRITInfo_t& oSI)
      87                 :         {
      88                 :             Copy(oSI);
      89                 :             return *this;
      90                 :         }
      91                 : 
      92                 :         /**
      93                 :          * Copy function
      94                 :          * @param oSI the SRITInfo_t to copy
      95                 :          */
      96               0 :         void Copy(const SRITInfo_t& oSI)
      97                 :         {
      98               0 :             if(this == &oSI)
      99                 :             {
     100               0 :                 return;
     101                 :             }
     102               0 :             delete OrbitPtr;
     103               0 :             OrbitPtr = NULL;
     104               0 :             if(oSI.OrbitPtr)
     105                 :             {
     106               0 :                 OrbitPtr = new EphemerisSeg_t(*oSI.OrbitPtr);
     107                 :             }
     108                 : 
     109               0 :             for(int i=0 ; i<256 ; i++)
     110                 :             {
     111               0 :                 nGCPIds[i] = oSI.nGCPIds[i];
     112               0 :                 nPixel[i] = oSI.nPixel[i];
     113               0 :                 nLine[i] = oSI.nLine[i];
     114               0 :                 dfElev[i] = oSI.dfElev[i];
     115                 :             }
     116                 : 
     117               0 :             N0x2 = oSI.N0x2;
     118               0 :             aa = oSI.aa;
     119               0 :             SmALPHA = oSI.SmALPHA;
     120               0 :             bb = oSI.bb;
     121               0 :             C0 = oSI.C0;
     122               0 :             cc = oSI.cc;
     123               0 :             COS_KHI = oSI.COS_KHI;
     124               0 :             DELTA_GAMMA = oSI.DELTA_GAMMA;
     125               0 :             GAMMA = oSI.GAMMA;
     126               0 :             K_1 = oSI.K_1;
     127               0 :             L0 = oSI.L0;
     128               0 :             P = oSI.P;
     129               0 :             Q = oSI.Q;
     130               0 :             TAU = oSI.TAU;
     131               0 :             THETA = oSI.THETA;
     132               0 :             THETA_SEC = oSI.THETA_SEC;
     133               0 :             X0 = oSI.X0;
     134               0 :             Y0 = oSI.Y0;
     135               0 :             delh = oSI.delh;
     136               0 :             COEF_Y2 = oSI.COEF_Y2;
     137               0 :             delT = oSI.delT;
     138               0 :             delL = oSI.delL;
     139               0 :             delTau = oSI.delTau;
     140               0 :             nDownSample = oSI.nDownSample;
     141               0 :             nGCPCount = oSI.nGCPCount;
     142               0 :             nEphemerisSegNo = oSI.nEphemerisSegNo;
     143               0 :             nAttitudeFlag = oSI.nAttitudeFlag;
     144               0 :             utmunit = oSI.utmunit;
     145               0 :             GCPUnit = oSI.GCPUnit;
     146               0 :             GCPMeanHtFlag = oSI.GCPMeanHtFlag;
     147               0 :             dfGCPMeanHt = oSI.dfGCPMeanHt;
     148               0 :             dfGCPMinHt = oSI.dfGCPMinHt;
     149               0 :             dfGCPMaxHt = oSI.dfGCPMaxHt;
     150               0 :             Qdeltar = oSI.Qdeltar;
     151               0 :             Hdeltat = oSI.Hdeltat;
     152               0 :             Sensor = oSI.Sensor;
     153               0 :             nSensor = oSI.nSensor;
     154               0 :             nModel = oSI.nModel;
     155               0 :             RawToGeo = oSI.RawToGeo;
     156               0 :             oProjectionInfo = oSI.oProjectionInfo;
     157                 :         }
     158                 : 
     159                 :         double N0x2;
     160                 :         double aa;
     161                 :         double SmALPHA;
     162                 :         double bb;
     163                 :         double C0;
     164                 :         double cc;
     165                 :         double COS_KHI;
     166                 :         double DELTA_GAMMA;
     167                 :         double GAMMA;
     168                 :         double K_1;
     169                 :         double L0;
     170                 :         double P;
     171                 :         double Q;
     172                 :         double TAU;
     173                 :         double THETA;
     174                 :         double THETA_SEC;
     175                 :         double X0;
     176                 :         double Y0;
     177                 :         double delh;
     178                 :         double COEF_Y2;
     179                 :         double delT;
     180                 :         double delL;
     181                 :         double delTau;
     182                 :         int    nDownSample;
     183                 :         int    nGCPCount;
     184                 :         int    nEphemerisSegNo;
     185                 :         int    nAttitudeFlag;
     186                 :         std::string   utmunit;
     187                 :         std::string   GCPUnit;
     188                 :         char   GCPMeanHtFlag;
     189                 :         double dfGCPMeanHt;
     190                 :         double dfGCPMinHt;
     191                 :         double dfGCPMaxHt;
     192                 :         int    nGCPIds[256];
     193                 :         int    nPixel[256],nLine[256];
     194                 :         double dfElev[256];
     195                 :         std::vector<double> Qdeltar;
     196                 :         std::vector<double> Hdeltat;
     197                 :         std::string   Sensor;
     198                 :         int    nSensor;
     199                 :         int    nModel;
     200                 :         EphemerisSeg_t *OrbitPtr;
     201                 :         bool  RawToGeo;
     202                 :         std::string oProjectionInfo;
     203                 :     } ;
     204                 : }
     205                 : 
     206                 : #endif // __INCLUDE_PCIDSK_TOUTIN_INFORMATION_H

Generated by: LCOV version 1.7