You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
|| Jim Curry on 2015-05-09 17:17
|| Priority: Normal
|| Affected: branch 'master' (3.0-dev)
|| Category: highgui-camera
|| Tracker: Bug
|| Difficulty:
|| PR:
|| Platform: x64 / Windows
VideoCapture leaking handles
I am using OpenCV VideoCapture on Win 7-64 with Python 2.7.9 to capture images from several webcams. The code works but leaks handles severely. I have reduced the code to the snippet below and still see the leak. I have tried OpenCV versions 2.4.10 and 3.0.0rc1 and a version from about a year ago. This was originally asked at http://answers.opencv.org/ and I was advised to bring it here. Any ideas on how to correct this would be appreciated. Thanks.
<pre>
import cv2
def webcam():
n=0
while n<4:
cap=cv2.VideoCapture(n)
cap.release()
cv2.waitKey(1)
n=n+1
while True:
webcam()
</pre>
History
Vadim Pisarevsky on 2015-05-14 18:35
Since you have the hardware configuration where you can reproduce the problem and we don't, I wonder if the problem exists in C++ version as well. I mean, we need to figure out whether it's highgui or python bindings problem
- Category set to highgui-camera
Jim Curry on 2015-05-16 14:38
The issue does exist in C++ using both 2.4.10 and 3.0.0rc1.
Jim Curry on 2015-06-04 23:34
This issue is now confirmed in 2.4.11 and 3.0.0.
The text was updated successfully, but these errors were encountered:
Transferred from http://code.opencv.org/issues/4327
VideoCapture leaking handles
History
Vadim Pisarevsky on 2015-05-14 18:35
Jim Curry on 2015-05-16 14:38
Jim Curry on 2015-06-04 23:34
The text was updated successfully, but these errors were encountered: