You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

20 lines
427 B

import cv2
c = cv2.VideoCapture(2)
# if not ding this we only have jittery 10fps
c.set(cv2.CAP_PROP_FOURCC, cv2.VideoWriter_fourcc(*"MJPG"))
# set camera resoltion
c.set(3, 1280)
c.set(4, 720)
for i in range(15):
_,im =
cv2.imwrite('calibrate/left-{:06d}.png'.format(i), im)
cv2.imshow('left', im)
if cv2.waitKey(1000) & 0xFF == ord('q'):