[Live-devel] rtp over rtsp, tcp sending: dropped frames

Ross Finlayson finlayson at live555.com
Tue Aug 9 12:47:49 PDT 2016


> In my opinion this behaviour is inappropriate, since I use TCP streaming exactly because I never must drop a frame.

This is unrealistic, and impossible if your network stream is exceeding the capacity of your network - which is what’s happening in your case.

You are streaming datagrams, which means that - even if you’re encapsulating them within a TCP connection - you have to be prepared for the possibility of some of these datagrams being lost.  It’s important to understand the difference between transmitting a stream - which occurs at a fixed data rate, regardless of what kind of network you happen to have underneath you - and downloading a file (i.e, the World-Wide Web), which occurs over TCP connections whose speed automatically matches the speed of the underlying network.  We’re doing the former; not the latter.

I won’t be changing the existing code in this case.  Please also read these earlier responses to other people who have asked the same thing:
	http://lists.live555.com/pipermail/live-devel/2014-September/018693.html
	http://lists.live555.com/pipermail/live-devel/2015-July/019523.html


> I also find that increasing the TCP sendbuffer from 50kB to 1MB in GenericMediaServer.cpp is helpful in this cause.

FYI, this is something that you can do yourself, in your own code - e.g., in your implementation of the “createNewRTPSink()” virtual function.


Also:

> especially when I send big I-Frames.

It’s best not to try and transmit very large I-frames.  Instead, they are best broken up into multiple ‘slice’ NAL units.  This is also something that I’ve covered multiple times, e.g.,
	http://lists.live555.com/pipermail/live-devel/2011-December/014190.html
	http://lists.live555.com/pipermail/live-devel/2012-August/015615.html
	http://lists.live555.com/pipermail/live-devel/2013-May/016994.html
	http://lists.live555.com/pipermail/live-devel/2014-June/018426.html
	http://lists.live555.com/pipermail/live-devel/2014-June/018432.html
	http://lists.live555.com/pipermail/live-devel/2014-June/018433.html
	http://lists.live555.com/pipermail/live-devel/2014-June/018434.html
	http://lists.live555.com/pipermail/live-devel/2015-March/019135.html
	http://lists.live555.com/pipermail/live-devel/2015-April/019228.html


Ross Finlayson
Live Networks, Inc.
http://www.live555.com/




More information about the live-devel mailing list