diff --git a/modules/photo/src/calibrate.cpp b/modules/photo/src/calibrate.cpp index 23b612995a..e9fb461f5b 100644 --- a/modules/photo/src/calibrate.cpp +++ b/modules/photo/src/calibrate.cpp @@ -104,7 +104,7 @@ public: for(size_t i = 0; i < sample_points.size(); i++) { for(size_t j = 0; j < images.size(); j++) { - int val = images[j].ptr()[3*(sample_points[i].y * images[j].cols + sample_points[j].x) + channel]; + int val = images[j].ptr()[3*(sample_points[i].y * images[j].cols + sample_points[i].x) + channel]; A.at(eq, val) = w.at(val); A.at(eq, LDR_SIZE + (int)i) = -w.at(val); B.at(eq, 0) = w.at(val) * log(times.at((int)j));