Documentation ¶
Overview ¶
Package chunk implements RTMP chunks.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Chunk0 ¶
type Chunk0 struct { ChunkStreamID byte Timestamp uint32 Type uint8 MessageStreamID uint32 BodyLen uint32 Body []byte }
Chunk0 is a type 0 chunk. This type MUST be used at the start of a chunk stream, and whenever the stream timestamp goes backward (e.g., because of a backward seek).
type Chunk1 ¶
type Chunk1 struct { ChunkStreamID byte TimestampDelta uint32 Type uint8 BodyLen uint32 Body []byte }
Chunk1 is a type 1 chunk. The message stream ID is not included; this chunk takes the same stream ID as the preceding chunk. Streams with variable-sized messages (for example, many video formats) SHOULD use this format for the first chunk of each new message after the first.
type Chunk2 ¶
Chunk2 is a type 2 chunk. Neither the stream ID nor the message length is included; this chunk has the same stream ID and message length as the preceding chunk.
type Chunk3 ¶
Chunk3 is a type 3 chunk. Type 3 chunks have no message header. The stream ID, message length and timestamp delta fields are not present; chunks of this type take values from the preceding chunk for the same Chunk Stream ID. When a single message is split into chunks, all chunks of a message except the first one SHOULD use this type.