Expand description
HLS (HTTP Live Streaming) playlist generation for CMAF VOD output.
Produces:
master.m3u8— the top-level multivariant playlist with one#EXT-X-STREAM-INFper video rendition and one#EXT-X-MEDIA:TYPE=AUDIOrendition group entry pointing at the shared audio playlist.<rendition>/playlist.m3u8per video rendition — VOD media playlist with#EXT-X-MAPreferring to the rendition’sinit.mp4and#EXTINFlines pointing at theseg-NNNNN.m4sfiles (relative URIs).<audio_dir>/audio.m3u8— the shared audio media playlist.
Spec: RFC 8216 (HLS) + Apple’s HLS Authoring Spec for VOD content,
plus AV1-CMAF-HLS interoperability notes from hls.js’s test suite.
We target HLS protocol version 7 — the minimum that supports
EXT-X-MAP (fMP4 init segment) and EXT-X-INDEPENDENT-SEGMENTS.
Codec strings (the load-bearing CODECS attribute) are passed in
by the caller — they MUST be parsed from the actual encoded
bitstream by codec::codec_strings::av1_codec_string, not
composed from a config file. A wrong string causes hls.js / Safari
to silently skip the variant.
Structs§
- Audio
Variant Spec - Description of one audio rendition. CMAF-HLS uses a separate rendition group so video variants can switch bitrate without touching the audio track. We currently emit exactly one audio rendition (default English / undetermined-language); multi-track audio is a future task.
- HlsManifest
Paths - Paths produced by
write_hls_package. Useful for the integration test + the wire-contract reporter that surfaces a manifest URL to lewd.net. - Video
Variant Spec - Description of one video rendition for the master playlist.
Functions§
- write_
hls_ package - Emit a complete CMAF-HLS playlist tree under
output_dir.