This removes reliance on MediaKeys.isTypeSupported and instead uses the
supportedConfigurations parameter of requestMediaKeySystemAccess.
A lot of refactoring went into this effort, particularly around
StreamVideoSource, StreamSetInfo, and StreamInfoProcessor.
Closes#2, b/19354928.
Change-Id: Ibf81da909b8207b5babaec5ef0422dd1293d130d
* Stretch/compress segments within a SegmentTimeline to align them
to the beginning of the next segment.
This does not allow playback of content with actual gaps in it, but
allows MPDs with inaccurate SegmentTimelines to be used.
Closes#24, b/19144876
Change-Id: I183935db23fe26e1d6295e099b201a6af487d53b
This adds support for EME key statuses, which are translated into
Player error events. It also listens for error events on the video
tag, which are also translated into Player error events.
This also updates the prefixed EME polyfill to simulate key statuses
for prefixed EME.
Applications can now detect HDCP failures and message appropriately.
Native key status support was not added to Chrome until Chrome 42.
The prefixed EME events to detect HDCP failures work in Chrome 39 and
Chrome 42, but are broken in Chrome 40 & 41.
Closes#14, b/19244591
Change-Id: I112c489bda63360d2bedca83f190c639559641ea
* Revert 5c7fca90b6, which intended
to allow startNumber to be 0, and maintain the previous behavior,
which requires startNumber to begin at 1 (this appears to be in-line
with the MPD spec).
* Correctly compute the $Time$ placeholder.
* Rename firstSegmentNumber to startNumber to clarify code.
Closes#10
Change-Id: I9b565edc9e23b9ad7c6bc62829d6b0ab565008a4
* Adjust SourceBuffer timestamps forward by the Period's
start time and backwards by the Representation's
presentationTimeOffset.
* Incorporate the start time of a Representation's first
segment in the calculation of a Period's duration.
* Seek to the latest start time before starting playback.
Further adjustments will be required to support live playback.
Closes#17, b/19130302
Change-Id: Ia9fe6d8bbe5a69488130de2d8b146ce54dfff50e
Includes unit tests and covers zero-sized PSSHs, truncated PSSHs, and
various orderings of both v0 and v1 PSSHs.
Change-Id: I79ecc9475d483be610c003b57e831954a1c9800b
AdaptationSets are sorted by language (audio-only), then by those with
the "main" role. Main sets are preferred when there are multiple to
choose from.
Closes#20, b/19214703.
Change-Id: I4fdd601c0bd7c7d29801084199123311ab9dbec3
Checks to see if a seek is within the buffered zone or not.
Clears the SourceBuffer if seeking outside the buffered zone.
This allows the efficient indexed lookup for inserted segments to still
be used while streaming, optimizes buffered seeks, keeps the playback
timeline sane in spite of the browser's eviction strategy, and obviates
the need for an earlier fix for some other MSE weirdness.
Closes#15.
Change-Id: I0226ebb679fab6739d3d0cc071e22f434983c9d2
Most of these StringUtils were either operating on Uint8Arrays directly
or using strings to move around Uint8Array data anyhow.
Change-Id: I71efe6ede34210ca721d46acd53452344efff5bb
* Move internal non-DASH specific code into the 'media' namespace.
* Remove DASH references from generic stream code.
The documentation is not changed as a follow-up patch will factor out
DASH functionality from StreamVideoSource back into a new
DashVideoSource class.
b/18903621
Change-Id: I78d6e4f2824d4983619f17872828d95655fcfe50
* Create generic stream description classes to represent
Representations, AdaptationSets, and Periods.
* Move generic stream selection logic out of MpdProcessor and
into StreamInfoProcessor.
* Refactor DashVideoSource and DashStream to use the generic
stream description classes.
A follow-up patch is required to re-organize files and namespaces.
b/18903621
b/18948677
Change-Id: I8bbb87ebf0242b31541199d0d1d3c40767c93a29
This gives our version numbering more granularity than just release
versions. Uncompiled builds will show a "-debug" tag, and builds with
local changes will show a "-dirty" tag.
This also adds the version number to the test app UI.
Change-Id: Ia333c89de81df1e8faacd97a5f70405da0364bf7