VR-Forces Developer's Guide
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
flatEarthCS.h
Go to the documentation of this file.
1 /*********************************************************************
2 ** Copyright (c) 2004 MAK Technologies, Inc.
3 ** All rights reserved.
4 *********************************************************************/
5 /*********************************************************************
6 ** $RCSfile: flatEarthCrdSys.h,v $ $Revision: 1.14 $ $State: Exp $
7 *********************************************************************/
8 #ifndef flatEarthCS_H_
9 #define flatEarthCS_H_
10 
11 //
12 // \file flatEarthCrdSys.h Contains the flat earth coordinate system class declaration.
13 //
14 
16 #include "terrainCS/coordSystem.h"
17 
18 //
19 // Instances of DtFlatEarthCS are used by the terrain objects
20 // for performing coordinate conversions from geocentric to flat earth.
22 {
23 public:
24  // constructor
25  DtFlatEarthCS(double refLatitude,
26  double refLongitude, bool setUseDynamicSceneOrigin = false,
27  double dynamicSceneOriginDeadband = 0.0);
28 
29  DtFlatEarthCS(bool setUseDynamicSceneOrigin = false,
30  double dynamicSceneOriginDeadband = 0.0);
31 
32  // copy constructor
33  DtFlatEarthCS(const DtFlatEarthCS& orig);
34 
35  // destructor
36  virtual ~DtFlatEarthCS();
37 
38  // assignment operator
40 
41  // Clone operator
42  virtual Coordinate_System* clone() const;
43 
44  // coordinates in the local (i.e., projected) coordinate system only
45  // consist of X and Y, but we use a three element vector to store them so a
46  // programmer can use the Z value for height above terrain.
47  virtual void dis2local(const DtVector& in, DtVector& out) const;
48  virtual void local2dis(const DtVector& in, DtVector& out) const;
49 
50  virtual DtVector down(const DtVector& location) const;
51  virtual void topoToLocal(const DtVector& localPosition, DtDcm& topoToLocal) const;
52  virtual void localToTopo(const DtVector& localPosition, DtDcm& localToTopo) const;
53 
54  // Returns the geodetic coordinate for a given local position.
55  virtual void localToGeodetic(const DtVector& localPosition,
56  DtGeodeticCoord& geodeticPosition) const;
57 
58  // Returns the local coordinate for a given geodetic position.
59  virtual void geodeticToLocal(const DtGeodeticCoord& geodeticPosition,
60  DtVector& localPosition) const;
61 
62  virtual void initFromLatLon(double latRadians, double lonRadians);
63 
64  virtual void init();
65 
66  // Returns name of coordinate system
67  virtual DtString coordinateSystemName() const;
68  virtual void setOrigin(const DtGeodeticCoord& c);
69 
70  // Override as UTM grid declination calculations should not be used for this
71  virtual DtDcm topoToUtmMatrix(const DtVector& geocLoc) const;
72  virtual DtDcm utmToTopoMatrix(const DtVector& geocLoc) const;
73 
74 protected:
75  double myRefLatitude;
77 
78 public:
79  // Radius of the earth used in the Multigen Flat Earth projection.
80  // (defined to be 6366707.02 meters).
81  // This value was taken from the SRM_EOR_MFE enumerant in the
82  // SRM_Ellipsoid_Of_Revolution table on the SEDRIS web site
83  // (www.sedris.org).
84  static const double theMultigenFlatEarthRadius;
85 };
86 
87 #endif
Definition: flatEarthCS.h:21
virtual void setOrigin(const DtGeodeticCoord &)
double myRefLatitude
Definition: flatEarthCS.h:75
virtual void localToTopo(const DtVector &localPosition, DtDcm &localToTopo) const
Definition: coordSystem.h:54
virtual void local2dis(const DtVector &in, DtVector &out) const
virtual void dis2local(const DtVector &in, DtVector &out) const
virtual void topoToLocal(const DtVector &localPosition, DtDcm &topoToLocal) const
Coordinate_System & operator=(const Coordinate_System &orig)
virtual void geodeticToLocal(const DtGeodeticCoord &geodeticPosition, DtVector &localPosition) const
virtual DtVector down(const DtVector &localPosition) const
virtual Coordinate_System * clone() const
static const double theMultigenFlatEarthRadius
Definition: flatEarthCS.h:84
double myRefLongitude
Definition: flatEarthCS.h:76
virtual void localToGeodetic(const DtVector &localPosition, DtGeodeticCoord &geodeticPosition) const
DT_DLL_DEBUGDRAWRENDERER void init(makVrv::DtDe &de)
Work function for the plugin initialization.
virtual DtString coordinateSystemName() const
#define DT_DLL_terrainCS
Definition: terrainCSDefines.h:23

Document ID: Generated on Tue Sep 24 19:28:17 EDT 2024 from SVN revision 269799
Copyright © 2005-2024 MAK Technologies. All Rights Reserved (www.mak.com)