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