Copyright © 2013 W3C® (MIT, ERCIM, Keio, Beihang), All Rights Reserved. W3C liability, trademark and document use rules apply.
This specification defines a Media Source Extensions byte stream format specification based on the WebM container format.
This document was published by the HTML Working Group. If you wish to make comments regarding this document, please send them to public-html-media@w3.org (subscribe, archives). All comments are welcome.
This specification describes a byte stream format based on the WebM container format. It defines the MIME-type parameters used to signal codecs, and provides the necessary format specific definitions for initialization segments, media segments, and random access points required by the byte stream formats section of the Media Source Extensions spec.
This section specifies the parameters that can be used in the MIME-type passed to isTypeSupported()
or addSourceBuffer()
.
Codec ID | Valid with "audio/webm" | Valid with "video/webm" |
---|---|---|
vorbis | true | true |
opus | true | true |
vp8 | false | true |
vp9 | false | true |
Examples of valid MIME-types with a codecs parameter.
A WebM initialization segment must contain a subset of the elements at the start of a typical WebM file.
The user agent must run the end of stream algorithm with the error parameter set to "decode"
if any of the following conditions are not met:
A WebM media segment is a single Cluster element.
The user agent uses the following rules when interpreting content in a Cluster:
The user agent must run the end of stream algorithm with the error parameter set to "decode"
if any of the following conditions are not met:
A SimpleBlock element with its Keyframe flag set signals the location of a random access point for that track. Media segments containing multiple tracks are only considered a random access point if the first SimpleBlock for each track has its Keyframe flag set. The order of the multiplexed blocks must conform to the WebM Muxer Guidelines.