Hi,
In camera_calibration.cpp under the folder tutorial_code\calib3d\camera_calibration, for function runCalibration(), the object points coordinates are calculated as:
objectPoints[0][s.boardSize.width - 1].x = objectPoints[0][0].x + grid_width;
in which the grid_width is calcualted as:
grid_width = s.squareSize * (s.boardSize.width - 1);
The s.squareSize is half of the distance between two neighboring circle center. I think a factor 2.0 is missing for the grid_width calculation. In another words, the grid_width should be:
grid_width = 2.0 * s.squareSize * (s.boardSize.width - 1);
Yixun