Bitmovin with Media Acceleration

MA SDK Statistics
0 MB

CDN
0 MB

P2P
0 MB

Uploaded
0 %

Offload
0 %

Offload last 20 s
0

Peers

Here, you'll find basic instructions on how to integrate the Media Acceleration SDK with a Bitmovin player using Bitmovin API version 7.

How to

  1. Add a <script> tag to your page that points to the minified MASDK Javascript file. In the example that follows, we point to the latest version of the SDK.

    <script src="https://media-acceleration-host.akamaized.net/sdk/js/2.8/bitmovin-v7.min.js"></script>

  2. Locate the spot in your code where you are instantiating an instance of the player:

    /* Before MASDK integration */

    var player = bitmovin.player(elementId);

    player.setup(bitmovinConfig)
    .then(function() {
      player.play();
    });

  3. Initialize the MediaAccelerationBitmovinWrapper using both an MASDK configuration object and the bitmovinConfig, and use the player that is provided by this wrapper to replace the Bitmovin instance from the previous step.

    Please note that the MediaAccelerationBitmovinWrapper will call player.setup and you should not do this as well.

    /* After MASDK integration */

    /* MASDK configuration options */
    var maConfig = {};

    var maWrapper = new MediaAccelerationBitmovinWrapper(elementId, maConfig, bitmovinConfig);

    /* Retrieve the wrapped player */
    var player = maWrapper.getPlayer();

    player.load({ hls: "https://url/master.m3u8" })
    .then((player) => {
      player.play();
    });

What you should see

Once the MediaAccelerationBitmovinWrapper is initialized, you can get the version of the MASDK by accessing the version property: maWrapper.version. The value returned uses the <major-version>.<minor-version>.<patch> pattern. Use this for logging and troubleshooting.

For a complete example we recommend that you view the source code of this demo page or download the SDK and simple example pages at the Media Acceleration SDK page.