fixed incorrect array access in solvepnp (which affected debug builds only)

This commit is contained in:
Vadim Pisarevsky
2014-10-17 17:01:39 +04:00
parent 3f37e034a0
commit 4038beb67e

View File

@@ -73,12 +73,12 @@ private:
{ {
for(int i = 0; i < number_of_correspondences; i++) for(int i = 0; i < number_of_correspondences; i++)
{ {
pws[3 * i ] = opoints.at<OpointType>(0,i).x; pws[3 * i ] = opoints.at<OpointType>(i).x;
pws[3 * i + 1] = opoints.at<OpointType>(0,i).y; pws[3 * i + 1] = opoints.at<OpointType>(i).y;
pws[3 * i + 2] = opoints.at<OpointType>(0,i).z; pws[3 * i + 2] = opoints.at<OpointType>(i).z;
us[2 * i ] = ipoints.at<IpointType>(0,i).x; us[2 * i ] = ipoints.at<IpointType>(i).x;
us[2 * i + 1] = ipoints.at<IpointType>(0,i).y; us[2 * i + 1] = ipoints.at<IpointType>(i).y;
} }
} }