HTML5 Player Framework Preview: Frequently Asked Questions

What is the HTML5 Player Framework?

  • The HTML5 Player Framework delivers a consistent video experience for the browser. This is accomplished by detecting support for different video player technologies available on the client (e.g. HTML5 video tag, Silverlight, etc.) and then providing the same JavaScript API and the same set of controls regardless of the technology that is used. The HTML5 Player Framework will iterate through a list of fallback video player technologies until a supported technology is found.

What are the supported fallback scenarios and what are the reasons for using them?

  • Different fallback scenarios composed of ordered alternatives are available depending on what you want the primary viewing experience to be:
    • If only progressive video is needed, then a video tag can be used as the primary experience and a Silverlight object tag can be nested under the video tag.
    • If Smooth Streaming video is available or another Silverlight feature is wanted, then a Silverlight object tag can be used as the primary experience and a video tag referencing a progressive file can be nested under the object tag.
    • Other fallback scenarios can be provided using custom plugins created by developers to support any video player technology needed.

What if neither the video tag nor Silverlight are supported?

  • A third fallback alternative can be provided that displays static download links to the videos so that the user can play them locally. Additionally, users can create their own fallback handlers such as using Flash.

How is the fallback scenario configured?

  • Currently, the fallback scenario is declared in the web page using standard HTML. The HTML5 Player Framework takes reference to the DOM ID of the tag representing the primary video experience and automatically finds the fallback alternatives nested underneath. We plan to provide a method of generating the required markup based on a fallback order passed in the configuration.

Are we required to provide fallback alternatives?

  • No, the HTML5 Player Framework can be used with a single video player technology (e.g. only the video tag or only Silverlight). You can still benefit from the consistent control strip and JavaScript API. However, to ensure support for a wider range of clients, it is recommended that you provide multiple alternatives.

Can we require the installation of Silverlight?

  • Yes, if Silverlight is the primary and only experience or if Silverlight is the last fallback alternative, then the HTML5 Player Framework can prompt the user to install Silverlight.

What if I don’t provide encodings in the video tag to support all browsers (e.g. .mp4, .ogv, .webm, etc.)?

  • If a browser does not support any of the provided encodings in the video tag, the HTML5 Player Framework will force a fallback to the next alternative experience (e.g. Silverlight).

What is the recommended fallback scenario embed code?

  • The recommended embed code is video tag with nested sources and a nested object tag that references a Silverlight .xap. This is similar to the “Video for Everybody” approach and provides video support for browsers that either do not support the video tag or do not support JavaScript.

What convention does the JavaScript API follow?

  • The JavaScript API matches the video tag API as described by the HTML5 spec. This allows developers that are already familiar with the HTML5 video API to quickly develop with the HTML5 Player Framework.

Does the HTML5 Player Framework depend on any external libraries such as jQuery?

  • The HTML5 Player Framework does not depend on any external libraries or frameworks. The code that another library could have saved us from writing would have been minimal and with the additional file size, we decided not to take on an external dependency. The Player Framework is currently under 6k when minified and gzipped, while jQuery 1.6.1 is 32k.

Can I use the HTML5 Player Framework as a jQuery plugin?

  • We plan to provide a simple wrapper that will allow you to use jQuery to attach the HTML5 Player Framework to an existing DOM element and then chain other jQuery expressions off of the returned object.

How is support for functionality in different browsers determined?

  • Feature detection is used to determine if specific functionality is available in the browser. No browser sniffing takes place. The video experience is progressively enhanced wherever possible.

How are the fallback scenarios simulated in the demos?

  • For the fallback to Silverlight from HTML5, we provide invalid video types in the <source> tags. Using a browser that does not support the video tag would also work in this case. For the fallback to HTML5 video from Silverlight, we provide an invalid version number in the object tag parameter “minRuntimeVersion”. Disabling the Silverlight plugin would also work in this case.

What is the style of the default controls and how are they created?

  • The default controls are styled to be consistent with the default IE9 video tag controls. They are created using HTML and CSS (no images) and used by both the video tag and Silverlight. We have plans to create Silverlight controls styled to match the default IE9 video tag controls as overlaying HTML on Silverlight requires using windowless mode in Silverlight which can degrade video performance.

Can I provide my own controls or style the existing controls?

  • Yes, you can provide your own controls by adding a control strip plugin or the existing controls can be styled using CSS.

Can I use the native video player controls?

  • Yes, there is a configuration option to switch to the controls provided by the selected video player.

Can I create other plugins for the HTML5 Player Framework?

  • Yes, the HTML5 Player Framework is built on a pluggable architecture, so that developers can create their own custom plugins such as control strip plugins and media plugins for other video player technologies. We use our own plugin architecture to provide support for the video tag, Silverlight, and the default controls.

How do I configure the HTML5 Player Framework?

  • Documentation on the available configuration options will be released along with the first drop of the HTML5 Player Framework. Configuration is passed into the Player constructor when creating a new instance of the Player:

var myPlayer = new PlayerFramework.Player("myVideo", { /* configuration */ });

Last edited Jul 6, 2011 at 2:05 AM by jcostello, version 4

Comments

No comments yet.