I'm trying to perform live processing on a video stream using mode=1 (documented as being 1920x1080 pixels from the middle of the sensor) on a camera V2.1. I'm starting with the code
which is adapted from that given in http://picamera.readthedocs.io/en/relea ... om-outputs.
Code: Select all
#!/usr/bin/env python3 import time import picamera class FrameHandler(object): def write(self, buf): pass def flush(self): pass with picamera.PiCamera(sensor_mode=1, resolution='1920x1080', framerate=30) as camera: time.sleep(2) # let the camera warm up camera.start_recording(FrameHandler(), 'yuv') camera.wait_recording(10) camera.stop_recording()
When I run this code, I get the warning message
Which sounds as if it will cause the image to be rescaled slightly before it's passed to my frame handler, which I don't want to happen./usr/lib/python3/dist-packages/picamera/encoders.py:544: PiCameraResolutionRounded: frame size rounded up from 1920x1080 to 1920x1088
width, height, fwidth, fheight)))
How can I get un-scaled mode 1 data?
Thanks for any hints!