rtspsrc cpu optimization

Olivier CrĂȘte olivier.crete at collabora.com
Tue Oct 14 12:40:03 PDT 2014


On 14/10/14 03:26 PM, Eloi Bail wrote:
> See the result in attachment. I do not see for the moment that something
> really consume CPU. I see increasing p_thread_mutex_lock.
> Doing I see *also 10 simultaneous threads running* !

For each receive pipeline, you should only have two threads involved in
the streaming, one taking packets from the network socket to the
jitterbuffer. And one taking packets from the jitterbuffer. If you have
audio and video, then that's a total of 4 threads.

> As live555 is monothread and event-driven it could explain such a
> consumption difference.
> 
> I would like to decrease thread creation having less elements. Gathering
> gstrtpsession, gstrtpssrcdemux, gstjitterbuffer, gstrtpptdemux into one
> big "RtpBin" element would be a idea. 

There is also a rtpbin containing all of those. The number of elements
doesn't really affect the number of threads or the performance much.


-- 
Olivier Crête
olivier.crete at collabora.com


More information about the gstreamer-devel mailing list