Commit Graph

500 Commits

Author SHA1 Message Date
Joey Parrish 89d8b7e94a Add support for raw values in Promise.all and Promise.race
Change-Id: Ifce7a22bc8f17f026c85bd90de2feced7f549b83
2015-10-26 11:39:05 -07:00
Joey Parrish 83f7ad8d3a Merge pull request #218 from leandromoreira/patch-1
Fixes #217 broken link
2015-10-24 17:46:18 -07:00
Leandro Moreira 31e1623104 Fixes #217 broken link 2015-10-24 10:57:13 -02:00
Joey Parrish d52298c3fe Set Promise test exit code based on failure count
Previously, the exit was always zero, which is not very useful as part
of a continuous integration system.

Change-Id: I3fd5e9061f605950c48240419c2a093c74005144
2015-10-22 10:49:10 -07:00
Joey Parrish c55978cc79 Add a Promise polyfill
This will help with porting to IE11.  Chrome, Firefox, Safari, and
Edge all have native Promises.

This polyfill does not support thenables because Shaka does not use
them.  Other than tests related to thenables, this polyfill passes
the A+ test suite.

It is also worth noting that this polyfill is incompatible with
native Promises, so it should not be used to replace a native
implementation or mixed with browser APIs that may use a native
implementation internally.

To safely test in Chrome, force prefixed EME (to avoid native
Promises), set window.Promise to null, then load some content in
the test app.  If using a verison of Chrome after prefixed EME
was dropped, use unencrypted content.

To run the A+ test suite, compile the library, install nodejs and the
module 'promises-aplus-tests', then run ./test_promise_polyfill.js.

Inspired by pull #176

Change-Id: I0d25049f162ff7f3b57bbc795403fcdedf927262
2015-10-21 11:12:18 -07:00
Natalie Harris 5eb9310d3a Chromecast demo. Issue #117.
Change-Id: Iae1f129d9f02ff47f09d9aacd60fb9a80ff8459c
2015-10-21 16:55:40 +00:00
Joey Parrish 93bcf28e41 Fix mixed content URLs in integration tests
Change-Id: I9b50b581b341302fbeaf127c411e16d9927facf2
2015-10-20 16:41:24 -07:00
Joey Parrish 7b78b9747d Drop unused member in ContainerSegmentIndexSource
Change-Id: I7d95493e56f5efe881c801fff3493269ce766e80
2015-10-20 20:02:12 +00:00
Joey Parrish ff1dcc2820 Refine MediaKeys polyfill error type
Inspired by code in pull #176

Change-Id: I2e29310c8a3583ed208d7bd1ae2e747a92ddf480
2015-10-20 12:42:58 -07:00
Jacob Trimble 5637962073 Offline now doesn't use data URI for init data.
Also now uses the same ContentDatabaseReader for offline segment
requests.

Change-Id: I9cebc90b46ca9067467a8a343d48b264abc7cf26
2015-10-19 23:10:22 +00:00
Jacob Trimble d84428b42f Removed 1.6.0 deprecated functionality.
Closes #203

Change-Id: I52f72030078c2bf69f1da33fae035664ca50daca
2015-10-15 17:14:11 +00:00
Joey Parrish 3a552b808f Remove Uint8ArrayUtils.key
These keys cannot always be used as keys, for example on IE11 where
very large init datas are found in PlayReady content.  Since there
should not be a large number of unique init datas, a linear
suppression pass and a quadratic removeDuplicates should not be a
problem in practice.

Related to pull #176

Change-Id: I9dd9b5e45422544c86dd95686766625a0b336963
2015-10-14 18:09:07 +00:00
Jacob Trimble 1e16366eb3 Update configuration documentation.
Change-Id: I65df78f278e5a02c81aabb03fe3c0b81ff3ed605
2015-10-13 14:49:14 -07:00
Jacob Trimble ed33ef958f Uses correct buffering goal when re-buffering.
Closes #190

Change-Id: Iee663056ce221e8388b9e6bd7b78f587c8ed0191
2015-10-13 11:32:05 -07:00
Jacob Trimble 62adcd40c1 Always apply timestamp correction to OPT.
Closes #200

Change-Id: I821d7a8336cc66593665dbc2ad794adc3fb55918
2015-10-13 18:23:34 +00:00
Joey Parrish 151936c6be Ungroup Angel One audio
Change-Id: Ia89e90b5ac9cfb94c4664be2996ba000615b6014
2015-10-13 18:10:47 +00:00
Jacob Trimble f346ece22c Improve live end-of-stream behavior.
* Supports live streams of a fixed length.
* Live streams that stop now correctly end the video.
* Only uses local MPD when @availabilityStartTime is in the future.
* Added configuration option liveStreamEndTimeout.

A live stream is considered "ended" when the play-head moves past
the last segment for liveStreamEndTimeout amount of time.  This allows
the MPD to be updated with new segments.

Closes #139
Closes #140
Closes #145
Issue #172

Change-Id: I0675203931f35ca3e0dee60a87c54ba74cbdbaea
2015-10-13 18:00:01 +00:00
Joey Parrish 9befe6240b Add one more bugfix to 1.5.1
Change-Id: I0ba3dce729513f2aa16e5102171eeb57676c06ef
2015-10-07 22:40:32 +00:00
Jacob Trimble ee872017ed Added 'app' error type.
Change-Id: I1c56d875ec92291af408a10e01e7d2c8fae24749
2015-10-07 22:28:24 +00:00
Jacob Trimble f8d0028b1a Clock synchronizing no longer allows caching.
Closes #191

Change-Id: I66086ad247a0deec34756ae70ea4e3ddfc5fd264
2015-10-07 22:27:45 +00:00
Joey Parrish 14049b905d Update changelog for v1.5.1
Change-Id: I54d3f1315efc2ff85486eca8ab946398205cf211
2015-10-07 22:12:21 +00:00
Timothy Drews 6bbdad3156 Improve internal docs for VideoSource and Stream.
* Document timestamp correction better.
* Add additional API details to Stream.
* Tidy-up and make comments/docs more consistent.

Change-Id: I41d873967a930634fa48c83fe65b6e9cf512d782
2015-10-07 21:26:13 +00:00
Joey Parrish ef1098c416 Avoid mixed content on the poster
Change-Id: I4a933094cb274d3f0c6a858a5b72eb84f3dc9f20
2015-10-07 17:55:43 +00:00
Joey Parrish e14612989d Fix cross-origin subtitles, as in Angel One
Change-Id: Ia30fce895725504bf64f5d35bfab448f0ad65ad8
2015-10-07 17:33:28 +00:00
Joey Parrish bb0e21aaa4 Fix typo
Change-Id: I26c05e0fa9aa093156fb1608f67128d9b1855ff6
2015-10-06 16:57:24 -07:00
Joey Parrish b197354a94 Pull the poster from appspot.
Change-Id: I4794733960cd6dd28c32ab87258af19bb90c2997
2015-10-06 13:11:02 -07:00
Timothy Drews fb9c419e1b Make ST + @duration test use explicit values.
Change-Id: Ibd2a9327898ef798b10c617507706a4b4780daa9
2015-10-05 09:31:12 -07:00
Jacob Trimble 5dd6a513ac Does not clamp seek start with buffered live content.
Closes #141

Change-Id: I9b6b574306435c7c0087d72c9da7e88711a840ed
2015-09-30 11:18:41 -07:00
Jacob Trimble e4603b1c4a Re-Process MPD when availabilityStartTime reached.
When the availabilityStartTime is in the future, the
StreamVideoSource will re-process the local MPD once the
availabilityStartTime passes.

Closes #172

Change-Id: I1432ae06fbff6c4978ed93bc51263f7cac37e136
2015-09-29 22:39:19 +00:00
Jacob Trimble be008764a5 Reorganize MpdProcessor tests.
* Renamed mpd_* files to mpd_parser_* where applicable.
* Gave the mpd test groups more descriptive names.
* Split mpd_processor_spec into several files.
* Cleaned up the createStreamInfoFromSegmentTemplate_ tests.

Closes #189

Change-Id: I71daa1600e944b53937030ff87b53a3dbca3948e
2015-09-28 16:34:49 -07:00
Jacob Trimble 1f88c9dae1 Reorganize integration tests.
* Split player_integration into several files.
* Moved some helper methods from player_integration to
  integration_util.

Closes #188

Change-Id: I14cb2eda8375fc24ef0419e7993027b90e881d5b
2015-09-28 23:09:51 +00:00
Timothy Drews 9dcbda7234 Use Period.duration for ST + @duration.
For static content that uses SegmentTemplate + @duration, compress
the last SegmentReference so that it does not go beyond the
Period's duration.

Issue #173
Closes #187

Change-Id: Ifb9404ddfe267915541c035a5d6286f63f7bc032
2015-09-25 22:30:18 +00:00
Jacob Trimble f750207444 Improve error reporting with OfflineVideoSource.
* License errors in store() are reported as a failed promise.
* store() cleans up after errors.
* Added argument to deleteGroup to ignore session errors.

Change-Id: I8030d89a7f99cabb6ecb7840a854a0452a2f2ef2
2015-09-25 14:03:37 -07:00
Jacob Trimble 9b50f2ad94 Deleting offline content now deletes persistent session.
Closes #171

Change-Id: Ia0ff2c9892f53c2ceeddb2b589e2e2c886aea54a
2015-09-24 22:05:01 +00:00
Timothy Drews b962c81e82 Improve key status error reporting.
* Give key status errors type 'drm' for both DASH and HTTP.
* Include the EME key status code for HTTP for testing
  purposes.
* Make error reporting between DASH and HTTP more consistent.

Change-Id: I8c42dbf08257cc88c6e089d817f55f0caa575473
2015-09-24 20:46:57 +00:00
Timothy Drews 80961de8f2 Reduce preferred language test flakiness.
Wait for playback to begin after each load(), not just the
first load().

Change-Id: I790270d5054ba1c1878c65f1a60e1fa0655e4a3c
2015-09-24 17:39:41 +00:00
Timothy Drews 1fac67cb29 Don't cache responses in FailoverUri.
Issue #184

Change-Id: If7137f96ac4994d593615ef6baecadb668218403
2015-09-23 16:42:35 -07:00
Timothy Drews 638b9a1274 Fix preferred language tests.
Waiting for playback to begin ensures there's an active
audio track.

Change-Id: I9b5a107fc1644bd6a61349bac0618148239e389d
2015-09-23 15:45:37 -07:00
Timothy Drews 0ee549727a Bump version numbers for v1.5.0
Change-Id: Ifcf55b95091763f18f652dadc03f2d37f986c072
v1.5.0
2015-09-17 14:41:12 -07:00
Joey Parrish bab2e1b852 Update changelog for v1.5.0
Change-Id: Ibf699bc7747e460d29cb8625ce93edf718ebf610
2015-09-17 13:14:43 -07:00
Timothy Drews 26bfade2df Fix multiple audio language support.
* Ensure AdaptationSets with different languages but with the same group
  end up in different StreamSetInfos.
* Set the main flag in a StreamSetInfo if any one of the source
  AdaptationSets has their main flag set (commit
  689c2a47aa broke Role 'main' support).

Closes #182

Change-Id: Ia017e294e0b359c62133adc42a8d701d614f3b0d
2015-09-15 17:36:20 -07:00
Timothy Drews 5e84b9bd39 Fail gracefully when all tracks are restricted.
* Fire an error event when all audio/video tracks are restricted
  during playback.
* Fire an error event and fail gracefully when all audio/video tracks
  are restricted before playback (requires calling player.unload() when
  the VideoSource's attach promise gets rejected).
* Rework AbrManager so that getInitialVideoTrack() can be called before
  starting bandwidth monitoring.

Closes #170
Issue #179

Change-Id: I4ac6cdf2a4c862e0d0560dff2f2d7bb6801bbc38
2015-09-15 21:12:39 +00:00
Timothy Drews 104e746ff4 Fix 'usable' key detection.
getKeyStatusErrorMessage() may return null (not undefined).

Change-Id: Ie2cbb942661e825d5421bb29672fc4f2bffdf6cd
2015-09-14 16:22:28 -07:00
Timothy Drews 6049d67804 Re-allow pausing while rewinding.
This fixes a regression and adds more integration tests.

Closes #130

Change-Id: Idd386931ae6d9f37052f24438ebcba10774e3451
2015-09-11 13:09:29 -07:00
Timothy Drews 35d4c5ec20 Only apply restrictions to video tracks.
Closes #179

Change-Id: I5ef1167903b98840ce2d9d031d99845269e9e1d4
2015-09-10 13:08:23 -07:00
Joey Parrish 4e69e00b67 Fix CENC car MPD for IE & Firefox
The manifest didn't declare an XML namespace.  Firefox and IE are
very strict about this, whereas Chrome is not.

Change-Id: I96fd44bb2debb974d7587603732965982681eadd
2015-09-09 19:59:24 +00:00
Joey Parrish 959595a5f6 Fix EME manager for multiple configs
Fixes #177

Change-Id: I2976b2d1af237fb758892374c42f60ed488e41cb
2015-09-09 19:53:37 +00:00
Timothy Drews c45a3c273f Fix typo that affects startup buffering.
Closes #175

Change-Id: I277c1e478be10b5aa3aa32a30253451931204438
2015-09-09 09:51:18 -07:00
Timothy Drews d0b8c68b04 Skip unknown keys in compiled mode too.
If the key was not specified in the manifest then it should always
be skipped.

Issue #174

Change-Id: Iad31203967c5e0380b85e49075d4d2523e042a9b
2015-09-08 15:04:41 -07:00
Timothy Drews 9fd655f17c Fix SegmentTimelines with @presentationTimeOffset.
Fixes #143

Change-Id: I49bf77c7a63be48bcac19281dcadd373b52bcd4f
2015-09-08 21:57:13 +00:00