even further documentation

This commit is contained in:
2018-11-12 13:34:12 +01:00
parent 661c44f459
commit b9beddd4a4
5 changed files with 58 additions and 33 deletions

View File

@@ -155,8 +155,7 @@ class VideoReader(object):
raise ValueError('Error while reading video.\n' +
'Or video is over.')
self.ctr += 1
if (self.ctr == self.cap.get(cv2.cv.CV_CAP_PROP_FRAME_COUNT) and
self.loop):
if (self.ctr == self.cap.get(cv2.cv.CV_CAP_PROP_FRAME_COUNT) and self.loop):
self.ctr = 0
self.cap.set(cv2.cv.CV_CAP_PROP_POS_FRAMES, 0)
return frame