enum { SOLVEPNP_ITERATIVE = 0,
SOLVEPNP_EPNP = 1, //!< EPnP: Efficient Perspective-n-Point Camera Pose Estimation @cite lepetit2009epnp
SOLVEPNP_P3P = 2, //!< Complete Solution Classification for the Perspective-Three-Point Problem @cite gao2003complete
SOLVEPNP_DLS = 3, //!< A Direct Least-Squares (DLS) Method for PnP @cite hesch2011direct
SOLVEPNP_UPNP = 4, //!< Exhaustive Linearization for Robust Camera Pose and Focal Length Estimation @cite penate2013exhaustive
SOLVEPNP_AP3P = 5, //!< An Efficient Algebraic Solution to the Perspective-Three-Point Problem @cite Ke17
SOLVEPNP_MAX_COUNT //!< Used for count
};
solvePnP() - opencv/modules/calib3d/src/solvepnp.cpp
bool solvePnP( InputArray _opoints, InputArray _ipoints,
InputArray _cameraMatrix, InputArray _distCoeffs,
OutputArray _rvec, OutputArray _tvec, bool useExtrinsicGuess, int flags )
{ ...
cvFindExtrinsicCameraParams2() - opencv/modules/calib3d/src/calibration.cpp
CV_IMPL void cvFindExtrinsicCameraParams2( const CvMat* objectPoints,
const CvMat* imagePoints, const CvMat* A,
const CvMat* distCoeffs, CvMat* rvec, CvMat* tvec,
int useExtrinsicGuess )
cvFindHomography() - opencv/modules/calib3d/src/compat_ptsetreg.cpp
CV_IMPL int cvFindHomography( const CvMat* _src, const CvMat* _dst, CvMat* __H, int method,
double ransacReprojThreshold, CvMat* _mask, int maxIters,
double confidence)
cv::findHomography() - opencv/modules/calib3d/src/fundam.cpp
cv::Mat cv::findHomography( InputArray _points1, InputArray _points2,
int method, double ransacReprojThreshold, OutputArray _mask,
const int maxIters, const double confidence)
method: 最小中值法、RANSAC方法、最小二乘法 ref
cvConvertPointsHomogeneous() - modules/calib3d/src/compat_ptsetreg.cpp - doc doc2
Converts points to/from homogeneous coordinates. - 轉換點 至 齊次座標
CV_IMPL void cvConvertPointsHomogeneous( const CvMat* _src, CvMat* _dst )
urbste/MLPnP_matlab_toolbox - The toolbox is a collection of PnP methods for Matlab. 有時間試試