class mrpt::vision::pnp::rpnp
Overview
Chandra Mangipudi
10/08/16
#include </home/jlblanco/mrpt/libs/vision/src/pnp/rpnp.h> class rpnp { public: // construction rpnp( Eigen::MatrixXd obj_pts_, Eigen::MatrixXd img_pts_, Eigen::MatrixXd cam_, int n0 ); // methods bool compute_pose(Eigen::Ref<Eigen::Matrix3d> R_, Eigen::Ref<Eigen::Vector3d> t_); Eigen::VectorXd getp3p( double l1, double l2, double A5, double C1, double C2, double D1, double D2, double D3 ); Eigen::VectorXd getpoly7(const Eigen::VectorXd& vin); void calcampose( Eigen::MatrixXd& XXc, Eigen::MatrixXd& XXw, Eigen::Matrix3d& R2, Eigen::Vector3d& t2 ); };
Construction
rpnp( Eigen::MatrixXd obj_pts_, Eigen::MatrixXd img_pts_, Eigen::MatrixXd cam_, int n0 )
Number of 2D/3D correspondences.
Constructor for rpnp class
Methods
bool compute_pose( Eigen::Ref<Eigen::Matrix3d> R_, Eigen::Ref<Eigen::Vector3d> t_ )
Function to compute pose.
Parameters:
R_  | 
Rotaiton matrix  | 
t_  | 
Translation vector  | 
Returns:
Success flag
Eigen::VectorXd getp3p( double l1, double l2, double A5, double C1, double C2, double D1, double D2, double D3 )
Function to compute pose using P3P.
Parameters:
l1  | 
Internal parameter for P3P computation  | 
l2  | 
Internal parameter for P3P computation  | 
A5  | 
Internal parameter for P3P computation  | 
C1  | 
Internal parameter for P3P computation  | 
C2  | 
Internal parameter for P3P computation  | 
D1  | 
Internal parameter for P3P computation  | 
D2  | 
Internal parameter for P3P computation  | 
D3  | 
Internal parameter for P3P computation  | 
Returns:
Output vector
Eigen::VectorXd getpoly7(const Eigen::VectorXd& vin)
Get Polynomial from input vector.
Parameters:
vin  | 
Input vector  | 
Returns:
Output Polynomial co-efficients
void calcampose( Eigen::MatrixXd& XXc, Eigen::MatrixXd& XXw, Eigen::Matrix3d& R2, Eigen::Vector3d& t2 )
Function to calculate final pose.
Parameters:
XXc  | 
Object points  | 
XXw  | 
Image Points  | 
R2  | 
Final Rotation matrix  | 
t2  | 
Final Translation vector  |