Skip to content

sfm_projectionFromKRt

sfmfunctionOpenCV 5.0.0
import { sfm_projectionFromKRt } from '@banou/opencv-wasm'

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

ARGUMENTSK, R, t, P
FUNCTIONsfm_projectionFromKRt
RETURN TYPEvoid
Call structure. A void return can still write to destination arguments. The parameter descriptions define inputs, outputs and ownership.

Get projection matrix P from K, R and t.

sfm_projectionFromKRt(K: Mat, R: Mat, t: Mat, P: Mat): void;
K

Input 3x3 camera matrix K = \vecthreethree{f_x}{0}{c_x}{0}{f_y}{c_y}{0}{0}{1}.

R

Input 3x3 rotation matrix.

t

Input 3x1 translation vector.

P

Output destination, filled by the native operation. Output 3x4 projection matrix.

This function estimate the projection matrix by solving the following equation: P = K * [R|t]

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.