MRPT
2.0.3
pnp
ppnp.h
Go to the documentation of this file.
1
/* +------------------------------------------------------------------------+
2
| Mobile Robot Programming Toolkit (MRPT) |
3
| https://www.mrpt.org/ |
4
| |
5
| Copyright (c) 2005-2020, Individual contributors, see AUTHORS file |
6
| See: https://www.mrpt.org/Authors - All rights reserved. |
7
| Released under BSD License. See: https://www.mrpt.org/License |
8
+------------------------------------------------------------------------+ */
9
//#include <mrpt/math/types_math.h> // Eigen must be included first via MRPT to
10
// enable the plugin system
11
#include <Eigen/Dense>
12
#include <iostream>
13
14
namespace
mrpt::vision::pnp
15
{
16
/** \addtogroup pnp Perspective-n-Point pose estimation
17
* \ingroup mrpt_vision_grp
18
* @{
19
*/
20
21
/**
22
* @class ppnp
23
* @author Chandra Mangipudi
24
* @date 10/08/16
25
* @file ppnp.h
26
* @brief Procrustes - PnP
27
*/
28
class
ppnp
29
{
30
public
:
31
//! Constructor for the P-PnP class
32
ppnp
(
33
const
Eigen::MatrixXd& obj_pts,
const
Eigen::MatrixXd& img_pts,
34
const
Eigen::MatrixXd& cam_intrinsic);
35
36
/**
37
* @brief Function to compute pose
38
* @param[out] R Rotation matrix
39
* @param t Trnaslation Vector
40
* @param n Number of 2d/3d correspondences
41
* @return
42
*/
43
bool
compute_pose
(Eigen::Matrix3d&
R
, Eigen::Vector3d& t,
int
n);
44
45
private
:
46
Eigen::MatrixXd
P
;
//! Image points in pixels
47
Eigen::MatrixXd
S
;
//! Object points in Camera Co-ordinate system
48
Eigen::MatrixXd
C
;
//! Camera intrinsic matrix
49
};
50
51
/** @} */
// end of grouping
52
}
// namespace mrpt::vision::pnp
mrpt::vision::pnp::ppnp::P
Eigen::MatrixXd P
Definition:
ppnp.h:46
R
const float R
Definition:
CKinematicChain.cpp:137
mrpt::vision::pnp
Perspective n Point (PnP) Algorithms toolkit for MRPT.
Definition:
pnp_algos.h:23
mrpt::vision::pnp::ppnp
Definition:
ppnp.h:28
mrpt::vision::pnp::ppnp::S
Eigen::MatrixXd S
Image points in pixels.
Definition:
ppnp.h:47
mrpt::vision::pnp::ppnp::compute_pose
bool compute_pose(Eigen::Matrix3d &R, Eigen::Vector3d &t, int n)
Function to compute pose.
Definition:
ppnp.cpp:29
mrpt::vision::pnp::ppnp::ppnp
ppnp(const Eigen::MatrixXd &obj_pts, const Eigen::MatrixXd &img_pts, const Eigen::MatrixXd &cam_intrinsic)
Constructor for the P-PnP class.
Definition:
ppnp.cpp:20
mrpt::vision::pnp::ppnp::C
Eigen::MatrixXd C
Object points in Camera Co-ordinate system.
Definition:
ppnp.h:48
Page generated by
Doxygen 1.8.17
for MRPT 2.0.3 at Fri May 29 13:06:46 UTC 2020