@ -121,7 +121,7 @@ def main():
cv2 . resizeWindow ( ' Stream ' , webcam_width , webcam_height )
cv2 . resizeWindow ( ' Stream ' , webcam_width , webcam_height )
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" )
print ( " Press C to center Webcam, Press B/ N for previous/ next image in media directory, T to alter between relative and absolute transformation, Q to quit" )
x1 , y1 , x2 , y2 = [ 0 , 0 , 0 , 0 ]
x1 , y1 , x2 , y2 = [ 0 , 0 , 0 , 0 ]
relative = True
relative = True
while True :
while True :
@ -171,16 +171,16 @@ def main():
video_capture . release ( )
video_capture . release ( )
break
break
elif k == ord ( ' c ' ) :
elif k == ord ( ' c ' ) :
print ( " Centering the image " )
# center
# center
print ( " Centering the image " )
reset = True
reset = True
elif k == ord ( ' b ' ) :
elif k == ord ( ' b ' ) :
# rotate images
# previous image
print ( " Loading previous image " )
print ( " Loading previous image " )
source_image = readpreviousimage ( )
source_image = readpreviousimage ( )
reset = True
reset = True
elif k == ord ( ' n ' ) :
elif k == ord ( ' n ' ) :
# rotate images
# next image
print ( " Loading next image " )
print ( " Loading next image " )
source_image = readnextimage ( )
source_image = readnextimage ( )
reset = True
reset = True