WSF
BrawlerCoordinateConversion.hpp
Go to the documentation of this file.
1// ****************************************************************************
2// CUI//REL TO USA ONLY
3//
4// The Advanced Framework for Simulation, Integration, and Modeling (AFSIM)
5//
6// Copyright 2003-2015 The Boeing Company. All rights reserved.
7//
8// The use, dissemination or disclosure of data in this file is subject to
9// limitation or restriction. See accompanying README and LICENSE for details.
10// ****************************************************************************
11
12#ifndef BRAWLERCOORDINATECONVERSION_HPP
13#define BRAWLERCOORDINATECONVERSION_HPP
14
15#include "brawler_export.h"
16
17#include "UtEntity.hpp"
18#include "UtVec3.hpp"
19
21//
22// This class converts between a geodetic (LLA) coordinate system and
23// a flat-earth (NED) coordinate system. Right now a simple round earth
24// approximation is being used, but a more robust conversion should be
25// implemented: LLC, TM, or EQR.
26//
28class BRAWLER_EXPORT BrawlerCoordinateConversion
29{
30public:
31 // LLA in (degrees, degrees, meters)
32 // NED in (feet, feet, feet)
33 static UtVec3d ConvertLLAtoNED(UtVec3d& lla);
34 static UtVec3d ConvertNEDtoLLA(UtVec3d& ned);
35
36 static UtVec3d GetPositionNED(UtEntity& ref);
37 static UtVec3d GetVelocityNED(UtEntity& ref); // TODO - test this
38 static UtVec3d GetAccelerationNED(UtEntity& ref); // TODO - test this
39 static UtVec3d GetOrientationNED(UtEntity& ref); // TODO - test this
40
41 static UtVec3d RelativePositionNED(UtEntity& ref, UtEntity& tgt);
42 static UtVec3d RelativePositionNED(UtVec3d& llaRef, UtVec3d& llaTgt);
43 static UtVec3d RelativeVelocityNED(UtEntity& ref, UtEntity& tgt);
44
45 static void RegisterLocationLLA(UtVec3d& lla);
46 static void RegisterLocationEntity(UtEntity& ref);
47
48 // TODO - these are place holders until we get a proper flat earth coordinate conversion in place
49 static bool mReferenceSet;
50 static double mRefLat;
51 static double mRefLon;
52};
53
54#endif
Definition BrawlerCoordinateConversion.hpp:29
static UtVec3d RelativeVelocityNED(UtEntity &ref, UtEntity &tgt)
Definition BrawlerCoordinateConversion.cpp:121
static double mRefLon
Definition BrawlerCoordinateConversion.hpp:51
static UtVec3d ConvertNEDtoLLA(UtVec3d &ned)
Definition BrawlerCoordinateConversion.cpp:38
static UtVec3d GetPositionNED(UtEntity &ref)
Definition BrawlerCoordinateConversion.cpp:53
static UtVec3d ConvertLLAtoNED(UtVec3d &lla)
Definition BrawlerCoordinateConversion.cpp:25
static double mRefLat
Definition BrawlerCoordinateConversion.hpp:50
static void RegisterLocationLLA(UtVec3d &lla)
Definition BrawlerCoordinateConversion.cpp:130
static UtVec3d GetAccelerationNED(UtEntity &ref)
Definition BrawlerCoordinateConversion.cpp:70
static UtVec3d RelativePositionNED(UtEntity &ref, UtEntity &tgt)
Definition BrawlerCoordinateConversion.cpp:87
static UtVec3d GetVelocityNED(UtEntity &ref)
Definition BrawlerCoordinateConversion.cpp:61
static UtVec3d GetOrientationNED(UtEntity &ref)
Definition BrawlerCoordinateConversion.cpp:79
static bool mReferenceSet
Definition BrawlerCoordinateConversion.hpp:49
static void RegisterLocationEntity(UtEntity &ref)
Definition BrawlerCoordinateConversion.cpp:141
Copyrights Multiple, All Rights Reserved