Fixed solvePnPRansac minInliers parameter changed to confidence in OpenCV3

This commit is contained in:
matlabbe
2015-07-27 16:13:34 -04:00
parent 1d926fe867
commit c717020405
4 changed files with 16 additions and 3 deletions

View File

@@ -244,6 +244,7 @@ Transform OdometryBOW::computeTransform(
UASSERT(data.stereoCameraModel().isValid() || (data.cameraModels().size() == 1 && data.cameraModels()[0].isValid()));
const CameraModel & cameraModel = data.stereoCameraModel().isValid()?data.stereoCameraModel().left():data.cameraModels()[0];
UDEBUG("");
t = util3d::estimateMotion3DTo2D(
localMap_,
newSignature->getWords(),

View File

@@ -259,7 +259,11 @@ Transform OdometryOpticalFlow::computeTransform(
true,
this->getIterations(),
this->getPnPReprojError(),
0,
#if CV_MAJOR_VERSION < 3
0, // min inliers
#else
0.99, // confidence
#endif
inliersV,
this->getPnPFlags());

View File

@@ -459,7 +459,11 @@ std::multimap<int, pcl::PointXYZ> generateWords3DMono(
true,
pnpIterations,
pnpReprojError,
0,
#if CV_MAJOR_VERSION < 3
0, // min inliers
#else
0.99, // confidence
#endif
inliersV,
pnpFlags);

View File

@@ -110,7 +110,11 @@ Transform estimateMotion3DTo2D(
true,
iterations,
reprojError,
0,
#if CV_MAJOR_VERSION < 3
0, // min inliers
#else
0.99, // confidence
#endif
inliers,
flagsPnP);