Remove multiprocessing
This commit is contained in:
parent
56d4b8c371
commit
a58f11ac0e
|
@ -45,7 +45,8 @@ class Video:
|
|||
|
||||
cv2.imshow("window", frame)
|
||||
|
||||
cv2.waitKey(int(delay))
|
||||
if cv2.waitKey(int(delay)) == ord('q'):
|
||||
break
|
||||
|
||||
# Break the loop
|
||||
else:
|
||||
|
@ -58,13 +59,5 @@ class Video:
|
|||
|
||||
if __name__ == "__main__":
|
||||
video = Video(0, 0)
|
||||
x = multiprocessing.Process(target = video.start, args=("slave/videos/sample-mp4-file.mp4",))
|
||||
x.start()
|
||||
time.sleep(2)
|
||||
x.terminate()
|
||||
time.sleep(1)
|
||||
video = Video(4000, 0)
|
||||
x = multiprocessing.Process(target = video.start, args=("slave/videos/sample-mp4-file.mp4",))
|
||||
x.start()
|
||||
time.sleep(1)
|
||||
x.terminate()
|
||||
video.start("slave/videos/sample-mp4-file.mp4")
|
||||
|
Loading…
Reference in New Issue