Skip to content

Commit

Permalink
Giving more keypress feedback on the console.
Browse files Browse the repository at this point in the history
  • Loading branch information
Alessandro Cauduro authored and Alessandro Cauduro committed Apr 12, 2020
1 parent f718dd5 commit 0a7eb27
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 3 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -113,7 +113,7 @@ $ v4l2-ctl --list-formats -d /dev/video1

## Mac Support

Unfortunately, Apple and NVidia have stopped collaborating and CUDA support is no longer available for the Mac. If we get it running on the Mac (which is possible), it will be very slow as everything will be running on the CPU whihc is not ideal.
Unfortunately, Apple and NVidia have stopped collaborating and CUDA support is no longer available for the Mac. If we get it running on the Mac (which is possible), it will be very slow as everything will be running on the CPU.

## Images

Expand Down
9 changes: 7 additions & 2 deletions faceit_live.py
Original file line number Diff line number Diff line change
Expand Up @@ -120,7 +120,7 @@ def main():
cv2.resizeWindow('Stream', webcam_width,webcam_width)


print("Press C to center Webcam, Press N for next image in media directory, R to alter between relative and absolute transformation")
print("Press C to center Webcam, Press N for next image in media directory, T to alter between relative and absolute transformation, Q to quit")
x1,y1,x2,y2 = [0,0,0,0]
relative = True
while True:
Expand Down Expand Up @@ -164,18 +164,23 @@ def main():
k = cv2.waitKey(1)
# Hit 'q' on the keyboard to quit!
if k & 0xFF == ord('q'):
print("Quiting")
video_capture.release()
break
elif k==ord('c'):
print("Centering the image")
# center
reset = True
elif k==ord('n'):
# rotate images
print("Loading new image")
source_image = readnextimage()
reset = True
elif k==ord('t'):
# rotate images
# rotate
relative = not relative
print("Changing transform mode")


cv2.destroyAllWindows()
exit()
Expand Down

0 comments on commit 0a7eb27

Please sign in to comment.