public static class DePacketizer.VP8PayloadDescriptor
extends java.lang.Object
Modifier and Type | Field and Description |
---|---|
static int |
MAX_LENGTH
Maximum length of a VP8 Payload Descriptor.
|
Constructor and Description |
---|
VP8PayloadDescriptor() |
Modifier and Type | Method and Description |
---|---|
static byte[] |
create(boolean startOfPartition)
Returns a simple Payload Descriptor, with PartID = 0, the 'start
of partition' bit set according to startOfPartition, and
all other bits set to 0.
|
static int |
getPartitionId(byte[] input,
int offset)
Returns the value of the PID (partition ID) field of the
VP8 Payload Descriptor at offset offset in input.
|
static int |
getPictureId(byte[] input,
int offset)
Gets the value of the PictureID field of a VP8 Payload Descriptor.
|
static int |
getSize(byte[] input,
int offset,
int length)
The size in bytes of the Payload Descriptor at offset
offset in input.
|
static int |
getSize(ByteArrayBuffer baf)
The size in bytes of the Payload Descriptor at offset
offset in input.
|
static int |
getTemporalLayerIndex(byte[] buf,
int off,
int len)
Gets the temporal layer index (TID), if that's set.
|
static boolean |
hasExtendedPictureId(byte[] buf,
int off,
int len)
Determines whether the VP8 payload specified in the buffer that is
passed as an argument has an extended picture ID or not.
|
static boolean |
hasPictureId(byte[] buf,
int off,
int len)
Determines whether the VP8 payload specified in the buffer that is
passed as an argument has a picture ID or not.
|
static boolean |
isStartOfFrame(byte[] input,
int offset)
Returns true if both the 'start of partition' bit
is set and the PID fields has value 0 in the VP8 Payload
Descriptor at offset offset in input.
|
static boolean |
isStartOfPartition(byte[] input,
int offset)
Checks whether the 'start of partition' bit is set in the
VP8 Payload Descriptor at offset offset in input.
|
static boolean |
isValid(byte[] buf,
int off,
int len)
Checks whether the arguments specify a valid buffer.
|
static boolean |
setExtendedPictureId(byte[] buf,
int off,
int len,
int val)
Sets the extended picture ID for the VP8 payload specified in the
buffer that is passed as an argument.
|
static boolean |
setTL0PICIDX(byte[] buf,
int off,
int len,
int val)
Sets the TL0PICIDX field for the VP8 payload specified in the
buffer that is passed as an argument.
|
public static final int MAX_LENGTH
public static int getTemporalLayerIndex(byte[] buf, int off, int len)
buf
- the byte buffer that holds the VP8 packet.off
- the offset in the byte buffer where the VP8 packet starts.len
- the length of the VP8 packet.public static byte[] create(boolean startOfPartition)
startOfPartition
- whether to 'start of partition' bit should be
setpublic static int getSize(ByteArrayBuffer baf)
baf
- the ByteArrayBuffer that holds the VP8 payload
descriptor.public static int getSize(byte[] input, int offset, int length)
input
- inputoffset
- offsetlength
- lengthpublic static boolean hasPictureId(byte[] buf, int off, int len)
buf
- the byte buffer that contains the VP8 payload.off
- the offset in the byte buffer where the VP8 payload
starts.len
- the length of the VP8 payload in the byte buffer.public static boolean hasExtendedPictureId(byte[] buf, int off, int len)
buf
- the byte buffer that contains the VP8 payload.off
- the offset in the byte buffer where the VP8 payload
starts.len
- the length of the VP8 payload in the byte buffer.public static int getPictureId(byte[] input, int offset)
input
- offset
- public static boolean setExtendedPictureId(byte[] buf, int off, int len, int val)
buf
- the byte buffer that contains the VP8 payload.off
- the offset in the byte buffer where the VP8 payload
starts.len
- the length of the VP8 payload in the byte buffer.public static boolean setTL0PICIDX(byte[] buf, int off, int len, int val)
buf
- the byte buffer that contains the VP8 payload.off
- the offset in the byte buffer where the VP8 payload
starts.len
- the length of the VP8 payload in the byte buffer.public static boolean isValid(byte[] buf, int off, int len)
buf
- off
- len
- public static boolean isStartOfPartition(byte[] input, int offset)
input
- inputoffset
- offsetpublic static boolean isStartOfFrame(byte[] input, int offset)
input
- offset
- public static int getPartitionId(byte[] input, int offset)
input
- offset
-
Jitsi, the OpenSource Java VoIP and Instant Messaging client.
Distributable under Apache license.