├── CODE_OF_CONDUCT.md ├── CONTRIBUTING.md ├── LICENSE.md ├── README.md ├── audio_splice.png ├── byte-stream-format-registry-cr.html ├── byte-stream-format-registry-respec.html ├── byte-stream-format-registry.html ├── cr-heartbeat-2 ├── audio_splice.png ├── byte-stream-format-registry.html ├── index.html ├── isobmff-byte-stream-format.html ├── mp2t-byte-stream-format.html ├── mpeg-audio-byte-stream-format.html ├── mse.css ├── pipeline_model.png └── webm-byte-stream-format.html ├── index.html ├── isobmff-byte-stream-format-cr.html ├── isobmff-byte-stream-format-respec.html ├── isobmff-byte-stream-format.html ├── media-source-cr.html ├── media-source-fpwd.html ├── media-source-lc.html ├── media-source-pr.html ├── media-source-respec.html ├── media-source-wd.html ├── media-source.html ├── media-source.js ├── mp2t-byte-stream-format-respec.html ├── mp2t-byte-stream-format.html ├── mpeg-audio-byte-stream-format-cr.html ├── mpeg-audio-byte-stream-format-respec.html ├── mpeg-audio-byte-stream-format.html ├── mse-1-errata.html ├── mse.css ├── pipeline_model.svg ├── pipeline_model_description.html ├── respec-w3c-common.js ├── w3c.json ├── webm-byte-stream-format-respec.html └── webm-byte-stream-format.html /CODE_OF_CONDUCT.md: -------------------------------------------------------------------------------- 1 | # Code of Conduct 2 | 3 | All documentation, code and communication under this repository are covered by the [W3C Code of Ethics and Professional Conduct](https://www.w3.org/Consortium/cepc/). 4 | -------------------------------------------------------------------------------- /CONTRIBUTING.md: -------------------------------------------------------------------------------- 1 | # HTML Working Group 2 | 3 | Contributions to this repository are intended to become part of Recommendation-track documents 4 | governed by the [W3C Patent Policy](http://www.w3.org/Consortium/Patent-Policy-20040205/) and 5 | [Document License](http://www.w3.org/Consortium/Legal/copyright-documents). To contribute, you must 6 | either participate in the relevant W3C Working Group or make a non-member patent licensing 7 | commitment. 8 | 9 | If you are not the sole contributor to a contribution (pull request), please identify all 10 | contributors in the pull request's body or in subsequent comments. 11 | 12 | To add a contributor (other than yourself, that's automatic), mark them one per line as follows: 13 | 14 | ``` 15 | +@github_username 16 | ``` 17 | 18 | If you added a contributor by mistake, you can remove them in a comment with: 19 | 20 | ``` 21 | -@github_username 22 | ``` 23 | 24 | If you are making a pull request on behalf of someone else but you had no part in designing the 25 | feature, you can remove yourself with the above syntax. 26 | -------------------------------------------------------------------------------- /LICENSE.md: -------------------------------------------------------------------------------- 1 | All documents in this Repository are licensed by contributors under the [W3C Document 2 | License](http://www.w3.org/Consortium/Legal/copyright-documents). 3 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # Incubation of vNext 'media-source' Specification Features 2 | 3 | 4 | # May 2021: See instead the upstream w3c media-source repository now for new feature incubations (this WICG repo was useful before MSE v2 work upstream began; current work is upstream). Moving incubated feature explainers, etc into the main spec is being done there currently (work-in-progress). 5 | 6 | 7 | This is [the repository forked off the W3C REC repository for 8 | media-source](https://github.com/w3c/media-source), and is intended to track 9 | incubation of new media-source features. 10 | 11 | You're welcome to contribute! Let's continue to make the Web rock our socks off! 12 | 13 | The admins will update this repository's gh-pages branch to align with 14 | the upstream w3c repository. 15 | 16 | **All** specification updates that are part of incubation will be done on a 17 | per-feature branch off of gh-pages in this repository. Please base your 18 | pull-requests accordingly. 19 | 20 | We will use the [upstream w3c/media-source repository's issue tracker](https://github.com/w3c/media-source/issues) 21 | for feature discussion beyond pull-requests. 22 | 23 | The following is the list of current feature incubation branches: 24 | 25 | * [codec-switching](https://github.com/WICG/media-source/tree/codec-switching) 26 | * Tracking issue: 27 | [w3c/media-source/issues/155](https://github.com/w3c/media-source/issues/155) 28 | * [Feature 29 | explainer](https://github.com/wicg/media-source/blob/codec-switching/codec-switching-explainer.md) 30 | * [HTML Diff versus REC 31 | spec](https://services.w3.org/htmldiff?doc1=https%3A%2F%2Fwww.w3.org%2FTR%2Fmedia-source%2F&doc2=https%3A%2F%2Frawgit.com%2FWICG%2Fmedia-source%2Fcodec-switching%2Findex.html) 32 | * [HTML Diff versus upstream W3C Editor's 33 | Draft](https://services.w3.org/htmldiff?doc1=https%3A%2F%2Frawgit.com%2FW3C%2Fmedia-source%2Fgh-pages%2Findex.html&doc2=https%3A%2F%2Frawgit.com%2FWICG%2Fmedia-source%2Fcodec-switching%2Findex.html) 34 | 35 | * [mse-in-workers-using-handle](https://github.com/WICG/media-source/tree/mse-in-workers-using-handle) 36 | * Tracking issue: 37 | [w3c/media-source/issues/175](https://github.com/w3c/media-source/issues/175) 38 | * [Feature 39 | explainer](https://github.com/wicg/media-source/blob/mse-in-workers-using-handle/mse-in-workers-using-handle-explainer.md) 40 | 41 | * [eviction 42 | policies](https://github.com/WICG/media-source/tree/mse-eviction-policies) 43 | * Tracking issue: 44 | [w3c/media-source/issues/232](https://github.com/w3c/media-source/issues/232) 45 | * [Feature 46 | explainer](https://github.com/wicg/media-source/blob/mse-eviction-policies/mse-eviction-policies-explainer.md) 47 | -------------------------------------------------------------------------------- /audio_splice.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/WICG/media-source/8f8b4205a038a8e02a525841fd83f272077d71ce/audio_splice.png -------------------------------------------------------------------------------- /byte-stream-format-registry-cr.html: -------------------------------------------------------------------------------- 1 | 2 | 3 |
4 | 5 |175 | Copyright © 176 | 2014 177 | 178 | W3C® 179 | (MIT, 180 | ERCIM, 181 | Keio, Beihang), 182 | 183 | All Rights Reserved. 184 | 185 | W3C liability, 186 | trademark and 187 | 188 | document use 189 | 190 | rules apply. 191 |
192 | 193 | 194 |This registry is intended to enhance interoperability among implementations and users of
200 | SourceBuffer
objects described in the
201 | Media Source Extensions(MSE) specification. In particular, this registry provides the means (1) to identify
202 | and avoid MIME-type collisions among byte stream formats, and (2) to disclose information about byte stream formats accepted by MSE
203 | implementations to promote interoperability.
204 |
The registry maintains a mapping between MIME-type/subtype pairs and byte stream format specifications. The byte stream format specifications describe the
209 | structure and semantics of byte streams accepted by SourceBuffer
objects
210 | created with the associated MIME-type/subtype pair.
This registry is not intended to include any information on whether a byte stream format is encumbered by intellectual property claims. Implementors and users 212 | are advised to seek appropriate legal counsel in this matter if they intend to implement or use a specific byte stream format.
213 |SourceBuffer
when handling the byte stream format.If a registration fails to satisfy a mandatory requirement specified above, then it may be removed from the registry (without prejudice). 231 |
MIME type/subtype | 239 |Public Specification(s) | 240 |Generate Timestamps Flag | 241 |
---|---|---|
246 | audio/webm 247 | video/webm 248 | |
249 | WebM Byte Stream Format | 250 |false | 251 |
254 | audio/mp4 255 | video/mp4 256 | |
257 | ISO BMFF Byte Stream Format | 258 |false | 259 |
262 | audio/mp2t 263 | video/mp2t 264 | |
265 | MPEG-2 Transport Streams Byte Stream Format | 266 |false | 267 |
270 | audio/mpeg 271 | audio/aac 272 | |
273 | MPEG Audio Byte Stream Format | 274 |true | 275 |
This specification defines the byte stream formats for use with the specification [[!MEDIA-SOURCE]].
114 |The working group maintains a list of all bug reports that the editors have not yet tried to address; there may also be open bugs in the previous bug tracker.
118 |Implementors should be aware that this specification is not stable. Implementors who are not taking part in the discussions are likely to find the specification changing out from under them in incompatible ways. Vendors interested in implementing this specification before it eventually reaches the Candidate Recommendation stage should join the mailing list mentioned below and take part in the discussions.
119 |This registry is intended to enhance interoperability among implementations and users of 124 | SourceBuffer objects described in the 125 | (MSE) specification. In particular, this registry provides the means (1) to identify 126 | and avoid MIME-type collisions among byte stream formats, and (2) to disclose information about byte stream formats accepted by MSE 127 | implementations to promote interoperability. 128 |
The registry maintains a mapping between MIME-type/subtype pairs and byte stream format specifications. The byte stream format specifications describe the 133 | structure and semantics of byte streams accepted by SourceBuffer objects 134 | created with the associated MIME-type/subtype pair.
135 |This registry is not intended to include any information on whether a byte stream format is encumbered by intellectual property claims. Implementors and users 136 | are advised to seek appropriate legal counsel in this matter if they intend to implement or use a specific byte stream format.
137 |If a registration fails to satisfy a mandatory requirement specified above, then it MAY be removed from the registry (without prejudice). 155 |
142 |
143 |
144 |
145 |
146 |
147 |
177 | Copyright © 178 | 2015 179 | 180 | W3C® 181 | (MIT, 182 | ERCIM, 183 | Keio, Beihang). 184 | 185 | W3C liability, 186 | trademark and 187 | 188 | document use 189 | 190 | rules apply. 191 |
192 | 193 | 194 |This registry is intended to enhance interoperability among implementations and users of
200 | SourceBuffer
objects described in the
201 | Media Source Extensions(MSE) specification. In particular, this registry provides the means (1) to identify
202 | and avoid MIME-type collisions among byte stream formats, and (2) to disclose information about byte stream formats accepted by MSE
203 | implementations to promote interoperability.
204 |
The registry maintains a mapping between MIME-type/subtype pairs and byte stream format specifications. The byte stream format specifications describe the
209 | structure and semantics of byte streams accepted by SourceBuffer
objects
210 | created with the associated MIME-type/subtype pair.
This registry is not intended to include any information on whether a byte stream format is encumbered by intellectual property claims. Implementors and users 212 | are advised to seek appropriate legal counsel in this matter if they intend to implement or use a specific byte stream format.
213 |SourceBuffer
when handling the byte stream format.If a registration fails to satisfy a mandatory requirement specified above, then it may be removed from the registry (without prejudice). 231 |
MIME type/subtype | 239 |Public Specification(s) | 240 |Generate Timestamps Flag | 241 |
---|---|---|
246 | audio/webm 247 | video/webm 248 | |
249 | WebM Byte Stream Format | 250 |false | 251 |
254 | audio/mp4 255 | video/mp4 256 | |
257 | ISO BMFF Byte Stream Format | 258 |false | 259 |
262 | audio/mp2t 263 | video/mp2t 264 | |
265 | MPEG-2 Transport Streams Byte Stream Format | 266 |false | 267 |
270 | audio/mpeg 271 | audio/aac 272 | |
273 | MPEG Audio Byte Stream Format | 274 |true | 275 |
194 |
195 |
196 |
197 |
198 |
199 |
235 | Copyright © 236 | 2015 237 | 238 | W3C® 239 | (MIT, 240 | ERCIM, 241 | Keio, Beihang). 242 | 243 | W3C liability, 244 | trademark and 245 | 246 | document use 247 | 248 | rules apply. 249 |
250 | 251 | 252 |255 | This specification defines a Media Source Extensions byte stream format specification based on MPEG-2 Transport Streams. 256 |
261 | This document is merely a W3C-internal document. It 262 | has no official standing of any kind and does not represent consensus of the W3C 263 | Membership. 264 |
265 | 266 | 267 | 268 | 269 |This specification defines segment formats for implementations that choose to support MPEG-2 Transport Streams 274 | (MPEG-2 TS) specified in ISO/IEC 13818-1.
It defines the MIME-type parameters used to signal codecs, and provides 275 | the necessary format specific definitions for initialization segments, media segments, and random access points required by 276 | the byte stream formats section of the Media Source Extensions spec. This document also defines extra behaviors and state that only apply to this 277 | byte stream format. 278 |The MIME-type/subtype pair of "video/MP2T", as specified in RFC 3551, must be used for byte streams that conform 283 | to this specification.
284 | 285 |This following parameters can be used in the MIME-type passed to isTypeSupported()
or addSourceBuffer()
.
MPEG-2 TS media and initialization segments must conform to the MPEG-2 TS Adaptive Profile (ISO/IEC 13818-1:2012 Amd. 2).
299 | 300 |The user agent must run the append error algorithm with the decode error parameter set to true if any of the following conditions are met:
301 |An MPEG-2 TS initialization segment consists of a single PAT and a single PMT.
311 |The user agent must run the append error algorithm with the decode error parameter set to true if any of the following conditions are met:
312 |The user agent must accept and ignore other SI, such as CAT, that are invariant for all subsequent media segments.
318 |The user agent must source attribute values for id, kind, label and language for AudioTrack
, VideoTrack
and
319 | TextTrack
objects as described for MPEG-2 Transport Streams in the in-band tracks spec [INBANDTRACKS].
The user agent must run the append error algorithm with the decode error parameter set to true if any of the following conditions are met:
326 |A random access point as defined in this specification corresponds to Elementary Stream Random Access Point as defined in 338 | ISO/IEC 13818-1.
339 |Timestamp rollovers and discontinuities must be handled by the UA. The UA's MPEG-2 TS implementation must maintain an internal offset
343 | variable, MPEG2TS_timestampOffset, to keep track of the offset that needs to be applied to timestamps
344 | that have rolled over or are part of a discontinuity. MPEG2TS_timestampOffset is initially set to 0 when the SourceBuffer
is
345 | created. This offset must be applied to the timestamps as part of the conversion process from MPEG-2 TS packets
346 | into coded frames for the coded frame processing algorithm. This results in the coded frame timestamps
347 | for a packet being computed by the following equations:
Coded Frame Presentation Timestamp = (MPEG-2 TS presentation timestamp) + MPEG2TS_timestampOffset 349 | Coded Frame Decode Timestamp = (MPEG-2 TS decode timestamp) + MPEG2TS_timestampOffset350 | 351 |
MPEG2TS_timestampOffset is updated in the following ways:
352 |abort()
is called, MPEG2TS_timestampOffset must be set to 0.timestampOffset
is successfully set, MPEG2TS_timestampOffset must be set to 0.
194 |
195 |
196 |
197 |
198 |
199 |
232 | Copyright © 233 | 2015 234 | 235 | W3C® 236 | (MIT, 237 | ERCIM, 238 | Keio, Beihang). 239 | 240 | W3C liability, 241 | trademark and 242 | 243 | document use 244 | 245 | rules apply. 246 |
247 | 248 | 249 |252 | This specification defines a Media Source Extensions byte stream format specification based on MPEG audio streams. 253 |
258 | This document is merely a W3C-internal document. It 259 | has no official standing of any kind and does not represent consensus of the W3C 260 | Membership. 261 |
262 | 263 | 264 | 265 | 266 |This specification defines segment formats for implementations that choose to support MPEG audio streams specified in ISO/IEC 11172-3:1993, ISO/IEC 13818-3:1998, and ISO/IEC 14496-3:2009.
271 |It defines the MIME-types 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. It also defines extra behaviors and state that only apply to this byte stream format.
272 |This section specifies the MIME-types that may be passed to isTypeSupported()
or addSourceBuffer()
for byte streams that conform to this specification.
The "codecs" MIME-type parameter must not be used with these MIME-types.
282 |The format of an MPEG Audio Frame depends on the MIME-type used.
287 |Since ID3v1, ID3v2 metadata frames, and Icecast headers are common in existing MPEG audio streams, implementations should gracefully handle such frames. Zero or more of these metadata frames are allowed to occur before, after, or between MPEG Audio Frames. Minimal implementations must accept, consume, and ignore these frames. More advanced implementations may choose to expose the metadata information via an inband TextTrack
or some other mechanism.
There is no normative spec for Icecast/SHOUTcast headers, just examples. For the purpose of this specification, an Icecast header is defined as beginning with the 4 character sequence "ICY "(U+0049 I, U+0043 C, U+0059 Y, U+0020 SPACE) and ending with a pair of carriage-return line-feed sequences (U+000D CARRIAGE RETURN, U+000A LINE FEED, U+000D CARRIAGE RETURN, U+000A LINE FEED).
300 |Icecast headers are allowed in the byte streams because some Icecast and SHOUTcast 301 | servers return a status line that looks like "ICY OK 200" instead of a standard HTTP status line. 302 | User-agent network stacks typically interpret this as an HTTP 0.9 response and include the 303 | header in the response body. Allowing these headers to appear provides a simple way to 304 | interoperate with these servers.
The MPEG audio byte stream is a combination of one or more MPEG Audio Frames and zero or more Metadata Frames.
311 |
193 |
194 |
195 |
196 |
197 |
198 |
228 | Copyright © 229 | 2015 230 | 231 | W3C® 232 | (MIT, 233 | ERCIM, 234 | Keio, Beihang). 235 | 236 | W3C liability, 237 | trademark and 238 | 239 | document use 240 | 241 | rules apply. 242 |
243 | 244 | 245 |248 | This specification defines a Media Source Extensions byte stream format specification based on the WebM container format. 249 |
254 | This document is merely a W3C-internal document. It 255 | has no official standing of any kind and does not represent consensus of the W3C 256 | Membership. 257 |
258 | 259 | 260 | 261 | 262 |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 267 | the necessary format specific definitions for initialization segments, media segments, and random access points required by 268 | the byte stream formats section of the Media Source Extensions spec.
269 |This section specifies the parameters that can be used in the MIME-type passed to isTypeSupported()
or addSourceBuffer()
.
Codec ID | 282 |Valid with "audio/webm" | 283 |Valid with "video/webm" | 284 |
---|---|---|
vorbis | 289 |true | 290 |true | 291 |
opus | 294 |true | 295 |true | 296 |
vp8 | 299 |false | 300 |true | 301 |
vp9 | 304 |false | 305 |true | 306 |
Examples of valid MIME-types with a codecs parameter.
314 |A WebM initialization segment must contain a subset of the elements at the start of a typical WebM file.
328 | 329 |The user agent must run the append error algorithm with the decode error parameter set to true if any of the following conditions are not met:
330 |The user agent must accept and ignore any elements other than an EBML Header or a Cluster that occur before, in between, or after the Segment Information and 337 | Tracks elements.
338 | 339 |The user agent must source attribute values for id, kind, label and language for AudioTrack
, VideoTrack
and
340 | TextTrack
objects as described for WebM in the in-band tracks spec [INBANDTRACKS].
A WebM media segment is a single Cluster element.
346 | 347 |The user agent uses the following rules when interpreting content in a Cluster:
348 |The user agent must run the append error algorithm with the decode error parameter set to true if any of the following conditions are not met:
356 |The user agent must accept and ignore Cues or Chapters elements that follow a Cluster element.
364 |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 369 | 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.
370 |217 | Copyright © 218 | 2014 219 | 220 | W3C® 221 | (MIT, 222 | ERCIM, 223 | Keio, Beihang), 224 | 225 | All Rights Reserved. 226 | 227 | W3C liability, 228 | trademark and 229 | 230 | document use 231 | 232 | rules apply. 233 |
234 | 235 | 236 |239 | This specification defines a Media Source Extensions byte stream format specification based on the ISO Base Media 240 | File Format. 241 |
246 | This document is merely a W3C-internal document. It 247 | has no official standing of any kind and does not represent consensus of the W3C 248 | Membership. 249 |
250 | 251 | 252 | 253 | 254 |This specification defines segment formats for implementations that choose to support the ISO Base Media File Format 259 | ISO/IEC 14496-12 (ISO BMFF).
It defines the MIME-type parameters used to signal codecs, and provides 260 | the necessary format specific definitions for initialization segments, media segments, and random access points required by 261 | the byte stream formats section of the Media Source Extensions spec. 262 |This section specifies the parameters that can be used in the MIME-type passed to isTypeSupported()
or addSourceBuffer()
.
MIME-types for this specification must conform to the rules outlined for "audio/mp4" and "video/mp4" in RFC 6381. 268 |
269 |An ISO BMFF initialization segment is defined in this specification as a single File Type Box (ftyp) followed by a single Movie Header Box (moov).
275 | 276 |The user agent must run the end of stream algorithm with the error parameter set to "decode"
if any of the following conditions are met:
The user agent must support setting the offset from media composition time to movie presentation time by handling an Edit Box (edts) containing a single Edit List Box 287 | (elst) that contains a single edit with media rate one. This edit may have a duration of 0 (indicating that it spans all subsequent media) or may have a non-zero duration 288 | (indicating the total duration of the movie including fragments).
289 | 290 |The user agent must support parameter sets (e.g., PPS/SPS) stored in the sample entry (as defined for avc1/avc2), and should support parameter 291 | sets stored inband in the samples themselves (as defined for avc3/avc4).
292 |For maximum content interoperability, user agents are strongly advised to support both inband and out-of-band storage of the SPS and PPS.
Valid top-level boxes such as pdin, free, and sidx are 295 | allowed to appear before the moov box. These boxes must be accepted and ignored by the user agent and are not 296 | considered part of the initialization segment in this specification.
297 |An ISO BMFF media segment is defined in this specification as one optional 302 | Segment Type Box (styp) followed by a single Movie Fragment Box 303 | (moof) followed by one or more Media Data Boxes (mdat). 304 | If the Segment Type Box is not present, the segment must conform to the brands listed in the 305 | File Type Box (ftyp) in the initialization segment.
306 |Valid top-level boxes defined in ISO/IEC 14496-12 other than ftyp, 307 | moov, styp, moof, and mdat are allowed to appear between the end of an 308 | initialization segment or media segment and before the beginning of a new media segment. 309 | These boxes must be accepted and ignored by the user agent and are not considered part of the media segment in this 310 | specification. 311 |
312 | 313 |The user agent must run the end of stream algorithm with the error parameter set to "decode"
if any of the following conditions are met:
A Movie Fragment Box uses movie-fragment relative addressing 331 | when the first Track Fragment Run(trun) box in each Track Fragment Box 332 | has the data-offset-present flag set and either of the following 333 | conditions are met:
334 |This implies that the base-data-offset-present flag 337 | is not set.
A random access point as defined in this specification corresponds to a Stream Access Point of type 1 or 2 as defined in Annex I of ISO/IEC 14496-12.
346 |Version | 359 |Comment | 360 |
---|---|
20 June 2014 | 365 |
366 |
|
370 |
03 March 2014 | 373 |
374 |
|
379 |
02 December 2013 | 382 |Initial CR version. | 383 |
The working group maintains a list of all bug reports that the editors have not yet tried to address; there may also be open bugs in the previous bug tracker.
144 |Implementors should be aware that this specification is not stable. Implementors who are not taking part in the discussions are likely to find the specification changing out from under them in incompatible ways. Vendors interested in implementing this specification before it eventually reaches the Candidate Recommendation stage should join the mailing list mentioned below and take part in the discussions.
145 |This specification defines segment formats for implementations that choose to support the ISO Base Media File Format 150 | [[!ISOBMFF]].
It defines the MIME-type parameters used to signal codecs, and provides 151 | the necessary format specific definitions for , , and required by 152 | the of the Media Source Extensions spec. 153 |This section specifies the parameters that can be used in the MIME-type passed to or .
158 |MIME-types for this specification MUST conform to the rules outlined for "audio/mp4" and "video/mp4" in RFC 6381. 159 |
160 |An ISO BMFF is defined in this specification as a single File Type Box (ftyp) followed by a single Movie Box (moov).
166 | 167 |The user agent MUST run the if any of the following conditions are met:
168 |The user agent MUST support setting the offset from media composition time to movie presentation time by handling an Edit Box (edts) containing a single Edit List Box 178 | (elst) that contains a single edit with media rate one. This edit MAY have a duration of 0 (indicating that it spans all subsequent media) or MAY have a non-zero duration 179 | (indicating the total duration of the movie including fragments).
180 | 181 |The user agent MUST support codec configurations stored out-of-band in the sample entry, and for codecs which allow codec configurations stored inband in the samples themselves, the user agent SHOULD support codec configurations stored inband.
182 |For example, for codecs which include SPS and PPS parameter sets, for maximum content interoperability, user agents are strongly advised to support both inband (e.g., as defined for avc3/avc4) and out-of-band (e.g., as defined for avc1/2) storage of the SPS and PPS.
183 | 184 |Valid top-level boxes such as pdin, free, and sidx are 185 | allowed to appear before the moov box. These boxes MUST be accepted and ignored by the user agent and are not 186 | considered part of the in this specification.
187 | 188 |The user agent MUST source attribute values for id, kind, label and language for , and 189 | objects as described for MPEG-4 ISOBMFF in the in-band tracks spec [[INBANDTRACKS]].
190 |An ISO BMFF is defined in this specification as one optional 195 | Segment Type Box (styp) followed by a single Movie Fragment Box 196 | (moof) followed by one or more Media Data Boxes (mdat). 197 | If the Segment Type Box is not present, the segment MUST conform to the brands listed in the 198 | File Type Box (ftyp) in the .
199 |Valid top-level boxes defined in other than ftyp, 200 | moov, styp, moof, and mdat are allowed to appear between the end of an 201 | or and before the beginning of a new . 202 | These boxes MUST be accepted and ignored by the user agent and are not considered part of the in this 203 | specification. 204 |
205 | 206 |The user agent MUST run the if any of the following conditions are met:
207 |A Movie Fragment Box uses movie-fragment relative addressing 224 | when the first Track Fragment Run(trun) box in each Track Fragment Box 225 | has the data-offset-present flag set and either of the following 226 | conditions are met:
227 |This implies that the base-data-offset-present flag 230 | is not set.
231 |A as defined in this specification corresponds to a Stream Access Point of type 1 or 2 as defined in Annex I of .
239 |The working group maintains a list of all bug reports that the editors have not yet tried to address; there may also be open bugs in the previous bug tracker.
136 |Implementors should be aware that this specification is not stable. Implementors who are not taking part in the discussions are likely to find the specification changing out from under them in incompatible ways. Vendors interested in implementing this specification before it eventually reaches the Candidate Recommendation stage should join the mailing list mentioned below and take part in the discussions.
137 |This specification defines segment formats for implementations that choose to support MPEG-2 Transport Streams 142 | [[!MPEG2TS]].
It defines the MIME-type parameters used to signal codecs, and provides 143 | the necessary format specific definitions for , , and required by 144 | the of the Media Source Extensions spec. This document also defines extra behaviors and state that only apply to this 145 | byte stream format. 146 |The MIME-type/subtype pair of "video/MP2T", as specified in [[!RFC3551]], MUST be used for byte streams that conform 151 | to this specification.
152 | 153 |This following parameters can be used in the MIME-type passed to or .
154 |MPEG-2 TS media and initialization segments MUST conform to the MPEG-2 TS Adaptive Profile (ISO/IEC 13818-1:2012 Amd. 2).
166 | 167 |The user agent MUST run the if any of the following conditions are met:
168 |An MPEG-2 TS initialization segment consists of a single PAT and a single PMT.
178 |The user agent MUST run the if any of the following conditions are met:
179 | 183 | 184 |The user agent MUST accept and ignore other SI, such as CAT, that are invariant for all subsequent media segments.
185 |The user agent MUST source attribute values for id, kind, label and language for , and 186 | objects as described for MPEG-2 Transport Streams in the in-band tracks spec [[INBANDTRACKS]].
187 |The user agent MUST run the if any of the following conditions are met:
193 |A random access point as defined in this specification corresponds to Elementary Stream Random Access Point as defined in 205 | [[!MPEG2TS]].
206 |Timestamp rollovers and discontinuities MUST be handled by the UA. The UA's MPEG-2 TS implementation MUST maintain an internal offset 210 | variable, MPEG2TS_timestampOffset, to keep track of the offset that needs to be applied to timestamps 211 | that have rolled over or are part of a discontinuity. MPEG2TS_timestampOffset is initially set to 0 when the SourceBuffer is 212 | created. This offset MUST be applied to the timestamps as part of the conversion process from MPEG-2 TS packets 213 | into for the . This results in the coded frame timestamps 214 | for a packet being computed by the following equations:
215 |216 | Coded Frame Presentation Timestamp = (MPEG-2 TS presentation timestamp) + MPEG2TS_timestampOffset 217 | Coded Frame Decode Timestamp = (MPEG-2 TS decode timestamp) + MPEG2TS_timestampOffset218 | 219 |
is updated in the following ways:
220 |211 | Copyright © 212 | 2014 213 | 214 | W3C® 215 | (MIT, 216 | ERCIM, 217 | Keio, Beihang), 218 | 219 | All Rights Reserved. 220 | 221 | W3C liability, 222 | trademark and 223 | 224 | document use 225 | 226 | rules apply. 227 |
228 | 229 | 230 |233 | This specification defines a Media Source Extensions byte stream format specification based on MPEG audio streams. 234 |
239 | This document is merely a W3C-internal document. It 240 | has no official standing of any kind and does not represent consensus of the W3C 241 | Membership. 242 |
243 | 244 | 245 | 246 | 247 |This specification defines segment formats for implementations that choose to support MPEG audio streams specified in ISO/IEC 11172-3:1993, ISO/IEC 13818-3:1998, and ISO/IEC 14496-3:2009.
252 |It defines the MIME-types 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. It also defines extra behaviors and state that only apply to this byte stream format.
253 |This section specifies the MIME-types that may be passed to isTypeSupported()
or addSourceBuffer()
for byte streams that conform to this specification.
The "codecs" MIME-type parameter must not be used with these MIME-types.
263 |The format of an MPEG Audio Frame depends on the MIME-type used.
268 |Since ID3v1, ID3v2 metadata frames, and Icecast headers are common in existing MPEG audio streams, implementations should gracefully handle such frames. Zero or more of these metadata frames are allowed to occur before, after, or between MPEG Audio Frames. Minimal implementations must accept, consume, and ignore these frames. More advanced implementations may choose to expose the metadata information via an inband TextTrack
or some other mechanism.
There is no normative spec for Icecast/SHOUTcast headers, just examples. For the purpose of this specification, an Icecast header is defined as beginning with the 4 character sequence "ICY "(U+0049 I, U+0043 C, U+0059 Y, U+0020 SPACE) and ending with a pair of carriage-return line-feed sequences (U+000D CARRIAGE RETURN, U+000A LINE FEED, U+000D CARRIAGE RETURN, U+000A LINE FEED).
281 |Icecast headers are allowed in the byte streams because some Icecast and SHOUTcast 282 | servers return a status line that looks like "ICY OK 200" instead of a standard HTTP status line. 283 | User-agent network stacks typically interpret this as an HTTP 0.9 response and include the 284 | header in the response body. Allowing these headers to appear provides a simple way to 285 | interoperate with these servers.
The MPEG audio byte stream is a combination of one or more MPEG Audio Frames and zero or more Metadata Frames.
292 |The working group maintains a list of all bug reports that the editors have not yet tried to address; there may also be open bugs in the previous bug tracker.
126 |Implementors should be aware that this specification is not stable. Implementors who are not taking part in the discussions are likely to find the specification changing out from under them in incompatible ways. Vendors interested in implementing this specification before it eventually reaches the Candidate Recommendation stage should join the mailing list mentioned below and take part in the discussions.
127 |This specification defines segment formats for implementations that choose to support MPEG audio streams specified in , , and .
132 |It defines the used to signal codecs, and provides the necessary format specific definitions for , , and required by the of the Media Source Extensions spec. It also defines extra behaviors and state that only apply to this byte stream format.
133 |This section specifies the MIME-types that may be passed to or for byte streams that conform to this specification.
138 |The "codecs" MIME-type parameter MUST NOT be used with these MIME-types.
143 |The format of an MPEG Audio Frame depends on the used.
148 |Since , metadata frames, and are common in existing MPEG audio streams, implementations SHOULD gracefully handle such frames. Zero or more of these metadata frames are allowed to occur before, after, or between . Minimal implementations MUST accept, consume, and ignore these frames. More advanced implementations MAY choose to expose the metadata information via an inband or some other mechanism.
157 | 158 |There is no normative spec for Icecast/SHOUTcast headers, just examples. For the purpose of this specification, an Icecast header is defined as beginning with the 4 character sequence "ICY "(U+0049 I, U+0043 C, U+0059 Y, U+0020 SPACE) and ending with a pair of carriage-return line-feed sequences (U+000D CARRIAGE RETURN, U+000A LINE FEED, U+000D CARRIAGE RETURN, U+000A LINE FEED).
161 |Icecast headers are allowed in the byte streams because some Icecast and SHOUTcast 162 | servers return a status line that looks like "ICY OK 200" instead of a standard HTTP status line. 163 | User-agent network stacks typically interpret this as an HTTP 0.9 response and include the 164 | header in the response body. Allowing these headers to appear provides a simple way to 165 | interoperate with these servers.
166 |The MPEG audio byte stream is a combination of one or more and zero or more .
172 | 177 |This is the errata page for the Media Source Extensions™ specification.
14 | 15 |No erratum yet.
16 | 17 | 18 | -------------------------------------------------------------------------------- /mse.css: -------------------------------------------------------------------------------- 1 | .nonnormative { color: green; margin: 2em 0 2em 0em; padding: 0.5em 1em; border: none; background: #DDFFDD; } 2 | .nonnormative h3 { color: inherit; background: inherit; } 3 | .nonnormative:before { display: table; margin: -1em -0.5em -0.5em auto; width: auto; content: 'This section is non-normative.'; color: black; font-style: italic; border: solid 2px; background: white; padding: 0 0.25em; } 4 | 5 | table.old-table { border-collapse: collapse; border-style: hidden hidden none hidden; } 6 | table.old-table thead, table tbody { border-bottom: solid; } 7 | table.old-table tbody th:first-child { border-left: solid; } 8 | table.old-table tbody th { text-align: left; } 9 | table.old-table td, table th { border-left: solid; border-right: solid; border-bottom: solid thin; vertical-align: top; padding: 0.2em; } 10 | 11 | dl.switch { padding-left: 2em; } 12 | dl.switch > dt { text-indent: -1.5em; } 13 | dl.switch > dt:before { content: '\21AA'; padding: 0 0.5em 0 0; display: inline-block; width: 1em; text-align: right; line-height: 0.5em; } 14 | 15 | p + * > li, dd li { margin: 1em 0; } 16 | 17 | @media screen { code :link, code :visited { color: inherit; } } 18 | 19 | /* fix bug entry form styling */ 20 | body > form { padding: 4px; border: 1px solid red; background-color: white; } 21 | 22 | #bug-assist-form { position: fixed; width: 10em; top: 5em; right: 1em; font-family: Tahoma, sans-serif; font-size: 11px; opacity: 0.8; text-align: right; } 23 | -------------------------------------------------------------------------------- /pipeline_model.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 630 | -------------------------------------------------------------------------------- /pipeline_model_description.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 |The flowchart reads from a top down perspective. At the top is a container 20 | marked MediaSource, with 3 arrows flowing down to containers each marked 21 | SourceBuffer. (Not indicated, but for sake of clarity in this description 22 | referred to here-after as SourceBuffer 1, shown with a blue background; 23 | SourceBuffer 2, shown with a mauve background; and SourceBuffer 3, shown 24 | with a rose background; as described from Left to Right).
25 | 26 | 27 |Below these 3 SourceBuffer containers is a dashed line, with an indication 28 | that the top half (MediaSource plus the 3 SourceBuffer containers) are taken 29 | from the Media Source API, while the details to follow are taken from the 30 | HTMLMediaElement.
31 | 32 | 33 | 34 | 35 |
Flowing down from SourceBuffer 1 is a blue triangle with 3 arrows pointing 39 | to 3 process indications, each labeled Track Buffer.
40 | 41 |The first Track Buffer from the left then flows to a red box labeled Video 42 | Decoder, which then flows to an indicator (three dots stacked vertically) 43 | labeled Video Tag Display Region.
44 | 45 |The second Track Buffer flows to a green box labeled Audio Decoder, which 46 | then follows to an indicator of an open switch, which then continues to an 47 | indicator (green circle with an X) labeled Audio Device.
48 | 49 |The third Track Buffer also flows to a green box labeled Video Decoder, 50 | which also flows to a switch, this time however indicated closed, which then 51 | also continues to the same indicator (green circle with an X) labeled Audio 52 | Device as the second Track Buffer.
53 | 54 | 55 | 56 | 57 |Flowing down from SourceBuffer 2 is a mauve triangle with an arrow flowing 61 | to a red box labeled Video Decoder, which then flows to the same Video Tag 62 | Display Region previously mentioned in SourceBuffer 1.
63 | 64 | 65 |Flowing down from SourceBuffer 3 is a rose triangle with an arrow flowing to 69 | a green box labeled Audio Decoder, which then flows through a closed switch, 70 | which then also continues to the same indicator (green circle with an X) 71 | labeled Audio Device previously mentioned in SourceBuffer 1
72 | 73 | 74 |With thanks to J. Foliot, Deque Systems
75 | 76 |The working group maintains a list of all bug reports that the editors have not yet tried to address; there may also be open bugs in the previous bug tracker.
150 |Implementors should be aware that this specification is not stable. Implementors who are not taking part in the discussions are likely to find the specification changing out from under them in incompatible ways. Vendors interested in implementing this specification before it eventually reaches the Candidate Recommendation stage should join the mailing list mentioned below and take part in the discussions.
151 |This specification describes a byte stream format based on the WebM container format [[!WEBM]]. It defines the MIME-type parameters used to signal codecs, and provides 156 | the necessary format specific definitions for , , and required by 157 | the of the Media Source Extensions spec.
158 |This section specifies the parameters that can be used in the MIME-type passed to or .
163 |Codec ID | 171 |Valid with "audio/webm" | 172 |Valid with "video/webm" | 173 |
---|---|---|
vorbis | 178 |true | 179 |true | 180 |
opus | 183 |true | 184 |true | 185 |
vp8 | 188 |false | 189 |true | 190 |
vp9 | 193 |false | 194 |true | 195 |
vp09... as described in the VP Codec ISO Media File Format Binding document[[VP09CODECSPARAMETERSTRING]] | 198 |false | 199 |true | 200 |
Examples of valid MIME-types with a codecs parameter.
211 |A WebM MUST contain a subset of the elements at the start of a typical WebM file.
227 | 228 |The user agent MUST run the if any of the following conditions are not met:
229 |The user agent MUST accept and ignore any elements other than an or a that occur before, in between, or after the and 236 | elements.
237 | 238 |The user agent MUST source attribute values for id, kind, label and language for , and 239 | objects as described for WebM in the in-band tracks spec [[INBANDTRACKS]].
240 |The user agent uses the following rules when interpreting content in a :
247 |The user agent MUST run the if any of the following conditions are not met:
255 |The user agent MUST accept and ignore or elements that follow a element.
263 |Either a SimpleBlock element with its Keyframe flag set, or a BlockGroup element having no ReferenceBlock elements, signals the location of a for that track. The order of multiplexed blocks within a MUST conform to the .
268 |