-
Notifications
You must be signed in to change notification settings - Fork 0
/
types.hpp
56 lines (46 loc) · 1.13 KB
/
types.hpp
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
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
#ifndef RECORDER_TYPES_H_
#define RECORDER_TYPES_H_
namespace cv { class Mat; } // fwd decl
namespace recorder {
struct Vector3d {
double x, y, z;
};
struct Quaternion {
double x, y, z, w;
};
struct Pose {
/** Timestamp in seconds. Monotonically increasing */
double time;
/**
* 3D position in a right-handed metric coordinate system
* where the z-axis points up
*/
Vector3d position;
/** Orientation quaternion in the same coordinate system as position */
Quaternion orientation;
};
struct FrameData {
/** Timestamp in seconds. Monotonically increasing */
double t;
/** Index to separate multiple cameras. 0, 1, … */
int cameraInd;
double focalLengthX;
double focalLengthY;
/** Principal point **/
double px;
double py;
/** Optional: Frame data as an OpenCV matrix. If present, recorded to a video file */
const cv::Mat *frameData = nullptr;
};
struct AccelerometerData {
double t;
double x, y, z;
double temperature = -1.0;
};
struct GyroscopeData {
double t;
double x, y, z;
double temperature = -1.0;
};
} // namespace recorder
#endif