Skip to content

Low FPS in GStreamer aganst LiveCam #11

@aleksan8r-max

Description

@aleksan8r-max

I'm getting unexpectedly low FPS when using GStreamer.
I'm using image BananaPi_M2_zero_OV5640.img.
The ov5640camera initialization:
sudo media-ctl --device /dev/media1 --set-v4l2 '"ov5640 2-003c":0[fmt:YUYV8_2X8/640x480]'

When using the LiveCam script I don't see any problems with FPS. But for some reason it doesn't work with 1280x720 resolution. And outputs image to screen, but I need output to network.
cd software/python/LiveCam
python3 ./LiveCam.py
At the same time, the load on all 4 cores of the BananaPi M2 zero is approximately more than half.

When using GStreamer streaming to screen:
gst-launch-1.0 v4l2src device=/dev/video1 ! video/x-raw, width=640, height=480, framerate=30/1 ! videoconvert ! autovideosink
I get about 1 fps and lots of repeating warnings:

WARNING: from element /GstPipeline:pipeline0/GstAutoVideoSink:autovideosink0/GstGLImageSinkBin:autovideosink0-actual-sink-glimage/GstGLImageSink:sink: A lot of buffers are being dropped.
Additional debug info:
gstbasesink.c(2902): gst_base_sink_is_too_late (): /GstPipeline:pipeline0/GstAutoVideoSink:autovideosink0/GstGLImageSinkBin:autovideosink0-actual-sink-glimage/GstGLImageSink:sink:
There may be a timestamping problem, or this computer is too slow.

At the same time, the load on all 4 BananaPi M2 zero cores is slightly higher than with LiveCam, but not 100%.

UDP streaming to another computer using GStreamer:
gst-launch-1.0 -v v4l2src device=/dev/video1 num-buffers=-1 ! video/x-raw, width=640, height=480, framerate=30/1 ! videoconvert ! jpegenc ! rtpjpegpay ! udpsink host=10.42.0.1 port=5200
Receiver:
gst-launch-1.0 -v udpsrc port=5200 ! application/x-rtp, media=video, clock-rate=90000, payload=96 ! rtpjpegdepay ! jpegdec ! videoconvert ! autovideosink
At the same time I get about 6 fps, only one core is loaded at 100%, the rest are around 0.

I got a BananaPi M2 zero hoping to get 30fps 1280x720 over the network, because you wrote:

we managed to transfer a 1280x720 UDP stream at 30 FPS using GStreamer.

What can be done with this? Or is the project dead?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions