Initial version. Can fly simple mission defined in JSON file.

Please check README.md how to install dependencies and run the application.
This commit is contained in:
Tuomas Järvinen
2024-03-18 22:31:38 +01:00
commit f7acface7f
20 changed files with 1354 additions and 0 deletions
+46
View File
@@ -0,0 +1,46 @@
#pragma once
#include <iostream>
#include <string>
#include <vector>
#include "az_action_point.h"
#include "az_coordinate.h"
using namespace std;
const double INVALID_HEIGHT = -100000;
enum AzGeofenceType { AZ_GEOFENCE_TYPE_NONE = 0, AZ_GEOFENCE_TYPE_INCLUSION = 1, AZ_GEOFENCE_TYPE_EXCLUSION = 2 };
class AzGeofence
{
public:
vector<AzCoordinate> coordinates;
AzGeofenceType type;
};
class AzMission
{
public:
AzMission(string filename);
const vector<AzGeofence> &getGeofences(void) const;
const vector<AzActionPoint> &getActionPoints(void) const;
int getOperationalHeight(void) const;
AzCoordinate getReturnPoint(void) const;
friend std::ostream &operator<<(std::ostream &os, const AzMission &obj);
private:
void parse(void);
string mFilename;
vector<AzGeofence> mGeofences;
vector<AzActionPoint> mActionPoints;
int mOperationalHeight;
AzCoordinate mReturnPoint;
};