shaka-player 3.1.4 → 3.1.7
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/.csslintrc +11 -1
- package/.github/ISSUE_TEMPLATE/bug_report.md +1 -1
- package/.github/workflows/build-and-test.yaml +130 -0
- package/.github/workflows/custom-actions/prep-for-appspot/action.yaml +56 -0
- package/.github/workflows/custom-actions/set-commit-status/action.yaml +41 -0
- package/.github/workflows/demo-version-index.yaml +29 -0
- package/.github/workflows/nightly-demo.yaml +42 -0
- package/.github/workflows/release-please.yaml +145 -0
- package/.github/workflows/safari-homedir-launcher.sh +18 -0
- package/.github/workflows/selenium-lab-tests.yaml +93 -0
- package/AUTHORS +2 -0
- package/CHANGELOG.md +1540 -1474
- package/CONTRIBUTING.md +2 -2
- package/CONTRIBUTORS +2 -0
- package/README.md +7 -7
- package/app-engine/README.md +9 -0
- package/app-engine/demo-version-index/README.md +14 -0
- package/app-engine/demo-version-index/app.yaml +2 -0
- package/app-engine/demo-version-index/main.py +162 -0
- package/app-engine/demo-version-index/requirements.txt +6 -0
- package/app-engine/demo-version-index/templates/index.html +114 -0
- package/app-engine/shaka-player-demo/README.md +18 -0
- package/app-engine/shaka-player-demo/app.yaml +61 -0
- package/app-engine/shaka-player-demo/main.py +95 -0
- package/app-engine/shaka-player-demo/posters/10yo.png +0 -0
- package/app-engine/shaka-player-demo/posters/10yo.xcf +0 -0
- package/app-engine/shaka-player-demo/posters/1yo.jpg +0 -0
- package/app-engine/shaka-player-demo/posters/2yo.png +0 -0
- package/app-engine/shaka-player-demo/posters/2yo.xcf +0 -0
- package/app-engine/shaka-player-demo/posters/3yo.png +0 -0
- package/app-engine/shaka-player-demo/posters/3yo.xcf +0 -0
- package/app-engine/shaka-player-demo/posters/4yo.png +0 -0
- package/app-engine/shaka-player-demo/posters/4yo.xcf +0 -0
- package/app-engine/shaka-player-demo/posters/5yo.png +0 -0
- package/app-engine/shaka-player-demo/posters/5yo.xcf +0 -0
- package/app-engine/shaka-player-demo/posters/6yo.png +0 -0
- package/app-engine/shaka-player-demo/posters/6yo.xcf +0 -0
- package/app-engine/shaka-player-demo/posters/7yo.png +0 -0
- package/app-engine/shaka-player-demo/posters/7yo.xcf +0 -0
- package/app-engine/shaka-player-demo/posters/8yo.png +0 -0
- package/app-engine/shaka-player-demo/posters/8yo.xcf +0 -0
- package/app-engine/shaka-player-demo/posters/9yo.png +0 -0
- package/app-engine/shaka-player-demo/posters/9yo.xcf +0 -0
- package/app-engine/shaka-player-demo/posters/audioOnly.gif +0 -0
- package/app-engine/shaka-player-demo/posters/audioRickRoll.gif +0 -0
- package/app-engine/shaka-player-demo/posters/colorbars.gif +0 -0
- package/app-engine/shaka-player-demo/posters/fireworks.jpg +0 -0
- package/app-engine/shaka-player-demo/posters/party-hat.png +0 -0
- package/app-engine/shaka-player-demo/posters/sources.txt +46 -0
- package/app-engine/shaka-player-demo/posters/standard.png +0 -0
- package/app-engine/shaka-player-demo/posters/trek.jpg +0 -0
- package/app-engine/shaka-player-demo/posters/valentines.png +0 -0
- package/app-engine/shaka-player-demo/posters/zombie.jpg +0 -0
- package/app-engine/shaka-player-demo/posters.py +110 -0
- package/app-engine/shaka-player-demo/requirements.txt +5 -0
- package/app-engine/shaka-player-demo/time.txt +1 -0
- package/build/README.md +1 -1
- package/build/checkversion.py +1 -1
- package/build/conformance.textproto +13 -0
- package/build/docker/Dockerfile +20 -0
- package/build/docker/docker-compose.yml +10 -0
- package/build/gendeps.py +18 -15
- package/build/shaka-lab.yaml +163 -0
- package/build/shakaBuildHelpers.py +4 -29
- package/build/test.py +93 -28
- package/build/wrapper.template.js +2 -2
- package/demo/TengwarTelcontar.woff2 +0 -0
- package/demo/asset_card.js +1 -2
- package/demo/cast_receiver/index.html +1 -1
- package/demo/cast_receiver/receiver_app.css +14 -14
- package/demo/common/assets.js +2 -0
- package/demo/config.js +0 -1
- package/demo/custom.js +0 -1
- package/demo/customWarning.txt +2 -2
- package/demo/demo.less +29 -18
- package/demo/demo_uncompiled.js +1 -13
- package/demo/index.html +1 -1
- package/demo/main.js +3 -3
- package/dist/controls.css +2 -2
- package/dist/controls.css.map +1 -1
- package/dist/demo.compiled.debug.js +191 -194
- package/dist/demo.compiled.debug.map +4 -4
- package/dist/demo.compiled.js +191 -194
- package/dist/demo.compiled.map +4 -4
- package/dist/demo.css +1 -1
- package/dist/demo.css.map +1 -1
- package/dist/deps.js +224 -218
- package/dist/locales.js +30 -30
- package/dist/receiver.compiled.debug.js +43 -45
- package/dist/receiver.compiled.debug.map +4 -4
- package/dist/receiver.compiled.js +43 -45
- package/dist/receiver.compiled.map +4 -4
- package/dist/shaka-player.compiled.d.ts +237 -222
- package/dist/shaka-player.compiled.debug.d.ts +237 -222
- package/dist/shaka-player.compiled.debug.externs.js +20 -3
- package/dist/shaka-player.compiled.debug.js +361 -365
- package/dist/shaka-player.compiled.debug.map +4 -4
- package/dist/shaka-player.compiled.externs.js +20 -3
- package/dist/shaka-player.compiled.js +811 -815
- package/dist/shaka-player.compiled.map +4 -4
- package/dist/shaka-player.ui.d.ts +281 -275
- package/dist/shaka-player.ui.debug.d.ts +281 -275
- package/dist/shaka-player.ui.debug.externs.js +34 -26
- package/dist/shaka-player.ui.debug.js +384 -389
- package/dist/shaka-player.ui.debug.map +4 -4
- package/dist/shaka-player.ui.externs.js +34 -26
- package/dist/shaka-player.ui.js +945 -950
- package/dist/shaka-player.ui.map +4 -4
- package/docs/design/REDESIGN.md +33 -33
- package/docs/design/codec_preferences.md +1 -1
- package/docs/design/dash-audio-channels.md +3 -3
- package/docs/design/dash-manifests.md +1 -1
- package/docs/design/gap-jumping.md +3 -3
- package/docs/design/preload.md +2 -2
- package/docs/tutorials/faq.md +8 -8
- package/docs/tutorials/index.json +1 -0
- package/docs/tutorials/plugins.md +3 -3
- package/docs/tutorials/selenium-grid-config.md +122 -0
- package/docs/tutorials/welcome.md +10 -2
- package/externs/shaka/text.js +10 -0
- package/karma.conf.js +156 -45
- package/lib/abr/simple_abr_manager.js +12 -6
- package/lib/ads/ad_manager.js +1 -0
- package/lib/cast/cast_proxy.js +6 -4
- package/lib/cast/cast_receiver.js +3 -0
- package/lib/cea/cea608_data_channel.js +3 -3
- package/lib/cea/cea608_memory.js +1 -1
- package/lib/cea/cea708_service.js +6 -5
- package/lib/cea/cea_decoder.js +1 -1
- package/lib/cea/i_caption_decoder.js +2 -3
- package/lib/cea/mp4_cea_parser.js +11 -5
- package/lib/cea/sei_processor.js +6 -3
- package/lib/dash/dash_parser.js +43 -31
- package/lib/dash/mpd_utils.js +4 -5
- package/lib/dash/segment_list.js +1 -2
- package/lib/dash/segment_template.js +3 -3
- package/lib/hls/hls_parser.js +11 -9
- package/lib/hls/manifest_text_parser.js +4 -3
- package/lib/media/adaptation_set.js +1 -2
- package/lib/media/closed_caption_parser.js +0 -1
- package/lib/media/content_workarounds.js +2 -2
- package/lib/media/drm_engine.js +3 -2
- package/lib/media/media_source_engine.js +3 -2
- package/lib/media/mp4_segment_index_parser.js +1 -4
- package/lib/media/playhead.js +2 -2
- package/lib/media/presentation_timeline.js +18 -8
- package/lib/media/region_observer.js +39 -33
- package/lib/media/region_timeline.js +17 -19
- package/lib/media/streaming_engine.js +12 -9
- package/lib/media/time_ranges_utils.js +1 -3
- package/lib/media/video_wrapper.js +1 -1
- package/lib/net/networking_engine.js +5 -1
- package/lib/offline/storage.js +14 -15
- package/lib/player.js +52 -22
- package/lib/polyfill/all.js +2 -3
- package/lib/polyfill/encryption_scheme.js +1 -1
- package/lib/polyfill/media_capabilities.js +32 -17
- package/lib/polyfill/mediasource.js +1 -1
- package/lib/routing/walker.js +2 -3
- package/lib/text/cue.js +7 -1
- package/lib/text/simple_text_displayer.js +2 -1
- package/lib/text/text_engine.js +1 -1
- package/lib/text/ttml_text_parser.js +92 -63
- package/lib/text/ui_text_displayer.js +18 -12
- package/lib/util/buffer_utils.js +1 -3
- package/lib/util/ebml_parser.js +3 -3
- package/lib/util/error.js +1 -1
- package/lib/util/fake_event_target.js +21 -1
- package/lib/util/iterables.js +0 -46
- package/lib/util/mp4_box_parsers.js +1 -4
- package/lib/util/mp4_parser.js +5 -7
- package/lib/util/periods.js +8 -9
- package/lib/util/platform.js +3 -3
- package/lib/util/pssh.js +1 -4
- package/lib/util/stream_utils.js +60 -8
- package/lib/util/string_utils.js +3 -5
- package/lib/util/uint8array_utils.js +3 -5
- package/lib/util/xml_utils.js +34 -7
- package/package.json +62 -40
- package/roadmap.md +17 -17
- package/test/abr/simple_abr_manager_unit.js +3 -8
- package/test/ads/ad_manager_unit.js +0 -6
- package/test/cast/cast_proxy_unit.js +0 -8
- package/test/cast/cast_receiver_integration.js +1 -18
- package/test/cast/cast_receiver_unit.js +1 -9
- package/test/cast/cast_sender_unit.js +0 -6
- package/test/cast/cast_utils_unit.js +0 -13
- package/test/cea/cea608_memory_unit.js +0 -5
- package/test/cea/cea708_service_unit.js +0 -7
- package/test/cea/cea708_window_unit.js +0 -5
- package/test/cea/cea_decoder_unit.js +0 -6
- package/test/cea/dtvcc_packet_builder_unit.js +0 -3
- package/test/cea/dtvcc_packet_unit.js +0 -5
- package/test/cea/mp4_cea_parser_unit.js +0 -4
- package/test/dash/dash_parser_content_protection_unit.js +1 -10
- package/test/dash/dash_parser_live_unit.js +45 -15
- package/test/dash/dash_parser_manifest_unit.js +37 -18
- package/test/dash/dash_parser_segment_base_unit.js +1 -8
- package/test/dash/dash_parser_segment_list_unit.js +1 -7
- package/test/dash/dash_parser_segment_template_unit.js +0 -9
- package/test/dash/mpd_utils_unit.js +3 -11
- package/test/demo/demo_unit.js +0 -5
- package/test/deprecate/enforcer_unit.js +0 -4
- package/test/deprecate/version_unit.js +0 -2
- package/test/hls/hls_live_unit.js +2 -14
- package/test/hls/hls_parser_unit.js +76 -15
- package/test/hls/manifest_text_parser_unit.js +0 -10
- package/test/media/adaptation_set_criteria_unit.js +3 -7
- package/test/media/adaptation_set_unit.js +0 -2
- package/test/media/buffering_observer_unit.js +1 -4
- package/test/media/closed_caption_parser_unit.js +0 -3
- package/test/media/drm_engine_integration.js +3 -17
- package/test/media/drm_engine_unit.js +7 -26
- package/test/media/manifest_parser_unit.js +0 -4
- package/test/media/media_source_engine_integration.js +0 -7
- package/test/media/media_source_engine_unit.js +1 -14
- package/test/media/mp4_segment_index_parser_unit.js +0 -4
- package/test/media/play_rate_controller_unit.js +0 -4
- package/test/media/playhead_unit.js +8 -16
- package/test/media/presentation_timeline_unit.js +4 -7
- package/test/media/region_observer_unit.js +40 -10
- package/test/media/region_timeline_unit.js +40 -25
- package/test/media/segment_index_unit.js +0 -6
- package/test/media/segment_reference_unit.js +0 -3
- package/test/media/stall_detector_unit.js +0 -5
- package/test/media/streaming_engine_integration.js +11 -37
- package/test/media/streaming_engine_unit.js +155 -34
- package/test/media/time_ranges_utils_unit.js +0 -2
- package/test/media/transmuxer_integration.js +0 -6
- package/test/media/webm_segment_index_parser_unit.js +0 -4
- package/test/net/data_uri_plugin_unit.js +0 -7
- package/test/net/http_plugin_unit.js +0 -9
- package/test/net/networking_engine_unit.js +0 -11
- package/test/offline/download_progress_estimator_unit.js +0 -2
- package/test/offline/indexeddb_storage_unit.js +0 -6
- package/test/offline/manifest_convert_unit.js +0 -8
- package/test/offline/offline_integration.js +1 -10
- package/test/offline/offline_manifest_parser_unit.js +0 -6
- package/test/offline/offline_scheme_unit.js +0 -8
- package/test/offline/offline_uri_unit.js +0 -2
- package/test/offline/storage_compatibility_unit.js +1 -14
- package/test/offline/storage_integration.js +1 -25
- package/test/player_external.js +2 -10
- package/test/player_integration.js +21 -28
- package/test/player_load_graph_integration.js +1 -6
- package/test/player_src_equals_external.js +3 -9
- package/test/player_src_equals_integration.js +0 -7
- package/test/player_unit.js +57 -42
- package/test/routing/walker_unit.js +0 -8
- package/test/test/assets/large_file.mpd +1 -1
- package/test/test/boot.js +75 -22
- package/test/test/externs/jasmine.js +2 -2
- package/test/test/externs/karma.js +4 -0
- package/test/test/namespace.js +10 -0
- package/test/test/util/canned_idb.js +0 -8
- package/test/test/util/cea_utils.js +0 -6
- package/test/test/util/dash_parser_util.js +0 -13
- package/test/test/util/fake_ad.js +0 -3
- package/test/test/util/fake_ad_manager.js +0 -9
- package/test/test/util/fake_demo_main.js +0 -5
- package/test/test/util/fake_drm_engine.js +0 -6
- package/test/test/util/fake_media_source_engine.js +0 -7
- package/test/test/util/fake_networking_engine.js +0 -5
- package/test/test/util/fake_text_displayer.js +0 -5
- package/test/test/util/indexeddb_utils.js +1 -10
- package/test/test/util/jasmine_fetch.js +0 -1
- package/test/test/util/loader.js +0 -18
- package/test/test/util/manifest_generator.js +9 -14
- package/test/test/util/manifest_parser_util.js +0 -6
- package/test/test/util/offline_utils.js +0 -5
- package/test/test/util/simple_fakes.js +9 -26
- package/test/test/util/stream_generator.js +0 -14
- package/test/test/util/streaming_engine_util.js +0 -15
- package/test/test/util/test_scheme.js +1 -19
- package/test/test/util/ttml_utils.js +79 -0
- package/test/test/util/ui_utils.js +0 -9
- package/test/test/util/util.js +15 -26
- package/test/test/util/waiter.js +84 -43
- package/test/text/cue_integration.js +0 -4
- package/test/text/lrc_text_parser_unit.js +0 -4
- package/test/text/mp4_ttml_parser_unit.js +10 -23
- package/test/text/mp4_vtt_parser_unit.js +1 -7
- package/test/text/sbv_text_parser_unit.js +0 -4
- package/test/text/simple_text_displayer_unit.js +1 -8
- package/test/text/srt_text_parser_unit.js +0 -4
- package/test/text/ssa_text_parser_unit.js +0 -5
- package/test/text/text_engine_unit.js +2 -7
- package/test/text/text_track_integration.js +0 -2
- package/test/text/ttml_text_parser_unit.js +495 -237
- package/test/text/ui_text_displayer_unit.js +44 -41
- package/test/text/vtt_text_parser_unit.js +0 -9
- package/test/text/web_vtt_generator_unit.js +0 -3
- package/test/ui/ad_ui_unit.js +0 -11
- package/test/ui/localization_unit.js +0 -3
- package/test/ui/text_displayer_layout_unit.js +9 -19
- package/test/ui/ui_customization_unit.js +0 -6
- package/test/ui/ui_integration.js +0 -16
- package/test/ui/ui_unit.js +1 -17
- package/test/util/abortable_operation_unit.js +4 -9
- package/test/util/array_utils_unit.js +0 -2
- package/test/util/buffer_utils_unit.js +0 -2
- package/test/util/data_view_reader_unit.js +0 -4
- package/test/util/ebml_parser_unit.js +0 -4
- package/test/util/event_manager_unit.js +0 -3
- package/test/util/fake_event_target_unit.js +0 -5
- package/test/util/functional_unit.js +1 -1
- package/test/util/iterables_unit.js +0 -64
- package/test/util/language_utils_unit.js +0 -3
- package/test/util/manifest_parser_utils_unit.js +0 -2
- package/test/util/mp4_box_parsers_unit.js +0 -5
- package/test/util/mp4_parser_unit.js +0 -4
- package/test/util/multi_map_unit.js +0 -3
- package/test/util/object_utils_unit.js +0 -2
- package/test/util/periods_unit.js +14 -7
- package/test/util/pssh_unit.js +0 -5
- package/test/util/state_history_unit.js +0 -2
- package/test/util/stream_utils_unit.js +38 -37
- package/test/util/string_utils_unit.js +0 -6
- package/test/util/text_parser_unit.js +0 -2
- package/test/util/xml_utils_unit.js +0 -4
- package/ui/controls.js +3 -0
- package/ui/less/ad_controls.less +4 -4
- package/ui/less/buttons.less +5 -9
- package/ui/less/containers.less +5 -7
- package/ui/less/overflow_menu.less +4 -4
- package/ui/less/range_elements.less +5 -0
- package/ui/locales/sjn-translations.yaml +257 -0
- package/ui/locales/sjn.json +42 -0
- package/ui/localization.js +12 -36
- package/ui/text_selection.js +1 -0
- package/externs/media_capabilities.js +0 -16
- package/externs/svgelement.js +0 -18
package/docs/design/REDESIGN.md
CHANGED
|
@@ -28,11 +28,11 @@ often requiring [multiple][] [fixes][] to get certain dependencies removed.
|
|
|
28
28
|
This means users all end up using the same monolithic player library.
|
|
29
29
|
Features in Shaka 2 should be modular and easy to exclude from the build.
|
|
30
30
|
|
|
31
|
-
[difficult]: https://github.com/
|
|
32
|
-
[to exclude]: https://github.com/
|
|
33
|
-
[from the build]: https://github.com/
|
|
34
|
-
[multiple]: https://github.com/
|
|
35
|
-
[fixes]: https://github.com/
|
|
31
|
+
[difficult]: https://github.com/shaka-project/shaka-player/commit/671611ef3722169b9f6b51ab44bdd6b4098d959e
|
|
32
|
+
[to exclude]: https://github.com/shaka-project/shaka-player/commit/603fae969550c69ea38a61249da905857c67b9f1
|
|
33
|
+
[from the build]: https://github.com/shaka-project/shaka-player/commit/f248647685b92ba928bbfd06d45d2b99023d60c2
|
|
34
|
+
[multiple]: https://github.com/shaka-project/shaka-player/commit/39be45d3d55cdcef20a6a529a87246b0ea11cb33
|
|
35
|
+
[fixes]: https://github.com/shaka-project/shaka-player/commit/6fe239150a8939728876e93e1a4269032530d9f1
|
|
36
36
|
|
|
37
37
|
Some operations, in particular [starting playback and filling the buffer][],
|
|
38
38
|
take longer than they need to. Startup and buffering in Shaka 2 should be as
|
|
@@ -46,54 +46,54 @@ us from updating MediaSource duration][] and makes it [difficult to set initial
|
|
|
46
46
|
playback time][] on browsers other than Chrome. Shaka 2 should have a simpler
|
|
47
47
|
streaming core that works better across browsers.
|
|
48
48
|
|
|
49
|
-
[StreamVideoSource]: https://github.com/
|
|
50
|
-
[Stream]: https://github.com/
|
|
51
|
-
[SourceBufferManager]: https://github.com/
|
|
52
|
-
[prevents us from updating MediaSource duration]: https://github.com/
|
|
53
|
-
[difficult to set initial playback time]: https://github.com/
|
|
49
|
+
[StreamVideoSource]: https://github.com/shaka-project/shaka-player/blob/v1.5.x/lib/player/stream_video_source.js
|
|
50
|
+
[Stream]: https://github.com/shaka-project/shaka-player/blob/v1.5.x/lib/media/stream.js
|
|
51
|
+
[SourceBufferManager]: https://github.com/shaka-project/shaka-player/blob/v1.5.x/lib/media/source_buffer_manager.js
|
|
52
|
+
[prevents us from updating MediaSource duration]: https://github.com/shaka-project/shaka-player/blob/v1.5.1/lib/player/stream_video_source.js#L1807
|
|
53
|
+
[difficult to set initial playback time]: https://github.com/shaka-project/shaka-player/issues/101
|
|
54
54
|
|
|
55
55
|
[Buffering state][] in Shaka 1 involves coordination between several layers
|
|
56
56
|
(from [Player][] to [Stream][]) and has been [tough][] [to][] [get][]
|
|
57
57
|
[right][]. Buffering state in Shaka 2 should be simple and consistent.
|
|
58
58
|
|
|
59
|
-
[Buffering state]: https://github.com/
|
|
60
|
-
[Player]: https://github.com/
|
|
61
|
-
[Stream]: https://github.com/
|
|
62
|
-
[tough]: https://github.com/
|
|
63
|
-
[to]: https://github.com/
|
|
64
|
-
[get]: https://github.com/
|
|
65
|
-
[right]: https://github.com/
|
|
59
|
+
[Buffering state]: https://github.com/shaka-project/shaka-player/blob/v1.5.1/lib/player/player.js#L994
|
|
60
|
+
[Player]: https://github.com/shaka-project/shaka-player/blob/v1.5.x/lib/player/player.js
|
|
61
|
+
[Stream]: https://github.com/shaka-project/shaka-player/blob/v1.5.x/lib/media/stream.js
|
|
62
|
+
[tough]: https://github.com/shaka-project/shaka-player/issues/44
|
|
63
|
+
[to]: https://github.com/shaka-project/shaka-player/issues/63
|
|
64
|
+
[get]: https://github.com/shaka-project/shaka-player/issues/127
|
|
65
|
+
[right]: https://github.com/shaka-project/shaka-player/issues/221#issuecomment-152781243
|
|
66
66
|
|
|
67
67
|
Shaka 1 relies on the browser to implement support for text types, and is
|
|
68
68
|
therefore limited to non-segmented WebVTT. Shaka 2 should also support
|
|
69
69
|
[segmented text types][] and [types not natively supported by the browser][].
|
|
70
70
|
|
|
71
|
-
[segmented text types]: https://github.com/
|
|
72
|
-
[types not natively supported by the browser]: https://github.com/
|
|
71
|
+
[segmented text types]: https://github.com/shaka-project/shaka-player/issues/150
|
|
72
|
+
[types not natively supported by the browser]: https://github.com/shaka-project/shaka-player/issues/111
|
|
73
73
|
|
|
74
74
|
Bandwidth estimation in Shaka 1 relies on the assumption that segments are not
|
|
75
75
|
cached locally. Use of [cache-busting techniques][] to enforce this makes
|
|
76
76
|
Shaka very [cache][]-[unfriendly][]. Shaka 2 should be cache-friendly.
|
|
77
77
|
|
|
78
|
-
[cache-busting techniques]: https://github.com/
|
|
79
|
-
[cache]: https://github.com/
|
|
80
|
-
[unfriendly]: https://github.com/
|
|
78
|
+
[cache-busting techniques]: https://github.com/shaka-project/shaka-player/blob/v1.5.1/lib/util/ajax_request.js#L241
|
|
79
|
+
[cache]: https://github.com/shaka-project/shaka-player/issues/76
|
|
80
|
+
[unfriendly]: https://github.com/shaka-project/shaka-player/issues/191
|
|
81
81
|
|
|
82
82
|
Shaka 1 [uses HTTP headers to synchronize the user's clock][] with the server.
|
|
83
83
|
This is [error-prone for some CDNs][] and also raises [CORS issues][], so Shaka
|
|
84
84
|
2 should avoid using HTTP headers.
|
|
85
85
|
|
|
86
|
-
[uses HTTP headers to synchronize the user's clock]: https://github.com/
|
|
87
|
-
[error-prone for some CDNs]: https://github.com/
|
|
88
|
-
[CORS issues]: https://github.com/
|
|
86
|
+
[uses HTTP headers to synchronize the user's clock]: https://github.com/shaka-project/shaka-player/blob/v1.5.1/lib/util/ajax_request.js#L448
|
|
87
|
+
[error-prone for some CDNs]: https://github.com/shaka-project/shaka-player/issues/205
|
|
88
|
+
[CORS issues]: https://github.com/shaka-project/shaka-player/issues/159
|
|
89
89
|
|
|
90
90
|
[HttpVideoSource][] does not build on MSE and classes like [EmeManager][] have
|
|
91
91
|
special cases to support it. Since it was originally created for debugging
|
|
92
92
|
purposes, Shaka 2 should drop HttpVideoSource and only support MSE-based
|
|
93
93
|
playback.
|
|
94
94
|
|
|
95
|
-
[HttpVideoSource]: https://github.com/
|
|
96
|
-
[EmeManager]: https://github.com/
|
|
95
|
+
[HttpVideoSource]: https://github.com/shaka-project/shaka-player/blob/v1.5.x/lib/player/http_video_source.js
|
|
96
|
+
[EmeManager]: https://github.com/shaka-project/shaka-player/blob/v1.5.x/lib/media/eme_manager.js
|
|
97
97
|
|
|
98
98
|
Integration tests using externally-hosted resources [can be flaky][],
|
|
99
99
|
especially when run outside of Google's network. Shaka 2 should avoid tests
|
|
@@ -106,34 +106,34 @@ and application developers sometimes [have to use error message strings][]
|
|
|
106
106
|
hard-coded into the library. Shaka 2 should have a consistent error format
|
|
107
107
|
that is easy to read.
|
|
108
108
|
|
|
109
|
-
[have to use error message strings]: https://github.com/
|
|
109
|
+
[have to use error message strings]: https://github.com/shaka-project/shaka-player/issues/201
|
|
110
110
|
|
|
111
111
|
Networking abstractions in Shaka 1 are built inside of AjaxRequest, which
|
|
112
112
|
requires non-HTTP requests to [pretend to come from XmlHttpRequest][]. The
|
|
113
113
|
networking abstraction in Shaka 2 should be simpler and should not treat
|
|
114
114
|
XHR as the basis for all networking.
|
|
115
115
|
|
|
116
|
-
[pretend to come from XmlHttpRequest]: https://github.com/
|
|
116
|
+
[pretend to come from XmlHttpRequest]: https://github.com/shaka-project/shaka-player/blob/v1.5.1/lib/util/ajax_request.js#L305
|
|
117
117
|
|
|
118
118
|
A developer who wishes to use a custom network protocol or a custom manifest
|
|
119
119
|
format in Shaka 1 will have to modify the library to do so. Shaka 2 should
|
|
120
120
|
[support external plugins for networking][] and manifest support.
|
|
121
121
|
|
|
122
|
-
[support external plugins for networking]: https://github.com/
|
|
122
|
+
[support external plugins for networking]: https://github.com/shaka-project/shaka-player/issues/198
|
|
123
123
|
|
|
124
124
|
The functionality that can be injected into Shaka 1 ([IBandwidthEstimator][],
|
|
125
125
|
[IAbrManager][]) is based on implementing class interfaces, which can be complex
|
|
126
126
|
for those unfamiliar with the Closure compiler. Plugins and extensions to Shaka
|
|
127
127
|
2 should be as simple as possible.
|
|
128
128
|
|
|
129
|
-
[IBandwidthEstimator]: https://github.com/
|
|
130
|
-
[IAbrManager]: https://github.com/
|
|
129
|
+
[IBandwidthEstimator]: https://github.com/shaka-project/shaka-player/blob/v1.5.1/lib/util/i_bandwidth_estimator.js
|
|
130
|
+
[IAbrManager]: https://github.com/shaka-project/shaka-player/blob/v1.5.1/lib/media/i_abr_manager.js
|
|
131
131
|
|
|
132
132
|
[Static members][] in Shaka 1 make it impossible in some cases to host multiple
|
|
133
133
|
Player instances with different settings. Player instances should be completely
|
|
134
134
|
independent in Shaka 1.
|
|
135
135
|
|
|
136
|
-
[Static members]: https://github.com/
|
|
136
|
+
[Static members]: https://github.com/shaka-project/shaka-player/issues/126
|
|
137
137
|
|
|
138
138
|
|
|
139
139
|
## Shaka v2 Design Principles
|
|
@@ -97,7 +97,7 @@ A platform may support multiple DRM key systems, (for example, Widevine and
|
|
|
97
97
|
PlayReady). The `drm.preferredKeySystems` configuration allows the application
|
|
98
98
|
to specify which key systems it wants to choose.
|
|
99
99
|
|
|
100
|
-
[Github issue](https://github.com/
|
|
100
|
+
[Github issue](https://github.com/shaka-project/shaka-player/issues/3002)
|
|
101
101
|
|
|
102
102
|
Previously, Shaka Player chose a DRM key system based on:
|
|
103
103
|
1. Only use the key systems supported by the platform.
|
|
@@ -4,7 +4,7 @@ Shaka Player parses channel count information from HLS manifests, but not yet
|
|
|
4
4
|
from DASH manifests. We have had an [open request][dash_channels_request] to
|
|
5
5
|
do this for a year.
|
|
6
6
|
|
|
7
|
-
[dash_channels_request]: https://github.com/
|
|
7
|
+
[dash_channels_request]: https://github.com/shaka-project/shaka-player/issues/424
|
|
8
8
|
|
|
9
9
|
|
|
10
10
|
## The DASH Spec
|
|
@@ -79,7 +79,7 @@ Neither 23003-3 nor the DASH spec corrigenda were freely available at the time
|
|
|
79
79
|
of this writing, so we have not confirmed these assumptions.
|
|
80
80
|
|
|
81
81
|
[cast_labs_23003]: https://github.com/castlabs/dashencrypt/blob/1d604896/dash.fragmencrypter/src/main/java/com/castlabs/dash/helpers/DashHelper.java#L193
|
|
82
|
-
[shaka_packager_23003]: https://github.com/
|
|
82
|
+
[shaka_packager_23003]: https://github.com/shaka-project/shaka-packager/blob/4ba5bec6/packager/mpd/base/xml/xml_node.cc#L378
|
|
83
83
|
|
|
84
84
|
|
|
85
85
|
### tag:dolby.com,2014:dash:audio\_channel\_configuration:2011
|
|
@@ -101,7 +101,7 @@ Packager][shaka_packager_ec3_enum] supports this interpretation. This has not
|
|
|
101
101
|
been confirmed from primary sources.
|
|
102
102
|
|
|
103
103
|
[dash_if_audio_config]: http://dashif.org/identifiers/audio-source-data/
|
|
104
|
-
[shaka_packager_ec3_enum]: https://github.com/
|
|
104
|
+
[shaka_packager_ec3_enum]: https://github.com/shaka-project/shaka-packager/blob/47363dd0/packager/media/codecs/ec3_audio_util.cc#L34
|
|
105
105
|
|
|
106
106
|
|
|
107
107
|
### urn:dts:dash:audio\_channel\_configuration:2012
|
|
@@ -244,5 +244,5 @@ segments. You can follow progress in [#999][]. But note that DASH requires
|
|
|
244
244
|
accurate clock times, so even after that feature is added, your manifest may
|
|
245
245
|
not play in other DASH players.
|
|
246
246
|
|
|
247
|
-
[#999]: https://github.com/
|
|
247
|
+
[#999]: https://github.com/shaka-project/shaka-player/issues/999
|
|
248
248
|
|
|
@@ -21,13 +21,13 @@ buffered ranges.
|
|
|
21
21
|
|
|
22
22
|
There have been a number of bugs filed asking for this feature.
|
|
23
23
|
|
|
24
|
-
#### [#180](https://github.com/
|
|
24
|
+
#### [#180](https://github.com/shaka-project/shaka-player/issues/180)
|
|
25
25
|
One of the first bugs asking for gap jumping. The author talks about how live
|
|
26
26
|
streams can commonly lose source content (e.g. from network outages or weather).
|
|
27
27
|
This can cause the packagers to introduce gaps in either the media segments or
|
|
28
28
|
the manifest.
|
|
29
29
|
|
|
30
|
-
#### [#555](https://github.com/
|
|
30
|
+
#### [#555](https://github.com/shaka-project/shaka-player/issues/555)
|
|
31
31
|
This one is also asking about live streams and outages. The author discusses
|
|
32
32
|
several options for dealing with interruptions in the live streams. The
|
|
33
33
|
suggestions were:
|
|
@@ -41,7 +41,7 @@ can’t tell if a segment will never be available or is just not created yet.
|
|
|
41
41
|
Also that dummy content is usually generated by the server; however, the author
|
|
42
42
|
notes that this may not be feasible.
|
|
43
43
|
|
|
44
|
-
#### [#661](https://github.com/
|
|
44
|
+
#### [#661](https://github.com/shaka-project/shaka-player/issues/661)
|
|
45
45
|
This content with small gaps in the media that result in playback stalling.
|
|
46
46
|
Chrome and Firefox will actually play through the gap, but we don’t allow it
|
|
47
47
|
since it wouldn’t work on Safari.
|
package/docs/design/preload.md
CHANGED
|
@@ -15,7 +15,7 @@ This allows an application using Shaka Player to:
|
|
|
15
15
|
the user is making a decision on which video to play.
|
|
16
16
|
- Start to play the selected video almost immediately.
|
|
17
17
|
|
|
18
|
-
[Github issue](https://github.com/
|
|
18
|
+
[Github issue](https://github.com/shaka-project/shaka-player/issues/880)
|
|
19
19
|
|
|
20
20
|
|
|
21
21
|
## Background & Context
|
|
@@ -296,4 +296,4 @@ When preloading, the MediaSourceEngine appends the data to the SourceBuffer.
|
|
|
296
296
|
to the MediaSource.
|
|
297
297
|
3. For a live stream video, StreamingEngine can keep fetching the latest piece
|
|
298
298
|
of the content. The MediaSourceEngine stores the latest data, and abandons
|
|
299
|
-
the older data.
|
|
299
|
+
the older data.
|
package/docs/tutorials/faq.md
CHANGED
|
@@ -274,18 +274,18 @@ so don't declare it using a ref(), and if you put your player instance into a
|
|
|
274
274
|
data() object, you can prefix the property name with "$" or "_" to make Vue not
|
|
275
275
|
proxy them.
|
|
276
276
|
|
|
277
|
-
[386]: https://github.com/
|
|
278
|
-
[489]: https://github.com/
|
|
279
|
-
[743]: https://github.com/
|
|
280
|
-
[887]: https://github.com/
|
|
281
|
-
[999]: https://github.com/
|
|
282
|
-
[1667]: https://github.com/
|
|
277
|
+
[386]: https://github.com/shaka-project/shaka-player/issues/386#issuecomment-227898001
|
|
278
|
+
[489]: https://github.com/shaka-project/shaka-player/issues/489#issuecomment-240466224
|
|
279
|
+
[743]: https://github.com/shaka-project/shaka-player/issues/743
|
|
280
|
+
[887]: https://github.com/shaka-project/shaka-player/issues/887
|
|
281
|
+
[999]: https://github.com/shaka-project/shaka-player/issues/999
|
|
282
|
+
[1667]: https://github.com/shaka-project/shaka-player/issues/1667
|
|
283
283
|
[BigInteger.js]: https://github.com/peterolson/BigInteger.js
|
|
284
284
|
[CORS]: https://developer.mozilla.org/en-US/docs/Web/HTTP/Access_control_CORS
|
|
285
|
-
[Shaka Player Embedded]: https://github.com/
|
|
285
|
+
[Shaka Player Embedded]: https://github.com/shaka-project/shaka-player-embedded
|
|
286
286
|
[auth]: https://shaka-player-demo.appspot.com/docs/api/tutorial-license-server-auth.html
|
|
287
287
|
[buffering]: https://shaka-player-demo.appspot.com/docs/api/tutorial-network-and-buffering-config.html
|
|
288
288
|
[drm_tutorial]: https://shaka-player-demo.appspot.com/docs/api/tutorial-drm-config.html
|
|
289
289
|
[eme_https]: https://sites.google.com/a/chromium.org/dev/Home/chromium-security/deprecating-powerful-features-on-insecure-origins
|
|
290
290
|
[wrapping]: https://shaka-player-demo.appspot.com/docs/api/tutorial-license-wrapping.html
|
|
291
|
-
[including mux.js]: https://github.com/
|
|
291
|
+
[including mux.js]: https://github.com/shaka-project/shaka-player/blob/967f3399/demo/index.html#L39
|
|
@@ -18,6 +18,7 @@
|
|
|
18
18
|
{ "offline": { "title": "Offline Storage and Playback" } },
|
|
19
19
|
{ "fairplay": { "title": "FairPlay support" } },
|
|
20
20
|
{ "application-level-redirects": { "title": "Application-Level Redirects" } },
|
|
21
|
+
{ "selenium-grid-config": { "title": "Selenium Grid Config" } },
|
|
21
22
|
{ "faq": { "title": "Frequently Asked Questions" } },
|
|
22
23
|
{ "upgrade": {
|
|
23
24
|
"title": "Upgrade Guide",
|
|
@@ -108,7 +108,7 @@ python build/build.py +@complete -@polyfill
|
|
|
108
108
|
python build/build.py +@complete -@polyfill -@text
|
|
109
109
|
```
|
|
110
110
|
|
|
111
|
-
To see the complete list of categories, its in [`build/types/`](https://github.com/
|
|
111
|
+
To see the complete list of categories, its in [`build/types/`](https://github.com/shaka-project/shaka-player/tree/main/build/types)
|
|
112
112
|
|
|
113
113
|
#### Build Configs
|
|
114
114
|
|
|
@@ -177,5 +177,5 @@ If you have a great plugin that you'd like to contribute back to the community,
|
|
|
177
177
|
we'd love to hear from you. You can get in touch via our [issue tracker][] to
|
|
178
178
|
discuss it, and once it's ready, you can send a [pull request][] on github.
|
|
179
179
|
|
|
180
|
-
[issue tracker]: https://github.com/
|
|
181
|
-
[pull request]: https://github.com/
|
|
180
|
+
[issue tracker]: https://github.com/shaka-project/shaka-player/issues/new/choose
|
|
181
|
+
[pull request]: https://github.com/shaka-project/shaka-player/pull/new/main
|
|
@@ -0,0 +1,122 @@
|
|
|
1
|
+
# Selenium Grid Config
|
|
2
|
+
|
|
3
|
+
Shaka Player's test runner (Karma) can be directed to run tests on a Selenium
|
|
4
|
+
grid. For this, you need a config file that defines what browsers are
|
|
5
|
+
available, and how to request them via WebDriver.
|
|
6
|
+
|
|
7
|
+
For a fully-worked, detailed example, see the config for the private grid in
|
|
8
|
+
our lab at [build/shaka-lab.yaml](https://github.com/shaka-project/shaka-player/blob/main/build/shaka-lab.yaml)
|
|
9
|
+
|
|
10
|
+
## Usage
|
|
11
|
+
|
|
12
|
+
```sh
|
|
13
|
+
python build/test.py \
|
|
14
|
+
--grid-config grid-config.yaml \
|
|
15
|
+
--grid-address selenium-hub-hostname:4444
|
|
16
|
+
```
|
|
17
|
+
|
|
18
|
+
## Syntax
|
|
19
|
+
|
|
20
|
+
The config file is written in YAML. We chose YAML because it has two big
|
|
21
|
+
advantages over JSON:
|
|
22
|
+
|
|
23
|
+
1. You can add comments
|
|
24
|
+
2. You can define variables (with YAML "anchors") to factor out common configs
|
|
25
|
+
|
|
26
|
+
### Variables
|
|
27
|
+
|
|
28
|
+
You can define any common variables in the `vars` section, then refer to them
|
|
29
|
+
elsewhere. For example:
|
|
30
|
+
|
|
31
|
+
```yaml
|
|
32
|
+
vars:
|
|
33
|
+
# Generates an "anchor" with the given name. Later, you can inject the
|
|
34
|
+
# contents of the variable with "*name".
|
|
35
|
+
firefox_config: &firefox_config
|
|
36
|
+
moz:firefoxOptions:
|
|
37
|
+
# Override Firefox default preferences in the temporary profile created
|
|
38
|
+
# for each test run.
|
|
39
|
+
prefs:
|
|
40
|
+
# Overrides Selenium's explicit default setting, to allow Firefox to
|
|
41
|
+
# install the Widevine CDM on demand.
|
|
42
|
+
media.gmp-manager.updateEnabled: true
|
|
43
|
+
# Overrides Firefox's Linux-specific default setting to disable DRM.
|
|
44
|
+
media.eme.enabled: true
|
|
45
|
+
|
|
46
|
+
# These three browser definitions share the same config from above.
|
|
47
|
+
FirefoxMac:
|
|
48
|
+
browser: firefox
|
|
49
|
+
os: Mac
|
|
50
|
+
extra_config: *firefox_config
|
|
51
|
+
|
|
52
|
+
FirefoxWindows:
|
|
53
|
+
browser: firefox
|
|
54
|
+
os: Windows
|
|
55
|
+
extra_config: *firefox_config
|
|
56
|
+
|
|
57
|
+
FirefoxLinux:
|
|
58
|
+
browser: firefox
|
|
59
|
+
os: Linux
|
|
60
|
+
extra_config: *firefox_config
|
|
61
|
+
```
|
|
62
|
+
|
|
63
|
+
### Browsers
|
|
64
|
+
|
|
65
|
+
Each top-level key in the config file (except for `vars`) is the name of a
|
|
66
|
+
browser made available to Karma. Within each of those keys are the following:
|
|
67
|
+
|
|
68
|
+
- `browser`: The name of the browser. This is case-sensitive, and must match
|
|
69
|
+
the string and case used by Selenium.
|
|
70
|
+
- `os` (optional): The name of the OS. This is case-INsensitive, and must
|
|
71
|
+
match the name of the platform as used by Selenium. For Generic
|
|
72
|
+
WebDriver Server, this can be omitted or set to the name of the host
|
|
73
|
+
platform.
|
|
74
|
+
- `version` (optional): The version of the browser. This is case-sensitive,
|
|
75
|
+
and must match the string and case used in the Selenium node config.
|
|
76
|
+
- `disabled` (optional): If true, this browser is disabled and will not be
|
|
77
|
+
used unless explicitly requested.
|
|
78
|
+
- `extra_config` (optional): A dictionary of extra configs which will be
|
|
79
|
+
merged with the WebDriver launcher config in Karma.
|
|
80
|
+
|
|
81
|
+
Examples of basic desktop browsers definitions:
|
|
82
|
+
|
|
83
|
+
```yaml
|
|
84
|
+
ChromeMac:
|
|
85
|
+
browser: chrome
|
|
86
|
+
os: Mac
|
|
87
|
+
|
|
88
|
+
FirefoxMac:
|
|
89
|
+
browser: firefox
|
|
90
|
+
os: Mac
|
|
91
|
+
|
|
92
|
+
Safari:
|
|
93
|
+
browser: safari
|
|
94
|
+
os: Mac
|
|
95
|
+
|
|
96
|
+
SafariTP:
|
|
97
|
+
browser: safari
|
|
98
|
+
os: Mac
|
|
99
|
+
extra_config:
|
|
100
|
+
safari.options:
|
|
101
|
+
technologyPreview: true
|
|
102
|
+
|
|
103
|
+
ChromeWindows:
|
|
104
|
+
browser: chrome
|
|
105
|
+
os: Windows
|
|
106
|
+
|
|
107
|
+
FirefoxWindows:
|
|
108
|
+
browser: firefox
|
|
109
|
+
os: Windows
|
|
110
|
+
|
|
111
|
+
Edge:
|
|
112
|
+
browser: msedge
|
|
113
|
+
os: Windows
|
|
114
|
+
|
|
115
|
+
ChromeLinux:
|
|
116
|
+
browser: chrome
|
|
117
|
+
os: Linux
|
|
118
|
+
|
|
119
|
+
FirefoxLinux:
|
|
120
|
+
browser: firefox
|
|
121
|
+
os: Linux
|
|
122
|
+
```
|
|
@@ -35,11 +35,13 @@ To get the sources and compile the library, you will need:
|
|
|
35
35
|
* _NOTE: A local web server is required because browsers place restrictions
|
|
36
36
|
on applications from file:/// URLs._
|
|
37
37
|
|
|
38
|
+
If you just want to compile for export to other projects, you might consider compiling through a docker container. (see compile instructions)
|
|
39
|
+
|
|
38
40
|
To quickly install these prerequisites on Ubuntu or Debian, you can run this
|
|
39
41
|
script:
|
|
40
42
|
|
|
41
43
|
```sh
|
|
42
|
-
curl https://raw.githubusercontent.com/
|
|
44
|
+
curl https://raw.githubusercontent.com/shaka-project/shaka-player/main/build/install-linux-prereqs.sh | bash
|
|
43
45
|
```
|
|
44
46
|
|
|
45
47
|
We do not provide detailed instructions or scripts for installing these
|
|
@@ -51,7 +53,7 @@ links above to download and install the prerequisites manually on any OS.
|
|
|
51
53
|
#### Get the source
|
|
52
54
|
|
|
53
55
|
```sh
|
|
54
|
-
git clone https://github.com/
|
|
56
|
+
git clone https://github.com/shaka-project/shaka-player.git
|
|
55
57
|
cd shaka-player
|
|
56
58
|
```
|
|
57
59
|
|
|
@@ -62,6 +64,12 @@ cd shaka-player
|
|
|
62
64
|
python build/all.py
|
|
63
65
|
```
|
|
64
66
|
|
|
67
|
+
Alternatively you can use a docker container:
|
|
68
|
+
```sh
|
|
69
|
+
cd build/docker
|
|
70
|
+
docker-compose run --rm shaka-compiler
|
|
71
|
+
```
|
|
72
|
+
|
|
65
73
|
The output is:
|
|
66
74
|
* dist/shaka-player.compiled.js (compiled bundle)
|
|
67
75
|
* dist/shaka-player.compiled.debug.js (debug bundle)
|
package/externs/shaka/text.js
CHANGED
|
@@ -349,6 +349,16 @@ shaka.extern.Cue = class {
|
|
|
349
349
|
*/
|
|
350
350
|
this.nestedCues;
|
|
351
351
|
|
|
352
|
+
/**
|
|
353
|
+
* If true, this represents a container element that is "above" the main
|
|
354
|
+
* cues. For example, the <body> and <div> tags that contain the <p> tags
|
|
355
|
+
* in a TTML file. This controls the flow of the final cues; any nested cues
|
|
356
|
+
* within an "isContainer" cue will be laid out as separate lines.
|
|
357
|
+
* @type {boolean}
|
|
358
|
+
* @exportDoc
|
|
359
|
+
*/
|
|
360
|
+
this.isContainer;
|
|
361
|
+
|
|
352
362
|
/**
|
|
353
363
|
* Whether or not the cue only acts as a line break between two nested cues.
|
|
354
364
|
* Should only appear in nested cues.
|