+
+# A basic form of stream, with HTTP input. Often, you will need no more than this.
+# The input must be Metacube framed (VLC can produce this with an option).
+stream /test.flv src=http://gruessi.zrh.sesse.net:4013/test.flv
+
+# Streams can share the same input (the same is reused, no extra bandwidth needed).
+# force_prebuffer=<number of bytes> is a parameter where we don't start sending
+# any data to a newly connected client before we can do that many bytes at once.
+# This is useful for clients that don't properly buffer themselves before starting
+# playing, e.g., most web browsers and some Flash players when playing from HTTP
+# (e.g., JW Player).
+stream /test-jwplayer.flv src=http://gruessi.zrh.sesse.net:4013/test.flv force_prebuffer=1500000
+
+# encoding=metacube means the _output_ will be Metacube framed. This is useful
+# for sending on to another Cubemap instance.
+stream /test.flv.metacube src=http://gruessi.zrh.sesse.net:4013/test.flv encoding=metacube
+
+# A stream where the input is _not_ Metacube framed. Note that the stream needs to
+# have no header and be self-synchronizing (like with UDP input below), and most formats
+# are not like this. A typical example, however, is MPEG-TS.
+stream /test.ts src=http://gruessi.zrh.sesse.net:4013/test.ts src_encoding=raw
+
+# If your input has PTS Metacube2 blocks (currently only generated by
+# Nageru >= 1.7.2 with MP4 output) and is segmentable (in practice MP4 with the
+# right tags, again typically generated by Nageru), you can serve HLS fragments
+# out of Cubemap's regular backlog, with the playlist served at the given URL
+# (in this case, /stream.m3u8). This allows you to serve video directly to
+# Mobile Safari (you'll need iOS >= 10 for fMP4 support; older iOS only
+# supports TS), and also allow rewinding in the stream if your backlog is large
+# enough. As of April 2018, iOS and hls.js seem to work well, while at least
+# VLC and mpv appear to be buggy.
+#
+# hls_frag_duration= sets the maximum fragment size in seconds; the default, 6,
+# is Apple's default recommendation. Larger fragments will cause more latency but
+# fewer HTTP requests (less chance of performance problems). (Typically, you'll want
+# a bit longer backlog than the default of 10 MB, as you won't fit many six-second
+# fragments into that.) Setting hls_backlog_margin= makes Cubemap not expose any
+# new fragments that are too far, measured in bytes, from the beginning of the
+# backlog, in order to reduce the risk of not managing to deliver them before
+# they rotate out. The default is zero, but you almost certainly want to change that
+# to be some reasonable fraction of your fragment length.
+stream /stream.mp4 src=http://gruessi.zrh.sesse.net:9095/test.mp4.metacube hls_playlist=/stream.m3u8 hls_frag_duration=6 backlog_size=20971520 hls_backlog_margin=1048576 allow_origin=*
+
+# UDP input. TS is the most common container to use over UDP (you cannot
+# take any arbitrary container and expect it to work).
+# backlog_size=<number of bytes> overrides the backlog, which is normally 10 MB.
+# If clients fall more behind than the backlog (plus the socket buffer),
+# they will drop data, so if you have extremely high-bitrate streams, you may want
+# to increase this. Or conversely, if you have little RAM and many streams
+# (or many servers) you can decrease it.