Ver Fonte

add gps_type

zhangjia há 4 anos atrás
pai
commit
1c0cb66094
1 ficheiros alterados com 109 adições e 99 exclusões
  1. 109 99
      src/decition/common/common/gps_type.h

+ 109 - 99
src/decition/common/common/gps_type.h

@@ -1,99 +1,109 @@
-#pragma once
-/*
-*GPS 惯导数据
-*/
-#ifndef _IV_COMMON_GPS_TYPE_
-#define _IV_COMMON_GPS_TYPE_
-
-#include <common/boost.h>
-namespace iv {
-    struct GPS_INS
-    {
-        int valid = 0xff;
-        int index = 0;	//gps点序号
-
-        double gps_lat = 0;//纬度
-        double gps_lng = 0;//经度
-
-        double gps_x = 0;
-        double gps_y = 0;
-        double gps_z = 0;
-
-        double ins_roll_angle = 0;	//横滚角 一般定义载体的右、前、上三个方向构成右手系,绕向前的轴旋转就是横滚角,绕向右的轴旋转就是俯仰角,绕向上的轴旋转就是航向角
-        double ins_pitch_angle = 0;	//俯仰角
-        double ins_heading_angle = 0;	//航向角
-
-        int ins_status = 0;	//惯导状态 4
-        int rtk_status = 0;	//rtk状态 6 -5 -3
-        int gps_satelites_num = 0;
-
-        //-----加速度--------------
-        double accel_x = 0;
-        double accel_y = 0;
-        double accel_z = 0;
-
-        //-------角速度------------
-        double ang_rate_x = 0;
-        double ang_rate_y = 0;
-        double ang_rate_z = 0;
-
-        //-----------方向速度--------------
-        double vel_N = 0;
-        double vel_E = 0;
-        double vel_D = 0;
-
-        int speed_mode = 0;
-        int mode2 = 0;
-        double speed = 0;			//速度  若导航点则为导航预设速度  若为当前点则为当前车速
-
-        int roadMode;
-        int runMode;
-        int roadSum;
-        int roadOri;
-
-
-
-    };
-
-//    typedef std::shared_ptr<iv::GPS_INS> GPSData;
-    typedef boost::shared_ptr<iv::GPS_INS> GPSData;
-     class Point2D
-    {
-      public:
-          double x = 0, y = 0, speed=0;
-         int v1 = 0, v2 = 0;
-         int roadMode = 0;
-
-         Point2D()
-        {
-            x = y = v1 = 0;
-        }
-
-         Point2D(double _x, double _y)
-        {
-            x = _x; y = _y;
-        }
-
-
-     };
-
-
-     class TrafficLight
-    {
-      public:
-         int leftColor = 0, rightColor = 0, straightColor=0, uturnColor=0;
-         int leftTime=0, rightTime=0 ,straightTime=0, uturnTime=0;
-
-         TrafficLight()
-        {
-            leftColor = 0, rightColor = 0, straightColor=0, uturnColor=0;
-            leftTime=0, rightTime=0 ,straightTime=0, uturnTime=0;
-        }
-
-     };
-
-
-
-
-}
-#endif // !_IV_COMMON_GPS_TYPE_
+#pragma once
+/*
+*GPS 惯导数据
+*/
+#ifndef _IV_COMMON_GPS_TYPE_
+#define _IV_COMMON_GPS_TYPE_
+
+#include <common/boost.h>
+namespace iv {
+    struct GPS_INS
+    {
+        int valid = 0xff;
+        int index = 0;	//gps点序号
+
+        double gps_lat = 0;//纬度
+        double gps_lng = 0;//经度
+
+        double gps_x = 0;
+        double gps_y = 0;
+        double gps_z = 0;
+
+        double ins_roll_angle = 0;	//横滚角 一般定义载体的右、前、上三个方向构成右手系,绕向前的轴旋转就是横滚角,绕向右的轴旋转就是俯仰角,绕向上的轴旋转就是航向角
+        double ins_pitch_angle = 0;	//俯仰角
+        double ins_heading_angle = 0;	//航向角
+
+        int ins_status = 0;	//惯导状态 4
+        int rtk_status = 0;	//rtk状态 6 -5 -3
+        int gps_satelites_num = 0;
+
+        //-----加速度--------------
+        double accel_x = 0;
+        double accel_y = 0;
+        double accel_z = 0;
+
+        //-------角速度------------
+        double ang_rate_x = 0;
+        double ang_rate_y = 0;
+        double ang_rate_z = 0;
+
+        //-----------方向速度--------------
+        double vel_N = 0;
+        double vel_E = 0;
+        double vel_D = 0;
+
+        int speed_mode = 0;
+        int mode2 = 0;
+        double speed = 0;			//速度  若导航点则为导航预设速度  若为当前点则为当前车速
+
+        int roadMode;
+        int runMode;
+        int roadSum;
+        int roadOri;
+
+
+
+    };
+
+//    typedef std::shared_ptr<iv::GPS_INS> GPSData;
+    typedef boost::shared_ptr<iv::GPS_INS> GPSData;
+
+   struct Station
+   {
+       int index;
+       GPS_INS station_location;
+       int map_index;
+   };
+
+
+
+     class Point2D
+    {
+      public:
+          double x = 0, y = 0, speed=0;
+         int v1 = 0, v2 = 0;
+         int roadMode = 0;
+
+         Point2D()
+        {
+            x = y = v1 = 0;
+        }
+
+         Point2D(double _x, double _y)
+        {
+            x = _x; y = _y;
+        }
+
+
+     };
+
+
+     class TrafficLight
+    {
+      public:
+         int leftColor = 0, rightColor = 0, straightColor=0, uturnColor=0;
+         int leftTime=0, rightTime=0 ,straightTime=0, uturnTime=0;
+
+         TrafficLight()
+        {
+            leftColor = 0, rightColor = 0, straightColor=0, uturnColor=0;
+            leftTime=0, rightTime=0 ,straightTime=0, uturnTime=0;
+        }
+
+     };
+
+
+
+
+}
+#endif // !_IV_COMMON_GPS_TYPE_