Skip to content

matFromImageData

TypeScript helpershelperOpenCV 5.0.0
import { matFromImageData } from '@banou/opencv-wasm'
ARGUMENTSSee signature below
HELPERmatFromImageData
RETURN TYPEMat
Call structure. A void return can still write to destination arguments. The parameter descriptions define inputs, outputs and ownership.

Copy canvas RGBA bytes into an owned CV_8UC4 matrix on the initialized shared engine. Dispose after use.

export declare function matFromImageData(image: ImagePixels): Mat;

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.