Distortion Correction#
Distortion is a form of optical aberration that causes a geometrical imaging error where straight lines don't appear straight in an image.
Using the Feature#
How It Works#
All Basler blaze cameras are calibrated at the Basler factory. The calibration includes the DistortionCorrection
parameter. When enabled, this feature automatically removes any distortion effects. The feature uses the distortion coefficients of the Brown-Conrady model that allow correction of both radial and tangential distortion.
As a rule, the correction should always be enabled. If it is disabled, no automatic distortion correction is performed and the depth maps and intensity images have a distortion error that negatively affects the measurement accuracy.
Depending on the camera model, different mapping functions are used for the correction.
The blaze-101 and blaze-102 use the distortion coefficients of the Brown-Conrady model. The radial distortions are corrected using the following two coefficients:
xd = (1 + k1r2 + k2r4) * xu
where r
is the distance to the principal point
For the blaze-112, the general camera model for wide-angle and fisheye lenses is used. Four coefficients are used here. These are sufficient to map the projection curves with acceptable accuracy.
r(θ) = θ + k1θ3 + k2θ5 + k3θ7 + k4θ9
The distortion coefficients are specific to each camera and can be read out via the Scan3dDistortionCoefficientSelector
and Scan3dDistortionCoefficientValue
parameters if distortion correction is disabled.
Disabling the Distortion Correction#
If you prefer to correct distortion effects yourself, disable the DistortionCorrection
parameter.
The pylon Supplementary Package for blaze includes the Distortion Correction sample that explains this procedure and tells you how to calculate a corrected point cloud.