Playback
Every live stream plays in four formats at once, straight from the same HTTP port as the panel. There’s nothing to turn on, a stream is ready to play the moment its publisher connects.
The URLs
Section titled “The URLs”For a stream called live/demo on a server at 192.0.2.10:
| Format | URL |
|---|---|
| HLS | http://192.0.2.10:8080/live/demo/index.m3u8 |
| LL-HLS | http://192.0.2.10:8080/live/demo/index.ll.m3u8 |
| DASH | http://192.0.2.10:8080/live/demo/index.mpd |
| MPEG-TS | http://192.0.2.10:8080/live/demo/mpegts |
A top level stream like demo works the same way, http://192.0.2.10:8080/demo/index.m3u8. The port is whatever http in [server] says.
Which one to pick
Section titled “Which one to pick”| Format | Good for | Notes |
|---|---|---|
| HLS | The widest reach: Safari, iPhones, smart TVs, set top boxes and every big player. | Classic HLS with MPEG-TS segments. A few segments of delay. |
| LL-HLS | Low latency in browsers and Apple devices. | fMP4 segments split into short parts that players fetch as soon as they exist. |
| DASH | Android, smart TVs and browser players like dash.js and Shaka Player. | fMP4 segments for each track. |
| MPEG-TS | IPTV set top boxes, VLC, FFmpeg and anything that wants one endless stream. | One long HTTP response, no playlists at all. |
Not sure? Start with HLS. It plays nearly everywhere, and players that know LL-HLS can use the low latency URL instead.
Players
Section titled “Players”- VLC: pick Media, then Open Network Stream and paste any of the URLs.
- ffplay or mpv:
ffplay http://192.0.2.10:8080/live/demo/index.m3u8 - Safari: plays HLS and LL-HLS natively, just put the URL in a
<video>tag. - Other browsers: use a player library like hls.js for HLS and LL-HLS, or dash.js for DASH.
Here’s the smallest web page that plays a stream with hls.js:
<video id="player" controls muted autoplay></video><script type="module"> import Hls from 'hls.js';
const url = 'http://192.0.2.10:8080/live/demo/index.ll.m3u8'; const video = document.getElementById('player'); if (Hls.isSupported()) { const hls = new Hls(); hls.loadSource(url); hls.attachMedia(video); } else { video.src = url; }</script>The panel uses the same thing for the live preview on each stream page.
Offline and warming up
Section titled “Offline and warming up”| Answer | What it means |
|---|---|
404 this stream is offline right now |
Nothing feeds the stream right now, no encoder and none of its sources. |
503 the stream is warming up |
The stream just went live and the first segment isn’t ready yet. Players retry on their own. |
404 nothing here |
There’s no such stream, or the URL has a typo. |
Latency
Section titled “Latency”How far behind live a player sits depends mostly on the segment length and how many segments it buffers. The knobs are in [packager]:
segment_durationsets the segment length. Shorter segments mean less delay and more requests.part_durationsets the length of LL-HLS parts. Shorter parts get LL-HLS players closer to live.window_segmentssets how many segments live playlists list.
Encoders matter too. Players can only start on a keyframe, so send one every second or two, -g 60 in FFmpeg at 30 frames per second, or a Keyframe Interval of 2 in OBS.
Embedding on other sites
Section titled “Embedding on other sites”Players on other websites need permission to fetch your streams. Nyquist sends Access-Control-Allow-Origin: * on playback by default, so it just works. Set allow_origin to your own site to lock it down, or to an empty string to leave the header out.
Caches and CDNs
Section titled “Caches and CDNs”Playlists change all the time while segments never do, so Nyquist sends different Cache-Control headers for each. The defaults suit a cache or a CDN in front of Nyquist, and you can change them in [http].
Putting a cache in front? Switch viewer tracking to address, so playlist links stay the same for everybody and the cache can share segments between viewers. Viewers and analytics explains why.
MPEG-TS details
Section titled “MPEG-TS details”The MPEG-TS output and the plain HLS segments use the PIDs, program number and timing from [mpegts]. The defaults suit almost everything, but some older set top boxes expect specific PIDs, and that’s where you’d set them.