According to this page Raspberry camera v2 can produce video stream with resolution of 3280x2464. However, all my tries with raspivid and gstreamer/v4l2 fails.

Knows someone how to reach this video resolution ?

My tries and errors:

  1. with raspivid
      pi@raspberrypi:~ $ raspivid -v -md 2 -w 3280 -h 2464 -fps 15 -o prueba.yuv
     "raspivid" Camera App (commit 6e6a2c859a17 Tainted)
     Camera Name imx219
     Width 3280, Height 2464, filename prueba.yuv
     Using camera 0, sensor mode 2
     GPS output Disabled
     bitrate 17000000, framerate 15, time delay 5000
     H264 Profile high
     H264 Level 4
     H264 Quantisation level 0, Inline headers No
     H264 Fill SPS Timings No
     H264 Intra refresh type (null), period -1
     H264 Slices 1
     Wait method : Simple capture
     Initial state 'record'
     Preview Yes, Full screen Yes
     Preview window 0,0,1024,768
     Opacity 255
     Sharpness 0, Contrast 0, Brightness 50
     Saturation 0, ISO 0, Video Stabilisation No, Exposure compensation 0
     Exposure Mode 'auto', AWB Mode 'auto', Image Effect 'none'
     Flicker Avoid Mode 'off'
     Metering Mode 'average', Colour Effect Enabled No with U = 128, V = 128
     Rotation 0, hflip No, vflip No
     ROI x 0.000000, y 0.000000, w 1.000000 h 1.000000
     Camera component done
     Too many macroblocks/s: Increasing H264 Level to 4.2
     Encoder component done
     Starting component connection stage
     Connecting camera preview port to preview input port
     Starting video preview
     Connecting camera video port to encoder input port
     mmal: mmal_vc_port_enable: failed to enable port vc.ril.video_encode:in:0(OPQV): ENOSPC
     mmal: mmal_port_enable: failed to enable connected port (vc.ril.video_encode:in:0(OPQV))0x10533e0 (ENOSPC)
     mmal: mmal_connection_enable: output port couldn't be enabled
     mmal: main: Failed to connect camera video port to encoder input
     mmal: Out of resources (other than memory)
     Closing down
     Close down completed, all components disconnected, disabled and destroyed
     mmal: Failed to run camera app. Please check for firmware updates
  2. with gstreamer/v4l2:
     pi@raspberrypi:~ $ gst-launch-1.0 v4l2src do-timestamp=true ! video/x-h264,width=3280,height=2464,framerate=15/1 ! fakesink
     Setting pipeline to PAUSED ...
     Pipeline is live and does not need PREROLL ...
     Setting pipeline to PLAYING ...
     New clock: GstSystemClock
     ERROR: from element /GstPipeline:pipeline0/GstV4l2Src:v4l2src0: Failed to allocate required memory.
     Additional debug info:
     gstv4l2src.c(658): gst_v4l2src_decide_allocation (): /GstPipeline:pipeline0/GstV4l2Src:v4l2src0:
     Buffer pool activation failed
     Execution ended after 0:00:00.471647017
     Setting pipeline to PAUSED ...
     Setting pipeline to READY ...
     Setting pipeline to NULL ...
     Freeing pipeline ...
  • 2
    Read section 6.2 hardware limits in same document you refer to.
    – dbmitch
    Jul 15, 2020 at 3:13

1 Answer 1


I hit a similar error to this:

 mmal: mmal_vc_port_enable: failed to enable port vc.ril.video_encode:in:0(OPQV): ENOSPC

because I still had motion set to run (from another attempt at steaming), check this: What causes ENOSPC error when using the Raspberry Pi camera module?

  • Thanks for your answer. After solve the issue, can you capture video at 3280x2464? Jul 25, 2020 at 7:19
  • I have not tried yet as I am just using the HQ camera to stream to youtube and I am just doing it at 1280x720. Did you look at the 6.2. Hardware Limits on that page to make sure the rest is falling in range? Jul 27, 2020 at 3:05

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.