[prev in list] [next in list] [prev in thread] [next in thread]
List: helix-protocol-cvs
Subject: [Protocol-cvs] transport/rdt rdttran.cpp,1.21,1.22
From: milko () helixcommunity ! org
Date: 2007-01-11 21:19:44
Message-ID: 200701112120.l0BLKaJl022553 () dombackupmx1 ! xen ! 10east ! com
[Download RAW message or body]
Update of /cvsroot/protocol/transport/rdt
In directory cvs01.internal.helixcommunity.org:/tmp/cvs-serv14780/rdt
Modified Files:
rdttran.cpp
Log Message:
Overview:
This check-in provides tools for deterministic testing of time-stamp wrap-around \
issues of live streams and corrects few issues discovered via such tools.
1.) The live stream testing tool:
The tools provided in this check-in allow testing of time-stamp wrap-around \
handling of live streams starting with source object and in all other down-stream \
objects (renderer, audio stream, audio player, audio session, audio device, site, \
surface).
2.) Fixes for live-stream timestamp wrap-around.
One test revelead few errors in time-stamp wrap-around handling that required \
modfications:
- Audio stream time-stamp mapping code (specific to RealAudio streams) use to \
correct files produced with inaccurate ressampling was causing constant-rebuffering \
after time-stamp wrap around due to failure to properly map the time-stamp. Mapping \
failure resulted in time line in up-stream player objects to halt. The mapping \
failure was caused by improper computation of 64 bit time-stamps in the mapping code \
by using time-stamp wrap around counter from the future (beginning of audio stream) \
at the time of audio mixing (end of audio stream). The issues was corrected by \
eliminating the use of 64 bit time-stamps in the mapping code since it is \
unnecessary.
- Corrected HXSource::CalcEventTime which attempted to clip event times against \
m_ulFirstPacketTime for live streams. This code is conceptually wrong and simply \
does not work in general. The code was simplified and rid of special case clipping \
logic.
- Corrected RealVideo depacketizer logic which handles incorrectly produced content \
missing the proper time-stamp size field setting (14 or 30 bits). The detection of \
such scenario was based on comparison of packet (32bit) and frame (14 or 30bit) \
time-stamps. The logic failed to discrad the upper 2 bits from the packet time-stamp \
thus possibly producing wrong conclusions for time-stamps > 30bits.
- Time-stamp wrap-around caused improper water-mark based rate throttling. The \
cause was inadequate implementation of IHXSourceBufferingStats::GetCurrentBuffering \
method in the transport buffer which did not continue to return the proper lowest and \
highest 64bit time-stamps after the wrap-around. While the relationship between the \
returned lowest and highest time-stamp was correct for a particular stream, the \
relationship to other stream was not guaranteed thus causing higher level code to \
establish incorrect time ranges on wrap-around condition.
- RealMedia file format and dtdriver framework halted on encounter with 0xFFFFFFFF \
time-stamp due to assumption made in the lowest time-stamp search algorithm that \
0xFFFFFFFF time-stamp is larger than any encountered time-stamp. This was true for \
the most part until the containment of live streams was introduced.
Other modification include addition of logging statements and eliminationn od \
circular QI in dtdriver framework.
Index: rdttran.cpp
===================================================================
RCS file: /cvsroot/protocol/transport/rdt/rdttran.cpp,v
retrieving revision 1.21
retrieving revision 1.22
diff -u -d -r1.21 -r1.22
--- rdttran.cpp 1 Apr 2006 07:45:19 -0000 1.21
+++ rdttran.cpp 11 Jan 2007 21:19:42 -0000 1.22
@@ -106,7 +106,7 @@
static UINT16
GetRDTBufferInfoForAllStreams(RDTTransportInfoResponsePacket& respPkt,
RTSPStreamHandler* pStreamHandler,
- IHXSourceBufferingStats2* pSrcBufferStats)
+ IHXSourceBufferingStats3* pSrcBufferStats)
{
RTSPStreamData* pStreamData = pStreamHandler->firstStreamData();
UINT16 ulIndex = 0;
@@ -118,22 +118,22 @@
if (pTransBuf)
{
- INT64 llLowTS = 0;
- INT64 llHighTS = 0;
+ UINT32 ulLowTS = 0;
+ UINT32 ulHighTS = 0;
UINT32 ulNumBytes = 0;
HXBOOL bDone = FALSE;
if (HXR_OK == pSrcBufferStats->GetTotalBuffering(streamNumber,
- llLowTS,
- llHighTS,
+ ulLowTS,
+ ulHighTS,
ulNumBytes,
bDone))
{
RDTBufferInfo* pBufInfo = &respPkt.buffer_info[ulIndex];
pBufInfo->stream_id = streamNumber;
- pBufInfo->lowest_timestamp = INT64_TO_UINT32(llLowTS);
- pBufInfo->highest_timestamp = INT64_TO_UINT32(llHighTS);
+ pBufInfo->lowest_timestamp = ulLowTS;
+ pBufInfo->highest_timestamp = ulHighTS;
pBufInfo->bytes_buffered = ulNumBytes;
ulIndex++;
}
@@ -148,7 +148,7 @@
static BYTE* PackTransportInfoResp(const RDTTransportInfoRequestPacket& reqPkt,
UINT32 ulTime,
RTSPStreamHandler* pStreamHandler,
- IHXSourceBufferingStats2* pSrcBufferStats,
+ IHXSourceBufferingStats3* pSrcBufferStats,
BYTE* packet)
{
RDTTransportInfoResponsePacket respPkt;
_______________________________________________
Protocol-cvs mailing list
Protocol-cvs@helixcommunity.org
http://lists.helixcommunity.org/mailman/listinfo/protocol-cvs
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic