Page 1 of 1

How to play MPEG DASH stream

PostPosted: Tue Feb 02, 2016 8:55 pm
by email_r_NhGpbbUkZh
From Mpeg dash forum, I could write a very simple player that play the mpeg dash stream, something like this:
Code: Select all
<!DOCTYPE html>
    <meta charset="utf-8"/>
    <title>Dash JavaScript Player</title>
    <script src="dash.all.debug.js"></script>
    <script src=""></script>
    <video id="video" controls="true" autoplay="true"></video>
        var video = document.getElementById("video");
        var protData = {
          "org.w3.clearkey": {
            "clearkeys": {
              "IAAAACAAIAAgACAAAAAAAg": "5t1CjnbMFURBou087OSj2w"
        var player = MediaPlayer().create();
        player.attachSource("", null, protData);

It runs perfectly on chome and firefox (on desktop). But when deploy to SDK, it shows nothing. Does smarttv sdk really support mpeg dash stream and if it does, how to write simple player? I had read documents but could not find the solution.

Re: How to play MPEG DASH stream

PostPosted: Wed Feb 03, 2016 6:12 am
by Specs_STA
MPEG DASH streams are played on STA platforms by directly using the HTML5 video object. Set the src tag of the video element to the URL of the stream's MPD. Please see section 3.4.1 and 3.4.2 of the STA developer guidelines, available here: ... umentation

There's no need to use the dash.js Javascript library. This uses a different API to play streams in desktop browsers.

Good luck with your application!