Microsoft Smooth Streaming Plugin for OSMF with Azure Media MPEG-DASH support

cropped-OSMF-Logo
One of the plugins that Microsoft released is Microsoft Smooth Streaming with OSMF Azure Plugin for Media MPEG-DASH support . We can extend the capabilities of OSMF (Open Source Media Framework for Adobe) adding Microsoft Smooth Streaming to players using this technology, as well as playback on Strobe Media Playback (SMP).

With this plugin we added the following features:

  • On-demand Smooth Streaming playback (Play, Pause, Seek, Stop)
  • On-demand Azure Media MPEG-DASH playback (beta) (Play, Pause, Seek, Stop)
  • Live Smooth Streaming playback (Play)
  • Live Smooth Streaming DVR playback (Play, Pause, Seek, go-to-live)
  • Support for video codecs – H.264
  • Support for Audio codecs – AAC
  • Multiple audio language switching with OSMF built-in APIs
  • Max playback quality selection with OSMF built-in APIs
  • This version only supports OSMF 2.0

Through this link you can download a set of files:

OMSF Downloads

  • MSAdaptiveStreamingPlugin-v1.0.10-osmf2.0.swc: for static loading.
  • MSAdaptiveStreamingPlugin-v1.0.10-osmf2.0.swf: for dynamic loading.
  • Smooth_Streaming_Plugin_for_OSMF.pdf: plugin documentation.
  • SmoothStreamingPlugin_EULA.rtf: plugin license.
  • StrobeMediaPlayback.2.0.swf: Strobe Media Playback

In this post we will focus on the dynamic loading using MSAdaptiveStreamingPlugin-v1.0.10-osmf2.0.swf.

Player settings

In order to test the player with Microsoft Azure Media Services, we must have at least one asset prepared for Smooth Streaming:

<object type="application/x-shockwave-flash"
        data="/OSMF/StrobeMediaPlayback.2.0.swf"
        width="920" height="640"
        id="flashPlayer"
        style="visibility: visible;">
    <param name="allowfullscreen" value="true">
    <param name="wmode" value="direct">
    <param name="flashvars" value="src=http://[YOUR_MEDIA_ACCOUNT].origin.mediaservices.windows.net/[LOCATOR]/[FILE_NAME].ism/Manifest&amp;autoPlay=true&amp;plugin_AdaptiveStreamingPlugin=/OSMF/MSAdaptiveStreamingPlugin-v1.0.10-osmf2.0.swf&amp;AdaptiveStreamingPlugin_retryLive=true&amp;AdaptiveStreamingPlugin_retryInterval=10">
</object>

As data param we use the player StrobeMediaPlayback.2.0.swf, in OSMF folder. For flashvars are included the following values ​​in this order:

  1. URL of the asset to playback.
  2. autoPlay=true for automatic playback.
  3. plugin_AdaptiveStreamingPlugin with the path of the plugin for OSMF
  4. AdaptiveStreamingPlugin_retryLive=true y AdaptiveStreamingPlugin_retryInterval=10 to enable the retry policy.

If we want to playback MPGE-DASH (still in beta), the configuration would be:

<object type="application/x-shockwave-flash"
        data="/OSMF/StrobeMediaPlayback.2.0.swf"
        width="920" height="640"
        id="flashPlayer"
        style="visibility: visible;">
    <param name="allowfullscreen" value="true">
    <param name="wmode" value="direct">
    <param name="flashvars" value="src=http://[YOUR_MEDIA_ACCOUNT].origin.mediaservices.windows.net/[LOCATOR]/[FILE_NAME].ism/Manifest(format=mpd-time-csf)&amp;autoPlay=true&amp;plugin_AdaptiveStreamingPlugin=/OSMF/MSAdaptiveStreamingPlugin-v1.0.10-osmf2.0.swf&amp;AdaptiveStreamingPlugin_retryLive=true&amp;AdaptiveStreamingPlugin_retryInterval=10">
</object>

As you can see in the code above, the only thing we need to change is the request for MPEG-DASH format, adding after Manifest (format=mpd-time-csf). Also, you can be interested in usign Dash.js for MPEG-DASH format.

Hope this helps.

Happy streaming!