blob: d03806969914f5a75d91f8966ac12c3a60257928 (
plain)
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
57
58
|
#ifndef camera_INC
#define camera_INC
#include <Eigen/Dense>
#include <iostream>
#include <yaml-cpp/yaml.h>
#define BINNING 0.5 // set the binning factor
#define YAWCORRECT 2.0
//#define DOYAWCORRECT
using Eigen::Matrix;
using Eigen::Vector4d;
using Eigen::Vector3d;
using Eigen::Quaterniond;
using std::cout;
using std::cerr;
using std::endl;
/*
* =====================================================================================
* Class: Camera
* Description: Class for the camera.
* =====================================================================================
*/
class Camera
{
public:
/* ==================== LIFECYCLE ======================================= */
Camera (const char *fin); /* constructor */
/* ==================== ACCESSORS ======================================= */
Matrix<double,3,3> K();
Matrix<double,4,4> K4();
Vector4d d();
Matrix<double,3,3> Rc2b();
Matrix<double,4,4> Rc2b4();
/* ==================== MUTATORS ======================================= */
/* ==================== OPERATORS ======================================= */
Vector3d img2body(Vector3d &xi);
protected:
/* ==================== METHODS ======================================= */
/* ==================== DATA MEMBERS ======================================= */
private:
/* ==================== METHODS ======================================= */
/* ==================== DATA MEMBERS ======================================= */
Matrix<double,3,3> _K;
Matrix<double,4,4> _T;
Vector4d _d;
}; /* ----- end of class Camera ----- */
#endif /* ----- #ifndef camera_INC ----- */
|