Template Function aslam::common::buildUndistortMap

Function Documentation

template<typename InputDerivedCameraType, typename OutputDerivedCameraType>
void aslam::common::buildUndistortMap(const InputDerivedCameraType &input_camera, const OutputDerivedCameraType &output_camera, int map_type, cv::OutputArray map_u, cv::OutputArray map_v)

Calculates the undistortion maps for the given camera geometries.

  • [in] input_camera: Input camera geometry

  • [in] output_camera_matrix: Desired output camera matrix (see getOptimalNewCameraMatrix)

  • [in] scale: Output image size scaling parameter wrt. to input image size.

  • [in] map_type: Type of the output maps. (cv::CV_32FC1, cv::CV_32FC2 or cv::CV_16SC2) Use cv::CV_16SC2 if you don’t know what to choose. (fastest fixed-point)

  • [out] map_u: Map that transforms u-coordinates from distorted to undistorted image plane.

  • [out] map_v: Map that transforms v-coordinates from distorted to undistorted image plane.