VideoCapture_waitAny
import { VideoCapture_waitAny } from '@banou/opencv-wasm'Use after await initOpenCV(). See the initialization and named imports guide.
ARGUMENTSstreams, readyIndex, timeoutNs
FUNCTIONVideoCapture_waitAny
RETURN TYPEboolean
Wait for ready frames from VideoCapture.
throws: Exception %Exception on stream errors (check .isOpened() to filter out malformed streams) or VideoCapture type is not supported
The primary use of the function is in multi-camera environments.
The method fills the ready state vector, grabs video frame, if camera is ready.
After this call use VideoCapture::retrieve() to decode and fetch frame data.
VideoCapture_waitAny(streams: VideoCaptureVector, readyIndex: IntVector, timeoutNs: bigint): boolean;2 available overloads
VideoCapture_waitAny(streams: VideoCaptureVector, readyIndex: IntVector): boolean;VideoCapture_waitAny(streams: VideoCaptureVector, readyIndex: IntVector, timeoutNs: bigint): boolean;streamsinput video streams
readyIndexOutput destination, filled by the native operation. stream indexes with grabbed frames (ready to use .retrieve() to fetch actual frame)
timeoutNsnumber of nanoseconds (0 - infinite)
Returns
true if streamReady is not empty
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.