snake_geometry.h.orig 1.1 KB
Newer Older
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36
#pragma once
#include <vector>
#include <array>

#include "WGS84toCartesian.hpp"

namespace snake_geometry {

typedef std::array<double, 2>   Point2D;
typedef std::vector<Point2D>         Point2DList;
typedef std::array<double, 3>   Point3D;
typedef std::vector<Point3D>         Point3DList;
typedef std::array<double, 2>   GeoPoint2D;
typedef std::vector<GeoPoint2D>      GeoPoint2DList;
typedef std::array<double, 3>   GeoPoint3D;
typedef std::vector<GeoPoint3D>      GeoPoint3DList;

typedef struct {
    double width;
    double height;
    double angle;
    std::array<Point2D,4> corners;
}min_bbox_rt;

<<<<<<< HEAD
    Point3D toENU(const GeoPoint3D &WGS84Reference, const GeoPoint3D &WGS84Position);
    GeoPoint3D fromENU(const Point3D &WGS84Reference, const Point3D &CartesianPosition);
=======
Point3D toENU(const Point3D &WGS84Reference, const Point3D &WGS84Position);
Point3D fromENU(const Point3D &WGS84Reference, const Point3D &CartesianPosition);
>>>>>>> 5687fb4553282f37531aa25fac4d66ec9a84932e

Point2D polygonCenter(const Point2DList &polygon);
min_bbox_rt minimalBoundingBox(const Point2DList &polygon);

}