An RTP packet header. More...
Instance Methods | |
(int) | - calculateHeaderLength |
Calculates the length of the header. More... | |
(FMLiveSwitchRtpPacketHeader *) | - clone |
Clones this instance. More... | |
(int) | - contributingSourceCount |
Gets the number of contributing sources. More... | |
(NSMutableArray *) | - contributingSources |
Gets the contributing sources. More... | |
(bool) | - extension |
Gets if there is an extension. More... | |
(NSObject< FMLiveSwitchIRtpHeaderExtension > *) | - headerExtension |
Gets the header extension. More... | |
(NSString *) | - id |
Gets the Id of the Rtp Packet Header. More... | |
(instancetype) | - init |
Creates a new instance of the FMLiveSwitchRtpPacketHeader class. More... | |
(bool) | - marker |
Gets if the marker bit is set. More... | |
(bool) | - padding |
Gets if the packet has padding. More... | |
(int) | - paddingLength |
Gets the number of bytes of padding. More... | |
(int) | - payloadType |
Gets the payload type. More... | |
(int) | - sequenceNumber |
Gets the sequence number. More... | |
(void) | - setContributingSourceCount: |
Sets the number of contributing sources. More... | |
(void) | - setContributingSources: |
Sets the contributing sources. More... | |
(void) | - setHeaderExtension: |
Sets the header extension. More... | |
(void) | - setMarker: |
Sets if the marker bit is set. More... | |
(void) | - setPadding: |
Sets if the packet has padding. More... | |
(void) | - setPayloadType: |
Sets the payload type. More... | |
(void) | - setSequenceNumber: |
Sets the sequence number. More... | |
(void) | - setSynchronizationSource: |
Sets the synchronization source. More... | |
(void) | - setTimestamp: |
Sets the timestamp. More... | |
(void) | - setVersion: |
Sets the version of the packet. More... | |
(long long) | - synchronizationSource |
Gets the synchronization source. More... | |
(long long) | - timestamp |
Gets the timestamp. More... | |
(int) | - version |
Gets the version of the packet. More... | |
(void) | - writeToWithBuffer:offset: |
Writes this header to a buffer starting at the offset. More... | |
Class Methods | |
(int) | + fixedHeaderLength |
Gets the length of the fixed header. More... | |
(FMLiveSwitchRtpPacketHeader *) | + readFromWithBuffer: |
Reads a header from a buffer. More... | |
(FMLiveSwitchRtpPacketHeader *) | + rtpPacketHeader |
Creates a new instance of the FMLiveSwitchRtpPacketHeader class. More... | |
An RTP packet header.
- (int) calculateHeaderLength |
Calculates the length of the header.
At least 12 bytes.
- (FMLiveSwitchRtpPacketHeader*) clone |
Clones this instance.
- (int) contributingSourceCount |
Gets the number of contributing sources.
- (NSMutableArray*) contributingSources |
Gets the contributing sources.
- (bool) extension |
Gets if there is an extension.
+ (int) fixedHeaderLength |
Gets the length of the fixed header.
- (NSObject<FMLiveSwitchIRtpHeaderExtension>*) headerExtension |
Gets the header extension.
- (instancetype) init |
Creates a new instance of the FMLiveSwitchRtpPacketHeader class.
- (bool) marker |
Gets if the marker bit is set.
- (bool) padding |
Gets if the packet has padding.
- (int) paddingLength |
Gets the number of bytes of padding.
- (int) payloadType |
Gets the payload type.
+ (FMLiveSwitchRtpPacketHeader*) readFromWithBuffer: | (FMLiveSwitchDataBuffer *) | buffer |
Reads a header from a buffer.
If padding exists, also calculates the padding length.
buffer | The source buffer |
+ (FMLiveSwitchRtpPacketHeader*) rtpPacketHeader |
Creates a new instance of the FMLiveSwitchRtpPacketHeader class.
- (int) sequenceNumber |
Gets the sequence number.
- (void) setContributingSourceCount: | (int) | value |
Sets the number of contributing sources.
- (void) setContributingSources: | (NSMutableArray *) | value |
Sets the contributing sources.
- (void) setHeaderExtension: | (NSObject< FMLiveSwitchIRtpHeaderExtension > *) | value |
Sets the header extension.
- (void) setMarker: | (bool) | value |
Sets if the marker bit is set.
- (void) setPadding: | (bool) | value |
Sets if the packet has padding.
- (void) setPayloadType: | (int) | value |
Sets the payload type.
- (void) setSequenceNumber: | (int) | value |
Sets the sequence number.
- (void) setSynchronizationSource: | (long long) | value |
Sets the synchronization source.
- (void) setTimestamp: | (long long) | value |
Sets the timestamp.
- (void) setVersion: | (int) | value |
Sets the version of the packet.
Should be 2.
- (long long) synchronizationSource |
Gets the synchronization source.
- (long long) timestamp |
Gets the timestamp.
- (int) version |
Gets the version of the packet.
Should be 2.
- (void) writeToWithBuffer: | (FMLiveSwitchDataBuffer *) | buffer | |
offset: | (int) | offset | |
Writes this header to a buffer starting at the offset.
buffer | The target buffer. |
offset | The starting offset. |