HTML5 audio and video accessibility, internationalisation and usability

Silvia Pfeiffer

Xiph.Org, Vquence Pty Ltd, Mozilla Contractor

Overview

HTML5 media elements

  <video src="elephant.ogv" poster="elephant.png" controls>Fallback</video>
  
  <audio src="chocolate_rain.ogg" controls>Fallback</audio>

Further attributes: autoplay, preload, loop

Markup: multiple alternative sources


http://www.whatwg.org/specs/web-apps/current-work/multipage/video.html

  <video controls>
    <source src="video.webm" type="video/webm">
    <source src="video.ogv" type="video/ogg">
    <source src="video.mp4" type="video/mp4">
    Fallback
  </video>

Further attributes on <source>: media

Future state with video on the Web

  • no plugins
  • less sources of bugs
  • uniform API
  • simple markup
  • baseline codec (WebM?)
  • integrated accessibility
[any material that should appear in print but not on the slide]

Demos

Video & CSS

Video & SVG

Video & Canvas

More Demos

Video & Web Worker Threads & Canvas

http://hacks.mozilla.org/2009/06/connecting-html5-video/

Video & Synchronous Data Display in Canvas

http://people.mozilla.org/~blizzard/launch/

Accessibility Requirements

http://www.w3.org/WAI/PF/HTML/wiki/Media_Accessibility_Requirements

Vision-Impaired

More Requirements

Hard-of-Hearing


Deaf-blind


Foreigners / Adverse Environments

Current Hacks

Subtitles

Chapters & Captions

Animated Lyrics with SVG

Transcript

More Current Hacks

Integrated Proposal: has textual audio descriptions, captions, subtitles, chapters, lyrics

Current Technology Activities

  1. Multitrack Video Support
  2. External Text Tracks Markup in HTML5
  3. External Text Track File Format
  4. Direct Access to Media Fragments

1. Multitrack Media JavaScript API

Proposal: http://www.w3.org/WAI/PF/HTML/wiki/Media_MultitrackAPI
http://www.whatwg.org/specs/web-apps/current-work/multipage/video.html#the-track-element
  interface TimedTrack {
    readonly attribute DOMString kind;
    readonly attribute DOMString label;
    readonly attribute DOMString language;
    readonly attribute DOMString type;

    const unsigned short NONE = 0;
    const unsigned short LOADING = 1;
    const unsigned short LOADED = 2;
    const unsigned short ERROR = 3;
    readonly attribute unsigned short readyState;
    readonly attribute Function onload;
    readonly attribute Function onerror;

1. Multitrack Media JavaScript API (continued)

    const unsigned short OFF = 0;
    const unsigned short HIDDEN = 1;
    const unsigned short SHOWING = 2;
             attribute unsigned short mode;

    readonly attribute TimedTrackCueList cues;
    readonly attribute TimedTrackCueList activeCues;

    readonly attribute Function oncuechange;
  };

Proposed Track Kinds (roles)

http://www.w3.org/WAI/PF/HTML/wiki/Media_MultitrackAPI
http://www.whatwg.org/specs/web-apps/current-work/multipage/video.html#the-track-element

Text tracks:

"captions", "subtitles", "descriptions", "metadata",
"chapters", "lyrics", "karaoke"

Video tracks:

"main", "alternate" (e.g. different camera angle),
"sign" (for sign language) 

Audio tracks:

"main", "alternate" (probably linked to an alternate video track),
"dub", "description", "music", "sfx" (sound effects) 

2. External text tracks Markup

Proposal: http://www.w3.org/WAI/PF/HTML/wiki/Media_TextAssociations
http://www.whatwg.org/specs/web-apps/current-work/multipage/video.html#the-track-element
  interface HTMLTrackElement : HTMLElement {
             attribute DOMString kind;
             attribute DOMString label;
             attribute DOMString src;
             attribute DOMString srclang;
             attribute DOMString type;
             attribute DOMString media;

    readonly attribute TimedTrack track;
  };

2. Example Markup

http://www.w3.org/WAI/PF/HTML/wiki/Media_TextAssociations
http://www.whatwg.org/specs/web-apps/current-work/multipage/video.html#the-track-element

<video src="video.ogv">
  <track src="video_tad.srt" type="text/srt; charset='UTF-8'"
      srclang="en" kind="descriptions"></track>
  <track src="video_sub_en.srt" type="text/srt; charset='Windows-1252'"
      srclang="en" kind="subtitles"></track>
  <track src="video_sub_de.srt" type="text/srt; charset='ISO-8859-1'"
      srclang="de" kind="subtitles"></track>
  <track src="video_sub_ja.srt" type="text/srt; charset='EUC-JP'"
      srclang="ja" kind="subtitles"></track>
  </track>
</video>

3. File Format for External Text Track

Comparison of Format Examples

Text Track Baseline Format Discussions will have to happen

4. Media Fragment Addressing

Next Steps

Questions?



What is your particular itch?



Contact: Silvia Pfeiffer

Email: silviapfeiffer1@gmail.com

Twitter: silviapfeiffer

Blog: http://blog.gingertech.net/

[any material that should appear in print but not on the slide]