[Live-devel] RE: RTP packet rate smoothing?

Ross Finlayson finlayson at live555.com
Fri Jan 20 13:19:45 PST 2006


>I see that my first attempt to fix this is similar to what you have
>proposed below. In my particular situation, should I stick with this
>solution or would you recommend something else?

No, I'd recommend something else.

The problem - in your case - appears to be that you're not setting 
the "fDurationInMicroseconds" variable in your audio source class (in 
your "doGetNextFrame()" implementation, before you inform the reader 
that new data is available).

Because you're not setting "fDurationInMicroseconds", the default 
value of zero gets used, and so "MultiFramedRTPSink" (quite properly) 
assumes that it can ask for new data immediately after sendng each RTP packet.

I.e., the problem is not in "MultiFramedRTPSink"; the problem is in 
your audio source class.

(Alternatively, you could change the implementation of your audio 
input source class to not use polling.  E.g., if the audio comes from 
an open file (socket), you could call 
"TaskScheduler::turnOnBackgroundReadHandling()" so that input data 
gets handled as part of the normal event loop.)


	Ross Finlayson
	Live Networks, Inc. (LIVE555.COM)
	<http://www.live555.com/>



More information about the live-devel mailing list