go back...
go-rtmp-server
What it does
RTMP is still the network protocol most encoders (OBS, hardware encoders, phones) use to push a live stream to a server. This project implements the server side without an off-the-shelf RTMP library.
What’s implemented
- Handshake: the C0/C1/C2 and S0/S1/S2 exchange that opens every connection.
- AMF0: encoding and decoding the command messages (
connect,createStream,publish) that set up a stream. - Chunk stream parsing: reassembling interleaved messages from RTMP chunks.
- FLV muxing: writing H.264 (AVC) video and AAC audio into FLV tags, including sequence headers.
What I’d do next
- Saving & Transcoding: Transcode into different video formats and qualities
Read more
I wrote up the hardest parts in Building an RTMP server from scratch in Go.