Skip to content

Python bindings for VideoCapture::waitAny #21826

@crackwitz

Description

@crackwitz

related: #15100

Everything in VideoCapture has Python bindings except for the new waitAny facility. I think that would be generally useful to have in Python too.

if the bindings generation doesn't imply a regular signature, I'd propose

waitAny(streams, timeoutNs=0) -> readyIndex

Where streams is a list of VideoCapture instances and readyIndex is a python list of indices into streams. No need to preserve the boolean return value. It's only false if the list is empty.

NB: Docs are inconsistent in their naming. Single mention of "streamReady". "readyIndex" was probably intended. It's not a singular value either ("index"), it's a vector/list (indices).

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions