imdecodemulti
import { imdecodemulti } from '@banou/opencv-wasm'Use after await initOpenCV(). See the initialization and named imports guide.
Reads a multi-page image from a buffer in memory.
The function imdecodemulti reads a multi-page image from the specified buffer in the memory. If the buffer is too short or contains invalid data, the function returns false.
See cv::imreadmulti for the list of supported formats and flags description.
Note: In the case of color images, the decoded images will have the channels stored in B G R order.
imdecodemulti(buf: Mat, flags: number, mats: MatVector, range: Range): boolean;2 available overloads
imdecodemulti(buf: Mat, flags: number, mats: MatVector): boolean;imdecodemulti(buf: Mat, flags: number, mats: MatVector, range: Range): boolean;bufInput array or vector of bytes.
flagsFlag that can take values of cv::ImreadModes.
matsOutput destination, filled by the native operation. A vector of Mat objects holding each page, if more than one.
rangeA continuous selection of pages.
The boolean result.
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.