MCPcopy Create free account
hub / github.com/PyImageSearch/imutils / __init__

Method __init__

imutils/video/webcamvideostream.py:6–17  ·  view source on GitHub ↗
(self, src=0, name="WebcamVideoStream")

Source from the content-addressed store, hash-verified

4
5class WebcamVideoStream:
6 def __init__(self, src=0, name="WebcamVideoStream"):
7 # initialize the video camera stream and read the first frame
8 # from the stream
9 self.stream = cv2.VideoCapture(src)
10 (self.grabbed, self.frame) = self.stream.read()
11
12 # initialize the thread name
13 self.name = name
14
15 # initialize the variable used to indicate if the thread should
16 # be stopped
17 self.stopped = False
18
19 def start(self):
20 # start the thread to read frames from the video stream

Callers

nothing calls this directly

Calls 1

readMethod · 0.45

Tested by

no test coverage detected