[Opalvoip-svn] SF.net SVN: opalvoip: [18748] opal/trunk/include/rtp/rtp.h
Brought to you by:
csoutheren,
rjongbloed
From: <cso...@us...> - 2007-10-23 04:02:22
|
Revision: 18748 http://opalvoip.svn.sourceforge.net/opalvoip/?rev=18748&view=rev Author: csoutheren Date: 2007-10-22 21:02:26 -0700 (Mon, 22 Oct 2007) Log Message: ----------- Fixed problems with back merge of RTP padding changes Modified Paths: -------------- opal/trunk/include/rtp/rtp.h Modified: opal/trunk/include/rtp/rtp.h =================================================================== --- opal/trunk/include/rtp/rtp.h 2007-10-23 01:40:28 UTC (rev 18747) +++ opal/trunk/include/rtp/rtp.h 2007-10-23 04:02:26 UTC (rev 18748) @@ -443,8 +443,8 @@ BOOL GetMarker() const { return (theArray[1]&0x80) != 0; } void SetMarker(BOOL m); - BOOL GetPadding() const; - void SetPadding(BOOL v); + BOOL GetPadding() const { return (theArray[0]&0x20) != 0; } + void SetPadding(BOOL v) { if (v) theArray[0] |= 0x20; else theArray[0] &= 0xdf; } unsigned GetPaddingSize() const; @@ -472,7 +472,7 @@ BOOL SetExtensionSize(PINDEX sz); BYTE * GetExtensionPtr() const; - PINDEX GetPayloadSize() const { return payloadSize; } + PINDEX GetPayloadSize() const { return payloadSize - GetPaddingSize(); } BOOL SetPayloadSize(PINDEX sz); BYTE * GetPayloadPtr() const { return (BYTE *)(theArray+GetHeaderSize()); } @@ -526,9 +526,6 @@ PINDEX GetCompoundSize() const; - BOOL GetPadding() const { return theArray[compoundOffset & 0x20] != 0; } - void SetPadding(BOOL v) { if (v) theArray[compoundOffset] |= 0x20; else theArray[compoundOffset] &= 0xdf; } - void Reset(PINDEX size); #pragma pack(1) This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |