DASH Playback¶
Flussonic Media Server supports playing video via the DASH protocol.
The supported codecs are: H264, H265, AAC, MP3, and AC-3.
Flussonic Media Server supports access via MPEG-DASH to live streams, VOD files, and DVR (catchup and timeshift).
If an incoming stream has DVB subtitles, then Flussonic can pass them to an output MPEG-DASH stream if you configure Flussonic for that. Subtitles are saved in DVR archive if a stream is recorded to the archive.
DASH uses a manifest file for transmitting information about a requested stream. To keep it simple, we call it 'playlist' here.
On this page:¶
- Simple video playback via DASH
- Playing back individual tracks
- DVR catchup playback via DASH
- Rewinding DASH videos
- DVR timeshift playback
- DASH manifests for playing on TVs with WebOS and other devices
- DVB compliance of a DASH manifest
- Playback with subtitles
- DASH playback with thumbnails
Simple video playback via DASH¶
When you have a live stream or file (one video track, one audio track) for playing, the URL for playback via DASH is simple:
http://FLUSSONIC-IP/STREAMNAME/index.mpd
where FLUSSONIC-IP
is a placeholder for your Flussonic Media Server host + port address.
Selecting tracks for playback¶
If a stream has several audio, video, or subtitle tracks, you can specify the tracks for playback. To do this, use the filter.tracks parameter.
See the following examples:
- Select the first audio and second video tracks:
http://FLUSSONIC-IP/STREAMNAME/index.mpd?filter.tracks=v2a1
- Select video only:
http://FLUSSONIC-IP/STREAMNAME/index.mpd?filter.tracks=v1
- Select the second video track and the first audio track for the DVR archive starting from UTC 1362504585 with the duration of 3600 seconds:
http://FLUSSONIC-IP/STREAMNAME/archive-1362504585-3600.mpd?filter.tracks=v2a1
DVR catch up playback via DASH¶
When your stream is already recorded on a server with our DVR, you can play video via DASH if you know the beginning and ending time of telecast, for example, from EPG.
URLs for playing video from archives will be like this:
http://FLUSSONIC-IP/STREAMNAME/archive-1362504585-3600.mpd
Such a URL will give a list of segments starting from UTC 1362504585 (2013, March, 5th, 17:29:45 GMT) and for one hour forward (3600 seconds).
If you have more than one language or more than one bitrate, you will get an adaptive stream with the possibility to select the audio track.
Rewinding DASH videos¶
Flussonic Media Server has a special playlist "rewind-N.mpd" with a wide sliding window that allows you to rewind DASH streams and pause them for many hours.
http://FLUSSONIC-IP/STREAMNAME/rewind-7200.mpd
Here 7200 is the duration of the DASH manifest in seconds, so your clients will be able to pause the stream for up to 2 hours or rewind to the start of a TV show without using catchup URLs.
Also, there is a playlist in which you can receive a live stream and rewind up to a specified time: "archive-N-now.mpd", where N — is a Unix timestamp of the moment to which users can rewind the stream.
http://FLUSSONIC-IP/STREAMNAME/archive-1362504585-now.mpd
DVR timeshift playback¶
Here we descibe one more way to play an archive via DASH with the option to rewind up to the specified time. If you haven't configured a timeshifted stream, you can still play timeshifted video via DASH by using a propely constructed URL.
Here goes the example of an URL for absolute timeshift:
http://FLUSSONIC-IP/STREAMNAME/timeshift_abs-1584435600.mpd
where 1584435600 is 03/17/2020 @ 9:00am (UTC)
The player will play live at the start and allow rewinding up to 1584435600.
DASH manifests for playing DVR on TVs with WebOS¶
Flussonic can create DASH manifest of two types: with multiple periods and with a single period.
Initially, Flussonic designed its DASH manifest for DVR playback with the view to usage in CDN. The manifest with multiple periods was suitable for this purpose.
However, such a manifest is incompatible with a wide range of devices and TV sets used by consumers in many countries, such as US. These include LG TVs on WebOS and others.
For devices that cannot play DASH with multi-period timeline, we designed a single-period manifest enabling you to play DASH on that devices.
Add period=mono
to the URL as follows:
http://FLUSSONIC-IP/STREAMNAME/archive-TIME-DURATION.mpd?period=mono
or
http://FLUSSONIC-IP/STREAMNAME/archive-TIME-now.mpd?period=mono
Note. The single-period manifest for live with the option to view the recorded archive (archive-TIME-now.mpd?period=mono) is sensitive to the quality of the input stream source — it is necessary that there are no gaps in the live stream.
Turning on DVB compliance of a DASH manifest¶
If you use a validator for DASH and you turn on checking for DVB compliance in the validator, you'll need to make sure that your DASH manifests are compliant with the DVB profile.
In order to get a DVB-compliant manifest, add the option dvb=1
to the stream's URL:
http://FLUSSONIC-IP/STREAMNAME/index.mpd?dvb=1
Playback with subtitles¶
Flussonic supports passing both TTML and WebVTT subtitles into DASH streams. This allows showing subtitles on a wider range of devices and set-top boxes.
Choosing subtitles format for DASH playback¶
As two formats of subtitles are included in a DASH manifest, you can choose one of them when playing an output stream:
https://FLUSSONIC-IP/STREAMNAME/index.mpd?text=wvtt
or (TTML is the default format)
https://FLUSSONIC-IP/STREAMNAME/index.mpd?text=ttml
The option text
can be used also with URLs like:
http://FLUSSONIC-IP/STREAMNAME/rewind-7200.mpd?text=wvtt
DASH playback with thumbnails¶
It is possible to add thumbnails into DASH playlist as special tags that a player can read. It works both for streams with DVR enabled and for VOD files.
To include thumbnails into the playlist, add ?thumbnails=
option to the stream or the VOD file URL.
Example for a DVR window:
http:// flussonic:80/ort/archive-1643013512-now.mpd?thumbnails=50
Example for a VOD file:
http://flussonic:80/vod/bunny.mp4/Manifest.mpd?thumbnails=100
This value defines how many thumbnail links will be added to the thumbnail playlist to cover the duration of the DVR window or the VOD file correspondingly. The player will add the thumbnail links to the progress bar at regular intervals. The duration of the interval between thumbnails is the whole duration of the DVR window or the VOD file divided by this value.
If you specify a big number, then the player will use additional resources which may make the player or the browser stuck. Decreasing this parameter allows to limit the number of thumbnails to play and thus to reduce the player resources usage.
This option requires the parameters thumbnails enabled=ondemand
and size
(thumbnail size) included in the stream or VOD location settings. For example, thumbnails enabled=ondemand size=320x240;
. You can specify multiple sizes separated by spaces, for example, size=320x250 size=640x480
. In this case, several thumbnails tracks will be included into the playlist. Each thumbnail in the playlist will be resized proportionally to fit the specified size.
For more information, please refer to Streaming API schema.