shaka-player 4.8.10 → 4.9.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (66) hide show
  1. package/README.md +5 -0
  2. package/dist/controls.css +1 -1
  3. package/dist/controls.css.map +1 -1
  4. package/dist/deps.js +5 -5
  5. package/dist/locales.js +34 -34
  6. package/dist/shaka-player.compiled.d.ts +39 -18
  7. package/dist/shaka-player.compiled.debug.d.ts +39 -18
  8. package/dist/shaka-player.compiled.debug.externs.js +32 -12
  9. package/dist/shaka-player.compiled.debug.js +638 -579
  10. package/dist/shaka-player.compiled.debug.map +4 -4
  11. package/dist/shaka-player.compiled.externs.js +32 -12
  12. package/dist/shaka-player.compiled.js +1272 -1237
  13. package/dist/shaka-player.compiled.map +4 -4
  14. package/dist/shaka-player.ui.d.ts +39 -18
  15. package/dist/shaka-player.ui.debug.d.ts +39 -18
  16. package/dist/shaka-player.ui.debug.externs.js +43 -23
  17. package/dist/shaka-player.ui.debug.js +668 -609
  18. package/dist/shaka-player.ui.debug.map +4 -4
  19. package/dist/shaka-player.ui.externs.js +43 -23
  20. package/dist/shaka-player.ui.js +1487 -1451
  21. package/dist/shaka-player.ui.map +4 -4
  22. package/externs/shaka/manifest.js +11 -1
  23. package/externs/shaka/offline.js +3 -0
  24. package/externs/shaka/player.js +105 -12
  25. package/externs/tizen.js +1 -1
  26. package/lib/abr/simple_abr_manager.js +5 -0
  27. package/lib/ads/media_tailor_ad.js +11 -0
  28. package/lib/ads/media_tailor_ad_manager.js +37 -3
  29. package/lib/dash/dash_parser.js +655 -46
  30. package/lib/dash/mpd_utils.js +7 -8
  31. package/lib/dash/segment_template.js +65 -10
  32. package/lib/hls/hls_parser.js +92 -34
  33. package/lib/media/content_workarounds.js +4 -2
  34. package/lib/media/drm_engine.js +274 -40
  35. package/lib/media/manifest_filterer.js +2 -2
  36. package/lib/media/media_source_engine.js +66 -31
  37. package/lib/media/segment_utils.js +14 -3
  38. package/lib/mss/mss_parser.js +2 -0
  39. package/lib/net/http_plugin_utils.js +2 -1
  40. package/lib/net/networking_engine.js +14 -0
  41. package/lib/offline/indexeddb/v1_storage_cell.js +1 -0
  42. package/lib/offline/indexeddb/v2_storage_cell.js +1 -0
  43. package/lib/offline/manifest_converter.js +2 -0
  44. package/lib/offline/storage.js +1 -0
  45. package/lib/player.js +220 -14
  46. package/lib/polyfill/media_capabilities.js +10 -35
  47. package/lib/transmuxer/aac_transmuxer.js +4 -2
  48. package/lib/transmuxer/ac3_transmuxer.js +2 -1
  49. package/lib/transmuxer/ec3_transmuxer.js +2 -1
  50. package/lib/transmuxer/mp3_transmuxer.js +4 -2
  51. package/lib/transmuxer/mpeg_ts_transmuxer.js +2 -1
  52. package/lib/transmuxer/mss_transmuxer.js +4 -2
  53. package/lib/transmuxer/ts_transmuxer.js +44 -24
  54. package/lib/util/config_utils.js +74 -6
  55. package/lib/util/error.js +17 -8
  56. package/lib/util/mp4_box_parsers.js +23 -2
  57. package/lib/util/periods.js +51 -28
  58. package/lib/util/platform.js +3 -1
  59. package/lib/util/player_configuration.js +20 -8
  60. package/lib/util/stream_utils.js +62 -30
  61. package/lib/util/tXml.js +74 -6
  62. package/package.json +2 -2
  63. package/support.html +1 -0
  64. package/ui/controls.js +4 -0
  65. package/ui/less/ad_controls.less +2 -1
  66. package/ui/resolution_selection.js +12 -3
@@ -825,7 +825,6 @@ shaka.util.Error.Code = {
825
825
  'TRANSMUXING_FAILED': 3018,
826
826
  'CONTENT_TRANSFORMATION_FAILED': 3019,
827
827
  'MSS_MISSING_DATA_FOR_TRANSMUXING': 3020,
828
- 'MSS_TRANSMUXING_CODEC_UNKNOWN': 3021,
829
828
  'MSS_TRANSMUXING_FAILED': 3022,
830
829
  'TRANSMUXING_NO_VIDEO_DATA': 3023,
831
830
  'UNABLE_TO_GUESS_MANIFEST_TYPE': 4000,
@@ -867,6 +866,7 @@ shaka.util.Error.Code = {
867
866
  'AES_128_INVALID_KEY_LENGTH': 4049,
868
867
  'DASH_CONFLICTING_AES_128': 4050,
869
868
  'DASH_UNSUPPORTED_AES_128': 4051,
869
+ 'DASH_INVALID_PATCH': 4052,
870
870
  'STREAMING_ENGINE_STARTUP_INVALID_STATE': 5006,
871
871
  'NO_RECOGNIZED_KEY_SYSTEMS': 6000,
872
872
  'REQUESTED_KEY_SYSTEM_CONFIG_UNAVAILABLE': 6001,
@@ -1249,7 +1249,7 @@ shaka.util.StreamUtils = class {
1249
1249
  * @param {shaka.extern.Variant} variant
1250
1250
  * @param {shaka.extern.Restrictions} restrictions
1251
1251
  * Configured restrictions from the user.
1252
- * @param {{width: number, height: number}} maxHwRes
1252
+ * @param {shaka.extern.Resolution} maxHwRes
1253
1253
  * The maximum resolution the hardware can handle.
1254
1254
  * This is applied separately from user restrictions because the setting
1255
1255
  * should not be easily replaced by the user's configuration.
@@ -1538,6 +1538,10 @@ shaka.net.NetworkingEngine = class extends shaka.util.FakeEventTarget {
1538
1538
  * Called when receive the response
1539
1539
  */
1540
1540
  constructor(onProgressUpdated, onHeadersReceived, onDownloadFailed, onRequest, onRetry, onResponse) {}
1541
+ /**
1542
+ * @param {boolean} forceHTTP
1543
+ */
1544
+ setForceHTTP(forceHTTP) {}
1541
1545
  /**
1542
1546
  * @param {boolean} forceHTTPS
1543
1547
  */
@@ -2830,6 +2834,12 @@ shaka.util.ConfigUtils = class {
2830
2834
  * @return {!Object}
2831
2835
  */
2832
2836
  static convertToConfigObject(fieldName, value) {}
2837
+ /**
2838
+ * @param {!Object} object
2839
+ * @param {!Object} base
2840
+ * @return {!Object}
2841
+ */
2842
+ static getDifferenceFromConfigObjects(object, base) {}
2833
2843
  };
2834
2844
  /**
2835
2845
  * @summary A set of FairPlay utility functions.
@@ -3247,6 +3257,17 @@ shaka.Player = class extends shaka.util.FakeEventTarget {
3247
3257
  * @return {!Promise.<?shaka.media.PreloadManager>}
3248
3258
  */
3249
3259
  unloadAndSavePreload(initializeMediaSource, keepAdManager) {}
3260
+ /**
3261
+ * Detach the player from the current media element, if any, and returns a
3262
+ * PreloadManager that contains the loaded manifest of that asset, if any.
3263
+ * Allows for the asset to be re-loaded by this player faster, in the future.
3264
+ * When in src= mode, this detach but does not make a PreloadManager.
3265
+ * Leaves the player in a state where it cannot play media, until it has been
3266
+ * attached to something else.
3267
+ * @param {boolean=} keepAdManager
3268
+ * @return {!Promise.<?shaka.media.PreloadManager>}
3269
+ */
3270
+ detachAndSavePreload(keepAdManager) {}
3250
3271
  /**
3251
3272
  * Starts to preload a given asset, and returns a PreloadManager object that
3252
3273
  * represents that preloading process.
@@ -3303,6 +3324,13 @@ shaka.Player = class extends shaka.util.FakeEventTarget {
3303
3324
  * @return {shaka.extern.PlayerConfiguration}
3304
3325
  */
3305
3326
  getConfiguration() {}
3327
+ /**
3328
+ * Return a copy of the current non default configuration. Modifications of
3329
+ * the returned value will not affect the Player's active configuration.
3330
+ * You must call <code>player.configure()</code> to make changes.
3331
+ * @return {!Object}
3332
+ */
3333
+ getNonDefaultConfiguration() {}
3306
3334
  /**
3307
3335
  * Returns the ratio of video length buffered compared to buffering Goal
3308
3336
  * @return {number}
@@ -4576,9 +4604,10 @@ shaka.util.PeriodCombiner = class {
4576
4604
  /**
4577
4605
  * @param {!Array.<shaka.extern.Period>} periods
4578
4606
  * @param {boolean} isDynamic
4607
+ * @param {boolean=} isPatchUpdate
4579
4608
  * @return {!Promise}
4580
4609
  */
4581
- combinePeriods(periods, isDynamic) {}
4610
+ combinePeriods(periods, isDynamic, isPatchUpdate) {}
4582
4611
  /**
4583
4612
  * @param {boolean} allowed If set to true, multi-mimeType or multi-codec
4584
4613
  * variants will be allowed.
@@ -5033,15 +5062,6 @@ shaka.polyfill.MediaCapabilities = class {
5033
5062
  * @type {MediaCapabilities}
5034
5063
  */
5035
5064
  shaka.polyfill.MediaCapabilities.originalMcap;
5036
- /**
5037
- * A cache that stores the MediaKeySystemAccess result of calling
5038
- * `navigator.requestMediaKeySystemAccess` by a key combination of
5039
- * video/audio codec and key system string.
5040
- * @type {(Object<(!string), (!MediaKeySystemAccess)>)}
5041
- */
5042
- shaka.polyfill.MediaCapabilities.memoizedMediaKeySystemAccessRequests_ = {
5043
-
5044
- };
5045
5065
  /**
5046
5066
  * A cache that stores the canDisplayType result of calling
5047
5067
  * `cast.__platform__.canDisplayType`.