gilestrolab/ethoscope

Video recording's performance is too slow.

ggilestro opened this issue · 0 comments

commit b3a49e5 changed the way we handle cameras to allow expansion to other cameras for the creation of superscope. however, the recording capabilities using the rPI camera have dramatically suffered going down to 8FPS for regular resolution and 1FPS for HD. cv2.writer is just not performing fast enough.
We need to go back to legacy behaviour and record h264 files using the picamera appropriate start_recording method.

This could be done using split_recording as we were doing before or using the new feature record_sequence:

import picamera
with picamera.PiCamera() as camera:
    for filename in camera.record_sequence([
            'clip01.h264',
            'clip02.h264',
            'clip03.h264']):
        print('Recording to %s' % filename)
        camera.wait_recording(10)