shaka-player 3.3.5 → 4.0.2
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/.github/config.yml +1 -0
- package/.github/workflows/demo-version-index.yaml +8 -0
- package/.github/workflows/release-please.yaml +18 -2
- package/.github/workflows/sync-labels.yaml +33 -0
- package/.github/workflows/update-issues.yaml +29 -0
- package/.github/workflows/validate-pr-title.yaml +35 -0
- package/AUTHORS +1 -0
- package/CHANGELOG.md +215 -41
- package/CONTRIBUTORS +1 -0
- package/README.md +14 -11
- package/app-engine/demo-version-index/README.md +3 -3
- package/app-engine/demo-version-index/app.yaml +27 -1
- package/app-engine/demo-version-index/generate.py +164 -0
- package/app-engine/demo-version-index/main.py +4 -155
- package/app-engine/demo-version-index/requirements.txt +0 -1
- package/build/checkversion.py +1 -1
- package/build/compiler.py +1 -1
- package/build/misspellings.txt +1 -0
- package/build/shaka-lab.yaml +0 -2
- package/build/types/polyfill +0 -3
- package/demo/common/asset.js +17 -1
- package/demo/common/assets.js +29 -0
- package/demo/common/message_ids.js +6 -3
- package/demo/config.js +10 -11
- package/demo/custom.js +39 -0
- package/demo/demo.less +0 -1
- package/demo/demo_utils.js +0 -1
- package/demo/locales/en.json +6 -3
- package/demo/locales/source.json +22 -10
- package/demo/main.js +9 -6
- package/demo/search.js +2 -1
- package/dist/controls.css +3 -3
- package/dist/controls.css.map +1 -1
- package/dist/demo.compiled.debug.js +71 -64
- package/dist/demo.compiled.debug.map +3 -3
- package/dist/demo.compiled.js +71 -64
- package/dist/demo.compiled.map +3 -3
- package/dist/demo.css +1 -1
- package/dist/demo.css.map +1 -1
- package/dist/deps.js +17 -20
- package/dist/locales.js +33 -31
- package/dist/receiver.compiled.debug.js +32 -28
- package/dist/receiver.compiled.debug.map +3 -3
- package/dist/receiver.compiled.js +32 -28
- package/dist/receiver.compiled.map +3 -3
- package/dist/shaka-player.compiled.d.ts +311 -314
- package/dist/shaka-player.compiled.debug.d.ts +311 -314
- package/dist/shaka-player.compiled.debug.externs.js +126 -126
- package/dist/shaka-player.compiled.debug.js +430 -484
- package/dist/shaka-player.compiled.debug.map +4 -4
- package/dist/shaka-player.compiled.externs.js +126 -126
- package/dist/shaka-player.compiled.js +829 -845
- package/dist/shaka-player.compiled.map +4 -4
- package/dist/shaka-player.ui.d.ts +357 -358
- package/dist/shaka-player.ui.debug.d.ts +357 -358
- package/dist/shaka-player.ui.debug.externs.js +134 -126
- package/dist/shaka-player.ui.debug.js +489 -541
- package/dist/shaka-player.ui.debug.map +4 -4
- package/dist/shaka-player.ui.externs.js +134 -126
- package/dist/shaka-player.ui.js +988 -1000
- package/dist/shaka-player.ui.map +4 -4
- package/docs/tutorials/config.md +0 -2
- package/docs/tutorials/drm-config.md +5 -0
- package/docs/tutorials/fairplay.md +7 -22
- package/docs/tutorials/faq.md +0 -11
- package/docs/tutorials/index.json +2 -8
- package/docs/tutorials/plugins.md +1 -3
- package/docs/tutorials/upgrade.md +85 -11
- package/externs/polyfill.js +15 -0
- package/externs/shaka/manifest.js +5 -1
- package/externs/shaka/net.js +12 -0
- package/externs/shaka/offline.js +5 -1
- package/externs/shaka/player.js +39 -21
- package/externs/shaka/text.js +12 -12
- package/externs/sourcebuffer.js +15 -0
- package/lib/abr/simple_abr_manager.js +2 -1
- package/lib/ads/client_side_ad.js +13 -2
- package/lib/ads/client_side_ad_manager.js +22 -4
- package/lib/cast/cast_utils.js +0 -1
- package/lib/dash/content_protection.js +85 -5
- package/lib/dash/dash_parser.js +1 -0
- package/lib/hls/hls_parser.js +390 -747
- package/lib/hls/manifest_text_parser.js +2 -3
- package/lib/media/drm_engine.js +105 -37
- package/lib/media/gap_jumping_controller.js +10 -45
- package/lib/media/media_source_engine.js +150 -30
- package/lib/media/playhead.js +2 -5
- package/lib/media/presentation_timeline.js +1 -2
- package/lib/media/segment_index.js +13 -46
- package/lib/media/segment_reference.js +47 -1
- package/lib/media/streaming_engine.js +28 -11
- package/lib/media/time_ranges_utils.js +4 -9
- package/lib/net/networking_engine.js +3 -0
- package/lib/offline/indexeddb/v1_storage_cell.js +1 -0
- package/lib/offline/indexeddb/v2_storage_cell.js +1 -0
- package/lib/offline/manifest_converter.js +1 -0
- package/lib/offline/storage.js +8 -41
- package/lib/player.js +17 -201
- package/lib/polyfill/media_capabilities.js +12 -6
- package/lib/polyfill/mediasource.js +0 -28
- package/lib/polyfill/patchedmediakeys_nop.js +2 -0
- package/lib/polyfill/patchedmediakeys_webkit.js +2 -0
- package/lib/text/cue.js +0 -6
- package/lib/text/lrc_text_parser.js +8 -0
- package/lib/text/mp4_ttml_parser.js +8 -0
- package/lib/text/mp4_vtt_parser.js +8 -0
- package/lib/text/sbv_text_parser.js +8 -0
- package/lib/text/simple_text_displayer.js +1 -7
- package/lib/text/srt_text_parser.js +8 -0
- package/lib/text/ssa_text_parser.js +8 -0
- package/lib/text/text_engine.js +19 -3
- package/lib/text/ttml_text_parser.js +8 -0
- package/lib/text/ui_text_displayer.js +1 -7
- package/lib/text/vtt_text_parser.js +27 -5
- package/lib/text/web_vtt_generator.js +1 -7
- package/lib/util/error.js +9 -13
- package/lib/util/fairplay_utils.js +109 -0
- package/lib/util/functional.js +0 -42
- package/lib/util/mime_utils.js +16 -5
- package/lib/util/platform.js +45 -0
- package/lib/util/player_configuration.js +17 -6
- package/lib/util/pssh.js +23 -4
- package/lib/util/stream_utils.js +92 -22
- package/lib/util/uint8array_utils.js +0 -16
- package/lib/util/xml_utils.js +1 -1
- package/package.json +5 -2
- package/roadmap.md +19 -19
- package/shaka-player.uncompiled.js +0 -3
- package/test/dash/dash_parser_content_protection_unit.js +44 -0
- package/test/dash/dash_parser_segment_template_unit.js +3 -4
- package/test/demo/demo_unit.js +2 -1
- package/test/hls/hls_live_unit.js +155 -230
- package/test/hls/hls_parser_unit.js +515 -432
- package/test/media/drm_engine_unit.js +86 -120
- package/test/media/media_source_engine_integration.js +25 -3
- package/test/media/media_source_engine_unit.js +3 -2
- package/test/media/playhead_unit.js +27 -191
- package/test/media/segment_index_unit.js +15 -25
- package/test/media/streaming_engine_integration.js +2 -39
- package/test/media/streaming_engine_unit.js +3 -2
- package/test/media/time_ranges_utils_unit.js +0 -5
- package/test/offline/manifest_convert_unit.js +34 -4
- package/test/offline/offline_manifest_parser_unit.js +1 -0
- package/test/offline/storage_integration.js +5 -4
- package/test/player_external.js +0 -6
- package/test/player_integration.js +16 -0
- package/test/player_unit.js +26 -0
- package/test/test/util/fake_media_source_engine.js +11 -4
- package/test/test/util/manifest_generator.js +3 -1
- package/test/test/util/manifest_parser_util.js +4 -1
- package/test/test/util/offline_utils.js +1 -0
- package/test/test/util/streaming_engine_util.js +1 -0
- package/test/test/util/test_scheme.js +24 -1
- package/test/test/util/util.js +4 -4
- package/test/text/cue_integration.js +2 -2
- package/test/text/lrc_text_parser_unit.js +6 -7
- package/test/text/mp4_ttml_parser_unit.js +6 -4
- package/test/text/mp4_vtt_parser_unit.js +6 -5
- package/test/text/sbv_text_parser_unit.js +5 -6
- package/test/text/srt_text_parser_unit.js +5 -6
- package/test/text/ssa_text_parser_unit.js +17 -29
- package/test/text/text_engine_unit.js +45 -5
- package/test/text/ttml_text_parser_unit.js +77 -77
- package/test/text/vtt_text_parser_unit.js +116 -59
- package/test/ui/ui_integration.js +0 -16
- package/test/ui/ui_unit.js +27 -0
- package/test/util/cmcd_manager_unit.js +3 -0
- package/test/util/stream_utils_unit.js +23 -7
- package/ui/controls.js +65 -40
- package/ui/fullscreen_button.js +26 -6
- package/ui/less/containers.less +4 -4
- package/ui/less/general.less +1 -1
- package/ui/less/range_elements.less +1 -0
- package/ui/locales/en.json +1 -0
- package/ui/locales/source.json +5 -0
- package/ui/resolution_selection.js +31 -33
- package/ui/ui.js +0 -17
- package/.github/pull_request_template.md +0 -10
- package/docs/tutorials/upgrade-v2-5.md +0 -441
- package/docs/tutorials/upgrade-v3.md +0 -38
- package/lib/polyfill/mathround.js +0 -49
- package/lib/polyfill/patchedmediakeys_apple.js +0 -744
- package/lib/polyfill/patchedmediakeys_ms.js +0 -698
- package/test/util/functional_unit.js +0 -82
package/lib/util/stream_utils.js
CHANGED
|
@@ -408,7 +408,7 @@ shaka.util.StreamUtils = class {
|
|
|
408
408
|
shaka.util.StreamUtils.filterManifestByCurrentVariant(
|
|
409
409
|
currentVariant, manifest);
|
|
410
410
|
shaka.util.StreamUtils.filterTextStreams_(manifest);
|
|
411
|
-
shaka.util.StreamUtils.filterImageStreams_(manifest);
|
|
411
|
+
await shaka.util.StreamUtils.filterImageStreams_(manifest);
|
|
412
412
|
}
|
|
413
413
|
|
|
414
414
|
|
|
@@ -815,37 +815,57 @@ shaka.util.StreamUtils = class {
|
|
|
815
815
|
* @param {shaka.extern.Manifest} manifest
|
|
816
816
|
* @private
|
|
817
817
|
*/
|
|
818
|
-
static filterImageStreams_(manifest) {
|
|
819
|
-
|
|
820
|
-
|
|
821
|
-
|
|
822
|
-
|
|
823
|
-
|
|
824
|
-
|
|
825
|
-
|
|
826
|
-
|
|
827
|
-
|
|
828
|
-
|
|
829
|
-
|
|
830
|
-
|
|
831
|
-
Platform.isTizen() ||
|
|
832
|
-
Platform.isChromecast();
|
|
833
|
-
if (webpSupport) {
|
|
834
|
-
validMimeTypes.push('image/webp');
|
|
818
|
+
static async filterImageStreams_(manifest) {
|
|
819
|
+
const imageStreams = [];
|
|
820
|
+
for (const stream of manifest.imageStreams) {
|
|
821
|
+
const mimeType = stream.mimeType;
|
|
822
|
+
if (!shaka.util.StreamUtils.supportedImageMimeTypes_.has(mimeType)) {
|
|
823
|
+
const minImage = shaka.util.StreamUtils.minImage_.get(mimeType);
|
|
824
|
+
if (minImage) {
|
|
825
|
+
// eslint-disable-next-line no-await-in-loop
|
|
826
|
+
const res = await shaka.util.StreamUtils.isImageSupported_(minImage);
|
|
827
|
+
shaka.util.StreamUtils.supportedImageMimeTypes_.set(mimeType, res);
|
|
828
|
+
} else {
|
|
829
|
+
shaka.util.StreamUtils.supportedImageMimeTypes_.set(mimeType, false);
|
|
830
|
+
}
|
|
835
831
|
}
|
|
836
|
-
|
|
837
|
-
const keep =
|
|
832
|
+
|
|
833
|
+
const keep =
|
|
834
|
+
shaka.util.StreamUtils.supportedImageMimeTypes_.get(mimeType);
|
|
838
835
|
|
|
839
836
|
if (!keep) {
|
|
840
837
|
shaka.log.debug('Dropping image stream. Is not supported by the ' +
|
|
841
838
|
'platform.', stream);
|
|
839
|
+
} else {
|
|
840
|
+
imageStreams.push(stream);
|
|
842
841
|
}
|
|
842
|
+
}
|
|
843
|
+
manifest.imageStreams = imageStreams;
|
|
844
|
+
}
|
|
843
845
|
|
|
844
|
-
|
|
846
|
+
/**
|
|
847
|
+
* @param {string} minImage
|
|
848
|
+
* @return {!Promise.<boolean>}
|
|
849
|
+
* @private
|
|
850
|
+
*/
|
|
851
|
+
static isImageSupported_(minImage) {
|
|
852
|
+
return new Promise((resolve) => {
|
|
853
|
+
const imageElement = /** @type {HTMLImageElement} */(new Image());
|
|
854
|
+
imageElement.src = minImage;
|
|
855
|
+
if ('decode' in imageElement) {
|
|
856
|
+
imageElement.decode().then(() => {
|
|
857
|
+
resolve(true);
|
|
858
|
+
}).catch(() => {
|
|
859
|
+
resolve(false);
|
|
860
|
+
});
|
|
861
|
+
} else {
|
|
862
|
+
imageElement.onload = imageElement.onerror = () => {
|
|
863
|
+
resolve(imageElement.height === 2);
|
|
864
|
+
};
|
|
865
|
+
}
|
|
845
866
|
});
|
|
846
867
|
}
|
|
847
868
|
|
|
848
|
-
|
|
849
869
|
/**
|
|
850
870
|
* @param {shaka.extern.Stream} s0
|
|
851
871
|
* @param {shaka.extern.Stream} s1
|
|
@@ -880,6 +900,11 @@ shaka.util.StreamUtils = class {
|
|
|
880
900
|
/** @type {?shaka.extern.Stream} */
|
|
881
901
|
const video = variant.video;
|
|
882
902
|
|
|
903
|
+
/** @type {?string} */
|
|
904
|
+
const audioMimeType = audio ? audio.mimeType : null;
|
|
905
|
+
/** @type {?string} */
|
|
906
|
+
const videoMimeType = video ? video.mimeType : null;
|
|
907
|
+
|
|
883
908
|
/** @type {?string} */
|
|
884
909
|
const audioCodec = audio ? audio.codecs : null;
|
|
885
910
|
/** @type {?string} */
|
|
@@ -944,6 +969,8 @@ shaka.util.StreamUtils = class {
|
|
|
944
969
|
pixelAspectRatio: null,
|
|
945
970
|
hdr: null,
|
|
946
971
|
mimeType: mimeType,
|
|
972
|
+
audioMimeType: audioMimeType,
|
|
973
|
+
videoMimeType: videoMimeType,
|
|
947
974
|
codecs: codecs.join(', '),
|
|
948
975
|
audioCodec: audioCodec,
|
|
949
976
|
videoCodec: videoCodec,
|
|
@@ -1011,6 +1038,8 @@ shaka.util.StreamUtils = class {
|
|
|
1011
1038
|
pixelAspectRatio: null,
|
|
1012
1039
|
hdr: null,
|
|
1013
1040
|
mimeType: stream.mimeType,
|
|
1041
|
+
audioMimeType: null,
|
|
1042
|
+
videoMimeType: null,
|
|
1014
1043
|
codecs: stream.codecs || null,
|
|
1015
1044
|
audioCodec: null,
|
|
1016
1045
|
videoCodec: null,
|
|
@@ -1083,6 +1112,8 @@ shaka.util.StreamUtils = class {
|
|
|
1083
1112
|
pixelAspectRatio: null,
|
|
1084
1113
|
hdr: null,
|
|
1085
1114
|
mimeType: stream.mimeType,
|
|
1115
|
+
audioMimeType: null,
|
|
1116
|
+
videoMimeType: null,
|
|
1086
1117
|
codecs: null,
|
|
1087
1118
|
audioCodec: null,
|
|
1088
1119
|
videoCodec: null,
|
|
@@ -1201,6 +1232,8 @@ shaka.util.StreamUtils = class {
|
|
|
1201
1232
|
pixelAspectRatio: null,
|
|
1202
1233
|
hdr: null,
|
|
1203
1234
|
mimeType: null,
|
|
1235
|
+
audioMimeType: null,
|
|
1236
|
+
videoMimeType: null,
|
|
1204
1237
|
codecs: null,
|
|
1205
1238
|
audioCodec: null,
|
|
1206
1239
|
videoCodec: null,
|
|
@@ -1505,3 +1538,40 @@ shaka.util.StreamUtils.DecodingAttributes = {
|
|
|
1505
1538
|
POWER: 'powerEfficient',
|
|
1506
1539
|
BANDWIDTH: 'bandwidth',
|
|
1507
1540
|
};
|
|
1541
|
+
|
|
1542
|
+
/**
|
|
1543
|
+
* @private {!Map.<string, boolean>}
|
|
1544
|
+
*/
|
|
1545
|
+
shaka.util.StreamUtils.supportedImageMimeTypes_ = new Map()
|
|
1546
|
+
.set('image/svg+xml', true)
|
|
1547
|
+
.set('image/png', true)
|
|
1548
|
+
.set('image/jpeg', true)
|
|
1549
|
+
.set('image/jpg', true);
|
|
1550
|
+
|
|
1551
|
+
/**
|
|
1552
|
+
* @const {string}
|
|
1553
|
+
* @private
|
|
1554
|
+
*/
|
|
1555
|
+
shaka.util.StreamUtils.minWebPImage_ = 'data:image/webp;base64,UklGRjoAAABXRU' +
|
|
1556
|
+
'JQVlA4IC4AAACyAgCdASoCAAIALmk0mk0iIiIiIgBoSygABc6WWgAA/veff/0PP8bA//LwY' +
|
|
1557
|
+
'AAA';
|
|
1558
|
+
|
|
1559
|
+
/**
|
|
1560
|
+
* @const {string}
|
|
1561
|
+
* @private
|
|
1562
|
+
*/
|
|
1563
|
+
shaka.util.StreamUtils.minAvifImage_ = 'data:image/avif;base64,AAAAIGZ0eXBhdm' +
|
|
1564
|
+
'lmAAAAAGF2aWZtaWYxbWlhZk1BMUIAAADybWV0YQAAAAAAAAAoaGRscgAAAAAAAAAAcGljd' +
|
|
1565
|
+
'AAAAAAAAAAAAAAAAGxpYmF2aWYAAAAADnBpdG0AAAAAAAEAAAAeaWxvYwAAAABEAAABAAEA' +
|
|
1566
|
+
'AAABAAABGgAAAB0AAAAoaWluZgAAAAAAAQAAABppbmZlAgAAAAABAABhdjAxQ29sb3IAAAA' +
|
|
1567
|
+
'AamlwcnAAAABLaXBjbwAAABRpc3BlAAAAAAAAAAIAAAACAAAAEHBpeGkAAAAAAwgICAAAAA' +
|
|
1568
|
+
'xhdjFDgQ0MAAAAABNjb2xybmNseAACAAIAAYAAAAAXaXBtYQAAAAAAAAABAAEEAQKDBAAAA' +
|
|
1569
|
+
'CVtZGF0EgAKCBgANogQEAwgMg8f8D///8WfhwB8+ErK42A=';
|
|
1570
|
+
|
|
1571
|
+
/**
|
|
1572
|
+
* @const {!Map.<string, string>}
|
|
1573
|
+
* @private
|
|
1574
|
+
*/
|
|
1575
|
+
shaka.util.StreamUtils.minImage_ = new Map()
|
|
1576
|
+
.set('image/webp', shaka.util.StreamUtils.minWebPImage_)
|
|
1577
|
+
.set('image/avif', shaka.util.StreamUtils.minAvifImage_);
|
|
@@ -6,7 +6,6 @@
|
|
|
6
6
|
|
|
7
7
|
goog.provide('shaka.util.Uint8ArrayUtils');
|
|
8
8
|
|
|
9
|
-
goog.require('shaka.Deprecate');
|
|
10
9
|
goog.require('shaka.util.BufferUtils');
|
|
11
10
|
goog.require('shaka.util.StringUtils');
|
|
12
11
|
|
|
@@ -17,21 +16,6 @@ goog.require('shaka.util.StringUtils');
|
|
|
17
16
|
* @export
|
|
18
17
|
*/
|
|
19
18
|
shaka.util.Uint8ArrayUtils = class {
|
|
20
|
-
/**
|
|
21
|
-
* Compare two Uint8Arrays for equality.
|
|
22
|
-
* @param {Uint8Array} arr1
|
|
23
|
-
* @param {Uint8Array} arr2
|
|
24
|
-
* @return {boolean}
|
|
25
|
-
* @deprecated
|
|
26
|
-
* @export
|
|
27
|
-
*/
|
|
28
|
-
static equal(arr1, arr2) {
|
|
29
|
-
shaka.Deprecate.deprecateFeature(4,
|
|
30
|
-
'shaka.util.Uint8ArrayUtils.equal',
|
|
31
|
-
'Please use shaka.util.BufferUtils.equal instead.');
|
|
32
|
-
return shaka.util.BufferUtils.equal(arr1, arr2);
|
|
33
|
-
}
|
|
34
|
-
|
|
35
19
|
/**
|
|
36
20
|
* Convert a buffer to a base64 string. The output will be standard
|
|
37
21
|
* alphabet as opposed to base64url safe alphabet.
|
package/lib/util/xml_utils.js
CHANGED
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "shaka-player",
|
|
3
3
|
"description": "DASH/EME video player library",
|
|
4
|
-
"version": "
|
|
4
|
+
"version": "4.0.2",
|
|
5
5
|
"homepage": "https://github.com/shaka-project/shaka-player",
|
|
6
6
|
"author": "Google",
|
|
7
7
|
"maintainers": [
|
|
@@ -50,7 +50,7 @@
|
|
|
50
50
|
"less": "https://gitpkg.now.sh/joeyparrish/less.js/packages/less?28c63a43",
|
|
51
51
|
"less-plugin-clean-css": "github:austingardner/less-plugin-clean-css#4e9e77bf",
|
|
52
52
|
"material-design-lite": "^1.3.0",
|
|
53
|
-
"mux.js": "^
|
|
53
|
+
"mux.js": "^6.1.0",
|
|
54
54
|
"open-sans-fonts": "^1.6.2",
|
|
55
55
|
"postcss-less": "^6.0.0",
|
|
56
56
|
"pwacompat": "^2.0.17",
|
|
@@ -97,5 +97,8 @@
|
|
|
97
97
|
},
|
|
98
98
|
"dependencies": {
|
|
99
99
|
"eme-encryption-scheme-polyfill": "^2.0.3"
|
|
100
|
+
},
|
|
101
|
+
"engines": {
|
|
102
|
+
"node": ">=14"
|
|
100
103
|
}
|
|
101
104
|
}
|
package/roadmap.md
CHANGED
|
@@ -9,41 +9,41 @@ The goals of future milestones are fluid until we begin that development cycle,
|
|
|
9
9
|
so the exact milestone for future features is not pre-determined.
|
|
10
10
|
|
|
11
11
|
Priority features up next:
|
|
12
|
-
- Support containerless formats
|
|
13
|
-
https://github.com/shaka-project/shaka-player/issues/2337
|
|
14
12
|
- Preload API
|
|
15
13
|
https://github.com/shaka-project/shaka-player/issues/880
|
|
16
|
-
- Codec-switching and order preference
|
|
17
|
-
https://github.com/shaka-project/shaka-player/issues/1528
|
|
18
|
-
https://github.com/shaka-project/shaka-player/issues/2179
|
|
19
14
|
|
|
20
15
|
Candidate features for future release cycles:
|
|
21
|
-
- HLS interstitial support
|
|
22
|
-
https://github.com/shaka-project/shaka-player/issues/3364
|
|
23
|
-
- Support ID3 tags in mp4
|
|
24
|
-
https://github.com/shaka-project/shaka-player/issues/3351
|
|
25
|
-
- MSE support for FairPlay
|
|
26
|
-
https://github.com/shaka-project/shaka-player/issues/3346
|
|
27
|
-
- Smaller, more modular binary
|
|
28
16
|
- Official TypeScript defs, generated from source
|
|
29
17
|
https://github.com/shaka-project/shaka-player/issues/1030
|
|
30
|
-
-
|
|
31
|
-
https://github.com/shaka-project/shaka-player/issues/
|
|
32
|
-
- Integration with Google Video ML/Cloud AI
|
|
33
|
-
|
|
34
|
-
v3.3 - 2021 Q3 or Q4
|
|
18
|
+
- Codec-switching
|
|
19
|
+
https://github.com/shaka-project/shaka-player/issues/1528
|
|
35
20
|
- Background fetch for offline storage
|
|
36
21
|
https://github.com/shaka-project/shaka-player/issues/879
|
|
37
|
-
-
|
|
38
|
-
https://github.com/shaka-project/shaka-player/issues/
|
|
22
|
+
- Support ID3 tags in mp4
|
|
23
|
+
https://github.com/shaka-project/shaka-player/issues/3351
|
|
24
|
+
- Smaller, more modular binary
|
|
25
|
+
|
|
26
|
+
v3.4 - 2022 Q1 or Q2
|
|
27
|
+
- MSE support for FairPlay
|
|
28
|
+
https://github.com/shaka-project/shaka-player/issues/3346
|
|
29
|
+
- Support containerless formats
|
|
30
|
+
https://github.com/shaka-project/shaka-player/issues/2337
|
|
39
31
|
|
|
40
32
|
=====
|
|
41
33
|
|
|
34
|
+
v3.3 - 2022 Q1
|
|
35
|
+
- Common Media Client Data (CMCD) logging support
|
|
36
|
+
https://github.com/shaka-project/shaka-player/issues/3619
|
|
37
|
+
- Non-linear IMA CS ads
|
|
38
|
+
https://github.com/shaka-project/shaka-player/pull/3639
|
|
39
|
+
|
|
42
40
|
v3.2 - 2021 Q3
|
|
43
41
|
- MediaCapabilities to make performance-based decisions
|
|
44
42
|
https://github.com/shaka-project/shaka-player/issues/1391
|
|
45
43
|
- Configurable key-system priority
|
|
46
44
|
https://github.com/shaka-project/shaka-player/issues/3002
|
|
45
|
+
- Codec order preferences
|
|
46
|
+
https://github.com/shaka-project/shaka-player/issues/2179
|
|
47
47
|
|
|
48
48
|
v3.1 - 2021 Q2
|
|
49
49
|
- Low-latency live (LL-HLS, LL-DASH)
|
|
@@ -35,12 +35,9 @@ goog.require('shaka.offline.indexeddb.StorageMechanism');
|
|
|
35
35
|
goog.require('shaka.polyfill.Aria');
|
|
36
36
|
goog.require('shaka.polyfill.EncryptionScheme');
|
|
37
37
|
goog.require('shaka.polyfill.Fullscreen');
|
|
38
|
-
goog.require('shaka.polyfill.MathRound');
|
|
39
38
|
goog.require('shaka.polyfill.MediaSource');
|
|
40
39
|
goog.require('shaka.polyfill.MediaCapabilities');
|
|
41
40
|
goog.require('shaka.polyfill.Orientation');
|
|
42
|
-
goog.require('shaka.polyfill.PatchedMediaKeysApple');
|
|
43
|
-
goog.require('shaka.polyfill.PatchedMediaKeysMs');
|
|
44
41
|
goog.require('shaka.polyfill.PatchedMediaKeysNop');
|
|
45
42
|
goog.require('shaka.polyfill.PatchedMediaKeysWebkit');
|
|
46
43
|
goog.require('shaka.polyfill.PiPWebkit');
|
|
@@ -805,6 +805,50 @@ describe('DashParser ContentProtection', () => {
|
|
|
805
805
|
});
|
|
806
806
|
});
|
|
807
807
|
|
|
808
|
+
describe('getClearKeyLicenseUrl', () => {
|
|
809
|
+
it('valid clearkey:Laurl node', () => {
|
|
810
|
+
const input = {
|
|
811
|
+
init: null,
|
|
812
|
+
keyId: null,
|
|
813
|
+
schemeUri: '',
|
|
814
|
+
node: strToXml([
|
|
815
|
+
'<test xmlns:clearkey="http://dashif.org/guidelines/clearKey">',
|
|
816
|
+
' <clearkey:Laurl ',
|
|
817
|
+
' Lic_type="EME-1.0">www.example.com</clearkey:Laurl>',
|
|
818
|
+
'</test>',
|
|
819
|
+
].join('\n')),
|
|
820
|
+
};
|
|
821
|
+
const actual = ContentProtection.getClearKeyLicenseUrl(input);
|
|
822
|
+
expect(actual).toBe('www.example.com');
|
|
823
|
+
});
|
|
824
|
+
|
|
825
|
+
it('clearkey:Laurl without license url', () => {
|
|
826
|
+
const input = {
|
|
827
|
+
init: null,
|
|
828
|
+
keyId: null,
|
|
829
|
+
schemeUri: '',
|
|
830
|
+
node: strToXml([
|
|
831
|
+
'<test xmlns:clearkey="http://dashif.org/guidelines/clearKey">',
|
|
832
|
+
' <clearkey:Laurl Lic_type="EME-1.0"></clearkey:Laurl>',
|
|
833
|
+
'</test>',
|
|
834
|
+
].join('\n')),
|
|
835
|
+
};
|
|
836
|
+
const actual = ContentProtection.getClearKeyLicenseUrl(input);
|
|
837
|
+
expect(actual).toBe('');
|
|
838
|
+
});
|
|
839
|
+
|
|
840
|
+
it('no clearkey:Laurl node', () => {
|
|
841
|
+
const input = {
|
|
842
|
+
init: null,
|
|
843
|
+
keyId: null,
|
|
844
|
+
schemeUri: '',
|
|
845
|
+
node: strToXml('<test></test>'),
|
|
846
|
+
};
|
|
847
|
+
const actual = ContentProtection.getClearKeyLicenseUrl(input);
|
|
848
|
+
expect(actual).toBe('');
|
|
849
|
+
});
|
|
850
|
+
});
|
|
851
|
+
|
|
808
852
|
describe('getPlayReadyLicenseURL', () => {
|
|
809
853
|
it('mspro', () => {
|
|
810
854
|
const laurl = [
|
|
@@ -106,9 +106,8 @@ describe('DashParser SegmentTemplate', () => {
|
|
|
106
106
|
's2.mp4', 50, 60, baseUri);
|
|
107
107
|
expectedRef2.timestampOffset = -10;
|
|
108
108
|
|
|
109
|
-
const
|
|
110
|
-
const
|
|
111
|
-
const ref2 = iterator.seek(55);
|
|
109
|
+
const ref1 = stream.segmentIndex.getIteratorForTime(45).next().value;
|
|
110
|
+
const ref2 = stream.segmentIndex.getIteratorForTime(55).next().value;
|
|
112
111
|
expect(ref1).toEqual(expectedRef1);
|
|
113
112
|
expect(ref2).toEqual(expectedRef2);
|
|
114
113
|
});
|
|
@@ -445,7 +444,7 @@ describe('DashParser SegmentTemplate', () => {
|
|
|
445
444
|
await variants[2].video.createSegmentIndex();
|
|
446
445
|
|
|
447
446
|
const getRefAt = (stream, time) => {
|
|
448
|
-
return stream.segmentIndex
|
|
447
|
+
return stream.segmentIndex.getIteratorForTime(time).next().value;
|
|
449
448
|
};
|
|
450
449
|
|
|
451
450
|
expect(getRefAt(variants[0].video, 0)).toEqual(
|
package/test/demo/demo_unit.js
CHANGED
|
@@ -93,7 +93,8 @@ describe('Demo', () => {
|
|
|
93
93
|
.add('preferredVariantRole')
|
|
94
94
|
.add('playRangeStart')
|
|
95
95
|
.add('playRangeEnd')
|
|
96
|
-
.add('manifest.dash.keySystemsByURI')
|
|
96
|
+
.add('manifest.dash.keySystemsByURI')
|
|
97
|
+
.add('manifest.hls.mediaPlaylistFullMimeType');
|
|
97
98
|
|
|
98
99
|
/**
|
|
99
100
|
* @param {!Object} section
|