OSSIM - Open Source Software Image Map
Version 1.9.0 (20180803)
src
projection
ossimUpspt.cpp
Go to the documentation of this file.
1
//*******************************************************************
2
//
3
// License: See top level LICENSE.txt file.
4
//
5
// Author: Garrett Potts (gpotts@imagelinks.com)
6
//
7
// Description:
8
//
9
// This is the Universal Polar Stereographic (UPS) point. Allows
10
// easy onversion between different coordinates.
11
//*******************************************************************
12
// $Id: ossimUpspt.cpp 9963 2006-11-28 21:11:01Z gpotts $
13
#include <
ossim/projection/ossimUpspt.h
>
14
#include <
ossim/projection/ossimUtmpt.h
>
15
#include <
ossim/projection/ossimUps.h
>
16
17
#include <
ossim/base/ossimGpt.h
>
18
#include <
ossim/base/ossimEcefPoint.h
>
19
#include <
ossim/base/ossimEllipsoid.h
>
20
#include <
ossim/base/ossimDatum.h
>
21
22
ossimUpspt::ossimUpspt
(
const
ossimGpt
&aPt)
23
{
24
convertFromGeodetic
(aPt);
25
}
26
27
ossimUpspt::ossimUpspt
(
const
ossimEcefPoint
&aPt)
28
{
29
convertFromGeodetic
(
ossimGpt
(aPt));
30
}
31
32
33
void
ossimUpspt::convertFromGeodetic
(
const
ossimGpt
&aPt)
34
{
35
const
ossimDatum
*aDatum = aPt.
datum
();
36
37
if
(aDatum)
38
{
39
Set_UPS_Parameters
(aDatum->
ellipsoid
()->
a
(),
40
aDatum->
ellipsoid
()->
b
());
41
42
Convert_Geodetic_To_UPS
(aPt.
latr
(),
43
aPt.
lonr
(),
44
&
theHemisphere
,
45
&
theEasting
,
46
&
theNorthing
);
47
theDatum
=
const_cast<
ossimDatum
*
>
(aDatum);
48
}
49
else
50
{
51
//ERROR: should never happen
52
}
53
}
ossimDatum
Definition:
ossimDatum.h:22
ossimUpspt::theEasting
double theEasting
Definition:
ossimUpspt.h:37
ossimGpt
Definition:
ossimGpt.h:31
ossimEllipsoid::b
const double & b() const
Definition:
ossimEllipsoid.h:64
ossimEllipsoid.h
ossimUpspt::convertFromGeodetic
void convertFromGeodetic(const ossimGpt &aPt)
Definition:
ossimUpspt.cpp:33
ossimGpt::datum
const ossimDatum * datum() const
datum().
Definition:
ossimGpt.h:196
ossimUtmpt.h
ossimEllipsoid::a
const double & a() const
Definition:
ossimEllipsoid.h:63
ossimEcefPoint.h
ossimGpt::lonr
double lonr() const
Returns the longitude in radian measure.
Definition:
ossimGpt.h:76
ossimUpspt::ossimUpspt
ossimUpspt(const ossimGpt &aPt)
Definition:
ossimUpspt.cpp:22
ossimUpspt.h
ossimDatum::ellipsoid
virtual const ossimEllipsoid * ellipsoid() const
Definition:
ossimDatum.h:60
ossimDatum.h
ossimGpt.h
ossimUpspt::theHemisphere
char theHemisphere
Definition:
ossimUpspt.h:36
Convert_Geodetic_To_UPS
long Convert_Geodetic_To_UPS(double Latitude, double Longitude, char *Hemisphere, double *Easting, double *Northing)
ossimUpspt::theDatum
ossimDatum * theDatum
Definition:
ossimUpspt.h:39
ossimGpt::latr
double latr() const
latr().
Definition:
ossimGpt.h:66
ossimUpspt::theNorthing
double theNorthing
Definition:
ossimUpspt.h:38
ossimEcefPoint
Definition:
ossimEcefPoint.h:35
Set_UPS_Parameters
long Set_UPS_Parameters(double a, double f)
ossimUps.h
Generated on Fri Aug 3 2018 08:46:54 for OSSIM - Open Source Software Image Map by
1.8.14