Skip to content

Calibration API

Karloina edited this page Apr 23, 2018 · 4 revisions

Description of Calibration module API

How to use CameraCalibration class

  1. Create CameraCalibration object using one of two constructors.
    • CameraCalibration(std::string), as the first parameter you have to provide settings file path (as default it's "default.xml"),
    • CameraCalibration(std::string, std::string), the first parameter is the same as above, the second one is path to calibration exported file.
  2. If you chose the first constructor you have to run init() method by CameraCalibration object to initiate camera calibration process. Otherwise (if you chose the second constructor) you don't have to kick off camera calibration process, because you have already provided camera matrix and distortion coefficients by second param.
  3. Finally, use GetUndistortedImage(cv::Mat) by CameraCalibration object and provide (as param) any distorted image to obtain undistorted image.

Resources

Clone this wiki locally