提交 82682450 编写于 作者: T Tejas Shah 提交者: Adam Geitgey

fixed leftover worker processes when user requested to end demo

上级 a9dd28d5
......@@ -62,6 +62,10 @@ def process(worker_id, read_frame_list, write_frame_list, Global, worker_num):
# Wait to read
while Global.read_num != worker_id or Global.read_num != prev_id(Global.buff_num, worker_num):
# If the user has requested to end the app, then stop waiting for webcam frames
if Global.is_exit:
break
time.sleep(0.01)
# Delay to make the video look smoother
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册