<HTML><HEAD></HEAD>
<BODY dir=ltr>
<DIV dir=ltr>
<DIV style="FONT-FAMILY: 'Calibri'; COLOR: #000000; FONT-SIZE: 12pt">
<DIV> </DIV>
<DIV>Hi Ross,</DIV>
<DIV> </DIV>
<DIV>We are streaming (over Wifi ) H264 encoded frames from a live source using
the reference of testH264VideoStreamer class. Camera frame rate is 30 fps.</DIV>
<DIV>Receiver is an iOS application referenced from testRTSPClient class.</DIV>
<DIV> </DIV>
<DIV>We are able to stream with Initial propagation delay around 200ms but after
a duration of 20 minutes we are observing a scenario in which we are not
receiving any frames (afterGettingFrame is not getting called) in the receiver
side for some very small duration(200-250 ms), and then a large propagation
delay (more than 1 sec) is being observed in streaming. This scenario is being
repeated every time.</DIV>
<DIV> </DIV>
<DIV>We are trying to analyze the Live555 Source code to any solution for above
and came across following unclear sections. </DIV>
<DIV> </DIV>
<DIV>1. As per our understanding RTP streaming will be done on UDP, then why in
In <STRONG>RTPInterface::sendPacket </STRONG>method Data is being sent on TCP?
</DIV>
<DIV> </DIV>
<DIV> // Normal case: Send as a UDP packet:</DIV>
<DIV> if (!fGS->output(envir(), fGS->ttl(), packet, packetSize))
success = False;</DIV>
<DIV> </DIV>
<DIV> // Also, send over each of our TCP sockets:</DIV>
<DIV> for (tcpStreamRecord* streams = fTCPStreams; streams != NULL;</DIV>
<DIV> streams = streams->fNext) {</DIV>
<DIV> if (!sendRTPOverTCP(packet, packetSize,</DIV>
<DIV>
streams->fStreamSocketNum, streams->fStreamChannelId)) {</DIV>
<DIV> success = False;</DIV>
<DIV> }</DIV>
<DIV> }</DIV>
<DIV> </DIV>
<DIV>2. In MultiFramedRTPSink::sendPacketIfNecessary() method as
<STRONG>fNoFramesLeft</STRONG> is false always, a delay of some amount is been
added. What is the exact reason for this?</DIV>
<DIV> </DIV>
<DIV>if (fNoFramesLeft) {</DIV>
<DIV> // We're done:</DIV>
<DIV> onSourceClosure(this);</DIV>
<DIV> } else {</DIV>
<DIV> // We have more frames left to send. Figure out
when the next frame</DIV>
<DIV> // is due to start playing, then make sure that we wait
this long before</DIV>
<DIV> // sending the next packet.</DIV>
<DIV> struct timeval timeNow;</DIV>
<DIV> gettimeofday(&timeNow, NULL);</DIV>
<DIV> int secsDiff = fNextSendTime.tv_sec -
timeNow.tv_sec;</DIV>
<DIV> int64_t uSecondsToGo = secsDiff*1000000 +
(fNextSendTime.tv_usec - timeNow.tv_usec);</DIV>
<DIV> if (uSecondsToGo < 0 || secsDiff < 0) { // sanity
check: Make sure that the time-to-delay is non-negative:</DIV>
<DIV> uSecondsToGo = 0;</DIV>
<DIV> }</DIV>
<DIV> </DIV>
<DIV> <STRONG>// Delay this amount of time:</STRONG></DIV>
<DIV> nextTask() =
envir().taskScheduler().scheduleDelayedTask(uSecondsToGo, (TaskFunc*)sendNext,
this);</DIV>
<DIV> }</DIV>
<DIV
style="FONT-FAMILY: 'Calibri'; COLOR: #000000; FONT-SIZE: 12pt"> </DIV>
<DIV style="FONT-FAMILY: 'Calibri'; COLOR: #000000; FONT-SIZE: 12pt">3. In
Receiver application, in MultiFramedRTPSource::networkReadHandler1 function
ReorderBufferPacket object is used, That’s calling storepacket function.</DIV>
<DIV style="FONT-FAMILY: 'Calibri'; COLOR: #000000; FONT-SIZE: 12pt">What is the
actual use of ReoderBufferPacket here? Whether this class is queueing the
packets?</DIV>
<DIV style="FONT-FAMILY: 'Calibri'; COLOR: #000000; FONT-SIZE: 12pt">In
ReorderBufferPacket class what's the use of fThresholdTime?</DIV>
<DIV
style="FONT-FAMILY: 'Calibri'; COLOR: #000000; FONT-SIZE: 12pt"> </DIV>
<DIV style="FONT-FAMILY: 'Calibri'; COLOR: #000000; FONT-SIZE: 12pt">4. In
void RTPReceptionStats::noteIncomingPacket() </DIV>
<DIV>Why Initially presentation time of the packet is same as wall-clock time
and then later it is been changed to time stamp of SR’s.</DIV>
<DIV> </DIV>
<DIV>// Return the 'presentation time' that corresponds to "rtpTimestamp":</DIV>
<DIV>if (fSyncTime.tv_sec == 0 && fSyncTime.tv_usec == 0) {</DIV>
<DIV> // This is the first timestamp that we've seen, so use the
current</DIV>
<DIV> // 'wall clock' time as the synchronization time. (This
will be</DIV>
<DIV> // corrected later when we receive RTCP SRs.)</DIV>
<DIV> fSyncTimestamp = rtpTimestamp;</DIV>
<DIV> fSyncTime = timeNow;</DIV>
<DIV>}</DIV>
<DIV style="FONT-FAMILY: 'Calibri'; COLOR: #000000; FONT-SIZE: 12pt"><BR>Thanks
& Regards,<BR>Ashfaque </DIV></DIV></DIV></BODY></HTML>