Commit 727a3394 authored by Andrey Kamaev's avatar Andrey Kamaev Committed by OpenCV Buildbot

Merge pull request #730 from vpisarev:ba_fix

parents 2a1cf23f 10702c6d
...@@ -435,7 +435,7 @@ namespace cv ...@@ -435,7 +435,7 @@ namespace cv
typedef bool (*BundleAdjustCallback)(int iteration, double norm_error, void* user_data); typedef bool (*BundleAdjustCallback)(int iteration, double norm_error, void* user_data);
class LevMarqSparse { class CV_EXPORTS LevMarqSparse {
public: public:
LevMarqSparse(); LevMarqSparse();
LevMarqSparse(int npoints, // number of points LevMarqSparse(int npoints, // number of points
......
...@@ -1105,7 +1105,7 @@ void LevMarqSparse::bundleAdjust( vector<Point3d>& points, //positions of points ...@@ -1105,7 +1105,7 @@ void LevMarqSparse::bundleAdjust( vector<Point3d>& points, //positions of points
Mat rot_vec = Mat(levmar.P).rowRange(i*num_cam_param, i*num_cam_param+3); Mat rot_vec = Mat(levmar.P).rowRange(i*num_cam_param, i*num_cam_param+3);
Rodrigues( rot_vec, R[i] ); Rodrigues( rot_vec, R[i] );
//translation //translation
T[i] = Mat(levmar.P).rowRange(i*num_cam_param + 3, i*num_cam_param+6); Mat(levmar.P).rowRange(i*num_cam_param + 3, i*num_cam_param+6).copyTo(T[i]);
//intrinsic camera matrix //intrinsic camera matrix
double* intr_data = (double*)cameraMatrix[i].data; double* intr_data = (double*)cameraMatrix[i].data;
......
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