public class ResumableStreamRewriter
extends java.lang.Object
Modifier and Type | Field and Description |
---|---|
(package private) int |
highestSequenceNumberSent
The highest sequence number that got accepted, mod 2^16.
|
(package private) int |
seqnumDelta
The sequence number delta between what's been accepted and what's been
received, mod 2^16.
|
Constructor and Description |
---|
ResumableStreamRewriter() |
Modifier and Type | Method and Description |
---|---|
boolean |
processRTCP(boolean rewrite,
byte[] buf,
int off,
int len)
Restores the RTP timestamp of the RTCP SR packet in the buffer.
|
boolean |
rewriteRTP(boolean accept,
byte[] buf,
int off,
int len)
Rewrites the sequence number of the RTP packet in the byte buffer,
hiding any gaps caused by drops.
|
(package private) int |
rewriteSequenceNumber(boolean accept,
int sequenceNumber)
Rewrites the sequence number passed as a parameter, hiding any gaps
caused by drops.
|
int seqnumDelta
int highestSequenceNumberSent
public boolean rewriteRTP(boolean accept, byte[] buf, int off, int len)
accept
- true if the packet is accepted, false otherwisebuf
- the byte buffer that contains the RTP packetoff
- the offset in the byte buffer where the RTP packet startslen
- the length of the RTP packet in the byte bufferpublic boolean processRTCP(boolean rewrite, byte[] buf, int off, int len)
buf
- the byte buffer that contains the RTCP packet.off
- the offset in the byte buffer where the RTCP packet starts.len
- the number of bytes in buffer which constitute the actual
data.int rewriteSequenceNumber(boolean accept, int sequenceNumber)
accept
- true if the packet is accepted, false otherwisesequenceNumber
- the sequence number to rewrite
Jitsi, the OpenSource Java VoIP and Instant Messaging client.
Distributable under Apache license.