Skip to content

Commit

Permalink
release resources when code ends
Browse files Browse the repository at this point in the history
close windows on 'esc' key press
  • Loading branch information
keshariS authored Jul 2, 2021
1 parent a6b2be4 commit e935888
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions example.py
Original file line number Diff line number Diff line change
Expand Up @@ -39,3 +39,6 @@

if cv2.waitKey(1) == 27:
break

webcam.release()
cv2.destroyAllWindows()

0 comments on commit e935888

Please sign in to comment.