Expand description
The RTMP wire identities — §5.1.2 chunk stream id, §5.1.3 message stream id and timestamp, §5.3.1.1’s basic-header encodability rule
(reference private/specs-verified/rtmp/rtmp-runtime/rtmp.md).
Each is a fixed-width wire field with no invalid bit pattern, so every bit pattern round-trips byte-exactly; the types exist so a chunk stream id cannot be passed where a message stream id is expected (the RTMP trap: both are bare integers in the spec) and so the basic-header range lives with the id it constrains.
Structs§
- Chunk
Stream Id - Chunk stream id (csid) — the per-chunk-stream multiplexing identity (§5.1.2), carried by the basic header in the range 2..=65599.
- Message
Stream Id - Message stream id (msid) — the application-level stream a message belongs
to (§5.1.3), allocated by
createStreamand carried little-endian in a Type 0 message header. - Sequence
Number - An RTMP acknowledgement sequence number (§5.4.3): the total number of bytes received so far, carried as a 32-bit field.
- Timestamp
- An RTMP
timestamp/timestamp delta(§5.3.1.2) — a whole number of milliseconds on the wire, held as a span so a caller never passes a raw tick count. - Timestamp
OutOf Range - A
Timestampthe 32-bit wire field cannot hold (a span of 2^32 ms or more, §5.3.1.2).
Constants§
- MAX_
CHUNK_ STREAM_ ID - Highest chunk stream id a basic header can carry: the 3-byte form encodes
(byte2 * 256) + byte1 + 64(§5.3.1.1). - MIN_
CHUNK_ STREAM_ ID - Lowest chunk stream id a basic header can carry; 0 and 1 are the 2-/3-byte form markers, not ids (§5.3.1.1).