Skip to content

omnidir_undistortPoints

ccalibfunctionOpenCV 5.0.0
import { omnidir_undistortPoints } from '@banou/opencv-wasm'

Use after await initOpenCV(). See the initialization and named imports guide.

ARGUMENTSdistorted, undistorted, K, D
FUNCTIONomnidir_undistortPoints
RETURN TYPEvoid
Call structure. A void return can still write to destination arguments. The parameter descriptions define inputs, outputs and ownership.

Undistort 2D image points for omnidirectional camera using CMei's model

omnidir_undistortPoints(distorted: Mat, undistorted: Mat, K: Mat, D: Mat, xi: Mat, R: Mat): void;
distorted

Array of distorted image points, vector of Vec2f or 1xN/Nx1 2-channel Mat of type CV_32F, 64F depth is also acceptable

undistorted

Output destination, filled by the native operation. array of normalized object points, vector of Vec2f/Vec2d or 1xN/Nx1 2-channel Mat with the same depth of distorted points.

K

Camera matrix K = \vecthreethree{f_x}{s}{c_x}{0}{f_y}{c_y}{0}{0}{_1}.

D

Distortion coefficients (k_1, k_2, p_1, p_2).

xi

The parameter xi for CMei's model

R

Rotation trainsform between the original and object space : 3x3 1-channel, or vector: 3x1/1x3 1-channel or 1x1 3-channel

These signatures describe this package. Upstream documentation can mention optional backends that are absent from this build. Check runtime compatibility before choosing a backend or file format.