This leads to huge number of frames accumulating at the RTP payloader. Adding a leaky queue can make it run, but the framerate is only a few fps.
The question is as always: why?! After glcolorconvert the buffers have GstGLSyncMeta attached. Maybe this is problematic for the RTP payloader. Removing those metadata might help? Any hints or tips appreciated.
add a queue max-size-bytes=0 max-size-time=0 max-size-buffers=5 before and after the rtpvrawpay
use a higher rtpvrawpay chunks-per-frame=X than the default (shouldn’t change overall cpu usage, just gets out data quicker and might lubricate things a little by sending smaller chunks at a time)
increase the kernel send buffer size with e.g. sudo sysctl net.core.wmem_max=67108864 (might be excessive, but the default is very very low) and then use a higher value with udpsink buffer-size=X (won’t change cpu usage, but makes packet loss through “lumpy scheduling of data to send out” less likely)
Also, videoconvert has an n-threads property which can be set to a non-1 value to parallelise the conversion, which might help push through frames on time with software conversion (depends on your CPU ofc).
@tpm many thanks for the hints. I’ve tuned the tcp stack and udpsink buffer-size, bumped payloader chunks-per-frame, but it was not (only) the case. Even with fakesink the payloader was still lagging.
What - did - help was commenting out this line:
So seems like GstGLSyncMeta was the problem? I don’t understand why after gldownload it is still there? I would assume that for the payloader passing anything related to the OpenGL context makes no sense?