shaka-player 4.7.13 → 4.8.0
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.
- package/AUTHORS +1 -0
- package/CONTRIBUTORS +1 -0
- package/LICENSE +54 -0
- package/README.md +22 -1
- package/dist/controls.css +1 -1
- package/dist/controls.css.map +1 -1
- package/dist/deps.js +34 -23
- package/dist/locales.js +44 -34
- package/dist/shaka-player.compiled.d.ts +194 -44
- package/dist/shaka-player.compiled.debug.d.ts +194 -44
- package/dist/shaka-player.compiled.debug.externs.js +474 -337
- package/dist/shaka-player.compiled.debug.js +949 -832
- package/dist/shaka-player.compiled.debug.map +4 -4
- package/dist/shaka-player.compiled.externs.js +474 -337
- package/dist/shaka-player.compiled.js +1237 -1171
- package/dist/shaka-player.compiled.map +4 -4
- package/dist/shaka-player.ui.d.ts +257 -47
- package/dist/shaka-player.ui.debug.d.ts +257 -47
- package/dist/shaka-player.ui.debug.externs.js +591 -376
- package/dist/shaka-player.ui.debug.js +1165 -965
- package/dist/shaka-player.ui.debug.map +4 -4
- package/dist/shaka-player.ui.externs.js +591 -376
- package/dist/shaka-player.ui.js +1521 -1404
- package/dist/shaka-player.ui.map +4 -4
- package/externs/device_sensor_event.js +18 -0
- package/externs/hisense.js +16 -0
- package/externs/playstation.js +31 -0
- package/externs/shaka/abr_manager.js +3 -1
- package/externs/shaka/ads.js +5 -0
- package/externs/shaka/codecs.js +13 -0
- package/externs/shaka/manifest.js +58 -6
- package/externs/shaka/net.js +13 -1
- package/externs/shaka/player.js +184 -13
- package/externs/shaka/text.js +19 -0
- package/externs/tizen.js +41 -0
- package/externs/webos.js +19 -0
- package/externs/xbox.js +43 -0
- package/lib/abr/simple_abr_manager.js +9 -1
- package/lib/ads/ad_manager.js +19 -2
- package/lib/ads/client_side_ad_manager.js +5 -3
- package/lib/ads/media_tailor_ad_manager.js +9 -0
- package/lib/cast/cast_receiver.js +0 -14
- package/lib/cast/cast_utils.js +1 -0
- package/lib/cea/mp4_cea_parser.js +6 -1
- package/lib/dash/content_protection.js +97 -53
- package/lib/dash/dash_parser.js +230 -176
- package/lib/dash/mpd_utils.js +72 -65
- package/lib/dash/segment_base.js +27 -21
- package/lib/dash/segment_list.js +18 -16
- package/lib/dash/segment_template.js +26 -21
- package/lib/hls/hls_parser.js +358 -164
- package/lib/media/buffering_observer.js +25 -1
- package/lib/media/drm_engine.js +91 -71
- package/lib/media/manifest_filterer.js +220 -0
- package/lib/media/media_source_engine.js +34 -5
- package/lib/media/preload_manager.js +827 -0
- package/lib/media/presentation_timeline.js +11 -0
- package/lib/media/segment_index.js +40 -30
- package/lib/media/segment_prefetch.js +140 -43
- package/lib/media/segment_reference.js +31 -8
- package/lib/media/segment_utils.js +208 -25
- package/lib/media/streaming_engine.js +319 -63
- package/lib/mss/content_protection.js +31 -25
- package/lib/mss/mss_parser.js +74 -55
- package/lib/net/networking_engine.js +49 -4
- package/lib/offline/storage.js +3 -3
- package/lib/player.js +882 -673
- package/lib/polyfill/media_capabilities.js +16 -1
- package/lib/text/simple_text_displayer.js +9 -0
- package/lib/text/stub_text_displayer.js +7 -0
- package/lib/text/text_engine.js +16 -3
- package/lib/text/ttml_text_parser.js +116 -114
- package/lib/text/ui_text_displayer.js +28 -11
- package/lib/text/vtt_text_parser.js +54 -115
- package/lib/transmuxer/opus.js +91 -0
- package/lib/transmuxer/ts_transmuxer.js +115 -0
- package/lib/util/cmcd_manager.js +152 -3
- package/lib/util/dom_utils.js +11 -0
- package/lib/util/error.js +5 -0
- package/lib/util/fake_event.js +2 -0
- package/lib/util/manifest_parser_utils.js +97 -3
- package/lib/util/mp4_box_parsers.js +346 -17
- package/lib/util/mp4_generator.js +23 -0
- package/lib/util/periods.js +19 -0
- package/lib/util/platform.js +161 -9
- package/lib/util/player_configuration.js +61 -3
- package/lib/util/stats.js +16 -0
- package/lib/util/stream_utils.js +16 -6
- package/lib/util/string_utils.js +36 -0
- package/lib/util/tXml.js +814 -0
- package/lib/util/ts_parser.js +50 -0
- package/lib/util/xml_utils.js +10 -338
- package/package.json +2 -2
- package/shaka-player.uncompiled.js +8 -0
- package/ui/controls.js +187 -5
- package/ui/enums.js +2 -0
- package/ui/externs/ui.js +30 -3
- package/ui/gl_matrix/matrix_4x4.js +568 -0
- package/ui/gl_matrix/matrix_quaternion.js +45 -0
- package/ui/less/containers.less +11 -0
- package/ui/locales/en-GB.json +2 -0
- package/ui/locales/en.json +2 -0
- package/ui/locales/es-419.json +2 -0
- package/ui/locales/es.json +2 -0
- package/ui/locales/source.json +8 -0
- package/ui/recenter_vr.js +126 -0
- package/ui/resolution_selection.js +25 -5
- package/ui/statistics_button.js +12 -0
- package/ui/text_selection.js +1 -1
- package/ui/toggle_stereoscopic.js +127 -0
- package/ui/ui.js +74 -38
- package/ui/vr_manager.js +557 -0
- package/ui/vr_utils.js +232 -0
- package/ui/vr_webgl.js +697 -0
|
@@ -127,6 +127,61 @@ shaka.util.FakeEventTarget = class {
|
|
|
127
127
|
* @typedef {EventListener|function(!Event):*}
|
|
128
128
|
*/
|
|
129
129
|
shaka.util.FakeEventTarget.ListenerType;
|
|
130
|
+
/**
|
|
131
|
+
* @summary A set of BufferSource utility functions.
|
|
132
|
+
*/
|
|
133
|
+
shaka.util.BufferUtils = class {
|
|
134
|
+
/**
|
|
135
|
+
* Compare two buffers for equality. For buffers of different types, this
|
|
136
|
+
* compares the underlying buffers as binary data.
|
|
137
|
+
* @param {?BufferSource} arr1
|
|
138
|
+
* @param {?BufferSource} arr2
|
|
139
|
+
* @return {boolean}
|
|
140
|
+
* @suppress {strictMissingProperties}
|
|
141
|
+
*/
|
|
142
|
+
static equal(arr1, arr2) {}
|
|
143
|
+
/**
|
|
144
|
+
* Gets an ArrayBuffer that contains the data from the given TypedArray. Note
|
|
145
|
+
* this will allocate a new ArrayBuffer if the object is a partial view of
|
|
146
|
+
* the data.
|
|
147
|
+
* @param {!BufferSource} view
|
|
148
|
+
* @return {!ArrayBuffer}
|
|
149
|
+
*/
|
|
150
|
+
static toArrayBuffer(view) {}
|
|
151
|
+
/**
|
|
152
|
+
* Creates a new Uint8Array view on the same buffer. This clamps the values
|
|
153
|
+
* to be within the same view (i.e. you can't use this to move past the end
|
|
154
|
+
* of the view, even if the underlying buffer is larger). However, you can
|
|
155
|
+
* pass a negative offset to access the data before the view.
|
|
156
|
+
* @param {BufferSource} data
|
|
157
|
+
* @param {number=} offset The offset from the beginning of this data's view
|
|
158
|
+
* to start the new view at.
|
|
159
|
+
* @param {number=} length The byte length of the new view.
|
|
160
|
+
* @return {!Uint8Array}
|
|
161
|
+
*/
|
|
162
|
+
static toUint8(data, offset, length) {}
|
|
163
|
+
/**
|
|
164
|
+
* Creates a new Uint16Array view on the same buffer. This clamps the values
|
|
165
|
+
* to be within the same view (i.e. you can't use this to move past the end
|
|
166
|
+
* of the view, even if the underlying buffer is larger). However, you can
|
|
167
|
+
* pass a negative offset to access the data before the view.
|
|
168
|
+
* @param {BufferSource} data
|
|
169
|
+
* @param {number=} offset The offset from the beginning of this data's view
|
|
170
|
+
* to start the new view at.
|
|
171
|
+
* @param {number=} length The byte length of the new view.
|
|
172
|
+
* @return {!Uint16Array}
|
|
173
|
+
*/
|
|
174
|
+
static toUint16(data, offset, length) {}
|
|
175
|
+
/**
|
|
176
|
+
* Creates a DataView over the given buffer.
|
|
177
|
+
* @see toUint8
|
|
178
|
+
* @param {BufferSource} buffer
|
|
179
|
+
* @param {number=} offset
|
|
180
|
+
* @param {number=} length
|
|
181
|
+
* @return {!DataView}
|
|
182
|
+
*/
|
|
183
|
+
static toDataView(buffer, offset, length) {}
|
|
184
|
+
};
|
|
130
185
|
/**
|
|
131
186
|
* @summary
|
|
132
187
|
* Describes an error that happened.
|
|
@@ -313,6 +368,7 @@ shaka.util.Error.Code = {
|
|
|
313
368
|
'NO_VIDEO_ELEMENT': 7002,
|
|
314
369
|
'OBJECT_DESTROYED': 7003,
|
|
315
370
|
'CONTENT_NOT_LOADED': 7004,
|
|
371
|
+
'SRC_EQUALS_PRELOAD_NOT_SUPPORTED': 7005,
|
|
316
372
|
'CAST_API_UNAVAILABLE': 8000,
|
|
317
373
|
'NO_CAST_RECEIVERS': 8001,
|
|
318
374
|
'ALREADY_CASTING': 8002,
|
|
@@ -342,6 +398,137 @@ shaka.util.Error.Code = {
|
|
|
342
398
|
'CURRENT_DAI_REQUEST_NOT_FINISHED': 10004,
|
|
343
399
|
'MT_AD_MANAGER_NOT_INITIALIZED': 10005
|
|
344
400
|
};
|
|
401
|
+
/**
|
|
402
|
+
* A timer allows a single function to be executed at a later time or at
|
|
403
|
+
* regular intervals.
|
|
404
|
+
* @final
|
|
405
|
+
*/
|
|
406
|
+
shaka.util.Timer = class {
|
|
407
|
+
/**
|
|
408
|
+
* Create a new timer. A timer is committed to a single callback function.
|
|
409
|
+
* While there is no technical reason to do this, it is far easier to
|
|
410
|
+
* understand and use timers when they are connected to one functional idea.
|
|
411
|
+
* @param {function()} onTick
|
|
412
|
+
*/
|
|
413
|
+
constructor(onTick) {}
|
|
414
|
+
/**
|
|
415
|
+
* Have the timer call |onTick| now.
|
|
416
|
+
* @return {!shaka.util.Timer}
|
|
417
|
+
*/
|
|
418
|
+
tickNow() {}
|
|
419
|
+
/**
|
|
420
|
+
* Have the timer call |onTick| after |seconds| has elapsed unless |stop| is
|
|
421
|
+
* called first.
|
|
422
|
+
* @param {number} seconds
|
|
423
|
+
* @return {!shaka.util.Timer}
|
|
424
|
+
*/
|
|
425
|
+
tickAfter(seconds) {}
|
|
426
|
+
/**
|
|
427
|
+
* Have the timer call |onTick| every |seconds| until |stop| is called.
|
|
428
|
+
* @param {number} seconds
|
|
429
|
+
* @return {!shaka.util.Timer}
|
|
430
|
+
*/
|
|
431
|
+
tickEvery(seconds) {}
|
|
432
|
+
/**
|
|
433
|
+
* Stop the timer and clear the previous behaviour. The timer is still usable
|
|
434
|
+
* after calling |stop|.
|
|
435
|
+
*/
|
|
436
|
+
stop() {}
|
|
437
|
+
};
|
|
438
|
+
/**
|
|
439
|
+
* @namespace shaka.util.StringUtils
|
|
440
|
+
* @summary A set of string utility functions.
|
|
441
|
+
*/
|
|
442
|
+
shaka.util.StringUtils = class {
|
|
443
|
+
/**
|
|
444
|
+
* Creates a string from the given buffer as UTF-8 encoding.
|
|
445
|
+
* @param {?BufferSource} data
|
|
446
|
+
* @return {string}
|
|
447
|
+
*/
|
|
448
|
+
static fromUTF8(data) {}
|
|
449
|
+
/**
|
|
450
|
+
* Creates a string from the given buffer as UTF-16 encoding.
|
|
451
|
+
* @param {?BufferSource} data
|
|
452
|
+
* @param {boolean} littleEndian
|
|
453
|
+
true to read little endian, false to read big.
|
|
454
|
+
* @param {boolean=} noThrow true to avoid throwing in cases where we may
|
|
455
|
+
* expect invalid input. If noThrow is true and the data has an odd
|
|
456
|
+
* length,it will be truncated.
|
|
457
|
+
* @return {string}
|
|
458
|
+
*/
|
|
459
|
+
static fromUTF16(data, littleEndian, noThrow) {}
|
|
460
|
+
/**
|
|
461
|
+
* Creates a string from the given buffer, auto-detecting the encoding that is
|
|
462
|
+
* being used. If it cannot detect the encoding, it will throw an exception.
|
|
463
|
+
* @param {?BufferSource} data
|
|
464
|
+
* @return {string}
|
|
465
|
+
*/
|
|
466
|
+
static fromBytesAutoDetect(data) {}
|
|
467
|
+
/**
|
|
468
|
+
* Creates a ArrayBuffer from the given string, converting to UTF-8 encoding.
|
|
469
|
+
* @param {string} str
|
|
470
|
+
* @return {!ArrayBuffer}
|
|
471
|
+
*/
|
|
472
|
+
static toUTF8(str) {}
|
|
473
|
+
/**
|
|
474
|
+
* Creates a ArrayBuffer from the given string, converting to UTF-16 encoding.
|
|
475
|
+
* @param {string} str
|
|
476
|
+
* @param {boolean} littleEndian
|
|
477
|
+
* @return {!ArrayBuffer}
|
|
478
|
+
*/
|
|
479
|
+
static toUTF16(str, littleEndian) {}
|
|
480
|
+
/**
|
|
481
|
+
* Resets the fromCharCode method's implementation.
|
|
482
|
+
* For debug use.
|
|
483
|
+
*/
|
|
484
|
+
static resetFromCharCode() {}
|
|
485
|
+
};
|
|
486
|
+
/**
|
|
487
|
+
* @summary A set of Uint8Array utility functions.
|
|
488
|
+
*/
|
|
489
|
+
shaka.util.Uint8ArrayUtils = class {
|
|
490
|
+
/**
|
|
491
|
+
* Convert a buffer to a base64 string. The output will be standard
|
|
492
|
+
* alphabet as opposed to base64url safe alphabet.
|
|
493
|
+
* @param {BufferSource} data
|
|
494
|
+
* @return {string}
|
|
495
|
+
*/
|
|
496
|
+
static toStandardBase64(data) {}
|
|
497
|
+
/**
|
|
498
|
+
* Convert a buffer to a base64 string. The output will always use the
|
|
499
|
+
* alternate encoding/alphabet also known as "base64url".
|
|
500
|
+
* @param {BufferSource} data
|
|
501
|
+
* @param {boolean=} padding If true, pad the output with equals signs.
|
|
502
|
+
* Defaults to true.
|
|
503
|
+
* @return {string}
|
|
504
|
+
*/
|
|
505
|
+
static toBase64(data, padding) {}
|
|
506
|
+
/**
|
|
507
|
+
* Convert a base64 string to a Uint8Array. Accepts either the standard
|
|
508
|
+
* alphabet or the alternate "base64url" alphabet.
|
|
509
|
+
* @param {string} str
|
|
510
|
+
* @return {!Uint8Array}
|
|
511
|
+
*/
|
|
512
|
+
static fromBase64(str) {}
|
|
513
|
+
/**
|
|
514
|
+
* Convert a hex string to a Uint8Array.
|
|
515
|
+
* @param {string} str
|
|
516
|
+
* @return {!Uint8Array}
|
|
517
|
+
*/
|
|
518
|
+
static fromHex(str) {}
|
|
519
|
+
/**
|
|
520
|
+
* Convert a buffer to a hex string.
|
|
521
|
+
* @param {BufferSource} data
|
|
522
|
+
* @return {string}
|
|
523
|
+
*/
|
|
524
|
+
static toHex(data) {}
|
|
525
|
+
/**
|
|
526
|
+
* Concatenate buffers.
|
|
527
|
+
* @param {...BufferSource} varArgs
|
|
528
|
+
* @return {!Uint8Array}
|
|
529
|
+
*/
|
|
530
|
+
static concat(...varArgs) {}
|
|
531
|
+
};
|
|
345
532
|
/**
|
|
346
533
|
* @summary A set of language utility functions.
|
|
347
534
|
* @final
|
|
@@ -648,61 +835,6 @@ shaka.util.EventManager = class {
|
|
|
648
835
|
* @typedef {function(!Event)}
|
|
649
836
|
*/
|
|
650
837
|
shaka.util.EventManager.ListenerType;
|
|
651
|
-
/**
|
|
652
|
-
* @summary A set of BufferSource utility functions.
|
|
653
|
-
*/
|
|
654
|
-
shaka.util.BufferUtils = class {
|
|
655
|
-
/**
|
|
656
|
-
* Compare two buffers for equality. For buffers of different types, this
|
|
657
|
-
* compares the underlying buffers as binary data.
|
|
658
|
-
* @param {?BufferSource} arr1
|
|
659
|
-
* @param {?BufferSource} arr2
|
|
660
|
-
* @return {boolean}
|
|
661
|
-
* @suppress {strictMissingProperties}
|
|
662
|
-
*/
|
|
663
|
-
static equal(arr1, arr2) {}
|
|
664
|
-
/**
|
|
665
|
-
* Gets an ArrayBuffer that contains the data from the given TypedArray. Note
|
|
666
|
-
* this will allocate a new ArrayBuffer if the object is a partial view of
|
|
667
|
-
* the data.
|
|
668
|
-
* @param {!BufferSource} view
|
|
669
|
-
* @return {!ArrayBuffer}
|
|
670
|
-
*/
|
|
671
|
-
static toArrayBuffer(view) {}
|
|
672
|
-
/**
|
|
673
|
-
* Creates a new Uint8Array view on the same buffer. This clamps the values
|
|
674
|
-
* to be within the same view (i.e. you can't use this to move past the end
|
|
675
|
-
* of the view, even if the underlying buffer is larger). However, you can
|
|
676
|
-
* pass a negative offset to access the data before the view.
|
|
677
|
-
* @param {BufferSource} data
|
|
678
|
-
* @param {number=} offset The offset from the beginning of this data's view
|
|
679
|
-
* to start the new view at.
|
|
680
|
-
* @param {number=} length The byte length of the new view.
|
|
681
|
-
* @return {!Uint8Array}
|
|
682
|
-
*/
|
|
683
|
-
static toUint8(data, offset, length) {}
|
|
684
|
-
/**
|
|
685
|
-
* Creates a new Uint16Array view on the same buffer. This clamps the values
|
|
686
|
-
* to be within the same view (i.e. you can't use this to move past the end
|
|
687
|
-
* of the view, even if the underlying buffer is larger). However, you can
|
|
688
|
-
* pass a negative offset to access the data before the view.
|
|
689
|
-
* @param {BufferSource} data
|
|
690
|
-
* @param {number=} offset The offset from the beginning of this data's view
|
|
691
|
-
* to start the new view at.
|
|
692
|
-
* @param {number=} length The byte length of the new view.
|
|
693
|
-
* @return {!Uint16Array}
|
|
694
|
-
*/
|
|
695
|
-
static toUint16(data, offset, length) {}
|
|
696
|
-
/**
|
|
697
|
-
* Creates a DataView over the given buffer.
|
|
698
|
-
* @see toUint8
|
|
699
|
-
* @param {BufferSource} buffer
|
|
700
|
-
* @param {number=} offset
|
|
701
|
-
* @param {number=} length
|
|
702
|
-
* @return {!DataView}
|
|
703
|
-
*/
|
|
704
|
-
static toDataView(buffer, offset, length) {}
|
|
705
|
-
};
|
|
706
838
|
/**
|
|
707
839
|
* The IClosedCaptionParser defines the interface to provide all operations for
|
|
708
840
|
* parsing the closed captions embedded in Dash videos streams.
|
|
@@ -1287,46 +1419,9 @@ shaka.text.TextEngine = class {
|
|
|
1287
1419
|
destroy() {}
|
|
1288
1420
|
};
|
|
1289
1421
|
/**
|
|
1290
|
-
* A
|
|
1291
|
-
* regular intervals.
|
|
1292
|
-
* @final
|
|
1422
|
+
* @summary A set of utility functions for dealing with Streams and Manifests.
|
|
1293
1423
|
*/
|
|
1294
|
-
shaka.util.
|
|
1295
|
-
/**
|
|
1296
|
-
* Create a new timer. A timer is committed to a single callback function.
|
|
1297
|
-
* While there is no technical reason to do this, it is far easier to
|
|
1298
|
-
* understand and use timers when they are connected to one functional idea.
|
|
1299
|
-
* @param {function()} onTick
|
|
1300
|
-
*/
|
|
1301
|
-
constructor(onTick) {}
|
|
1302
|
-
/**
|
|
1303
|
-
* Have the timer call |onTick| now.
|
|
1304
|
-
* @return {!shaka.util.Timer}
|
|
1305
|
-
*/
|
|
1306
|
-
tickNow() {}
|
|
1307
|
-
/**
|
|
1308
|
-
* Have the timer call |onTick| after |seconds| has elapsed unless |stop| is
|
|
1309
|
-
* called first.
|
|
1310
|
-
* @param {number} seconds
|
|
1311
|
-
* @return {!shaka.util.Timer}
|
|
1312
|
-
*/
|
|
1313
|
-
tickAfter(seconds) {}
|
|
1314
|
-
/**
|
|
1315
|
-
* Have the timer call |onTick| every |seconds| until |stop| is called.
|
|
1316
|
-
* @param {number} seconds
|
|
1317
|
-
* @return {!shaka.util.Timer}
|
|
1318
|
-
*/
|
|
1319
|
-
tickEvery(seconds) {}
|
|
1320
|
-
/**
|
|
1321
|
-
* Stop the timer and clear the previous behaviour. The timer is still usable
|
|
1322
|
-
* after calling |stop|.
|
|
1323
|
-
*/
|
|
1324
|
-
stop() {}
|
|
1325
|
-
};
|
|
1326
|
-
/**
|
|
1327
|
-
* @summary A set of utility functions for dealing with Streams and Manifests.
|
|
1328
|
-
*/
|
|
1329
|
-
shaka.util.StreamUtils = class {
|
|
1424
|
+
shaka.util.StreamUtils = class {
|
|
1330
1425
|
/**
|
|
1331
1426
|
* @param {shaka.extern.Variant} variant
|
|
1332
1427
|
* @param {shaka.extern.Restrictions} restrictions
|
|
@@ -1389,9 +1484,16 @@ shaka.abr.SimpleAbrManager = class {
|
|
|
1389
1484
|
*/
|
|
1390
1485
|
disable() {}
|
|
1391
1486
|
/**
|
|
1487
|
+
* @param {number} deltaTimeMs The duration, in milliseconds, that the request
|
|
1488
|
+
* took to complete.
|
|
1489
|
+
* @param {number} numBytes The total number of bytes transferred.
|
|
1490
|
+
* @param {boolean} allowSwitch Indicate if the segment is allowed to switch
|
|
1491
|
+
* to another stream.
|
|
1492
|
+
* @param {shaka.extern.Request=} request
|
|
1493
|
+
* A reference to the request
|
|
1392
1494
|
* @override
|
|
1393
1495
|
*/
|
|
1394
|
-
segmentDownloaded(deltaTimeMs, numBytes, allowSwitch) {}
|
|
1496
|
+
segmentDownloaded(deltaTimeMs, numBytes, allowSwitch, request) {}
|
|
1395
1497
|
/**
|
|
1396
1498
|
* @override
|
|
1397
1499
|
*/
|
|
@@ -1531,7 +1633,8 @@ shaka.util.AbortableOperation.prototype.promise;
|
|
|
1531
1633
|
*/
|
|
1532
1634
|
shaka.net.NetworkingEngine = class extends shaka.util.FakeEventTarget {
|
|
1533
1635
|
/**
|
|
1534
|
-
* @param {
|
|
1636
|
+
* @param {shaka.net.NetworkingEngine.onProgressUpdated=} onProgressUpdated
|
|
1637
|
+
* Called when
|
|
1535
1638
|
* a progress event is triggered. Passed the duration, in milliseconds,
|
|
1536
1639
|
* that the request took, the number of bytes transferred, and the boolean
|
|
1537
1640
|
* of whether the switching is allowed.
|
|
@@ -1543,8 +1646,10 @@ shaka.net.NetworkingEngine = class extends shaka.util.FakeEventTarget {
|
|
|
1543
1646
|
* Called when a request is made
|
|
1544
1647
|
* @param {shaka.net.NetworkingEngine.OnRetry=} onRetry
|
|
1545
1648
|
* Called when a request retry is made
|
|
1649
|
+
* @param {shaka.net.NetworkingEngine.OnResponse=} onResponse
|
|
1650
|
+
* Called when receive the response
|
|
1546
1651
|
*/
|
|
1547
|
-
constructor(onProgressUpdated, onHeadersReceived, onDownloadFailed, onRequest, onRetry) {}
|
|
1652
|
+
constructor(onProgressUpdated, onHeadersReceived, onDownloadFailed, onRequest, onRetry, onResponse) {}
|
|
1548
1653
|
/**
|
|
1549
1654
|
* @param {boolean} forceHTTPS
|
|
1550
1655
|
*/
|
|
@@ -1713,6 +1818,19 @@ shaka.net.NetworkingEngine.PluginPriority = {
|
|
|
1713
1818
|
* the player, plus some extra data.
|
|
1714
1819
|
*/
|
|
1715
1820
|
shaka.net.NetworkingEngine.OnHeadersReceived;
|
|
1821
|
+
/**
|
|
1822
|
+
* @typedef {function(
|
|
1823
|
+
* number,
|
|
1824
|
+
* number,
|
|
1825
|
+
* boolean,
|
|
1826
|
+
* shaka.extern.Request=)}
|
|
1827
|
+
* @description
|
|
1828
|
+
* A callback that is passed the duration, in milliseconds,
|
|
1829
|
+
* that the request took, the number of bytes transferred, a boolean
|
|
1830
|
+
* representing whether the switching is allowed and a ref to the
|
|
1831
|
+
* original request.
|
|
1832
|
+
*/
|
|
1833
|
+
shaka.net.NetworkingEngine.onProgressUpdated;
|
|
1716
1834
|
/**
|
|
1717
1835
|
* @typedef {function(
|
|
1718
1836
|
* !shaka.extern.Request,
|
|
@@ -1745,53 +1863,14 @@ shaka.net.NetworkingEngine.OnRequest;
|
|
|
1745
1863
|
*/
|
|
1746
1864
|
shaka.net.NetworkingEngine.OnRetry;
|
|
1747
1865
|
/**
|
|
1748
|
-
* @
|
|
1749
|
-
*
|
|
1866
|
+
* @typedef {function(
|
|
1867
|
+
* !shaka.net.NetworkingEngine.RequestType,
|
|
1868
|
+
* !shaka.extern.Response,
|
|
1869
|
+
* (shaka.extern.RequestContext|undefined))}
|
|
1870
|
+
* @description
|
|
1871
|
+
* A callback function called on every request
|
|
1750
1872
|
*/
|
|
1751
|
-
shaka.
|
|
1752
|
-
/**
|
|
1753
|
-
* Creates a string from the given buffer as UTF-8 encoding.
|
|
1754
|
-
* @param {?BufferSource} data
|
|
1755
|
-
* @return {string}
|
|
1756
|
-
*/
|
|
1757
|
-
static fromUTF8(data) {}
|
|
1758
|
-
/**
|
|
1759
|
-
* Creates a string from the given buffer as UTF-16 encoding.
|
|
1760
|
-
* @param {?BufferSource} data
|
|
1761
|
-
* @param {boolean} littleEndian
|
|
1762
|
-
true to read little endian, false to read big.
|
|
1763
|
-
* @param {boolean=} noThrow true to avoid throwing in cases where we may
|
|
1764
|
-
* expect invalid input. If noThrow is true and the data has an odd
|
|
1765
|
-
* length,it will be truncated.
|
|
1766
|
-
* @return {string}
|
|
1767
|
-
*/
|
|
1768
|
-
static fromUTF16(data, littleEndian, noThrow) {}
|
|
1769
|
-
/**
|
|
1770
|
-
* Creates a string from the given buffer, auto-detecting the encoding that is
|
|
1771
|
-
* being used. If it cannot detect the encoding, it will throw an exception.
|
|
1772
|
-
* @param {?BufferSource} data
|
|
1773
|
-
* @return {string}
|
|
1774
|
-
*/
|
|
1775
|
-
static fromBytesAutoDetect(data) {}
|
|
1776
|
-
/**
|
|
1777
|
-
* Creates a ArrayBuffer from the given string, converting to UTF-8 encoding.
|
|
1778
|
-
* @param {string} str
|
|
1779
|
-
* @return {!ArrayBuffer}
|
|
1780
|
-
*/
|
|
1781
|
-
static toUTF8(str) {}
|
|
1782
|
-
/**
|
|
1783
|
-
* Creates a ArrayBuffer from the given string, converting to UTF-16 encoding.
|
|
1784
|
-
* @param {string} str
|
|
1785
|
-
* @param {boolean} littleEndian
|
|
1786
|
-
* @return {!ArrayBuffer}
|
|
1787
|
-
*/
|
|
1788
|
-
static toUTF16(str, littleEndian) {}
|
|
1789
|
-
/**
|
|
1790
|
-
* Resets the fromCharCode method's implementation.
|
|
1791
|
-
* For debug use.
|
|
1792
|
-
*/
|
|
1793
|
-
static resetFromCharCode() {}
|
|
1794
|
-
};
|
|
1873
|
+
shaka.net.NetworkingEngine.OnResponse;
|
|
1795
1874
|
/**
|
|
1796
1875
|
* @summary DataViewReader abstracts a DataView object.
|
|
1797
1876
|
*/
|
|
@@ -1978,52 +2057,6 @@ shaka.util.Mp4Parser = class {
|
|
|
1978
2057
|
* @typedef {function(!shaka.extern.ParsedBox)}
|
|
1979
2058
|
*/
|
|
1980
2059
|
shaka.util.Mp4Parser.CallbackType;
|
|
1981
|
-
/**
|
|
1982
|
-
* @summary A set of Uint8Array utility functions.
|
|
1983
|
-
*/
|
|
1984
|
-
shaka.util.Uint8ArrayUtils = class {
|
|
1985
|
-
/**
|
|
1986
|
-
* Convert a buffer to a base64 string. The output will be standard
|
|
1987
|
-
* alphabet as opposed to base64url safe alphabet.
|
|
1988
|
-
* @param {BufferSource} data
|
|
1989
|
-
* @return {string}
|
|
1990
|
-
*/
|
|
1991
|
-
static toStandardBase64(data) {}
|
|
1992
|
-
/**
|
|
1993
|
-
* Convert a buffer to a base64 string. The output will always use the
|
|
1994
|
-
* alternate encoding/alphabet also known as "base64url".
|
|
1995
|
-
* @param {BufferSource} data
|
|
1996
|
-
* @param {boolean=} padding If true, pad the output with equals signs.
|
|
1997
|
-
* Defaults to true.
|
|
1998
|
-
* @return {string}
|
|
1999
|
-
*/
|
|
2000
|
-
static toBase64(data, padding) {}
|
|
2001
|
-
/**
|
|
2002
|
-
* Convert a base64 string to a Uint8Array. Accepts either the standard
|
|
2003
|
-
* alphabet or the alternate "base64url" alphabet.
|
|
2004
|
-
* @param {string} str
|
|
2005
|
-
* @return {!Uint8Array}
|
|
2006
|
-
*/
|
|
2007
|
-
static fromBase64(str) {}
|
|
2008
|
-
/**
|
|
2009
|
-
* Convert a hex string to a Uint8Array.
|
|
2010
|
-
* @param {string} str
|
|
2011
|
-
* @return {!Uint8Array}
|
|
2012
|
-
*/
|
|
2013
|
-
static fromHex(str) {}
|
|
2014
|
-
/**
|
|
2015
|
-
* Convert a buffer to a hex string.
|
|
2016
|
-
* @param {BufferSource} data
|
|
2017
|
-
* @return {string}
|
|
2018
|
-
*/
|
|
2019
|
-
static toHex(data) {}
|
|
2020
|
-
/**
|
|
2021
|
-
* Concatenate buffers.
|
|
2022
|
-
* @param {...BufferSource} varArgs
|
|
2023
|
-
* @return {!Uint8Array}
|
|
2024
|
-
*/
|
|
2025
|
-
static concat(...varArgs) {}
|
|
2026
|
-
};
|
|
2027
2060
|
/**
|
|
2028
2061
|
* @summary An interface to register manifest parsers.
|
|
2029
2062
|
*/
|
|
@@ -2072,10 +2105,10 @@ shaka.media.InitSegmentReference = class {
|
|
|
2072
2105
|
* the quality of the media associated with this init segment.
|
|
2073
2106
|
* @param {(null|number)=} timescale
|
|
2074
2107
|
* @param {(null|BufferSource)=} segmentData
|
|
2075
|
-
* @param {?shaka.extern.
|
|
2108
|
+
* @param {?shaka.extern.aesKey=} aesKey
|
|
2076
2109
|
* The segment's AES-128-CBC full segment encryption key and iv.
|
|
2077
2110
|
*/
|
|
2078
|
-
constructor(uris, startByte, endByte, mediaQuality, timescale, segmentData,
|
|
2111
|
+
constructor(uris, startByte, endByte, mediaQuality, timescale, segmentData, aesKey) {}
|
|
2079
2112
|
/**
|
|
2080
2113
|
* Returns the offset from the start of the resource to the
|
|
2081
2114
|
* start of the segment.
|
|
@@ -2148,12 +2181,12 @@ shaka.media.SegmentReference = class {
|
|
|
2148
2181
|
* @param {shaka.media.SegmentReference.Status=} status
|
|
2149
2182
|
* The segment status is used to indicate that a segment does not exist or is
|
|
2150
2183
|
* not available.
|
|
2151
|
-
* @param {?shaka.extern.
|
|
2184
|
+
* @param {?shaka.extern.aesKey=} aesKey
|
|
2152
2185
|
* The segment's AES-128-CBC full segment encryption key and iv.
|
|
2153
2186
|
* @param {boolean=} allPartialSegments
|
|
2154
2187
|
* Indicate if the segment has all partial segments
|
|
2155
2188
|
*/
|
|
2156
|
-
constructor(startTime, endTime, uris, startByte, endByte, initSegmentReference, timestampOffset, appendWindowStart, appendWindowEnd, partialReferences, tilesLayout, tileDuration, syncTime, status,
|
|
2189
|
+
constructor(startTime, endTime, uris, startByte, endByte, initSegmentReference, timestampOffset, appendWindowStart, appendWindowEnd, partialReferences, tilesLayout, tileDuration, syncTime, status, aesKey, allPartialSegments) {}
|
|
2157
2190
|
/**
|
|
2158
2191
|
* Creates and returns the URIs of the resource containing the segment.
|
|
2159
2192
|
* @return {!Array.<string>}
|
|
@@ -2271,6 +2304,16 @@ shaka.media.SegmentReference = class {
|
|
|
2271
2304
|
* @param {number} lowestSyncTime
|
|
2272
2305
|
*/
|
|
2273
2306
|
syncAgainst(lowestSyncTime) {}
|
|
2307
|
+
/**
|
|
2308
|
+
* Set the segment data.
|
|
2309
|
+
* @param {!BufferSource} segmentData
|
|
2310
|
+
*/
|
|
2311
|
+
setSegmentData(segmentData) {}
|
|
2312
|
+
/**
|
|
2313
|
+
* Return the segment data.
|
|
2314
|
+
* @return {?BufferSource}
|
|
2315
|
+
*/
|
|
2316
|
+
getSegmentData() {}
|
|
2274
2317
|
};
|
|
2275
2318
|
/**
|
|
2276
2319
|
* Rather than using booleans to communicate what the state of the reference,
|
|
@@ -2508,6 +2551,11 @@ shaka.media.PresentationTimeline = class {
|
|
|
2508
2551
|
* availability duration in seconds.
|
|
2509
2552
|
*/
|
|
2510
2553
|
setSegmentAvailabilityDuration(segmentAvailabilityDuration) {}
|
|
2554
|
+
/**
|
|
2555
|
+
* Gets the presentation's segment availability duration.
|
|
2556
|
+
* @return {number}
|
|
2557
|
+
*/
|
|
2558
|
+
getSegmentAvailabilityDuration() {}
|
|
2511
2559
|
/**
|
|
2512
2560
|
* Sets the presentation delay in seconds.
|
|
2513
2561
|
* @param {number} delay
|
|
@@ -2673,6 +2721,7 @@ shaka.media.PresentationTimeline = class {
|
|
|
2673
2721
|
shaka.media.PresentationTimeline.TimeRange;
|
|
2674
2722
|
/**
|
|
2675
2723
|
* SegmentIndex.
|
|
2724
|
+
* @implements {shaka.extern.SegmentIndex}
|
|
2676
2725
|
* @implements {shaka.util.IReleasable}
|
|
2677
2726
|
* @implements {Iterable.<!shaka.media.SegmentReference>}
|
|
2678
2727
|
*/
|
|
@@ -2683,6 +2732,14 @@ shaka.media.SegmentIndex = class {
|
|
|
2683
2732
|
* (ascending) and second by their end times (ascending).
|
|
2684
2733
|
*/
|
|
2685
2734
|
constructor(references) {}
|
|
2735
|
+
/**
|
|
2736
|
+
* @override
|
|
2737
|
+
*/
|
|
2738
|
+
getNumReferences() {}
|
|
2739
|
+
/**
|
|
2740
|
+
* @override
|
|
2741
|
+
*/
|
|
2742
|
+
getNumEvicted() {}
|
|
2686
2743
|
/**
|
|
2687
2744
|
* @override
|
|
2688
2745
|
*/
|
|
@@ -2695,20 +2752,11 @@ shaka.media.SegmentIndex = class {
|
|
|
2695
2752
|
*/
|
|
2696
2753
|
markImmutable() {}
|
|
2697
2754
|
/**
|
|
2698
|
-
*
|
|
2699
|
-
* to the start of the presentation. Returns the position of the segment
|
|
2700
|
-
* with the largest end time if more than one segment is known for the given
|
|
2701
|
-
* time.
|
|
2702
|
-
* @param {number} time
|
|
2703
|
-
* @return {?number} The position of the segment, or null if the position of
|
|
2704
|
-
* the segment could not be determined.
|
|
2755
|
+
* @override
|
|
2705
2756
|
*/
|
|
2706
2757
|
find(time) {}
|
|
2707
2758
|
/**
|
|
2708
|
-
*
|
|
2709
|
-
* @param {number} position The position of the segment as returned by find().
|
|
2710
|
-
* @return {shaka.media.SegmentReference} The SegmentReference, or null if
|
|
2711
|
-
* no such SegmentReference exists.
|
|
2759
|
+
* @override
|
|
2712
2760
|
*/
|
|
2713
2761
|
get(position) {}
|
|
2714
2762
|
/**
|
|
@@ -2766,9 +2814,10 @@ shaka.media.SegmentIndex = class {
|
|
|
2766
2814
|
* RFC 8216 rev 13, section 8.1: "Each (non-Partial) Media Segment in a Media
|
|
2767
2815
|
* Playlist will contain at least one independent frame."
|
|
2768
2816
|
* @param {number} time
|
|
2817
|
+
* @param {boolean=} allowNonIndepedent
|
|
2769
2818
|
* @return {?shaka.media.SegmentIterator}
|
|
2770
2819
|
*/
|
|
2771
|
-
getIteratorForTime(time) {}
|
|
2820
|
+
getIteratorForTime(time, allowNonIndepedent) {}
|
|
2772
2821
|
/**
|
|
2773
2822
|
* Create a SegmentIndex for a single segment of the given start time and
|
|
2774
2823
|
* duration at the given URIs.
|
|
@@ -2817,6 +2866,10 @@ shaka.media.MetaSegmentIndex = class extends shaka.media.SegmentIndex {
|
|
|
2817
2866
|
* @override
|
|
2818
2867
|
*/
|
|
2819
2868
|
release() {}
|
|
2869
|
+
/**
|
|
2870
|
+
* @override
|
|
2871
|
+
*/
|
|
2872
|
+
forEachTopLevelReference(fn) {}
|
|
2820
2873
|
/**
|
|
2821
2874
|
* @override
|
|
2822
2875
|
*/
|
|
@@ -2830,36 +2883,198 @@ shaka.media.MetaSegmentIndex = class extends shaka.media.SegmentIndex {
|
|
|
2830
2883
|
*/
|
|
2831
2884
|
offset(offset) {}
|
|
2832
2885
|
/**
|
|
2833
|
-
* @override
|
|
2886
|
+
* @override
|
|
2887
|
+
*/
|
|
2888
|
+
merge(references) {}
|
|
2889
|
+
/**
|
|
2890
|
+
* @override
|
|
2891
|
+
*/
|
|
2892
|
+
evict(time) {}
|
|
2893
|
+
/**
|
|
2894
|
+
* @override
|
|
2895
|
+
*/
|
|
2896
|
+
mergeAndEvict(references, windowStart) {}
|
|
2897
|
+
/**
|
|
2898
|
+
* @override
|
|
2899
|
+
*/
|
|
2900
|
+
fit(windowStart, windowEnd) {}
|
|
2901
|
+
/**
|
|
2902
|
+
* @override
|
|
2903
|
+
*/
|
|
2904
|
+
updateEvery(interval, updateCallback) {}
|
|
2905
|
+
};
|
|
2906
|
+
/**
|
|
2907
|
+
* @typedef {function(
|
|
2908
|
+
* !(shaka.media.InitSegmentReference|shaka.media.SegmentReference),
|
|
2909
|
+
* shaka.extern.Stream,
|
|
2910
|
+
* ?function(BufferSource):!Promise=
|
|
2911
|
+
* ):!shaka.net.NetworkingEngine.PendingRequest}
|
|
2912
|
+
* @description
|
|
2913
|
+
* A callback function that fetches a segment.
|
|
2914
|
+
*/
|
|
2915
|
+
shaka.media.SegmentPrefetch.FetchDispatcher;
|
|
2916
|
+
/** */
|
|
2917
|
+
shaka.util.ConfigUtils = class {
|
|
2918
|
+
/**
|
|
2919
|
+
* @param {!Object} destination
|
|
2920
|
+
* @param {!Object} source
|
|
2921
|
+
* @param {!Object} template supplies default values
|
|
2922
|
+
* @param {!Object} overrides
|
|
2923
|
+
* Supplies override type checking. When the current path matches
|
|
2924
|
+
* the key in this object, each sub-value must match the type in this
|
|
2925
|
+
* object. If this contains an Object, it is used as the template.
|
|
2926
|
+
* @param {string} path to this part of the config
|
|
2927
|
+
* @return {boolean}
|
|
2928
|
+
*/
|
|
2929
|
+
static mergeConfigObjects(destination, source, template, overrides, path) {}
|
|
2930
|
+
/**
|
|
2931
|
+
* Convert config from ('fieldName', value) format to a partial config object.
|
|
2932
|
+
* E. g. from ('manifest.retryParameters.maxAttempts', 1) to
|
|
2933
|
+
* { manifest: { retryParameters: { maxAttempts: 1 }}}.
|
|
2934
|
+
* @param {string} fieldName
|
|
2935
|
+
* @param {*} value
|
|
2936
|
+
* @return {!Object}
|
|
2937
|
+
*/
|
|
2938
|
+
static convertToConfigObject(fieldName, value) {}
|
|
2939
|
+
};
|
|
2940
|
+
/**
|
|
2941
|
+
* @summary A set of FairPlay utility functions.
|
|
2942
|
+
*/
|
|
2943
|
+
shaka.util.FairPlayUtils = class {
|
|
2944
|
+
/**
|
|
2945
|
+
* Check if FairPlay is supported.
|
|
2946
|
+
* @return {!Promise.<boolean>}
|
|
2947
|
+
*/
|
|
2948
|
+
static isFairPlaySupported() {}
|
|
2949
|
+
/**
|
|
2950
|
+
* Using the default method, extract a content ID from the init data. This is
|
|
2951
|
+
* based on the FairPlay example documentation.
|
|
2952
|
+
* @param {!BufferSource} initData
|
|
2953
|
+
* @return {string}
|
|
2954
|
+
*/
|
|
2955
|
+
static defaultGetContentId(initData) {}
|
|
2956
|
+
/**
|
|
2957
|
+
* Transforms the init data buffer using the given data. The format is:
|
|
2958
|
+
* <pre>
|
|
2959
|
+
* [4 bytes] initDataSize
|
|
2960
|
+
* [initDataSize bytes] initData
|
|
2961
|
+
* [4 bytes] contentIdSize
|
|
2962
|
+
* [contentIdSize bytes] contentId
|
|
2963
|
+
* [4 bytes] certSize
|
|
2964
|
+
* [certSize bytes] cert
|
|
2965
|
+
* </pre>
|
|
2966
|
+
* @param {!BufferSource} initData
|
|
2967
|
+
* @param {!BufferSource|string} contentId
|
|
2968
|
+
* @param {?BufferSource} cert The server certificate; this will throw if not
|
|
2969
|
+
* provided.
|
|
2970
|
+
* @return {!Uint8Array}
|
|
2971
|
+
*/
|
|
2972
|
+
static initDataTransform(initData, contentId, cert) {}
|
|
2973
|
+
/**
|
|
2974
|
+
* Verimatrix initDataTransform configuration.
|
|
2975
|
+
* @param {!Uint8Array} initData
|
|
2976
|
+
* @param {string} initDataType
|
|
2977
|
+
* @param {?shaka.extern.DrmInfo} drmInfo
|
|
2978
|
+
*/
|
|
2979
|
+
static verimatrixInitDataTransform(initData, initDataType, drmInfo) {}
|
|
2980
|
+
/**
|
|
2981
|
+
* EZDRM initDataTransform configuration.
|
|
2982
|
+
* @param {!Uint8Array} initData
|
|
2983
|
+
* @param {string} initDataType
|
|
2984
|
+
* @param {?shaka.extern.DrmInfo} drmInfo
|
|
2985
|
+
*/
|
|
2986
|
+
static ezdrmInitDataTransform(initData, initDataType, drmInfo) {}
|
|
2987
|
+
/**
|
|
2988
|
+
* Conax initDataTransform configuration.
|
|
2989
|
+
* @param {!Uint8Array} initData
|
|
2990
|
+
* @param {string} initDataType
|
|
2991
|
+
* @param {?shaka.extern.DrmInfo} drmInfo
|
|
2992
|
+
*/
|
|
2993
|
+
static conaxInitDataTransform(initData, initDataType, drmInfo) {}
|
|
2994
|
+
/**
|
|
2995
|
+
* ExpressPlay initDataTransform configuration.
|
|
2996
|
+
* @param {!Uint8Array} initData
|
|
2997
|
+
* @param {string} initDataType
|
|
2998
|
+
* @param {?shaka.extern.DrmInfo} drmInfo
|
|
2999
|
+
*/
|
|
3000
|
+
static expressplayInitDataTransform(initData, initDataType, drmInfo) {}
|
|
3001
|
+
/**
|
|
3002
|
+
* Verimatrix FairPlay request.
|
|
3003
|
+
* @param {shaka.net.NetworkingEngine.RequestType} type
|
|
3004
|
+
* @param {shaka.extern.Request} request
|
|
3005
|
+
* @param {shaka.extern.RequestContext=} context
|
|
3006
|
+
*/
|
|
3007
|
+
static verimatrixFairPlayRequest(type, request, context) {}
|
|
3008
|
+
/**
|
|
3009
|
+
* EZDRM FairPlay request.
|
|
3010
|
+
* @param {shaka.net.NetworkingEngine.RequestType} type
|
|
3011
|
+
* @param {shaka.extern.Request} request
|
|
3012
|
+
* @param {shaka.extern.RequestContext=} context
|
|
3013
|
+
*/
|
|
3014
|
+
static ezdrmFairPlayRequest(type, request, context) {}
|
|
3015
|
+
/**
|
|
3016
|
+
* Conax FairPlay request.
|
|
3017
|
+
* @param {shaka.net.NetworkingEngine.RequestType} type
|
|
3018
|
+
* @param {shaka.extern.Request} request
|
|
3019
|
+
* @param {shaka.extern.RequestContext=} context
|
|
3020
|
+
*/
|
|
3021
|
+
static conaxFairPlayRequest(type, request, context) {}
|
|
3022
|
+
/**
|
|
3023
|
+
* ExpressPlay FairPlay request.
|
|
3024
|
+
* @param {shaka.net.NetworkingEngine.RequestType} type
|
|
3025
|
+
* @param {shaka.extern.Request} request
|
|
3026
|
+
* @param {shaka.extern.RequestContext=} context
|
|
3027
|
+
*/
|
|
3028
|
+
static expressplayFairPlayRequest(type, request, context) {}
|
|
3029
|
+
/**
|
|
3030
|
+
* Common FairPlay response transform for some DRMs providers.
|
|
3031
|
+
* @param {shaka.net.NetworkingEngine.RequestType} type
|
|
3032
|
+
* @param {shaka.extern.Response} response
|
|
3033
|
+
* @param {shaka.extern.RequestContext=} context
|
|
3034
|
+
*/
|
|
3035
|
+
static commonFairPlayResponse(type, response, context) {}
|
|
3036
|
+
};
|
|
3037
|
+
/**
|
|
3038
|
+
* @final
|
|
3039
|
+
*/
|
|
3040
|
+
shaka.util.PlayerConfiguration = class {
|
|
3041
|
+
/**
|
|
3042
|
+
* @return {shaka.extern.PlayerConfiguration}
|
|
2834
3043
|
*/
|
|
2835
|
-
|
|
3044
|
+
static createDefault() {}
|
|
2836
3045
|
/**
|
|
2837
|
-
*
|
|
3046
|
+
* Merges the given configuration changes into the given destination. This
|
|
3047
|
+
* uses the default Player configurations as the template.
|
|
3048
|
+
* @param {shaka.extern.PlayerConfiguration} destination
|
|
3049
|
+
* @param {!Object} updates
|
|
3050
|
+
* @param {shaka.extern.PlayerConfiguration=} template
|
|
3051
|
+
* @return {boolean}
|
|
2838
3052
|
*/
|
|
2839
|
-
|
|
3053
|
+
static mergeConfigObjects(destination, updates, template) {}
|
|
3054
|
+
};
|
|
3055
|
+
/**
|
|
3056
|
+
* @implements {shaka.util.IDestroyable}
|
|
3057
|
+
*/
|
|
3058
|
+
shaka.media.PreloadManager = class extends shaka.util.FakeEventTarget {
|
|
2840
3059
|
/**
|
|
2841
|
-
* @
|
|
3060
|
+
* @param {string} assetUri
|
|
3061
|
+
* @param {?string} mimeType
|
|
3062
|
+
* @param {number} startTimeOfLoad
|
|
3063
|
+
* @param {?number} startTime
|
|
3064
|
+
* @param {*} playerInterface
|
|
2842
3065
|
*/
|
|
2843
|
-
|
|
3066
|
+
constructor(assetUri, mimeType, startTimeOfLoad, startTime, playerInterface) {}
|
|
2844
3067
|
/**
|
|
2845
|
-
*
|
|
3068
|
+
* Waits for the loading to be finished (or to fail with an error).
|
|
3069
|
+
* @return {!Promise}
|
|
2846
3070
|
*/
|
|
2847
|
-
|
|
3071
|
+
waitForFinish() {}
|
|
2848
3072
|
/**
|
|
3073
|
+
* Releases or stops all non-entrusted resources.
|
|
2849
3074
|
* @override
|
|
2850
3075
|
*/
|
|
2851
|
-
|
|
3076
|
+
destroy() {}
|
|
2852
3077
|
};
|
|
2853
|
-
/**
|
|
2854
|
-
* @typedef {function(
|
|
2855
|
-
* !(shaka.media.InitSegmentReference|shaka.media.SegmentReference),
|
|
2856
|
-
* shaka.extern.Stream,
|
|
2857
|
-
* ?function(BufferSource):!Promise=
|
|
2858
|
-
* ):!shaka.net.NetworkingEngine.PendingRequest}
|
|
2859
|
-
* @description
|
|
2860
|
-
* A callback function that fetches a segment.
|
|
2861
|
-
*/
|
|
2862
|
-
shaka.media.SegmentPrefetch.FetchDispatcher;
|
|
2863
3078
|
/**
|
|
2864
3079
|
* A text displayer plugin using the browser's native VTTCue interface.
|
|
2865
3080
|
* @implements {shaka.extern.TextDisplayer}
|
|
@@ -2870,6 +3085,10 @@ shaka.text.SimpleTextDisplayer = class {
|
|
|
2870
3085
|
* @param {string} label
|
|
2871
3086
|
*/
|
|
2872
3087
|
constructor(video, label) {}
|
|
3088
|
+
/**
|
|
3089
|
+
* @override
|
|
3090
|
+
*/
|
|
3091
|
+
configure(config) {}
|
|
2873
3092
|
/**
|
|
2874
3093
|
* @override
|
|
2875
3094
|
*/
|
|
@@ -2896,6 +3115,10 @@ shaka.text.SimpleTextDisplayer = class {
|
|
|
2896
3115
|
* @implements {shaka.extern.TextDisplayer}
|
|
2897
3116
|
*/
|
|
2898
3117
|
shaka.text.StubTextDisplayer = class {
|
|
3118
|
+
/**
|
|
3119
|
+
* @override
|
|
3120
|
+
*/
|
|
3121
|
+
configure(config) {}
|
|
2899
3122
|
/**
|
|
2900
3123
|
* @override
|
|
2901
3124
|
*/
|
|
@@ -2936,8 +3159,13 @@ shaka.text.UITextDisplayer = class {
|
|
|
2936
3159
|
* Constructor.
|
|
2937
3160
|
* @param {HTMLMediaElement} video
|
|
2938
3161
|
* @param {HTMLElement} videoContainer
|
|
3162
|
+
* @param {shaka.extern.TextDisplayerConfiguration} config
|
|
3163
|
+
*/
|
|
3164
|
+
constructor(video, videoContainer, config) {}
|
|
3165
|
+
/**
|
|
3166
|
+
* @override
|
|
2939
3167
|
*/
|
|
2940
|
-
|
|
3168
|
+
configure(config) {}
|
|
2941
3169
|
/**
|
|
2942
3170
|
* @override
|
|
2943
3171
|
*/
|
|
@@ -3014,145 +3242,6 @@ shaka.util.CmsdManager = class {
|
|
|
3014
3242
|
*/
|
|
3015
3243
|
getBandwidthEstimate(defaultEstimate) {}
|
|
3016
3244
|
};
|
|
3017
|
-
/** */
|
|
3018
|
-
shaka.util.ConfigUtils = class {
|
|
3019
|
-
/**
|
|
3020
|
-
* @param {!Object} destination
|
|
3021
|
-
* @param {!Object} source
|
|
3022
|
-
* @param {!Object} template supplies default values
|
|
3023
|
-
* @param {!Object} overrides
|
|
3024
|
-
* Supplies override type checking. When the current path matches
|
|
3025
|
-
* the key in this object, each sub-value must match the type in this
|
|
3026
|
-
* object. If this contains an Object, it is used as the template.
|
|
3027
|
-
* @param {string} path to this part of the config
|
|
3028
|
-
* @return {boolean}
|
|
3029
|
-
*/
|
|
3030
|
-
static mergeConfigObjects(destination, source, template, overrides, path) {}
|
|
3031
|
-
/**
|
|
3032
|
-
* Convert config from ('fieldName', value) format to a partial config object.
|
|
3033
|
-
* E. g. from ('manifest.retryParameters.maxAttempts', 1) to
|
|
3034
|
-
* { manifest: { retryParameters: { maxAttempts: 1 }}}.
|
|
3035
|
-
* @param {string} fieldName
|
|
3036
|
-
* @param {*} value
|
|
3037
|
-
* @return {!Object}
|
|
3038
|
-
*/
|
|
3039
|
-
static convertToConfigObject(fieldName, value) {}
|
|
3040
|
-
};
|
|
3041
|
-
/**
|
|
3042
|
-
* @summary A set of FairPlay utility functions.
|
|
3043
|
-
*/
|
|
3044
|
-
shaka.util.FairPlayUtils = class {
|
|
3045
|
-
/**
|
|
3046
|
-
* Check if FairPlay is supported.
|
|
3047
|
-
* @return {!Promise.<boolean>}
|
|
3048
|
-
*/
|
|
3049
|
-
static isFairPlaySupported() {}
|
|
3050
|
-
/**
|
|
3051
|
-
* Using the default method, extract a content ID from the init data. This is
|
|
3052
|
-
* based on the FairPlay example documentation.
|
|
3053
|
-
* @param {!BufferSource} initData
|
|
3054
|
-
* @return {string}
|
|
3055
|
-
*/
|
|
3056
|
-
static defaultGetContentId(initData) {}
|
|
3057
|
-
/**
|
|
3058
|
-
* Transforms the init data buffer using the given data. The format is:
|
|
3059
|
-
* <pre>
|
|
3060
|
-
* [4 bytes] initDataSize
|
|
3061
|
-
* [initDataSize bytes] initData
|
|
3062
|
-
* [4 bytes] contentIdSize
|
|
3063
|
-
* [contentIdSize bytes] contentId
|
|
3064
|
-
* [4 bytes] certSize
|
|
3065
|
-
* [certSize bytes] cert
|
|
3066
|
-
* </pre>
|
|
3067
|
-
* @param {!BufferSource} initData
|
|
3068
|
-
* @param {!BufferSource|string} contentId
|
|
3069
|
-
* @param {?BufferSource} cert The server certificate; this will throw if not
|
|
3070
|
-
* provided.
|
|
3071
|
-
* @return {!Uint8Array}
|
|
3072
|
-
*/
|
|
3073
|
-
static initDataTransform(initData, contentId, cert) {}
|
|
3074
|
-
/**
|
|
3075
|
-
* Verimatrix initDataTransform configuration.
|
|
3076
|
-
* @param {!Uint8Array} initData
|
|
3077
|
-
* @param {string} initDataType
|
|
3078
|
-
* @param {?shaka.extern.DrmInfo} drmInfo
|
|
3079
|
-
*/
|
|
3080
|
-
static verimatrixInitDataTransform(initData, initDataType, drmInfo) {}
|
|
3081
|
-
/**
|
|
3082
|
-
* EZDRM initDataTransform configuration.
|
|
3083
|
-
* @param {!Uint8Array} initData
|
|
3084
|
-
* @param {string} initDataType
|
|
3085
|
-
* @param {?shaka.extern.DrmInfo} drmInfo
|
|
3086
|
-
*/
|
|
3087
|
-
static ezdrmInitDataTransform(initData, initDataType, drmInfo) {}
|
|
3088
|
-
/**
|
|
3089
|
-
* Conax initDataTransform configuration.
|
|
3090
|
-
* @param {!Uint8Array} initData
|
|
3091
|
-
* @param {string} initDataType
|
|
3092
|
-
* @param {?shaka.extern.DrmInfo} drmInfo
|
|
3093
|
-
*/
|
|
3094
|
-
static conaxInitDataTransform(initData, initDataType, drmInfo) {}
|
|
3095
|
-
/**
|
|
3096
|
-
* ExpressPlay initDataTransform configuration.
|
|
3097
|
-
* @param {!Uint8Array} initData
|
|
3098
|
-
* @param {string} initDataType
|
|
3099
|
-
* @param {?shaka.extern.DrmInfo} drmInfo
|
|
3100
|
-
*/
|
|
3101
|
-
static expressplayInitDataTransform(initData, initDataType, drmInfo) {}
|
|
3102
|
-
/**
|
|
3103
|
-
* Verimatrix FairPlay request.
|
|
3104
|
-
* @param {shaka.net.NetworkingEngine.RequestType} type
|
|
3105
|
-
* @param {shaka.extern.Request} request
|
|
3106
|
-
* @param {shaka.extern.RequestContext=} context
|
|
3107
|
-
*/
|
|
3108
|
-
static verimatrixFairPlayRequest(type, request, context) {}
|
|
3109
|
-
/**
|
|
3110
|
-
* EZDRM FairPlay request.
|
|
3111
|
-
* @param {shaka.net.NetworkingEngine.RequestType} type
|
|
3112
|
-
* @param {shaka.extern.Request} request
|
|
3113
|
-
* @param {shaka.extern.RequestContext=} context
|
|
3114
|
-
*/
|
|
3115
|
-
static ezdrmFairPlayRequest(type, request, context) {}
|
|
3116
|
-
/**
|
|
3117
|
-
* Conax FairPlay request.
|
|
3118
|
-
* @param {shaka.net.NetworkingEngine.RequestType} type
|
|
3119
|
-
* @param {shaka.extern.Request} request
|
|
3120
|
-
* @param {shaka.extern.RequestContext=} context
|
|
3121
|
-
*/
|
|
3122
|
-
static conaxFairPlayRequest(type, request, context) {}
|
|
3123
|
-
/**
|
|
3124
|
-
* ExpressPlay FairPlay request.
|
|
3125
|
-
* @param {shaka.net.NetworkingEngine.RequestType} type
|
|
3126
|
-
* @param {shaka.extern.Request} request
|
|
3127
|
-
* @param {shaka.extern.RequestContext=} context
|
|
3128
|
-
*/
|
|
3129
|
-
static expressplayFairPlayRequest(type, request, context) {}
|
|
3130
|
-
/**
|
|
3131
|
-
* Common FairPlay response transform for some DRMs providers.
|
|
3132
|
-
* @param {shaka.net.NetworkingEngine.RequestType} type
|
|
3133
|
-
* @param {shaka.extern.Response} response
|
|
3134
|
-
* @param {shaka.extern.RequestContext=} context
|
|
3135
|
-
*/
|
|
3136
|
-
static commonFairPlayResponse(type, response, context) {}
|
|
3137
|
-
};
|
|
3138
|
-
/**
|
|
3139
|
-
* @final
|
|
3140
|
-
*/
|
|
3141
|
-
shaka.util.PlayerConfiguration = class {
|
|
3142
|
-
/**
|
|
3143
|
-
* @return {shaka.extern.PlayerConfiguration}
|
|
3144
|
-
*/
|
|
3145
|
-
static createDefault() {}
|
|
3146
|
-
/**
|
|
3147
|
-
* Merges the given configuration changes into the given destination. This
|
|
3148
|
-
* uses the default Player configurations as the template.
|
|
3149
|
-
* @param {shaka.extern.PlayerConfiguration} destination
|
|
3150
|
-
* @param {!Object} updates
|
|
3151
|
-
* @param {shaka.extern.PlayerConfiguration=} template
|
|
3152
|
-
* @return {boolean}
|
|
3153
|
-
*/
|
|
3154
|
-
static mergeConfigObjects(destination, updates, template) {}
|
|
3155
|
-
};
|
|
3156
3245
|
/**
|
|
3157
3246
|
* @summary The main player object for Shaka Player.
|
|
3158
3247
|
* @implements {shaka.util.IDestroyable}
|
|
@@ -3245,7 +3334,7 @@ shaka.Player = class extends shaka.util.FakeEventTarget {
|
|
|
3245
3334
|
/**
|
|
3246
3335
|
* Loads a new stream.
|
|
3247
3336
|
* If another stream was already playing, first unloads that stream.
|
|
3248
|
-
* @param {string}
|
|
3337
|
+
* @param {string|shaka.media.PreloadManager} assetUriOrPreloader
|
|
3249
3338
|
* @param {?number=} startTime
|
|
3250
3339
|
* When <code>startTime</code> is <code>null</code> or
|
|
3251
3340
|
* <code>undefined</code>, playback will start at the default start time (0
|
|
@@ -3253,7 +3342,39 @@ shaka.Player = class extends shaka.util.FakeEventTarget {
|
|
|
3253
3342
|
* @param {?string=} mimeType
|
|
3254
3343
|
* @return {!Promise}
|
|
3255
3344
|
*/
|
|
3256
|
-
load(
|
|
3345
|
+
load(assetUriOrPreloader, startTime, mimeType) {}
|
|
3346
|
+
/**
|
|
3347
|
+
* Unloads the currently playing stream, if any, and returns a PreloadManager
|
|
3348
|
+
* that contains the loaded manifest of that asset, if any.
|
|
3349
|
+
* Allows for the asset to be re-loaded by this player faster, in the future.
|
|
3350
|
+
* When in src= mode, this unloads but does not make a PreloadManager.
|
|
3351
|
+
* @param {boolean=} initializeMediaSource
|
|
3352
|
+
* @param {boolean=} keepAdManager
|
|
3353
|
+
* @return {!Promise.<?shaka.media.PreloadManager>}
|
|
3354
|
+
*/
|
|
3355
|
+
unloadAndSavePreload(initializeMediaSource, keepAdManager) {}
|
|
3356
|
+
/**
|
|
3357
|
+
* Starts to preload a given asset, and returns a PreloadManager object that
|
|
3358
|
+
* represents that preloading process.
|
|
3359
|
+
* The PreloadManager will load the manifest for that asset, as well as the
|
|
3360
|
+
* initialization segment. It will not preload anything more than that;
|
|
3361
|
+
* this feature is intended for reducing start-time latency, not for fully
|
|
3362
|
+
* downloading assets before playing them (for that, use
|
|
3363
|
+
* |shaka.offline.Storage|).
|
|
3364
|
+
* You can pass that PreloadManager object in to the |load| method on this
|
|
3365
|
+
* Player instance to finish loading that particular asset, or you can call
|
|
3366
|
+
* the |destroy| method on the manager if the preload is no longer necessary.
|
|
3367
|
+
* If this returns null rather than a PreloadManager, that indicates that the
|
|
3368
|
+
* asset must be played with src=, which cannot be preloaded.
|
|
3369
|
+
* @param {string} assetUri
|
|
3370
|
+
* @param {?number=} startTime
|
|
3371
|
+
* When <code>startTime</code> is <code>null</code> or
|
|
3372
|
+
* <code>undefined</code>, playback will start at the default start time (0
|
|
3373
|
+
* for VOD and liveEdge for LIVE).
|
|
3374
|
+
* @param {?string=} mimeType
|
|
3375
|
+
* @return {!Promise.<?shaka.media.PreloadManager>}
|
|
3376
|
+
*/
|
|
3377
|
+
preload(assetUri, startTime, mimeType) {}
|
|
3257
3378
|
/**
|
|
3258
3379
|
* Releases all of the mutexes of the player. Meant for use by the tests.
|
|
3259
3380
|
*/
|
|
@@ -3584,19 +3705,22 @@ shaka.Player = class extends shaka.util.FakeEventTarget {
|
|
|
3584
3705
|
*/
|
|
3585
3706
|
setTextTrackVisibility(isVisible) {}
|
|
3586
3707
|
/**
|
|
3587
|
-
* Get the current playhead position as a date.
|
|
3588
|
-
* when the player has loaded a live stream. If the player has not loaded a
|
|
3589
|
-
* live stream, this will return <code>null</code>.
|
|
3708
|
+
* Get the current playhead position as a date.
|
|
3590
3709
|
* @return {Date}
|
|
3591
3710
|
*/
|
|
3592
3711
|
getPlayheadTimeAsDate() {}
|
|
3593
3712
|
/**
|
|
3594
|
-
* Get the presentation start time as a date.
|
|
3595
|
-
* the player has loaded a live stream. If the player has not loaded a live
|
|
3596
|
-
* stream, this will return <code>null</code>.
|
|
3713
|
+
* Get the presentation start time as a date.
|
|
3597
3714
|
* @return {Date}
|
|
3598
3715
|
*/
|
|
3599
3716
|
getPresentationStartTimeAsDate() {}
|
|
3717
|
+
/**
|
|
3718
|
+
* Get the presentation segment availability duration. This should only be
|
|
3719
|
+
* called when the player has loaded a live stream. If the player has not
|
|
3720
|
+
* loaded a live stream, this will return <code>null</code>.
|
|
3721
|
+
* @return {?number}
|
|
3722
|
+
*/
|
|
3723
|
+
getSegmentAvailabilityDuration() {}
|
|
3600
3724
|
/**
|
|
3601
3725
|
* Get information about what the player has buffered. If the player has not
|
|
3602
3726
|
* loaded content or is currently loading content, the buffered content will
|
|
@@ -3648,8 +3772,6 @@ shaka.Player = class extends shaka.util.FakeEventTarget {
|
|
|
3648
3772
|
addChaptersTrack(uri, language, mimeType) {}
|
|
3649
3773
|
/**
|
|
3650
3774
|
* Set the maximum resolution that the platform's hardware can handle.
|
|
3651
|
-
* This will be called automatically by <code>shaka.cast.CastReceiver</code>
|
|
3652
|
-
* to enforce limitations of the Chromecast hardware.
|
|
3653
3775
|
* @param {number} width
|
|
3654
3776
|
* @param {number} height
|
|
3655
3777
|
*/
|
|
@@ -4153,6 +4275,11 @@ shaka.ads.AdManager = class extends shaka.util.FakeEventTarget {
|
|
|
4153
4275
|
* @override
|
|
4154
4276
|
*/
|
|
4155
4277
|
requestMediaTailorStream(url, adsParams, backupUrl) {}
|
|
4278
|
+
/**
|
|
4279
|
+
* @param {string} url
|
|
4280
|
+
* @override
|
|
4281
|
+
*/
|
|
4282
|
+
addMediaTailorTrackingUrl(url) {}
|
|
4156
4283
|
/**
|
|
4157
4284
|
* @override
|
|
4158
4285
|
*/
|
|
@@ -4558,6 +4685,16 @@ shaka.util.PeriodCombiner = class {
|
|
|
4558
4685
|
* @return {!Promise}
|
|
4559
4686
|
*/
|
|
4560
4687
|
combinePeriods(periods, isDynamic) {}
|
|
4688
|
+
/**
|
|
4689
|
+
* @param {boolean} allowed If set to true, multi-mimeType or multi-codec
|
|
4690
|
+
* variants will be allowed.
|
|
4691
|
+
*/
|
|
4692
|
+
setAllowMultiTypeVariants(allowed) {}
|
|
4693
|
+
/**
|
|
4694
|
+
* @param {boolean} useOnce if true, stream will be used only once in period
|
|
4695
|
+
* flattening algoritnm.
|
|
4696
|
+
*/
|
|
4697
|
+
setUseStreamOnce(useOnce) {}
|
|
4561
4698
|
};
|
|
4562
4699
|
/**
|
|
4563
4700
|
* Creates a new DASH parser.
|
|
@@ -5771,9 +5908,10 @@ shaka.ui.Controls = class extends shaka.util.FakeEventTarget {
|
|
|
5771
5908
|
* @param {!shaka.Player} player
|
|
5772
5909
|
* @param {!HTMLElement} videoContainer
|
|
5773
5910
|
* @param {!HTMLMediaElement} video
|
|
5911
|
+
* @param {?HTMLCanvasElement} vrCanvas
|
|
5774
5912
|
* @param {shaka.extern.UIConfiguration} config
|
|
5775
5913
|
*/
|
|
5776
|
-
constructor(player, videoContainer, video, config) {}
|
|
5914
|
+
constructor(player, videoContainer, video, vrCanvas, config) {}
|
|
5777
5915
|
/**
|
|
5778
5916
|
* @override
|
|
5779
5917
|
*/
|
|
@@ -5916,6 +6054,60 @@ shaka.ui.Controls = class extends shaka.util.FakeEventTarget {
|
|
|
5916
6054
|
* @return {boolean}
|
|
5917
6055
|
*/
|
|
5918
6056
|
isOpaque() {}
|
|
6057
|
+
/**
|
|
6058
|
+
*/
|
|
6059
|
+
showUI() {}
|
|
6060
|
+
/**
|
|
6061
|
+
*/
|
|
6062
|
+
hideUI() {}
|
|
6063
|
+
/**
|
|
6064
|
+
* Returns if a VR is capable.
|
|
6065
|
+
* @return {boolean}
|
|
6066
|
+
*/
|
|
6067
|
+
canPlayVR() {}
|
|
6068
|
+
/**
|
|
6069
|
+
* Returns if a VR is supported.
|
|
6070
|
+
* @return {boolean}
|
|
6071
|
+
*/
|
|
6072
|
+
isPlayingVR() {}
|
|
6073
|
+
/**
|
|
6074
|
+
* Get the angle of the north.
|
|
6075
|
+
* @return {?number}
|
|
6076
|
+
*/
|
|
6077
|
+
getVRNorth() {}
|
|
6078
|
+
/**
|
|
6079
|
+
* Returns the angle of the current field of view displayed in degrees.
|
|
6080
|
+
* @return {?number}
|
|
6081
|
+
*/
|
|
6082
|
+
getVRFieldOfView() {}
|
|
6083
|
+
/**
|
|
6084
|
+
* Changing the field of view increases or decreases the portion of the video
|
|
6085
|
+
* that is viewed at one time. If the field of view is decreased, a small
|
|
6086
|
+
* part of the video will be seen, but with more detail. If the field of view
|
|
6087
|
+
* is increased, a larger part of the video will be seen, but with less
|
|
6088
|
+
* detail.
|
|
6089
|
+
* @param {number} fieldOfView In degrees
|
|
6090
|
+
*/
|
|
6091
|
+
setVRFieldOfView(fieldOfView) {}
|
|
6092
|
+
/**
|
|
6093
|
+
* Toggle stereoscopic mode.
|
|
6094
|
+
*/
|
|
6095
|
+
toggleStereoscopicMode() {}
|
|
6096
|
+
/**
|
|
6097
|
+
* Increment the yaw in X angle in degrees.
|
|
6098
|
+
* @param {number} angle In degrees
|
|
6099
|
+
*/
|
|
6100
|
+
incrementYaw(angle) {}
|
|
6101
|
+
/**
|
|
6102
|
+
* Increment the pitch in X angle in degrees.
|
|
6103
|
+
* @param {number} angle In degrees
|
|
6104
|
+
*/
|
|
6105
|
+
incrementPitch(angle) {}
|
|
6106
|
+
/**
|
|
6107
|
+
* Increment the roll in X angle in degrees.
|
|
6108
|
+
* @param {number} angle In degrees
|
|
6109
|
+
*/
|
|
6110
|
+
incrementRoll(angle) {}
|
|
5919
6111
|
};
|
|
5920
6112
|
/**
|
|
5921
6113
|
* @extends {shaka.ui.Element}
|
|
@@ -5952,8 +6144,9 @@ shaka.ui.Overlay = class {
|
|
|
5952
6144
|
* @param {!shaka.Player} player
|
|
5953
6145
|
* @param {!HTMLElement} videoContainer
|
|
5954
6146
|
* @param {!HTMLMediaElement} video
|
|
6147
|
+
* @param {?HTMLCanvasElement=} vrCanvas
|
|
5955
6148
|
*/
|
|
5956
|
-
constructor(player, videoContainer, video) {}
|
|
6149
|
+
constructor(player, videoContainer, video, vrCanvas) {}
|
|
5957
6150
|
/**
|
|
5958
6151
|
* @override
|
|
5959
6152
|
*/
|
|
@@ -6116,6 +6309,17 @@ shaka.ui.PresentationTimeTracker = class extends shaka.ui.Element {
|
|
|
6116
6309
|
*/
|
|
6117
6310
|
constructor(parent, controls) {}
|
|
6118
6311
|
};
|
|
6312
|
+
/**
|
|
6313
|
+
* @extends {shaka.ui.Element}
|
|
6314
|
+
* @final
|
|
6315
|
+
*/
|
|
6316
|
+
shaka.ui.RecenterVRButton = class extends shaka.ui.Element {
|
|
6317
|
+
/**
|
|
6318
|
+
* @param {!HTMLElement} parent
|
|
6319
|
+
* @param {!shaka.ui.Controls} controls
|
|
6320
|
+
*/
|
|
6321
|
+
constructor(parent, controls) {}
|
|
6322
|
+
};
|
|
6119
6323
|
/**
|
|
6120
6324
|
* @extends {shaka.ui.Element}
|
|
6121
6325
|
* @final
|
|
@@ -6204,6 +6408,17 @@ shaka.ui.TextSelection = class extends shaka.ui.SettingsMenu {
|
|
|
6204
6408
|
*/
|
|
6205
6409
|
constructor(parent, controls) {}
|
|
6206
6410
|
};
|
|
6411
|
+
/**
|
|
6412
|
+
* @extends {shaka.ui.Element}
|
|
6413
|
+
* @final
|
|
6414
|
+
*/
|
|
6415
|
+
shaka.ui.ToggleStereoscopicButton = class extends shaka.ui.Element {
|
|
6416
|
+
/**
|
|
6417
|
+
* @param {!HTMLElement} parent
|
|
6418
|
+
* @param {!shaka.ui.Controls} controls
|
|
6419
|
+
*/
|
|
6420
|
+
constructor(parent, controls) {}
|
|
6421
|
+
};
|
|
6207
6422
|
/**
|
|
6208
6423
|
* @extends {shaka.ui.RangeElement}
|
|
6209
6424
|
* @final
|