final razeradjustments
This commit is contained in:
parent
9265070f9b
commit
4aeb99009f
@ -7,13 +7,12 @@ from gpiod.line import Direction, Value
|
|||||||
#from wakepy import keep
|
#from wakepy import keep
|
||||||
|
|
||||||
def minute_segment_from(the_time):
|
def minute_segment_from(the_time):
|
||||||
# this is mocked out too be a one minute segment instead
|
|
||||||
return the_time.replace(second=0, microsecond=0)
|
return the_time.replace(second=0, microsecond=0)
|
||||||
#return the_time.replace(minute=(the_time.minute // 1)*1, second=0, microsecond=0)
|
#return the_time.replace(minute=(the_time.minute // 1)*1, second=0, microsecond=0)
|
||||||
|
|
||||||
|
|
||||||
def path_to_video_at(time_stamp):
|
def path_to_video_at(time_stamp):
|
||||||
return 'videos/' + str(time_stamp) + '.mp4' # mkv required for h264 encoding
|
return 'videos/' + str(time_stamp) + '.mp4'
|
||||||
|
|
||||||
#delay for long delay
|
#delay for long delay
|
||||||
long_delay = timedelta(minutes=1)
|
long_delay = timedelta(minutes=1)
|
||||||
@ -28,8 +27,8 @@ if not camera.isOpened():
|
|||||||
|
|
||||||
# video writer
|
# video writer
|
||||||
|
|
||||||
|
|
||||||
fourcc = cv2.VideoWriter_fourcc(*'mp4v')
|
fourcc = cv2.VideoWriter_fourcc(*'mp4v')
|
||||||
|
camera.set(cv2.CAP_PROP_FOURCC, cv2.VideoWriter_fourcc(*'MJPG'))
|
||||||
camera.set(cv2.CAP_PROP_FPS, 60.0)
|
camera.set(cv2.CAP_PROP_FPS, 60.0)
|
||||||
camera_fps = camera.get(cv2.CAP_PROP_FPS)
|
camera_fps = camera.get(cv2.CAP_PROP_FPS)
|
||||||
camera.set(cv2.CAP_PROP_FRAME_WIDTH, 1280)
|
camera.set(cv2.CAP_PROP_FRAME_WIDTH, 1280)
|
||||||
|
Loading…
Reference in New Issue
Block a user