Skip to content

opencv-python missing bindings for setting videocapture open timeout and read timeout #788

@ribeirompl-soldersmith

Description

@ribeirompl-soldersmith

cv2.VideoCapture and the .read() method can hang indefinitely in certain situations when an RTSP stream drops connection abnormally.
There appears to have been some timeout parameters added to account for this: opencv/opencv#20541
But these parameters don't appear to be available in the latest version of opencv-python.

Although, the timeout feature in general seems to be missing? It was added to opencv here opencv/opencv#6053 with a default of 30sec, but it does not seem to be functional in opencv-python. With some minimal testing, it appears to timeout (stop blocking) after around 90 seconds.

Issue submission checklist
  • This is not a generic OpenCV usage question (looking for help for coding, other usage questions, homework etc.)
  • I have read the README of this repository and understand that this repository provides only an automated build toolchain for OpenCV Python packages (there is no actual OpenCV code here)
  • The issue is related to the build scripts in this repository, to the pre-built binaries or is a feature request (such as "please enable this additional dependency")
  • I'm using the latest version of opencv-python

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions