* Make function order in mpd_processor.js match function
dependencies.
* Make a two line parameter list into a one line parameter list.
Actual code and comments are not changed.
Change-Id: I586b2552601a3c36c5cd1711f4589447213462a4
* Rename SegmentIndex functions to shorter names.
* Add first() and last() functions for convenience.
* Throw exceptions for out of range errors.
* Handle more corner-cases in merge().
* Add more unit tests.
Change-Id: If875cd766e7091504c028413694326fcdf2aae5b
This should just be a normal bubbling event. There was really no
need to re-dispatch it in the first place.
Change-Id: I1bb5d7bd9d6dfd4cb5db642a3ca3a849f1a1673e
* Compute a seek range in DashVideoSource and update the
seek range for live streams.
* Fire an event when the seek range changes.
* Refactor stream creation and startup in
StreamVideoSource: streams are only created and started once all
streams are available.
* Correct 5b659acf9a, which set the video's
current time after the streams have been started. The video's
current time should be set before the streams start so that the
correct segment ranges are buffered. Fix buffering issue by
ensuring the streams do not have disjoint timelines before
starting.
Issue #21
Change-Id: Ib8f4924b09bfdf0e3b61e25273e16fd313feaf24
FakeEvents, when dispatched twice, have their targets overwritten.
For this to work, the target property needs to be set to writable.
Set all synthetic properties to writable to avoid exceptions.
Change-Id: I91556501bb857ddda69872d87d368cd3aea266e4
This introduces a new heuristic to determine when licenses have
been stored.
Also moves license acquisition before storage of content, so that
failure is quicker on platforms which don't support offline licenses.
Issue #23.
Change-Id: I683690077e134e40285727e6586b0f265f36e7fb
We used to wait until 8 seconds after the last adaptation began.
Now we wait until 30 seconds after the last adaptation completed.
Change-Id: Ibb673d1a2ca45d403a77a037fa3eeea9698d3e31
This assertion did not add much value, and it sometimes triggers a
test failure. Since prefixed EME does not have actual session
management, it's entirely possible for a stray message to come in
for a session we've already destroyed in the polyfill. Rather than
assert, just ignore it.
Change-Id: I4779d3f36a25bc21ade95c4ea3f25ad1f8a96e7b
This re-fixes an old bug in a new way. The old bug was reintroduced
by the fix for github issue #15.
This addresses the problem as an MSE implementaiton bug, and should
be more robust than the last fix.
Change-Id: I836801da2d72033dfa8c71a5587a2d836c534034
If fullscreenElement were defined not on document, but in its
prototype chain, using hasOwnProperty would fail to detect
fullscreenElement. So use the "in" operator to avoid making
assumptions about implementation details for this property.
Change-Id: I27aa4b0091f7534525f71932e73d18293c848303
This fixes FakeEventTarget and FakeEvent tests for Chrome 43+.
Also improves compatibility with strict mode.
Change-Id: I5ccca6798ff8a5f5b2fa98d6b9e8446378b7fab2
* After updating a manifest restart any streams that failed
to initially start.
* Seek to the stream start time only after the streams have been
initialized, seeking before can cause lock-ups with MSE.
* Rename 'bestStartTime' to 'currentSegmentStartTime'.
Issue #21
Change-Id: Ibad91fe2d5171196e93f20961008cdd25ecc437e
If a stream insertion didn't complete successfully, it was possible an error
would occur during the next stream insertion due to a key (streamId) conflict.
Updated to always take the max next stream id from the indexStore/contentStore
and to try to delete partially inserted streams.
Change-Id: I85c379a6ef17853da28ae873c448873006b1dce4
* The segmentNumber member in SegmentReference is used as an ID,
so rename it and update the doc string.
* Tidy up SegmentIndex unit tests.
Change-Id: I888b8cbfd6a198bab09f6ab846cbdbf70cfcaa5a
For live streams, update the manifest at least every
@minimumUpdatePeriod seconds, but always before the stream exhausts the
list of SegmentReferences.
Issue #21
Change-Id: I71cd75d86ffd342f812621d7d60f4ede4851db83
* Construct the initial SegmentIndex for a live stream such that it
includes at least @timeShiftBufferDepth seconds of content before
the "live-edge".
* Use segment numbers relative to @startNumber instead of relative
to the start of the Period in SegmentReference to handle MPDs
with partial segment information.
* Start live streams near the "live-edge", a.k.a., "best start time",
and start static streams at the latest start time.
Issue #21
Change-Id: I3c553a1b7120a59c68f19cdc85f412f31972c1b8
The Stream should not rely on the segment index for timestamps, since
this can be inaccurate, especially for live content.
Closes#44
Change-Id: Ie7202e04b6a96c3758541680ceed781bf6bd2ab3
* Write an initial set of unit tests for
StreamVideoSource.update().
* Correctly handle new manifests that omit periods, stream sets,
and streams that existed in the original manifest.
* Make StreamVideoSource.update() synchronous.
* Disallow merging SIDX based SegmentIndexes.
Issue #21
Change-Id: Id2e0b8cf56dd4b878b654732b7a088422163f418
* Expand SegmentTemplates directly to StreamInfos instead of using
intermediate SegmentBases and SegmentLists.
* Remove "fake" attributes from SegmentBase and SegmentUrl.
* Simplify Period duration derivation.
* Add additional unit tests.
Change-Id: I203e269bd9dfb1fb1cc4ca48be29043c1ee4007b
Some seek-related tests have been flaky lately. This reduces some of
the test flake, and speeds up a great number of tests.
This shaves as much as 45 seconds or 30% off of the run time of the
integration tests.
Change-Id: Ic8eab5037808e792344f43793b099183b405c6e3
If a postprocessor wants to impose restrictions, it will now have to
talk directly to the Player to do so.
Also closes#41.
Change-Id: Ic5acf63c2572bb440cc53026561b9e98ffb752ec
This hack seems to work around a piece of broken content, but disables
audio on some legitimate content.
Change-Id: Ia559391ac4446bda2392feb00e3285834792c026
* Set SourceBuffer.timestampOffset to StreamInfo.timestampOffset
directly.
* Compute StreamInfo.timestampOffset in MpdProcessor.
Change-Id: Iea5621bc29df3de29d378e58720d6f71452274cd
The clock will be synced, when possible, to the server hosting the
MPD. The synced clock will only be used in places where accurate
time matters, such as in loggable player stats and in live streaming.
Relates to #21
Change-Id: Id9da1cf23a781f2ce07a46e0936695d512a65133