Camera Models
Camera is the one of the means for machines to perceive the world. The most widely used camera model is the pinhole camera model.
Camera
class Camera
This is the base class of all camera classes.
Pinhole camera
class PinholeCamera
The Camera class contains intrinsic and extrinsic parameters of the camera. The information are stored in both matrix and vector form, and are automatically updated once the other is changed.
R_is the rotation matrix;t_is the translation matrix;std::vector<float> intrinsics_is a 4-element vector storing intrinsic parameters, which includes , , , ;std::vector<float> extrinsics_is a 6-element vector storing extrinsic parameters, which include , , , , , . The first three is the axis-angle representation of rotation matrix, the latter three are coefficients of the translation vector.
The position and orientation of the camera are also stored in the Camera class.
center_represents the center of projection;xaxis_,yaxis_,zaxis_store the axes of camera coordinate system;oaxis_stores principle axis.
void update_projection()
update the projection matrix from intrinsic and extrinsic matrices K_, R_, t_.
void update_projection()
update the camera parameter vectors from matrices.
void update_matrices(const is is_proj_mat)
update camera parameter matrices from either projection matrix or camera parameter vectors.
const Mat3f& projection() const;
Mat34f& projection();
return references to the projection matrix.
const Vec3f& direction() const;
Vec3f& direction();
return references to the principal axis.
const Vec3f& center() const;
Vec3f& center();
return references to the center of projection.