Method RegisterCameras
- Namespace
- OpenCvSharp
- Assembly
- OpenCvSharp.dll
RegisterCameras(IEnumerable<Mat>, IEnumerable<Mat>, IEnumerable<Mat>, IEnumerable<Mat>, InputArray, InputArray, CameraModel, InputArray, InputArray, CameraModel, InputOutputArray, InputOutputArray, OutputArray, OutputArray, OutputArray, CalibrationFlags, TermCriteria?)
Registers a pair of cameras (OpenCV 5), estimating the relative pose (R, T) between them. The two cameras may use different camera models (pinhole / fisheye).
public static double RegisterCameras(IEnumerable<Mat> objectPoints1, IEnumerable<Mat> objectPoints2, IEnumerable<Mat> imagePoints1, IEnumerable<Mat> imagePoints2, InputArray cameraMatrix1, InputArray distCoeffs1, CameraModel cameraModel1, InputArray cameraMatrix2, InputArray distCoeffs2, CameraModel cameraModel2, InputOutputArray r, InputOutputArray t, OutputArray e, OutputArray f, OutputArray perViewErrors, CalibrationFlags flags = CalibrationFlags.None, TermCriteria? criteria = null)
Parameters
objectPoints1IEnumerable<Mat>Object points observed by the first camera.
objectPoints2IEnumerable<Mat>Object points observed by the second camera.
imagePoints1IEnumerable<Mat>Image points for the first camera.
imagePoints2IEnumerable<Mat>Image points for the second camera.
cameraMatrix1InputArrayIntrinsic matrix of the first camera.
distCoeffs1InputArrayDistortion coefficients of the first camera.
cameraModel1CameraModelCamera model of the first camera.
cameraMatrix2InputArrayIntrinsic matrix of the second camera.
distCoeffs2InputArrayDistortion coefficients of the second camera.
cameraModel2CameraModelCamera model of the second camera.
rInputOutputArrayInput/Output rotation between the first and second camera coordinate systems.
tInputOutputArrayInput/Output translation between the camera coordinate systems.
eOutputArrayOutput essential matrix.
fOutputArrayOutput fundamental matrix.
perViewErrorsOutputArrayOutput per-view RMS reprojection errors.
flagsCalibrationFlagsOperation flags. Only UseExtrinsicGuess is supported.
criteriaTermCriteria?Termination criteria for the iterative optimization algorithm.
Returns
- double
Overall RMS reprojection error.