moved camera calibration information into a struct to make data handling smoother
This commit is contained in:
@ -15,6 +15,21 @@
|
||||
#include "imu_state.h"
|
||||
|
||||
namespace msckf_vio {
|
||||
|
||||
struct IlluminationParameter{
|
||||
double frame_bias;
|
||||
double frame_gain;
|
||||
double feature_bias;
|
||||
double feature_gain;
|
||||
};
|
||||
|
||||
struct CameraCalibration{
|
||||
std::string distortion_model;
|
||||
cv::Vec2i resolution;
|
||||
cv::Vec4d intrinsics;
|
||||
cv::Vec4d distortion_coeffs;
|
||||
};
|
||||
|
||||
/*
|
||||
* @brief CAMState Stored camera state in order to
|
||||
* form measurement model.
|
||||
@ -35,7 +50,7 @@ struct CAMState {
|
||||
// Position of the camera frame in the world frame.
|
||||
Eigen::Vector3d position;
|
||||
|
||||
//Illumination illumination;
|
||||
IlluminationParameter illumination;
|
||||
|
||||
// These two variables should have the same physical
|
||||
// interpretation with `orientation` and `position`.
|
||||
|
@ -22,6 +22,8 @@
|
||||
#include <message_filters/subscriber.h>
|
||||
#include <message_filters/time_synchronizer.h>
|
||||
|
||||
#include "cam_state.h"
|
||||
|
||||
namespace msckf_vio {
|
||||
|
||||
/*
|
||||
@ -332,15 +334,8 @@ private:
|
||||
std::vector<sensor_msgs::Imu> imu_msg_buffer;
|
||||
|
||||
// Camera calibration parameters
|
||||
std::string cam0_distortion_model;
|
||||
cv::Vec2i cam0_resolution;
|
||||
cv::Vec4d cam0_intrinsics;
|
||||
cv::Vec4d cam0_distortion_coeffs;
|
||||
|
||||
std::string cam1_distortion_model;
|
||||
cv::Vec2i cam1_resolution;
|
||||
cv::Vec4d cam1_intrinsics;
|
||||
cv::Vec4d cam1_distortion_coeffs;
|
||||
CameraCalibration cam0;
|
||||
CameraCalibration cam1;
|
||||
|
||||
// Take a vector from cam0 frame to the IMU frame.
|
||||
cv::Matx33d R_cam0_imu;
|
||||
|
@ -221,15 +221,9 @@ class MsckfVio {
|
||||
movingWindow cam1_moving_window;
|
||||
|
||||
// Camera calibration parameters
|
||||
std::string cam0_distortion_model;
|
||||
cv::Vec2i cam0_resolution;
|
||||
cv::Vec4d cam0_intrinsics;
|
||||
cv::Vec4d cam0_distortion_coeffs;
|
||||
CameraCalibration cam0;
|
||||
CameraCalibration cam1;
|
||||
|
||||
std::string cam1_distortion_model;
|
||||
cv::Vec2i cam1_resolution;
|
||||
cv::Vec4d cam1_intrinsics;
|
||||
cv::Vec4d cam1_distortion_coeffs;
|
||||
|
||||
// Indicate if the gravity vector is set.
|
||||
bool is_gravity_set;
|
||||
|
Reference in New Issue
Block a user