Commit aa3dada2 authored by Ilya Lysenkov's avatar Ilya Lysenkov

Added support of the CV_64F depth to solvePnP (ticket #835)

parent e4bbcdac
......@@ -48,8 +48,8 @@ void cv::solvePnP( const InputArray& _opoints, const InputArray& _ipoints,
OutputArray _rvec, OutputArray _tvec, bool useExtrinsicGuess )
{
Mat opoints = _opoints.getMat(), ipoints = _ipoints.getMat();
int npoints = opoints.checkVector(3, CV_32F);
CV_Assert( npoints >= 0 && npoints == ipoints.checkVector(2, CV_32F) );
int npoints = std::max(opoints.checkVector(3, CV_32F), opoints.checkVector(3, CV_64F));
CV_Assert( npoints >= 0 && npoints == std::max(ipoints.checkVector(2, CV_32F), ipoints.checkVector(2, CV_64F)) );
_rvec.create(3, 1, CV_64F);
_tvec.create(3, 1, CV_64F);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment