Skip to main content

Module header

Module header 

Source
Expand description

The four-byte header common to every RTCP packet. The RTCP header.

Four bytes on every packet: version and padding flags, a 5-bit count whose meaning depends on the packet type, the PacketType itself, and a length in 32-bit words. The *_SHIFT and *_MASK constants describe how the flags pack into the first octet.

The length field is why RTCP is compound: several packets can be concatenated in one datagram and walked by stepping over each header’s length.

Structs§

Header
A Header is the common header shared by all RTCP packets

Enums§

PacketType
PacketType specifies the type of an RTCP packet RTCP packet types registered with IANA. See: https://www.iana.org/assignments/rtp-parameters/rtp-parameters.xhtml#rtp-parameters-4

Constants§

COUNT_MASK
Bit mask of the report/source count field.
COUNT_MAX
The largest report count the 5-bit field can hold.
COUNT_SHIFT
Bit offset of the report/source count field.
FIR_MIN_OCTET_COUNT
The smallest valid FIR packet, in bytes.
FORMAT_AFB
FMT of application-layer feedback (PSFB, RFC 4585 §6.4), which REMB is one kind of.
FORMAT_CCFB
FMT value for CCFB (Congestion Control Feedback) per RFC 8888
FORMAT_ECN
FMT value for the RTCP ECN Feedback packet (RFC 6679 section 5.1)
FORMAT_FIR
FMT of the Full Intra Request (PSFB, RFC 5104 §4.3.1).
FORMAT_LRR
FMT of the Layer Refresh Request (PSFB, RFC 9627 §3).
FORMAT_PAUSE_RESUME
FMT of the PAUSE-RESUME message (RTPFB, RFC 7728 section 7).
FORMAT_PLI
FMT of the Picture Loss Indication (PSFB, RFC 4585 §6.3.1).
FORMAT_REMB
FMT of REMB: application-layer feedback whose payload starts with REMB.
FORMAT_RPSI
FMT of the Reference Picture Selection Indication (PSFB, RFC 4585 §6.3.3).
FORMAT_RRR
FMT of the Rapid Resynchronisation Request (RTPFB, RFC 6051 §3.2).
FORMAT_SLI
FMT of the Slice Loss Indication (PSFB, RFC 4585 §6.3.2).
FORMAT_TCC
FMT of transport-wide congestion control feedback (RTPFB). https://tools.ietf.org/html/draft-holmer-rmcat-transport-wide-cc-extensions-01#page-5
FORMAT_TLN
FMT of the generic NACK (RTPFB, RFC 4585 §6.2.1).
FORMAT_TMMBN
FMT of the Temporary Maximum Media Stream Bit Rate Notification (RTPFB, RFC 5104 §4.2.2).
FORMAT_TMMBR
FMT of the Temporary Maximum Media Stream Bit Rate Request (RTPFB, RFC 5104 §4.2.1).
FORMAT_TSTN
FMT of the Temporal-Spatial Trade-off Notification (PSFB, RFC 5104 §4.3.3).
FORMAT_TSTR
FMT of the Temporal-Spatial Trade-off Request (PSFB, RFC 5104 §4.3.2).
FORMAT_VBCM
FMT of the Video Back Channel Message (PSFB, RFC 5104 §4.3.4).
HEADER_LENGTH
Length of the RTCP header in bytes.
PADDING_MASK
Bit mask of the padding flag once shifted.
PADDING_SHIFT
Bit offset of the padding flag.
RTP_VERSION
The RTP/RTCP version this crate speaks.
SDES_MAX_OCTET_COUNT
The longest SDES item value, bounded by its one-byte length field.
SSRC_LENGTH
Length of an SSRC in bytes.
VERSION_MASK
Bit mask of the version field once shifted.
VERSION_SHIFT
Bit offset of the version field in the first header octet.