WSF
TargetConfig.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// Updated by Infoscitex, a DCS Company.
13// ****************************************************************************
14
15#ifndef TARGETCONFIG_HPP
16#define TARGETCONFIG_HPP
17
18#include <string>
19#include <vector>
20
21class UtInput;
22
23
24namespace engage
25{
26
27class Simulation;
28class Task;
29
31{
32public:
33 struct PathPoint
34 {
35 double mTime;
36 double mPosXYZ[3]; // X, Y, Z position
37 double mVelXYZ[3]; // X, Y, Z velocity
38 double mPitch;
39 double mRoll;
40 double mYaw;
41 };
42 using FlightPathVec = std::vector<PathPoint>;
43
45
46 bool Complete(bool aTargetGridUsed);
47
48 bool CreatePlatform(Simulation& aSimulation, const Task& aTask) const;
49
50 bool ProcessInput(UtInput& aInput);
51 bool ProcessSiteGridInput(UtInput& aInput);
52
53 int GetPointCount() const { return mPointCount; }
54 int GetGridDrCount() const { return mGridDownRangeCount; }
55 int GetGridCrCount() const { return mGridCrossRangeCount; }
56 int GetGridAltCount() const { return mGridAltitudeCount; }
57
58 double GetGridDrMin() const { return mGridDownRangeMin; }
59 double GetGridDrMax() const { return mGridDownRangeMax; }
60 double GetGridDrStep() const { return mGridDownRangeStep; }
61 std::string GetGridDrUnits() const { return mGridCrossRangeUnits; }
62
63 double GetGridCrMin() const { return mGridCrossRangeMin; }
64 double GetGridCrMax() const { return mGridCrossRangeMax; }
65 double GetGridCrStep() const { return mGridCrossRangeStep; }
66 std::string GetGridCrUnits() const { return mGridCrossRangeUnits; }
67
68 double GetGridAltMin() const { return mGridAltitudeMin; }
69 double GetGridAltMax() const { return mGridAltitudeMax; }
70 double GetGridAltStep() const { return mGridAltitudeStep; }
71 std::string GetGridAltUnits() const { return mGridAltitudeUnits; }
72
73 double GetGridSpeed() const { return mGridSpeed; }
74 double GetGridMach() const { return mGridMach; }
75 std::string GetGridSpeedUnits() const { return mGridSpeedUnits; }
76
77 void GetRunPosition(int aTargetIndex, double& aX, double& aY, double& aZ) const;
78
79private:
80 std::string mTargetType;
81
83
84 double mGridDownRangeMin;
85 double mGridDownRangeMax;
86 double mGridDownRangeStep;
87 std::string mGridDownRangeUnits;
88 double mGridCrossRangeMin;
89 double mGridCrossRangeMax;
90 double mGridCrossRangeStep;
91 std::string mGridCrossRangeUnits;
92 double mGridAltitudeMin;
93 double mGridAltitudeMax;
94 double mGridAltitudeStep;
95 std::string mGridAltitudeUnits;
96 double mGridSpeed;
97 double mGridMach;
98 std::string mGridSpeedUnits;
99
101 int mGridPointCount;
102 int mGridDownRangeCount;
103 int mGridCrossRangeCount;
104 int mGridAltitudeCount;
106
108
109 double mSimpleX; // SXT
110 double mSimpleY; // SYT
111 double mSimpleZ; // SZT
112 double mSimpleSpeed; // SVT
113 double mSimpleHeading; // SPSIT
114 double mSimplePitch; // Not in ESAMS
115 double mSimpleRoll; // Not in ESAMS
117
119
120 FlightPathVec mFlightPath;
122
124
125 struct RoutePoint
126 {
127 double mPosXYZ[3]; // X, Y, Z position
128 double mSpeed;
129 };
130
131 std::vector<RoutePoint> mFlightRoute;
133
134 int mPointCount;
135
136 bool mUseTargetPath; // Use the target input for position and path
137};
138
139} // namespace engage
140
141#endif
Definition Simulation.hpp:34
std::string GetGridCrUnits() const
Definition TargetConfig.hpp:66
double GetGridAltStep() const
Definition TargetConfig.hpp:70
bool CreatePlatform(Simulation &aSimulation, const Task &aTask) const
Definition TargetConfig.cpp:99
bool Complete(bool aTargetGridUsed)
This is called when all of the input has been read.
Definition TargetConfig.cpp:77
double GetGridDrStep() const
Definition TargetConfig.hpp:60
int GetGridDrCount() const
Definition TargetConfig.hpp:54
int GetPointCount() const
Definition TargetConfig.hpp:53
double GetGridCrMax() const
Definition TargetConfig.hpp:64
std::string GetGridAltUnits() const
Definition TargetConfig.hpp:71
double GetGridAltMax() const
Definition TargetConfig.hpp:69
double GetGridMach() const
Definition TargetConfig.hpp:74
double GetGridDrMax() const
Definition TargetConfig.hpp:59
std::vector< PathPoint > FlightPathVec
Definition TargetConfig.hpp:42
double GetGridCrStep() const
Definition TargetConfig.hpp:65
void GetRunPosition(int aTargetIndex, double &aX, double &aY, double &aZ) const
Definition TargetConfig.cpp:474
std::string GetGridDrUnits() const
Definition TargetConfig.hpp:61
double GetGridAltMin() const
Definition TargetConfig.hpp:68
int GetGridCrCount() const
Definition TargetConfig.hpp:55
std::string GetGridSpeedUnits() const
Definition TargetConfig.hpp:75
double GetGridSpeed() const
Definition TargetConfig.hpp:73
TargetConfig()
Definition TargetConfig.cpp:38
double GetGridDrMin() const
Definition TargetConfig.hpp:58
double GetGridCrMin() const
Definition TargetConfig.hpp:63
int GetGridAltCount() const
Definition TargetConfig.hpp:56
bool ProcessInput(UtInput &aInput)
Definition TargetConfig.cpp:200
bool ProcessSiteGridInput(UtInput &aInput)
Definition TargetConfig.cpp:427
Definition Task.hpp:47
Definition ApplicationExtension.cpp:26
Definition TargetConfig.hpp:34
double mYaw
Definition TargetConfig.hpp:40
double mPosXYZ[3]
Definition TargetConfig.hpp:36
double mTime
Definition TargetConfig.hpp:35
double mVelXYZ[3]
Definition TargetConfig.hpp:37
double mPitch
Definition TargetConfig.hpp:38
double mRoll
Definition TargetConfig.hpp:39
Copyrights Multiple, All Rights Reserved