Jump to content

Video Encoding Support for the Dragonwing EVK Board

From RidgeRun Developer Wiki


Follow us on: YouTube Twitter LinkedIn Email Share this page

Share This Page




Problems running the pipelines shown on this page? Please see our GStreamer Debugging guide for help .


Info
The following tests were done with an IMX577 camera connected to the Dragonwing IQ-9075 EVK

Video Encoding

The following elements were tested on the Ubuntu Image (24.04 LTS) provided, and with the packages installed in the GStreamer Section. They were tested for both their average performance as well as their limit performance for different supported formats following the instructions discussed in the Performance Section.

CPU Encoders

These are the supported CPU Encoders for the Dragonwing EVK Board:

  • x264enc
  • Example pipeline for the x264enc element:
gst-launch-1.0 -e -v qtiqmmfsrc camera=0 ! "video/x-raw,format=NV12,width=1920,height=1080,framerate=30/1,interlace-mode=progressive,colorimetry=bt601" ! x264enc bitrate=6000 speed-preset=ultrafast tune=zerolatency ! h264parse ! mp4mux ! filesink location=x264enc-test.mp4
  • Performance measurements for the x264enc element:
Format Resolution Average Performance Limit Performance
%MEM RSS (KB) BPS CPU (%) FPS Mean FPS
NV12 1280x720 0.0 27792 99880.000 50 264.328 269.958
NV12 1920x1080 0.1 40084 100912.000 57 168.299 161.116
NV12 3840x2160 0.2 104832 125440.000 67 62.899 59.653
I420 1280x720 0.0 27792 98056.000 49 248.869 248.757
I420 1920x1080 0.1 40224 97200.000 56 174.293 163.764
I420 3840x2160 0.2 104828 125440.000 67 63.079 58.831
  • x265enc
  • Example pipeline for the x265enc element:
 gst-launch-1.0 -e qtiqmmfsrc name=camsrc camera=0 ! "video/x-raw,format=NV12,width=1920,height=1080,framerate=30/1" ! videoconvert ! "video/x-raw,format=I420" ! queue ! x265enc ! h265parse ! mp4mux ! filesink location=x265enc-test.mp4
  • Performance measurements for the x265enc element:
Format Resolution Average Performance Limit Performance
%MEM RSS (KB) BPS CPU (%) FPS Mean FPS
I420 1280x720 0.2 74892 38800.000 67 45.750 41.179
I420 1920x1080 0.3 130364 21320.000 66 20.512 20.998
I420 3840x2160 1.1 424960 6568.000 71 6.728 5.054

There are other software-based encoders:

  • openh264enc
  • vp8enc
  • vp9enc
  • av1enc
  • svtav1enc
  • theoraenc

VPU Encoders

These are the supported Hardware Accelerated Encoders for the Dragonwing EVK Board. For these specific encoders, the extra-controls options can be found in the VPU Enabling section.

  • v4l2h264enc
    • Available options:
Property Description Type (Default Value) Values / Range
capture-io-mode Capture I/O mode matching the source pad behavior. GstV4l2IOMode (auto) auto, rw, mmap, userptr, dmabuf, dmabuf-import
device Device location used by the encoder. String (/dev/video33) Device node path
device-fd File descriptor associated with the device. Integer (-1) -1–2147483647
device-name Human-readable device name. String (null) Any valid device name
extra-controls Extra V4L2 controls (CIDs) applied to the encoder. GstStructure Boxed pointer
min-force-key-unit-interval Minimum interval between force-keyunit requests. Unsigned Integer64 (0) 0–18446744073709551615 ns
name Name assigned to the encoder instance. String (v4l2h264enc0) Any valid element name
output-io-mode Output side I/O mode matching the sink pad behavior. GstV4l2IOMode (auto) auto, rw, mmap, userptr, dmabuf, dmabuf-import
parent Parent object of the encoder element. GstObject Any GstObject
qos Enables handling of downstream QoS events. Boolean (false) true, false
  • Example pipeline for the v4l2h264enc element:
gst-launch-1.0 -e -v qtiqmmfsrc camera=0 ! "video/x-raw,format=NV12,width=1920,height=1080,framerate=30/1,interlace-mode=progressive,colorimetry=bt601" ! v4l2h264enc capture-io-mode=4 output-io-mode=5 extra-controls="controls,video_bitrate=12000000,video_bitrate_mode=0;" ! h264parse ! mp4mux ! filesink location=v4l2h264enc-camera-encoding.mp4
  • Performance measurements for the v4l2h264enc element:
Format Resolution Average Performance Limit Performance
%MEM RSS (KB) BPS CPU (%) FPS Mean FPS
NV12 1280x720 0.1 40580 2652256.000 20 1025.756 1021.513
NV12 1920x1080 0.2 72448 2423712.000 15 567.225 563.829
NV12 3840x2160 0.6 246884 2070280.000 11 202.389 202.405
  • v4l2h265enc
    • Available options:
Property Description Type (Default Value) Values / Range
capture-io-mode Capture I/O mode matching the source pad behavior. GstV4l2IOMode (auto) auto, rw, mmap, userptr, dmabuf, dmabuf-import
device Device location used by the encoder. String (/dev/video33) Device node path
device-fd File descriptor associated with the device. Integer (-1) -1–2147483647
device-name Human-readable device name. String (null) Any valid device name
extra-controls Extra V4L2 controls (CIDs) applied to the encoder. GstStructure Boxed pointer
min-force-key-unit-interval Minimum interval between force-keyunit requests in nanoseconds. Unsigned Integer64 (0) 0–18446744073709551615 ns
name Name assigned to the encoder instance. String (v4l2h265enc0) Any valid element name
output-io-mode Output side I/O mode matching the sink pad behavior. GstV4l2IOMode (auto) auto, rw, mmap, userptr, dmabuf, dmabuf-import
parent Parent object of the encoder element. GstObject Any GstObject
qos Enables handling of downstream QoS events. Boolean (false) true, false
  • Example pipeline for the v4l2h265enc element:
gst-launch-1.0 -e -v qtiqmmfsrc camera=0 ! "video/x-raw,format=NV12,width=1920,height=1080,framerate=30/1,interlace-mode=progressive,colorimetry=bt601" ! v4l2h265enc capture-io-mode=4 output-io-mode=5 extra-controls="controls,video_bitrate=12000000,video_bitrate_mode=0;" ! h265parse ! mp4mux ! filesink location=v4l2h265enc-camera-encoding.mp4
  • Performance measurement for the v4l2h265enc element:
Format Resolution Average Performance Limit Performance
%MEM RSS (KB) BPS CPU (%) FPS Mean FPS
NV12 1280x720 0.1 46436 318304.000 18 821.056 821.361
NV12 1920x1080 0.1 42640 305264.000 12 385.782 386.862
NV12 3840x2160 0.7 273016 512888.000 9 207.150 207.279


Attention
The limit performance performs low-entropy encoding, with replicated frames, which illustrates the BW of the encoder/decoder


Cookies help us deliver our services. By using our services, you agree to our use of cookies.