rx-player 4.0.0-dev.2023110700 → 4.0.0-dev.2023120600
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/CHANGELOG.md +18 -226
- package/FILES.md +1 -1
- package/VERSION +1 -1
- package/dist/_esm5.processed/compat/add_text_track.d.ts +1 -3
- package/dist/_esm5.processed/compat/add_text_track.js +4 -7
- package/dist/_esm5.processed/compat/browser_compatibility_types.d.ts +0 -7
- package/dist/_esm5.processed/compat/event_listeners.d.ts +2 -15
- package/dist/_esm5.processed/compat/event_listeners.js +2 -37
- package/dist/_esm5.processed/compat/index.d.ts +1 -3
- package/dist/_esm5.processed/compat/index.js +1 -3
- package/dist/_esm5.processed/config.d.ts +9 -21
- package/dist/_esm5.processed/core/adaptive/adaptive_representation_selector.d.ts +0 -58
- package/dist/_esm5.processed/core/adaptive/adaptive_representation_selector.js +14 -54
- package/dist/_esm5.processed/core/adaptive/utils/select_optimal_representation.d.ts +2 -8
- package/dist/_esm5.processed/core/adaptive/utils/select_optimal_representation.js +2 -11
- package/dist/_esm5.processed/core/api/debug/buffer_graph.js +2 -6
- package/dist/_esm5.processed/core/api/debug/modules/general_info.js +13 -32
- package/dist/_esm5.processed/core/api/debug/modules/segment_buffer_content.js +3 -3
- package/dist/_esm5.processed/core/api/debug/modules/segment_buffer_size.js +1 -1
- package/dist/_esm5.processed/core/api/option_utils.d.ts +14 -35
- package/dist/_esm5.processed/core/api/option_utils.js +47 -230
- package/dist/_esm5.processed/core/api/public_api.d.ts +92 -266
- package/dist/_esm5.processed/core/api/public_api.js +451 -807
- package/dist/_esm5.processed/core/{segment_buffers/implementations/image → api/track_management}/index.d.ts +3 -2
- package/dist/_esm5.processed/core/{segment_buffers/implementations/image → api/track_management}/index.js +3 -2
- package/dist/_esm5.processed/core/api/{tracks_management/media_element_track_choice_manager.d.ts → track_management/media_element_tracks_store.d.ts} +15 -75
- package/dist/_esm5.processed/core/api/{tracks_management/media_element_track_choice_manager.js → track_management/media_element_tracks_store.js} +74 -193
- package/dist/_esm5.processed/core/api/track_management/track_dispatcher.d.ts +84 -0
- package/dist/_esm5.processed/core/api/track_management/track_dispatcher.js +158 -0
- package/dist/_esm5.processed/core/api/track_management/tracks_store.d.ts +406 -0
- package/dist/_esm5.processed/core/api/track_management/tracks_store.js +932 -0
- package/dist/_esm5.processed/core/api/utils.d.ts +1 -0
- package/dist/_esm5.processed/core/api/utils.js +28 -11
- package/dist/_esm5.processed/core/decrypt/content_decryptor.js +3 -3
- package/dist/_esm5.processed/core/decrypt/find_key_system.js +83 -71
- package/dist/_esm5.processed/core/decrypt/get_media_keys.js +6 -5
- package/dist/_esm5.processed/core/decrypt/session_events_listener.js +10 -72
- package/dist/_esm5.processed/core/decrypt/utils/persistent_sessions_store.d.ts +4 -4
- package/dist/_esm5.processed/core/decrypt/utils/persistent_sessions_store.js +6 -4
- package/dist/_esm5.processed/core/fetchers/manifest/manifest_fetcher.d.ts +1 -3
- package/dist/_esm5.processed/core/fetchers/manifest/manifest_fetcher.js +7 -26
- package/dist/_esm5.processed/core/fetchers/segment/segment_fetcher.d.ts +3 -9
- package/dist/_esm5.processed/core/fetchers/segment/segment_fetcher.js +16 -9
- package/dist/_esm5.processed/core/fetchers/segment/segment_fetcher_creator.d.ts +1 -3
- package/dist/_esm5.processed/core/fetchers/segment/segment_fetcher_creator.js +1 -1
- package/dist/_esm5.processed/core/fetchers/utils/schedule_request.d.ts +1 -6
- package/dist/_esm5.processed/core/fetchers/utils/schedule_request.js +4 -41
- package/dist/_esm5.processed/core/init/directfile_content_initializer.js +1 -1
- package/dist/_esm5.processed/core/init/media_source_content_initializer.d.ts +1 -8
- package/dist/_esm5.processed/core/init/media_source_content_initializer.js +5 -19
- package/dist/_esm5.processed/core/init/types.d.ts +5 -15
- package/dist/_esm5.processed/core/init/utils/rebuffering_controller.d.ts +2 -36
- package/dist/_esm5.processed/core/init/utils/rebuffering_controller.js +2 -82
- package/dist/_esm5.processed/core/segment_buffers/implementations/text/html/text_track_cues_store.js +54 -6
- package/dist/_esm5.processed/core/segment_buffers/implementations/text/html/utils.d.ts +2 -1
- package/dist/_esm5.processed/core/segment_buffers/implementations/text/html/utils.js +19 -2
- package/dist/_esm5.processed/core/segment_buffers/implementations/text/native/native_text_segment_buffer.d.ts +1 -2
- package/dist/_esm5.processed/core/segment_buffers/implementations/text/native/native_text_segment_buffer.js +2 -3
- package/dist/_esm5.processed/core/segment_buffers/implementations/types.d.ts +2 -2
- package/dist/_esm5.processed/core/segment_buffers/index.d.ts +2 -2
- package/dist/_esm5.processed/core/segment_buffers/index.js +2 -1
- package/dist/_esm5.processed/core/segment_buffers/inventory/index.d.ts +1 -0
- package/dist/_esm5.processed/core/segment_buffers/inventory/index.js +1 -0
- package/dist/_esm5.processed/core/segment_buffers/inventory/utils.d.ts +33 -0
- package/dist/_esm5.processed/core/segment_buffers/inventory/utils.js +49 -0
- package/dist/_esm5.processed/core/segment_buffers/segment_buffers_store.d.ts +0 -1
- package/dist/_esm5.processed/core/segment_buffers/segment_buffers_store.js +2 -16
- package/dist/_esm5.processed/core/stream/adaptation/adaptation_stream.d.ts +0 -15
- package/dist/_esm5.processed/core/stream/adaptation/adaptation_stream.js +183 -93
- package/dist/_esm5.processed/core/stream/adaptation/get_representations_switch_strategy.d.ts +39 -0
- package/dist/_esm5.processed/core/stream/adaptation/get_representations_switch_strategy.js +133 -0
- package/dist/_esm5.processed/core/stream/adaptation/types.d.ts +27 -13
- package/dist/_esm5.processed/core/stream/index.d.ts +2 -3
- package/dist/_esm5.processed/core/stream/orchestrator/stream_orchestrator.d.ts +2 -0
- package/dist/_esm5.processed/core/stream/orchestrator/stream_orchestrator.js +5 -7
- package/dist/_esm5.processed/core/stream/period/period_stream.js +13 -12
- package/dist/_esm5.processed/core/stream/period/types.d.ts +5 -14
- package/dist/_esm5.processed/core/stream/period/utils/get_adaptation_switch_strategy.d.ts +2 -4
- package/dist/_esm5.processed/core/stream/period/utils/get_adaptation_switch_strategy.js +10 -46
- package/dist/_esm5.processed/core/stream/representation/representation_stream.js +29 -23
- package/dist/_esm5.processed/core/stream/representation/types.d.ts +11 -1
- package/dist/_esm5.processed/default_config.d.ts +35 -98
- package/dist/_esm5.processed/default_config.js +36 -113
- package/dist/_esm5.processed/errors/custom_loader_error.d.ts +1 -3
- package/dist/_esm5.processed/errors/custom_loader_error.js +1 -3
- package/dist/_esm5.processed/errors/media_error.js +2 -2
- package/dist/_esm5.processed/errors/network_error.d.ts +0 -1
- package/dist/_esm5.processed/errors/network_error.js +0 -1
- package/dist/_esm5.processed/errors/request_error.d.ts +2 -3
- package/dist/_esm5.processed/errors/request_error.js +2 -5
- package/dist/_esm5.processed/experimental/tools/VideoThumbnailLoader/video_thumbnail_loader.js +3 -3
- package/dist/_esm5.processed/features/features_object.js +0 -2
- package/dist/_esm5.processed/features/list/directfile.js +2 -5
- package/dist/_esm5.processed/features/list/index.d.ts +0 -2
- package/dist/_esm5.processed/features/list/index.js +0 -2
- package/dist/_esm5.processed/features/types.d.ts +3 -27
- package/dist/_esm5.processed/manifest/adaptation.d.ts +9 -11
- package/dist/_esm5.processed/manifest/adaptation.js +41 -30
- package/dist/_esm5.processed/manifest/index.d.ts +3 -4
- package/dist/_esm5.processed/manifest/manifest.d.ts +5 -54
- package/dist/_esm5.processed/manifest/manifest.js +5 -110
- package/dist/_esm5.processed/manifest/period.d.ts +4 -5
- package/dist/_esm5.processed/manifest/representation.d.ts +10 -5
- package/dist/_esm5.processed/manifest/representation.js +33 -10
- package/dist/_esm5.processed/manifest/representation_index/index.d.ts +2 -2
- package/dist/_esm5.processed/manifest/representation_index/static.d.ts +2 -0
- package/dist/_esm5.processed/manifest/representation_index/static.js +6 -0
- package/dist/_esm5.processed/manifest/representation_index/types.d.ts +42 -21
- package/dist/_esm5.processed/manifest/types.d.ts +0 -2
- package/dist/_esm5.processed/parsers/manifest/dash/common/convert_supplemental_codecs.d.ts +17 -0
- package/dist/_esm5.processed/parsers/manifest/dash/common/convert_supplemental_codecs.js +26 -0
- package/dist/_esm5.processed/parsers/manifest/dash/common/flatten_overlapping_periods.js +5 -0
- package/dist/_esm5.processed/parsers/manifest/dash/common/indexes/base.d.ts +17 -31
- package/dist/_esm5.processed/parsers/manifest/dash/common/indexes/base.js +26 -19
- package/dist/_esm5.processed/parsers/manifest/dash/common/indexes/list.d.ts +2 -0
- package/dist/_esm5.processed/parsers/manifest/dash/common/indexes/list.js +7 -1
- package/dist/_esm5.processed/parsers/manifest/dash/common/indexes/template.d.ts +2 -6
- package/dist/_esm5.processed/parsers/manifest/dash/common/indexes/template.js +11 -8
- package/dist/_esm5.processed/parsers/manifest/dash/common/indexes/timeline/timeline_representation_index.d.ts +2 -0
- package/dist/_esm5.processed/parsers/manifest/dash/common/indexes/timeline/timeline_representation_index.js +6 -0
- package/dist/_esm5.processed/parsers/manifest/dash/common/infer_adaptation_type.d.ts +2 -2
- package/dist/_esm5.processed/parsers/manifest/dash/common/infer_adaptation_type.js +1 -6
- package/dist/_esm5.processed/parsers/manifest/dash/common/parse_adaptation_sets.js +3 -5
- package/dist/_esm5.processed/parsers/manifest/dash/common/parse_mpd.d.ts +0 -2
- package/dist/_esm5.processed/parsers/manifest/dash/common/parse_mpd.js +1 -1
- package/dist/_esm5.processed/parsers/manifest/dash/common/parse_periods.js +2 -2
- package/dist/_esm5.processed/parsers/manifest/dash/common/parse_representation_index.d.ts +0 -2
- package/dist/_esm5.processed/parsers/manifest/dash/common/parse_representation_index.js +2 -2
- package/dist/_esm5.processed/parsers/manifest/dash/common/parse_representations.js +29 -17
- package/dist/_esm5.processed/parsers/manifest/dash/js-parser/node_parsers/AdaptationSet.js +13 -6
- package/dist/_esm5.processed/parsers/manifest/dash/js-parser/node_parsers/Representation.js +7 -2
- package/dist/_esm5.processed/parsers/manifest/dash/js-parser/node_parsers/utils.d.ts +10 -1
- package/dist/_esm5.processed/parsers/manifest/dash/js-parser/node_parsers/utils.js +18 -2
- package/dist/_esm5.processed/parsers/manifest/dash/node_parser_types.d.ts +6 -4
- package/dist/_esm5.processed/parsers/manifest/dash/wasm-parser/ts/generators/AdaptationSet.js +7 -6
- package/dist/_esm5.processed/parsers/manifest/dash/wasm-parser/ts/generators/Representation.js +5 -2
- package/dist/_esm5.processed/parsers/manifest/dash/wasm-parser/ts/types.d.ts +2 -1
- package/dist/_esm5.processed/parsers/manifest/local/representation_index.d.ts +2 -0
- package/dist/_esm5.processed/parsers/manifest/local/representation_index.js +6 -0
- package/dist/_esm5.processed/parsers/manifest/metaplaylist/metaplaylist_parser.js +6 -6
- package/dist/_esm5.processed/parsers/manifest/metaplaylist/representation_index.d.ts +12 -3
- package/dist/_esm5.processed/parsers/manifest/metaplaylist/representation_index.js +11 -2
- package/dist/_esm5.processed/parsers/manifest/smooth/create_parser.d.ts +0 -1
- package/dist/_esm5.processed/parsers/manifest/smooth/create_parser.js +11 -17
- package/dist/_esm5.processed/parsers/manifest/smooth/representation_index.d.ts +21 -83
- package/dist/_esm5.processed/parsers/manifest/smooth/representation_index.js +53 -125
- package/dist/_esm5.processed/parsers/manifest/smooth/shared_smooth_segment_timeline.d.ts +119 -0
- package/dist/_esm5.processed/parsers/manifest/smooth/shared_smooth_segment_timeline.js +159 -0
- package/dist/_esm5.processed/parsers/manifest/smooth/utils/add_segment_infos.d.ts +3 -6
- package/dist/_esm5.processed/parsers/manifest/smooth/utils/add_segment_infos.js +4 -4
- package/dist/_esm5.processed/parsers/manifest/types.d.ts +4 -3
- package/dist/_esm5.processed/parsers/texttracks/ttml/html/apply_extent.js +1 -8
- package/dist/_esm5.processed/parsers/texttracks/ttml/html/apply_origin.js +1 -9
- package/dist/_esm5.processed/public_types.d.ts +396 -308
- package/dist/_esm5.processed/tools/TextTrackRenderer/text_track_renderer.d.ts +5 -4
- package/dist/_esm5.processed/tools/TextTrackRenderer/text_track_renderer.js +5 -4
- package/dist/_esm5.processed/transports/dash/add_segment_integrity_checks_to_loader.js +4 -4
- package/dist/_esm5.processed/transports/dash/manifest_parser.js +2 -3
- package/dist/_esm5.processed/transports/dash/pipelines.js +1 -4
- package/dist/_esm5.processed/transports/dash/segment_loader.d.ts +2 -2
- package/dist/_esm5.processed/transports/dash/segment_loader.js +26 -20
- package/dist/_esm5.processed/transports/dash/segment_parser.js +19 -24
- package/dist/_esm5.processed/transports/dash/text_loader.js +5 -5
- package/dist/_esm5.processed/transports/dash/text_parser.js +28 -33
- package/dist/_esm5.processed/transports/local/pipelines.js +1 -10
- package/dist/_esm5.processed/transports/local/segment_loader.js +2 -2
- package/dist/_esm5.processed/transports/local/segment_parser.d.ts +1 -1
- package/dist/_esm5.processed/transports/local/segment_parser.js +10 -10
- package/dist/_esm5.processed/transports/local/text_parser.d.ts +2 -2
- package/dist/_esm5.processed/transports/local/text_parser.js +23 -23
- package/dist/_esm5.processed/transports/metaplaylist/pipelines.js +34 -52
- package/dist/_esm5.processed/{utils/list_to_map.d.ts → transports/smooth/is_mp4_embedded_track.d.ts} +5 -5
- package/dist/_esm5.processed/{features/list/image_buffer.d.ts → transports/smooth/is_mp4_embedded_track.js} +7 -6
- package/dist/_esm5.processed/transports/smooth/pipelines.js +33 -190
- package/dist/_esm5.processed/transports/smooth/segment_loader.d.ts +1 -1
- package/dist/_esm5.processed/transports/smooth/segment_loader.js +28 -22
- package/dist/_esm5.processed/transports/smooth/utils.d.ts +1 -26
- package/dist/_esm5.processed/transports/smooth/utils.js +1 -55
- package/dist/_esm5.processed/transports/types.d.ts +94 -89
- package/dist/_esm5.processed/transports/utils/call_custom_manifest_loader.js +3 -3
- package/dist/_esm5.processed/transports/utils/infer_segment_container.d.ts +3 -3
- package/dist/_esm5.processed/transports/utils/infer_segment_container.js +5 -7
- package/dist/_esm5.processed/transports/utils/parse_text_track.d.ts +8 -12
- package/dist/_esm5.processed/transports/utils/parse_text_track.js +19 -21
- package/dist/_esm5.processed/utils/array_includes.d.ts +2 -1
- package/dist/_esm5.processed/utils/array_includes.js +30 -28
- package/dist/_esm5.processed/utils/request/xhr.js +5 -5
- package/dist/commonjs/compat/is_codec_supported.js +22 -1
- package/dist/commonjs/compat/patch_webkit_source_buffer.js +2 -2
- package/dist/commonjs/config.d.ts +1 -0
- package/dist/commonjs/core/api/debug/buffer_graph.js +2 -6
- package/dist/commonjs/core/api/debug/modules/general_info.js +17 -10
- package/dist/commonjs/core/api/option_utils.d.ts +4 -0
- package/dist/commonjs/core/api/option_utils.js +8 -3
- package/dist/commonjs/core/api/public_api.d.ts +11 -1
- package/dist/commonjs/core/api/public_api.js +46 -11
- package/dist/commonjs/core/fetchers/manifest/manifest_fetcher.d.ts +6 -0
- package/dist/commonjs/core/fetchers/manifest/manifest_fetcher.js +11 -3
- package/dist/commonjs/core/fetchers/segment/segment_fetcher.d.ts +8 -1
- package/dist/commonjs/core/fetchers/segment/segment_fetcher.js +8 -4
- package/dist/commonjs/core/fetchers/segment/segment_fetcher_creator.d.ts +1 -0
- package/dist/commonjs/core/fetchers/utils/schedule_request.js +1 -1
- package/dist/commonjs/core/init/directfile_content_initializer.js +24 -7
- package/dist/commonjs/core/init/media_source_content_initializer.d.ts +6 -0
- package/dist/commonjs/core/init/media_source_content_initializer.js +4 -6
- package/dist/commonjs/core/init/utils/content_time_boundaries_observer.d.ts +13 -12
- package/dist/commonjs/core/init/utils/content_time_boundaries_observer.js +16 -17
- package/dist/commonjs/core/init/utils/get_initial_time.d.ts +17 -3
- package/dist/commonjs/core/init/utils/get_initial_time.js +9 -7
- package/dist/commonjs/core/segment_buffers/implementations/text/html/text_track_cues_store.js +54 -6
- package/dist/commonjs/core/segment_buffers/implementations/text/html/utils.d.ts +2 -1
- package/dist/commonjs/core/segment_buffers/implementations/text/html/utils.js +19 -2
- package/dist/commonjs/core/stream/adaptation/adaptation_stream.js +2 -2
- package/dist/commonjs/core/stream/orchestrator/stream_orchestrator.js +3 -3
- package/dist/commonjs/core/stream/period/period_stream.js +2 -2
- package/dist/commonjs/core/stream/representation/utils/get_buffer_status.js +3 -3
- package/dist/commonjs/core/stream/representation/utils/get_needed_segments.js +1 -1
- package/dist/commonjs/default_config.d.ts +5 -0
- package/dist/commonjs/default_config.js +5 -0
- package/dist/commonjs/experimental/tools/VideoThumbnailLoader/video_thumbnail_loader.js +3 -1
- package/dist/commonjs/experimental/tools/createMetaplaylist/get_duration_from_manifest.js +2 -0
- package/dist/commonjs/manifest/representation.js +18 -5
- package/dist/commonjs/manifest/representation_index/static.d.ts +1 -1
- package/dist/commonjs/manifest/representation_index/static.js +2 -2
- package/dist/commonjs/manifest/representation_index/types.d.ts +4 -4
- package/dist/commonjs/parsers/manifest/dash/common/convert_supplemental_codecs.d.ts +17 -0
- package/dist/commonjs/parsers/manifest/dash/common/convert_supplemental_codecs.js +30 -0
- package/dist/commonjs/parsers/manifest/dash/common/flatten_overlapping_periods.js +5 -0
- package/dist/commonjs/parsers/manifest/dash/common/indexes/base.d.ts +6 -1
- package/dist/commonjs/parsers/manifest/dash/common/indexes/base.js +4 -3
- package/dist/commonjs/parsers/manifest/dash/common/indexes/get_segments_from_timeline.d.ts +5 -2
- package/dist/commonjs/parsers/manifest/dash/common/indexes/get_segments_from_timeline.js +15 -4
- package/dist/commonjs/parsers/manifest/dash/common/indexes/index.d.ts +5 -5
- package/dist/commonjs/parsers/manifest/dash/common/indexes/list.d.ts +1 -1
- package/dist/commonjs/parsers/manifest/dash/common/indexes/list.js +2 -2
- package/dist/commonjs/parsers/manifest/dash/common/indexes/template.d.ts +12 -5
- package/dist/commonjs/parsers/manifest/dash/common/indexes/template.js +42 -29
- package/dist/commonjs/parsers/manifest/dash/common/indexes/timeline/index.d.ts +2 -1
- package/dist/commonjs/parsers/manifest/dash/common/indexes/timeline/timeline_representation_index.d.ts +99 -6
- package/dist/commonjs/parsers/manifest/dash/common/indexes/timeline/timeline_representation_index.js +250 -51
- package/dist/commonjs/parsers/manifest/dash/common/manifest_bounds_calculator.d.ts +40 -17
- package/dist/commonjs/parsers/manifest/dash/common/manifest_bounds_calculator.js +38 -18
- package/dist/commonjs/parsers/manifest/dash/common/parse_adaptation_sets.js +13 -10
- package/dist/commonjs/parsers/manifest/dash/common/parse_mpd.js +27 -14
- package/dist/commonjs/parsers/manifest/dash/common/parse_periods.d.ts +1 -1
- package/dist/commonjs/parsers/manifest/dash/common/parse_periods.js +17 -18
- package/dist/commonjs/parsers/manifest/dash/common/parse_representation_index.d.ts +19 -6
- package/dist/commonjs/parsers/manifest/dash/common/parse_representation_index.js +21 -8
- package/dist/commonjs/parsers/manifest/dash/common/parse_representations.js +36 -20
- package/dist/commonjs/parsers/manifest/dash/js-parser/node_parsers/AdaptationSet.js +3 -0
- package/dist/commonjs/parsers/manifest/dash/js-parser/node_parsers/Representation.js +3 -0
- package/dist/commonjs/parsers/manifest/dash/node_parser_types.d.ts +2 -0
- package/dist/commonjs/parsers/manifest/dash/wasm-parser/ts/generators/AdaptationSet.js +4 -0
- package/dist/commonjs/parsers/manifest/dash/wasm-parser/ts/generators/Representation.js +4 -0
- package/dist/commonjs/parsers/manifest/dash/wasm-parser/ts/types.d.ts +2 -1
- package/dist/commonjs/parsers/manifest/local/representation_index.d.ts +1 -1
- package/dist/commonjs/parsers/manifest/local/representation_index.js +3 -3
- package/dist/commonjs/parsers/manifest/metaplaylist/representation_index.d.ts +1 -1
- package/dist/commonjs/parsers/manifest/metaplaylist/representation_index.js +2 -2
- package/dist/commonjs/parsers/manifest/smooth/representation_index.d.ts +5 -5
- package/dist/commonjs/parsers/manifest/smooth/representation_index.js +25 -9
- package/dist/commonjs/parsers/manifest/types.d.ts +1 -0
- package/dist/commonjs/parsers/manifest/utils/index_helpers.js +1 -1
- package/dist/commonjs/public_types.d.ts +78 -34
- package/dist/commonjs/transports/dash/init_segment_loader.js +10 -5
- package/dist/commonjs/transports/dash/manifest_parser.js +5 -2
- package/dist/commonjs/transports/dash/segment_loader.js +2 -1
- package/dist/commonjs/transports/dash/text_loader.js +2 -0
- package/dist/commonjs/transports/metaplaylist/manifest_loader.js +2 -1
- package/dist/commonjs/transports/metaplaylist/pipelines.js +4 -1
- package/dist/commonjs/transports/smooth/pipelines.js +4 -2
- package/dist/commonjs/transports/smooth/segment_loader.js +2 -1
- package/dist/commonjs/transports/types.d.ts +12 -0
- package/dist/commonjs/transports/utils/generate_manifest_loader.js +6 -3
- package/dist/commonjs/utils/queue_microtask.d.ts +2 -0
- package/dist/commonjs/utils/queue_microtask.js +7 -0
- package/dist/commonjs/utils/request/fetch.d.ts +6 -0
- package/dist/commonjs/utils/request/fetch.js +29 -8
- package/dist/commonjs/utils/request/xhr.d.ts +11 -5
- package/dist/commonjs/utils/request/xhr.js +29 -8
- package/dist/es2017/compat/is_codec_supported.js +22 -1
- package/dist/es2017/compat/patch_webkit_source_buffer.js +2 -2
- package/dist/es2017/config.d.ts +1 -0
- package/dist/es2017/core/api/debug/buffer_graph.js +2 -6
- package/dist/es2017/core/api/debug/modules/general_info.js +17 -10
- package/dist/es2017/core/api/option_utils.d.ts +4 -0
- package/dist/es2017/core/api/option_utils.js +8 -3
- package/dist/es2017/core/api/public_api.d.ts +11 -1
- package/dist/es2017/core/api/public_api.js +44 -9
- package/dist/es2017/core/fetchers/manifest/manifest_fetcher.d.ts +6 -0
- package/dist/es2017/core/fetchers/manifest/manifest_fetcher.js +11 -3
- package/dist/es2017/core/fetchers/segment/segment_fetcher.d.ts +8 -1
- package/dist/es2017/core/fetchers/segment/segment_fetcher.js +8 -4
- package/dist/es2017/core/fetchers/segment/segment_fetcher_creator.d.ts +1 -0
- package/dist/es2017/core/fetchers/utils/schedule_request.js +1 -1
- package/dist/es2017/core/init/directfile_content_initializer.js +24 -7
- package/dist/es2017/core/init/media_source_content_initializer.d.ts +6 -0
- package/dist/es2017/core/init/media_source_content_initializer.js +4 -6
- package/dist/es2017/core/init/utils/content_time_boundaries_observer.d.ts +13 -12
- package/dist/es2017/core/init/utils/content_time_boundaries_observer.js +16 -15
- package/dist/es2017/core/init/utils/get_initial_time.d.ts +17 -3
- package/dist/es2017/core/init/utils/get_initial_time.js +9 -7
- package/dist/es2017/core/segment_buffers/implementations/text/html/text_track_cues_store.js +54 -6
- package/dist/es2017/core/segment_buffers/implementations/text/html/utils.d.ts +2 -1
- package/dist/es2017/core/segment_buffers/implementations/text/html/utils.js +18 -2
- package/dist/es2017/core/stream/adaptation/adaptation_stream.js +2 -2
- package/dist/es2017/core/stream/orchestrator/stream_orchestrator.js +3 -3
- package/dist/es2017/core/stream/period/period_stream.js +2 -2
- package/dist/es2017/core/stream/representation/utils/get_buffer_status.js +3 -3
- package/dist/es2017/core/stream/representation/utils/get_needed_segments.js +1 -1
- package/dist/es2017/default_config.d.ts +5 -0
- package/dist/es2017/default_config.js +5 -0
- package/dist/es2017/experimental/tools/VideoThumbnailLoader/video_thumbnail_loader.js +3 -1
- package/dist/es2017/experimental/tools/createMetaplaylist/get_duration_from_manifest.js +2 -0
- package/dist/es2017/manifest/representation.js +18 -5
- package/dist/es2017/manifest/representation_index/static.d.ts +1 -1
- package/dist/es2017/manifest/representation_index/static.js +2 -2
- package/dist/es2017/manifest/representation_index/types.d.ts +4 -4
- package/dist/es2017/parsers/manifest/dash/common/convert_supplemental_codecs.d.ts +17 -0
- package/dist/es2017/parsers/manifest/dash/common/convert_supplemental_codecs.js +26 -0
- package/dist/es2017/parsers/manifest/dash/common/flatten_overlapping_periods.js +5 -0
- package/dist/es2017/parsers/manifest/dash/common/indexes/base.d.ts +6 -1
- package/dist/es2017/parsers/manifest/dash/common/indexes/base.js +4 -3
- package/dist/es2017/parsers/manifest/dash/common/indexes/get_segments_from_timeline.d.ts +5 -2
- package/dist/es2017/parsers/manifest/dash/common/indexes/get_segments_from_timeline.js +15 -4
- package/dist/es2017/parsers/manifest/dash/common/indexes/index.d.ts +5 -5
- package/dist/es2017/parsers/manifest/dash/common/indexes/list.d.ts +1 -1
- package/dist/es2017/parsers/manifest/dash/common/indexes/list.js +2 -2
- package/dist/es2017/parsers/manifest/dash/common/indexes/template.d.ts +12 -5
- package/dist/es2017/parsers/manifest/dash/common/indexes/template.js +40 -27
- package/dist/es2017/parsers/manifest/dash/common/indexes/timeline/index.d.ts +2 -1
- package/dist/es2017/parsers/manifest/dash/common/indexes/timeline/timeline_representation_index.d.ts +99 -6
- package/dist/es2017/parsers/manifest/dash/common/indexes/timeline/timeline_representation_index.js +246 -51
- package/dist/es2017/parsers/manifest/dash/common/manifest_bounds_calculator.d.ts +40 -17
- package/dist/es2017/parsers/manifest/dash/common/manifest_bounds_calculator.js +38 -18
- package/dist/es2017/parsers/manifest/dash/common/parse_adaptation_sets.js +11 -8
- package/dist/es2017/parsers/manifest/dash/common/parse_mpd.js +27 -13
- package/dist/es2017/parsers/manifest/dash/common/parse_periods.d.ts +1 -1
- package/dist/es2017/parsers/manifest/dash/common/parse_periods.js +13 -16
- package/dist/es2017/parsers/manifest/dash/common/parse_representation_index.d.ts +19 -6
- package/dist/es2017/parsers/manifest/dash/common/parse_representation_index.js +10 -8
- package/dist/es2017/parsers/manifest/dash/common/parse_representations.js +36 -20
- package/dist/es2017/parsers/manifest/dash/js-parser/node_parsers/AdaptationSet.js +3 -0
- package/dist/es2017/parsers/manifest/dash/js-parser/node_parsers/Representation.js +3 -0
- package/dist/es2017/parsers/manifest/dash/node_parser_types.d.ts +2 -0
- package/dist/es2017/parsers/manifest/dash/wasm-parser/ts/generators/AdaptationSet.js +4 -0
- package/dist/es2017/parsers/manifest/dash/wasm-parser/ts/generators/Representation.js +4 -0
- package/dist/es2017/parsers/manifest/dash/wasm-parser/ts/types.d.ts +2 -1
- package/dist/es2017/parsers/manifest/local/representation_index.d.ts +1 -1
- package/dist/es2017/parsers/manifest/local/representation_index.js +3 -3
- package/dist/es2017/parsers/manifest/metaplaylist/representation_index.d.ts +1 -1
- package/dist/es2017/parsers/manifest/metaplaylist/representation_index.js +2 -2
- package/dist/es2017/parsers/manifest/smooth/representation_index.d.ts +5 -5
- package/dist/es2017/parsers/manifest/smooth/representation_index.js +25 -9
- package/dist/es2017/parsers/manifest/types.d.ts +1 -0
- package/dist/es2017/parsers/manifest/utils/index_helpers.js +1 -1
- package/dist/es2017/public_types.d.ts +78 -34
- package/dist/es2017/transports/dash/init_segment_loader.js +5 -0
- package/dist/es2017/transports/dash/manifest_parser.js +3 -0
- package/dist/es2017/transports/dash/segment_loader.js +1 -0
- package/dist/es2017/transports/dash/text_loader.js +2 -0
- package/dist/es2017/transports/metaplaylist/manifest_loader.js +1 -0
- package/dist/es2017/transports/metaplaylist/pipelines.js +4 -1
- package/dist/es2017/transports/smooth/pipelines.js +2 -0
- package/dist/es2017/transports/smooth/segment_loader.js +1 -0
- package/dist/es2017/transports/types.d.ts +12 -0
- package/dist/es2017/transports/utils/generate_manifest_loader.js +3 -0
- package/dist/es2017/utils/queue_microtask.d.ts +2 -0
- package/dist/es2017/utils/queue_microtask.js +5 -0
- package/dist/es2017/utils/request/fetch.d.ts +6 -0
- package/dist/es2017/utils/request/fetch.js +29 -8
- package/dist/es2017/utils/request/xhr.d.ts +11 -5
- package/dist/es2017/utils/request/xhr.js +30 -9
- package/dist/mpd-parser.wasm +0 -0
- package/dist/rx-player.js +900 -492
- package/dist/rx-player.min.js +1 -1
- package/package.json +3 -7
- package/scripts/update-version +2 -0
- package/sonar-project.properties +1 -1
- package/src/compat/is_codec_supported.ts +23 -1
- package/src/compat/patch_webkit_source_buffer.ts +2 -2
- package/src/core/api/debug/buffer_graph.ts +2 -5
- package/src/core/api/debug/modules/general_info.ts +15 -10
- package/src/core/api/option_utils.ts +11 -3
- package/src/core/api/public_api.ts +48 -8
- package/src/core/fetchers/manifest/manifest_fetcher.ts +21 -3
- package/src/core/fetchers/segment/segment_fetcher.ts +19 -5
- package/src/core/fetchers/segment/segment_fetcher_creator.ts +1 -0
- package/src/core/fetchers/utils/schedule_request.ts +1 -1
- package/src/core/init/directfile_content_initializer.ts +23 -7
- package/src/core/init/media_source_content_initializer.ts +13 -7
- package/src/core/init/utils/content_time_boundaries_observer.ts +23 -22
- package/src/core/init/utils/get_initial_time.ts +25 -12
- package/src/core/segment_buffers/implementations/text/html/__tests__/utils.test.ts +15 -0
- package/src/core/segment_buffers/implementations/text/html/text_track_cues_store.ts +57 -6
- package/src/core/segment_buffers/implementations/text/html/utils.ts +19 -2
- package/src/core/stream/adaptation/adaptation_stream.ts +2 -2
- package/src/core/stream/orchestrator/stream_orchestrator.ts +3 -3
- package/src/core/stream/period/period_stream.ts +2 -2
- package/src/core/stream/representation/utils/get_buffer_status.ts +3 -3
- package/src/core/stream/representation/utils/get_needed_segments.ts +2 -2
- package/src/default_config.ts +5 -0
- package/src/experimental/tools/VideoThumbnailLoader/video_thumbnail_loader.ts +3 -1
- package/src/experimental/tools/createMetaplaylist/get_duration_from_manifest.ts +2 -0
- package/src/manifest/representation.ts +19 -6
- package/src/manifest/representation_index/static.ts +2 -2
- package/src/manifest/representation_index/types.ts +4 -4
- package/src/parsers/manifest/dash/common/__tests__/convert_supplemental_codecs.test.ts +37 -0
- package/src/parsers/manifest/dash/common/__tests__/flatten_overlapping_period.test.ts +20 -0
- package/src/parsers/manifest/dash/common/__tests__/manifest_bounds_calculator.test.ts +182 -36
- package/src/parsers/manifest/dash/common/convert_supplemental_codecs.ts +32 -0
- package/src/parsers/manifest/dash/common/flatten_overlapping_periods.ts +5 -0
- package/src/parsers/manifest/dash/common/indexes/base.ts +12 -4
- package/src/parsers/manifest/dash/common/indexes/get_segments_from_timeline.ts +19 -5
- package/src/parsers/manifest/dash/common/indexes/index.ts +16 -4
- package/src/parsers/manifest/dash/common/indexes/list.ts +2 -2
- package/src/parsers/manifest/dash/common/indexes/template.ts +52 -31
- package/src/parsers/manifest/dash/common/indexes/timeline/index.ts +4 -1
- package/src/parsers/manifest/dash/common/indexes/timeline/timeline_representation_index.ts +366 -60
- package/src/parsers/manifest/dash/common/manifest_bounds_calculator.ts +63 -25
- package/src/parsers/manifest/dash/common/parse_adaptation_sets.ts +10 -4
- package/src/parsers/manifest/dash/common/parse_mpd.ts +28 -15
- package/src/parsers/manifest/dash/common/parse_periods.ts +12 -17
- package/src/parsers/manifest/dash/common/parse_representation_index.ts +50 -26
- package/src/parsers/manifest/dash/common/parse_representations.ts +39 -20
- package/src/parsers/manifest/dash/js-parser/node_parsers/AdaptationSet.ts +4 -0
- package/src/parsers/manifest/dash/js-parser/node_parsers/Representation.ts +4 -0
- package/src/parsers/manifest/dash/node_parser_types.ts +2 -0
- package/src/parsers/manifest/dash/wasm-parser/rs/events.rs +2 -0
- package/src/parsers/manifest/dash/wasm-parser/rs/processor/attributes.rs +2 -0
- package/src/parsers/manifest/dash/wasm-parser/ts/generators/AdaptationSet.ts +4 -0
- package/src/parsers/manifest/dash/wasm-parser/ts/generators/Representation.ts +4 -0
- package/src/parsers/manifest/dash/wasm-parser/ts/types.ts +2 -0
- package/src/parsers/manifest/local/representation_index.ts +3 -3
- package/src/parsers/manifest/metaplaylist/representation_index.ts +2 -2
- package/src/parsers/manifest/smooth/representation_index.ts +23 -9
- package/src/parsers/manifest/types.ts +2 -0
- package/src/parsers/manifest/utils/__tests__/get_first_time_from_adaptations.test.ts +1 -1
- package/src/parsers/manifest/utils/__tests__/get_last_time_from_adaptation.test.ts +1 -1
- package/src/parsers/manifest/utils/index_helpers.ts +1 -1
- package/src/public_types.ts +79 -34
- package/src/transports/dash/init_segment_loader.ts +5 -0
- package/src/transports/dash/manifest_parser.ts +6 -0
- package/src/transports/dash/segment_loader.ts +1 -0
- package/src/transports/dash/text_loader.ts +2 -0
- package/src/transports/metaplaylist/manifest_loader.ts +1 -0
- package/src/transports/metaplaylist/pipelines.ts +4 -1
- package/src/transports/smooth/pipelines.ts +2 -0
- package/src/transports/smooth/segment_loader.ts +1 -0
- package/src/transports/types.ts +12 -0
- package/src/transports/utils/generate_manifest_loader.ts +3 -0
- package/src/utils/queue_microtask.ts +7 -0
- package/src/utils/request/fetch.ts +35 -8
- package/src/utils/request/xhr.ts +45 -14
- package/dist/_esm5.processed/compat/fullscreen.d.ts +0 -32
- package/dist/_esm5.processed/compat/fullscreen.js +0 -78
- package/dist/_esm5.processed/compat/is_offline.d.ts +0 -39
- package/dist/_esm5.processed/compat/is_offline.js +0 -43
- package/dist/_esm5.processed/core/api/tracks_management/track_choice_manager.d.ts +0 -258
- package/dist/_esm5.processed/core/api/tracks_management/track_choice_manager.js +0 -989
- package/dist/_esm5.processed/core/segment_buffers/implementations/image/image_segment_buffer.d.ts +0 -75
- package/dist/_esm5.processed/core/segment_buffers/implementations/image/image_segment_buffer.js +0 -133
- package/dist/_esm5.processed/features/list/bif_parser.d.ts +0 -23
- package/dist/_esm5.processed/features/list/bif_parser.js +0 -27
- package/dist/_esm5.processed/features/list/image_buffer.js +0 -25
- package/dist/_esm5.processed/transports/dash/image_pipelines.d.ts +0 -38
- package/dist/_esm5.processed/transports/dash/image_pipelines.js +0 -129
- package/dist/_esm5.processed/utils/list_to_map.js +0 -28
- package/dist/_esm5.processed/utils/simple_set.d.ts +0 -51
- package/dist/_esm5.processed/utils/simple_set.js +0 -57
- package/dist/_esm5.processed/utils/uniq.d.ts +0 -36
- package/dist/_esm5.processed/utils/uniq.js +0 -43
- package/dist/commonjs/parsers/manifest/utils/is_segment_still_available.d.ts +0 -29
- package/dist/commonjs/parsers/manifest/utils/is_segment_still_available.js +0 -54
- package/dist/es2017/parsers/manifest/utils/is_segment_still_available.d.ts +0 -29
- package/dist/es2017/parsers/manifest/utils/is_segment_still_available.js +0 -51
- package/src/parsers/manifest/utils/is_segment_still_available.ts +0 -58
- package/src/typings/next-tick.d.ts +0 -23
- package/src/typings/object-assign.d.ts +0 -48
package/CHANGELOG.md
CHANGED
|
@@ -1,183 +1,32 @@
|
|
|
1
1
|
# Changelog
|
|
2
2
|
|
|
3
|
-
## v4.0.0-dev.
|
|
4
|
-
|
|
5
|
-
### Bug fixes
|
|
6
|
-
|
|
7
|
-
- Fix import of the `LOCAL_MANIFEST` experimental feature
|
|
8
|
-
- Smooth: Rely on a defined `segmentLoader` when playing smooth streaming contents.
|
|
9
|
-
|
|
10
|
-
### Other improvements
|
|
11
|
-
|
|
12
|
-
- Provide both commonJS and ES6-style exports to improve compatibilities with applications
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
## v4.0.0-beta.3 (2023-10-19)
|
|
16
|
-
|
|
17
|
-
### Changes
|
|
18
|
-
|
|
19
|
-
- The `MediaError`'s `trackInfo` property is now an array renamed as `tracksInfo` and similar `MediaError` are grouped in one [#1264]
|
|
20
|
-
- The `manifestUpdateUrl` `loadVideo` option has been removed as it was unused [#1276]
|
|
21
|
-
- The `/dist` directory in the project has been removed [#1270]
|
|
22
|
-
|
|
23
|
-
### Bug fixes
|
|
24
|
-
|
|
25
|
-
- Fix adaptive logic on some legacy Edge browsers [#1302]
|
|
26
|
-
|
|
27
|
-
### Other improvements
|
|
28
|
-
|
|
29
|
-
- `newAvailablePeriods` is now sent lazily at the time new Periods are considered to improve performance [#1265]
|
|
30
|
-
- Implement better error messages by not repeating the Error Type in it [#1290]
|
|
31
|
-
- All import path to the RxPlayer now depend on the same RxPlayer modular build (and not just the minimal, as before) [#1301]
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
## v4.0.0-beta.2 (2023-06-27)
|
|
35
|
-
|
|
36
|
-
### Changes
|
|
37
|
-
|
|
38
|
-
- If all Representations from the current track become undecipherable, automatically switch to another track (also send a `trackUpdate` event) instead of stopping on error [#1234]
|
|
39
|
-
- Only send `MediaError` errors with the `NO_PLAYABLE_REPRESENTATION` error code when no Representation from all tracks of a given type can be played [#1234]
|
|
40
|
-
|
|
41
|
-
### Features
|
|
42
|
-
|
|
43
|
-
- Add `representationListUpdate` event for when the list of available Representation for a current track changes [#1240]
|
|
44
|
-
- Add `"no-playable-representation"` as a `reason` for `trackUpdate` events when the track switch is due to encrypted Representations [#1234]
|
|
45
|
-
|
|
46
|
-
### Other improvements
|
|
47
|
-
|
|
48
|
-
- DRM: Reload when playback is unexpectedly frozen with encrypted but only decipherable data in the buffer to work-around rare encryption-related issues [#1236]
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
## v4.0.0-beta.1 (2023-03-08)
|
|
52
|
-
|
|
53
|
-
### Bug fixes
|
|
54
|
-
|
|
55
|
-
- (v4.0.0-beta.0-only issue) Fix memory leak
|
|
56
|
-
- (v4.0.0-beta.0-only issue) Fix MediaSource duration when the maximum buffered end is inferior to current duration but superior to calculated duration
|
|
57
|
-
- (v4.0.0-beta.0-only issue) Fix `stopAtEnd` option by also switching to STOPPED state on ended
|
|
58
|
-
- (v4.0.0-beta.0-only issue) Fix some target's support by not relying on `Promise.prototype.finally` anymore [#1224]
|
|
59
|
-
- (v4.0.0-beta.0-only issue) For dynamic contents, always set a very high duration [#1220]
|
|
60
|
-
- (v4.0.0-beta.0-only issue) DRM: Fix fallbacking for an already-played content by checking key statuses initially linked to a MediaKeySession
|
|
61
|
-
|
|
62
|
-
### Other improvements
|
|
63
|
-
|
|
64
|
-
- Based on the v3.30.0 of which it inherits all the features, bug fixes and other improvements
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
## v4.0.0-beta.0 (2023-01-27)
|
|
68
|
-
|
|
69
|
-
### Changes
|
|
70
|
-
|
|
71
|
-
- Create `"FREEZING"` player state for cases where the playback position is currently not advancing due to an unknown reason, to separate it from regular `"BUFFERING"`. [#1146]
|
|
72
|
-
- The `RELOADING` player state (gettable through the `getPlayerState` and `playerStateChange` API) can now happen at any time to unlock playback.
|
|
73
|
-
- Remove bitrate API: `getAvailableVideoBitrates`, `getAvailableAudioBitrates`, `setAudioBitrate`, `setVideoBitrate`, `getAudioBitrate`, `getVideoBitrate` in profit of the Representations lock APIs [#1144]
|
|
74
|
-
- Remove max bitrate API: `setMaxVideoBitrate`, `setMaxAudioBitrate`, `getMaxVideoBitrate` and `getMaxAudioBitrate` methods as well as the `maxVideoBitrate` and `maxAudioBitrate` options in profit of the Representations lock APIs
|
|
75
|
-
- Remove min bitrate API: `setMinVideoBitrate`, `setMinAudioBitrate`, `getMinVideoBitrate` and `getMinAudioBitrate` methods as well as the `minVideoBitrate` and `minAudioBitrate` options in profit of the Representations lock APIs
|
|
76
|
-
- Remove track preferences API (methods: `getPreferredAudioTracks`, `getPreferredVideoTracks`, `setPreferredAudioTracks` and `setPreferredVideoTracks`, types: `IAudioTrackPreference`, `ITextTrackPreference` and `IVideoTrackPreference`) in profit of the new tracks API
|
|
77
|
-
- Remove `getManualVideoBitrate` and `getManualAudioBitrate` in profit of the new Representations lock APIs
|
|
78
|
-
- Replace `initialAudioBitrate` and `initialVideoBitrate` constructor options with a single `baseBandwidth` option, which better translates what this option is actually doing and allows for future optimizations on our side. [#1155]
|
|
79
|
-
- Rename `audioTrackSwitchingMode` loadVideo option into `defaultAudioTrackSwitchingMode` [#1030]
|
|
80
|
-
- Remove `manualBitrateSwitchingMode` loadVideo option to instead rely on the `switchingMode` property of each `lockVideoRepresentations` and `lockAudioRepresentations` calls. [#1030]
|
|
81
|
-
- Remove `audioBitrateChange` and `videoBitrateChange` events in profit of the new `audioRepresentationChange` and `videoRepresentationChange` events
|
|
82
|
-
- Remove `availableAudioBitratesChange` and `availableVideoBitratesChange` events. Those are less needed with the new Representations lock API and can be mostly replicated through the `audioTrackChange` and `videoTrackChange` events
|
|
83
|
-
- "Flatten" the `transportOptions` loadVideo options by putting all its inner properties directly at the top level of loadVideo options, to simplify its documentation and discoverability [#1149]
|
|
84
|
-
- Remove `limitVideoWidth` constructor option in profit of the more configurable `videoResolutionLimit` constructor option
|
|
85
|
-
- Rename `networkConfig` into `requestConfig` and re-organize its inner properties to pave the way for future request-related APIs.
|
|
86
|
-
- Remove `stopAtEnd` `loadVideo` option and don't automatically stop when reaching the end by default. This behavior can be counter-intuitive and can be very easily implemented by the application.
|
|
87
|
-
- Remove `decipherabilityUpdate` event as it appeared to be not easily exploitable and exposed internal logic too much [#1168]
|
|
88
|
-
- Remove `getUrl` method in profit of the more powerful `getContentUrls`
|
|
89
|
-
- Impossibility to play the content due to unsupported audio and/or video tracks now triggers an error with the `MANIFEST_INCOMPATIBLE_CODECS_ERROR` instead of `MANIFEST_PARSE_ERROR`
|
|
90
|
-
- Remove methods: `getManifest`, `getCurrentAdaptations` and `getCurrentRepresentations`, as they reveal the RxPlayer's internals too much
|
|
91
|
-
- The `"smooth"` transport now needs to be communicated the URL of the Manifest directly (previously, it was possible to redirect it to a XML or JSON file first due to Canal+ legacy reasons).
|
|
92
|
-
- Remove the `supplementaryTextTracks` loadVideo option. You can use the `TextTrackRenderer` tool if you wish to diplay external subtitles on top of your content.
|
|
93
|
-
- Rename `maximumBufferTime` in `positionUpdate` events to `maximumPosition`
|
|
94
|
-
- Remove `getVideoPlayedTime` and `getVideoLoadedTime` methods. Their names was very confusing and can be re-implemented relatively easily using the media element's buffered property.
|
|
95
|
-
- Rename `getVideoDuration` to `getMediaDuration`, to avoid confusion with the video track's duration.
|
|
96
|
-
- Rename `getVideoBufferGap` to `getCurrentBufferGap, to avoid confusion with the "buffer gap" specific to the video track.
|
|
97
|
-
- Remove image-related API: `supplementaryImageTracks` `loadVideo` option, `imageTrackUpdate` event, `getImageTrackData` method. Those are better handled by an application. The `parseBifThumbnails` tool is still available.
|
|
98
|
-
- Replace `keySystems[].licenseStorage` `keySystems` option (for a `loadVideo` call) by the better-named `persistentLicenseConfig`. The `persistentLicense` boolean (also a `keySystems` option) has also been removed because it was redundant with it) [#1147]
|
|
99
|
-
- Remove `persistentStateRequired` API, in profit of the more powerful `persistentState` API [#1148]
|
|
100
|
-
- Remove `distinctiveIdentifierRequired` API, in profit of the more powerful `distinctiveIdentifier` API [#1148]
|
|
101
|
-
- Remove `keySystems[].fallbackOn` `loadVideo` property as it's now replaced by the more powerful `keySystems[].onKeyOutputRestricted` and `keySystems[].onKeyInternalError` properties.
|
|
102
|
-
- Remove `keySystems[].onKeyStatusesChange` API as it seems to never be used [#1148]
|
|
103
|
-
- Remove `keySystems[].throwOnLicenseExpiration` API as it can now be fully replaced by the `keySystems[].onKeyExpiration` option
|
|
104
|
-
- Remove `aggressiveMode` from the `transportOptions` `loadVideo` option
|
|
105
|
-
- Remove deprecated `throttleWhenHidden` player option in profit of `throttleVideoBitrateWhenHidden`
|
|
106
|
-
- Change payload of `periodChange` events, so they emit only core properties related to a `Period`.
|
|
107
|
-
- Change arguments given to a `transportOptions.segmentLoader` function (the `loadVideo` option): it now doesn't give the full `Manifest`, `Period`, `Adaptation`, `Representation` and `ISegment` structures in arguments but only core properties from it [#995]
|
|
108
|
-
- Custom `manifestLoader` function added to what was previously the `loadVideo`'s `transportOptions` option now set an object as argument (with an `url`property), to let us bring improvements on it in the future [#995]
|
|
109
|
-
- A Representation's `frameRate` is now always a number - in terms of frame per seconds - instead of a string.
|
|
110
|
-
- Update the arguments of the `representationFilter` API
|
|
111
|
-
- `Representations` (in methods: `getAvailableVideoTracks`, `getVideoTrack`, `representationFilter`, `getAvailableAudioTracks`, `getAudioTrack` and events: `audioTrackChange` and `videoTrackChange`) can have an `undefined` bitrate
|
|
112
|
-
- Remove deprecated fullscreen related APIs (methods: `isFullscreen`, `setFullscreen`, `exitFullscreen`, event: `fullscreenChange`) as a a UI is much more adapted to that task and can also bring with it things like a progress bar or HTML text tracks
|
|
113
|
-
- Remove deprecated `getNativeTextTrack` method. If advanced features are wanted, it's better to just use the HTML text track API
|
|
114
|
-
- Remove deprecated `nativeTextTracksChange` event. Same reason than for `getNativeTextTrack`
|
|
115
|
-
- Remove deprecated `hideNativeSubtitles` from `loadVideo` options. Same reason than for `getNativeTextTrack`
|
|
116
|
-
- Remove `xhr` property from a `NetworkError`. Doing so stop us from using the fetch API
|
|
117
|
-
- Remove deprecated `defaultAudioTrack` and `defaultTextTrack`in profit of new track APIs
|
|
118
|
-
- Remove `bitrateEstimationChange` event as it is poorly understood (it's not always close to the expected bandwidth) and has a very complex relationship with the chosen quality.
|
|
119
|
-
- Remove the notion of environment variables linked to personalized builds (e.g. RXP_DASH) in profit of the minimal RxPlayer.
|
|
120
|
-
- Rename `IPersistentSessionStorage` type to `IPersistentLicenseConfig` [#1147]
|
|
121
|
-
- Remove undocumented `audioRobustnesses` and `videoRobustnesses` properties of the `keySystems` option of `loadVideo` calls, as more powerful solutions now exist: respectively `audioCapabilitiesConfig` and `videoCapabilitiesConfig` [#1148]
|
|
122
|
-
- Remove public types `ISupplementaryTextTrackOption` and `ISupplementaryImageTrackOption`. Those are the types respectively for `supplementaryTextTracks` and `supplementaryImageTracks` which have been removed
|
|
123
|
-
- Remove public types `IBitrateEstimate` as no API depend on it anymore.
|
|
124
|
-
- Remove public types `IManifest`, `IPeriod`, `IAdaptation`, `IRepresentation`, `IRepresentationInfos`, `IBifThumbnail`, `IBifObject` and `IExposedSegment` as no API depend on them anymore.
|
|
125
|
-
- Remove public types `IDefaultAudioTrackOption` and `IDefaultTextTrackOption`. Those are the types respectively for `defaultAudioTrack` and `defaultTextTrack` `loadVideo` options which have been removed
|
|
126
|
-
- Remove public types `IAudioTrackPreference`, `ITextTrackPreference` and `IVideoTrackPreference` as the corresponding API do not exist anymore.
|
|
127
|
-
- Stop officially supporting the Internet Explorer 11 browser
|
|
3
|
+
## v4.0.0-dev.2023120600 (2023-12-06)
|
|
128
4
|
|
|
129
5
|
### Features
|
|
130
6
|
|
|
131
|
-
-
|
|
132
|
-
- Add `
|
|
133
|
-
-
|
|
134
|
-
-
|
|
135
|
-
- `disableTextTrack`, and`disableVideoTrack` can now optionally take a `periodId` argument to disable a track for a specific Period
|
|
136
|
-
- Add optional `lockedRepresentations` property to `setAudioTrack` and `setVideoTrack`, to only filter some allowed Representations (i.e. qualities) after switching to the wanted track.
|
|
137
|
-
- Add `getCurrentPeriod` method to retrieve information on the Period currently played
|
|
138
|
-
- Add `getAvailablePeriods` method to retrieve information on all Periods on which a track or Representation choice can be made
|
|
139
|
-
- Add `lockVideoRepresentations`, `lockAudioRepresentations`, `getLockedVideoRepresentations`, `getLockedAudioRepresentations`, `unlockVideoRepresentations` and `unlockAudioRepresentations` methods to allow a complex selection of Representations that are currently allowed to play.
|
|
140
|
-
- Add `getVideoRepresentation` and `getAudioRepresentation` method to retrieve information on the currently loaded representations [#1144]
|
|
141
|
-
- Add `audioRepresentationChange` and `videoRepresentationChange` events to be notified when the currently-loaded Representation for the current Period changes.
|
|
142
|
-
- Add `updateContentUrls` API, allowing to update the Manifest's URL during playback [#1182]
|
|
143
|
-
- DASH: implement forced-subtitles, adding the `forced` property to the audio tracks API and selecting by default a forced text track linked to the audio track's language if present [#1187]
|
|
144
|
-
- Add `getContentUrls` allowing to retrieve the one or several known URLs through which the current Manifest or content is reachable.
|
|
145
|
-
- Add `videoResolutionLimit` constructor option allowing to automatically limit a video Representation's resolution.
|
|
146
|
-
- Add `newAvailablePeriods` event to signal new Period on which a track and/or Representation choice can be made
|
|
147
|
-
- Add `brokenRepresentationsLock` event for when a Representations lock could not be respected anymore
|
|
148
|
-
- Add `trackUpdate` event for when a track has been updated for any type and Period
|
|
149
|
-
- Add `distinctiveIdentifier` property in the `keySystems` option (given to the `loadVideo` method) to have full control over the MediaKeySystemConfiguration of the same name in the chosen key system [#1148]
|
|
150
|
-
- Add `persistentState` property in the `keySystems` option (given to the `loadVideo` method) to have full control over the MediaKeySystemConfiguration of the same name in the chosen key system [#1148]
|
|
151
|
-
- Add `keySystems[].onKeyOutputRestricted` and `keySystems[].onKeyInternalError` properties to configure the RxPlayer's behavior when a key switches to the status respectively `"output-restricted"` and `"internal-error"`
|
|
152
|
-
- Add `audioCapabilitiesConfig` and `videoCapabilitiesConfig` properties in the `keySystems` option (given to the `loadVideo` method) to allow advanced configuration of respectively the "audioCapabilities" and "videoCapabilities" in the asked MediaKeySystemConfiguration [#1148]
|
|
153
|
-
- Add `ISegmentLoaderContext` public type for the first argument of the `segmentLoader` API
|
|
154
|
-
- Add `IRepresentationFilterRepresentation` public type for the first argument of the `representationFilter` API
|
|
155
|
-
- Add `IRepresentationContext` public type for the second argument of the `representationFilter` API
|
|
156
|
-
- Add `IManifestLoaderInfo` public type for the first argument of the `manifestLoader` API
|
|
157
|
-
- Add `IPeriodChangeEvent` public type to define the properties send through a `periodChange` event
|
|
158
|
-
- Add `IPeriod` public type to define a Period object returned by methods like `getAvailablePeriods` or `getCurrentPeriod`
|
|
159
|
-
- Add `IVideoTrackSwitchingMode` public type to define the type of the `switchingMode` property optionally given to `setAudioTrack`
|
|
160
|
-
- Add `IAudioRepresentationsSwitchingMode` public type to define the type of the `switchingMode` property optionally given to `lockAudioRepresentations`
|
|
161
|
-
- Add `IVideoRepresentationsSwitchingMode` public type to define the type of the `switchingMode` property optionally given to `lockAudioRepresentations`
|
|
162
|
-
- Add `IBrokenRepresentationsLockContext` public type to define the type sent as a payload of the `brokenRepresentationsLock` event
|
|
163
|
-
- Add `ITrackUpdateEventPayload` public type to define the type sent as a payload of the `trackUpdate` event
|
|
164
|
-
- Add `ILockedVideoRepresentationsSettings` public type to define the object that should be given to the new `lockVideoRepresentation` method
|
|
165
|
-
- Add `ILockedAudioRepresentationsSettings` public type to define the object that should be given to the new `lockAudioRepresentation` method
|
|
166
|
-
- Add `IAudioTrackSetting` public type to define the object that may be given to the `setAudioTrack` method
|
|
167
|
-
- Add `IVideoTrackSetting` public type to define the object that may be given to the `setVideoTrack` method
|
|
168
|
-
- Add `ITextTrackSetting` public type to define the object that may be given to the `setTextTrack` method
|
|
7
|
+
- Add `getLivePosition` RxPlayer method [#1300]
|
|
8
|
+
- Add `startAt.fromLivePosition` `loadVideo` option [#1300]
|
|
9
|
+
- add `connectionTimeout` property to the `requestConfig` `loadVideo` option for both the manifest and segment requests to set a timeout just linked to HTTP connection establishment [#1319]
|
|
10
|
+
- Add the possibility to set a new `keySystems` option on the `reload` API [#1308]
|
|
169
11
|
|
|
170
12
|
### Bug fixes
|
|
171
13
|
|
|
172
|
-
- Fix
|
|
173
|
-
-
|
|
174
|
-
-
|
|
175
|
-
-
|
|
176
|
-
- DRM/Compat: Renew MediaKeys at each `loadVideo` on all WebOS (LG TV) platforms to work around issues [#1188]
|
|
14
|
+
- Fix subtitles "blinking" in some specific conditions, especially with some DASH low-latency contents [#1314]
|
|
15
|
+
- DASH: Fix Period overlap resolution logic for when the first Period is removed [#1311]
|
|
16
|
+
- Fix import of the `LOCAL_MANIFEST` experimental feature
|
|
17
|
+
- Smooth: Rely on a defined `segmentLoader` when playing smooth streaming contents.
|
|
177
18
|
|
|
178
19
|
### Other improvements
|
|
179
20
|
|
|
180
|
-
-
|
|
21
|
+
- Provide both commonJS and ES6-style exports to improve compatibilities with applications
|
|
22
|
+
- DASH: rely on SCTE214 `supplementalCodecs` instead of `codecs` if it's supported to better support backward compatible Dolby Vision contents [#1307]
|
|
23
|
+
- DASH: Provide better support of the `availabilityTimeOffset` attribute [#1300]
|
|
24
|
+
- DEBUG_ELEMENT: Add unsupported and undecipherable bitrates to the debug element [#1321]
|
|
25
|
+
- DEBUG_ELEMENT: update buffer graph maximum size so it becomes more readable for lengthy contents [#1316]
|
|
26
|
+
- DEBUG_ELEMENT: always synchronize inventory of segments before rendering it [#1317]
|
|
27
|
+
- Remove remaining RxPlayer dependency removing possibility of some application-side bundling errors [#1312]
|
|
28
|
+
- Add cache when checking for codec support, improving performance on some devices and potentially working around some xbox bugs on long-lived pages [#1324]
|
|
29
|
+
- Demo: Add possibility to see the debug element in the demo page
|
|
181
30
|
|
|
182
31
|
|
|
183
32
|
## v3.32.1 (2023-10-19)
|
|
@@ -237,63 +86,6 @@
|
|
|
237
86
|
- doc: externalize documentation-generator code
|
|
238
87
|
|
|
239
88
|
|
|
240
|
-
## v3.32.0
|
|
241
|
-
|
|
242
|
-
### Features
|
|
243
|
-
|
|
244
|
-
- DASH: add optional `isSpatialAudio` boolean property to Representation returned by `getAvailableAudioTracks`, `getAudioTrack`, corresponding events, and `trackInfo` optional property of `MediaError` objects to signal Dolby Atmos techology [#1275]
|
|
245
|
-
- `LOCAL`: add `isSpatialAudio` property to Representation of the experiment `"local"` transport (used for offline playback) [#1275]
|
|
246
|
-
- `addFeatures` static method is now available on all RxPlayer builds. It was previously only in the minimal (`rx-player/minimal` import path) [#1287]
|
|
247
|
-
- The `NATIVE_TEXT_BUFFER`, `HTML_TEXT_BUFFER` and `IMAGE_BUFFER` features are now totally optional [#1287, #1293]
|
|
248
|
-
|
|
249
|
-
### Bug fixes
|
|
250
|
-
|
|
251
|
-
- Fix `setVideoBitrate` and `setAudioBitrate` API which may have led to a higher quality than wanted in the default `"seamless"` `manualBitrateSwitchingMode` if our buffer-based adaptive logic decided to [#1267, #1271]
|
|
252
|
-
- On the PlayStation 5, only switch to the `"LOADED"` state once the HTMLMediaElement's `readyState` of `4` has been reached, as it seems to switch to `3` too soon there [#1257]
|
|
253
|
-
- DASH: Fix potential track duplication if more than two `AdaptationSet` have an `adaptation-set-switching` `<SupplementalProperty>` between one another [#1279]
|
|
254
|
-
- DASH-WASM: availabilityTimeOffset is actually a floating number [#1278]
|
|
255
|
-
|
|
256
|
-
### Other improvements
|
|
257
|
-
|
|
258
|
-
- Do not load the last text segment if the current position goes after it as it is unnecessary [#1256]
|
|
259
|
-
- Implement better `NetworkError` messages [#1274]
|
|
260
|
-
- Set a better error message for when no `keySystems` option is set when playing an encrypted content
|
|
261
|
-
- Fix very small memory leak when reloading a content [#1286]
|
|
262
|
-
- Re-check for segments to load immediately after the manifest has been refreshed [#1282]
|
|
263
|
-
- When "fallbacking" an undecipherable Representation, now empty the whole buffer if we can't make out where content was in the buffer [#1283]
|
|
264
|
-
- Improve segment start detection in buffer when there's unknown data buffered before it [#1284]
|
|
265
|
-
- DRM: Selection of alternative EME API like those used on IE11 or Safari has been refactored to facilitate future developments [#1261]
|
|
266
|
-
|
|
267
|
-
### Deprecated
|
|
268
|
-
|
|
269
|
-
- Deprecate the `manifestUpdateUrl` `loadVideo` option as it doesn't seem used anymore [#1288]
|
|
270
|
-
- Deprecate the `NATIVE_TEXT_BUFFER`, `HTML_TEXT_BUFFER` and `IMAGE_BUFFER` features as they are now unneeded [#1287, #1293]
|
|
271
|
-
|
|
272
|
-
|
|
273
|
-
## v3.31.0 (2023-06-14)
|
|
274
|
-
|
|
275
|
-
### Features
|
|
276
|
-
|
|
277
|
-
- Add `isContentLoaded`, `isBuffering`, `isPaused`, and `getLastStoredContentPosition` methods [#1248]
|
|
278
|
-
- Add `play` and `paused` events [#1253]
|
|
279
|
-
- Add `trackInfo` property to some `MediaError` to expose information on the track that caused the error [#1241]
|
|
280
|
-
|
|
281
|
-
### Bug fixes
|
|
282
|
-
|
|
283
|
-
- DASH: Fix issue which could lead to infinite rebuffering when switching between multiple Periods [#1232]
|
|
284
|
-
- Return actual ending duration through the `getVideoDuration` method when playing dynamic contents whose future end is already known [#1235]
|
|
285
|
-
- DASH/WASM: actually reject the `DASH_WASM.initialize`'s Promise if it fails [#1238]
|
|
286
|
-
- On the PlayStation 5, set `Infinity` MediaSource duration for live contents to prevent playback issues [#1250]
|
|
287
|
-
|
|
288
|
-
### Other improvements
|
|
289
|
-
|
|
290
|
-
- adaptive: Perform various adaptive tweaks to avoid switching too much between qualities in some conditions [#1237]
|
|
291
|
-
- Directfile: Detect "forced" subtitles on Safari when playing directfile contents (such as HLS) [#1239]
|
|
292
|
-
- Improve `"direct"` `audioTrackSwitchingMode` compatibility by re-seeking [#1246]
|
|
293
|
-
- The `DEBUG_ELEMENT` feature now uses the `monospace` fallback font as a default for a better rendering on apple devices
|
|
294
|
-
- doc: externalize documentation-generator code
|
|
295
|
-
|
|
296
|
-
|
|
297
89
|
## v3.30.0 (2023-03-07)
|
|
298
90
|
|
|
299
91
|
### Features
|
package/FILES.md
CHANGED
|
@@ -20,7 +20,7 @@ At the time of writing, there are two distinct demos:
|
|
|
20
20
|
|
|
21
21
|
## `dist/`: Builds
|
|
22
22
|
|
|
23
|
-
The `
|
|
23
|
+
The `dist/` directory stores the player builds of the last version released.
|
|
24
24
|
|
|
25
25
|
Directories can also be generated in here if the right scripts are called.
|
|
26
26
|
These allow to publish more modular codebases to npm.
|
package/VERSION
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
4.0.0-dev.
|
|
1
|
+
4.0.0-dev.2023120600
|
|
@@ -23,11 +23,9 @@ import { ICompatTextTrack } from "./browser_compatibility_types";
|
|
|
23
23
|
* undefined if no trackElement was added.
|
|
24
24
|
*
|
|
25
25
|
* @param {HTMLMediaElement} mediaElement
|
|
26
|
-
* @param {Boolean} hidden - If `true`, the text track will be hidden by
|
|
27
|
-
* default. If `false`, the text track will be directly showing.
|
|
28
26
|
* @returns {Object}
|
|
29
27
|
*/
|
|
30
|
-
export default function addTextTrack(mediaElement: HTMLMediaElement
|
|
28
|
+
export default function addTextTrack(mediaElement: HTMLMediaElement): {
|
|
31
29
|
track: ICompatTextTrack;
|
|
32
30
|
trackElement: HTMLTrackElement | undefined;
|
|
33
31
|
};
|
|
@@ -23,12 +23,10 @@ import { isIEOrEdge } from "./browser_detection";
|
|
|
23
23
|
* undefined if no trackElement was added.
|
|
24
24
|
*
|
|
25
25
|
* @param {HTMLMediaElement} mediaElement
|
|
26
|
-
* @param {Boolean} hidden - If `true`, the text track will be hidden by
|
|
27
|
-
* default. If `false`, the text track will be directly showing.
|
|
28
26
|
* @returns {Object}
|
|
29
27
|
*/
|
|
30
|
-
export default function addTextTrack(mediaElement
|
|
31
|
-
var _a
|
|
28
|
+
export default function addTextTrack(mediaElement) {
|
|
29
|
+
var _a;
|
|
32
30
|
var track;
|
|
33
31
|
var trackElement;
|
|
34
32
|
var kind = "subtitles";
|
|
@@ -36,15 +34,14 @@ export default function addTextTrack(mediaElement, hidden) {
|
|
|
36
34
|
var tracksLength = mediaElement.textTracks.length;
|
|
37
35
|
track = (tracksLength > 0 ? mediaElement.textTracks[tracksLength - 1] :
|
|
38
36
|
mediaElement.addTextTrack(kind));
|
|
39
|
-
track.mode =
|
|
40
|
-
((_b = track.SHOWING) !== null && _b !== void 0 ? _b : "showing");
|
|
37
|
+
track.mode = (_a = track.SHOWING) !== null && _a !== void 0 ? _a : "showing";
|
|
41
38
|
}
|
|
42
39
|
else {
|
|
43
40
|
trackElement = document.createElement("track");
|
|
44
41
|
mediaElement.appendChild(trackElement);
|
|
45
42
|
track = trackElement.track;
|
|
46
43
|
trackElement.kind = kind;
|
|
47
|
-
track.mode =
|
|
44
|
+
track.mode = "showing";
|
|
48
45
|
}
|
|
49
46
|
return { track: track, trackElement: trackElement };
|
|
50
47
|
}
|
|
@@ -52,15 +52,8 @@ interface ICompatTextTrack extends TextTrack {
|
|
|
52
52
|
* functions for some "old" browsers.
|
|
53
53
|
*/
|
|
54
54
|
interface ICompatDocument extends Document {
|
|
55
|
-
fullscreenElement: Element | null;
|
|
56
|
-
mozCancelFullScreen?: () => void;
|
|
57
|
-
mozFullScreenElement?: HTMLElement;
|
|
58
55
|
mozHidden?: boolean;
|
|
59
|
-
msExitFullscreen?: () => void;
|
|
60
|
-
msFullscreenElement?: Element | null;
|
|
61
56
|
msHidden?: boolean;
|
|
62
|
-
webkitExitFullscreen: () => void;
|
|
63
|
-
webkitFullscreenElement: Element | null;
|
|
64
57
|
webkitHidden?: boolean;
|
|
65
58
|
}
|
|
66
59
|
/**
|
|
@@ -34,15 +34,6 @@ export type IEventTargetLike = HTMLElement | IEventEmitterLike | IEventEmitter<u
|
|
|
34
34
|
* be triggered when that event is emitted on a given event target.
|
|
35
35
|
*/
|
|
36
36
|
declare function createCompatibleEventListener(eventNames: string[], prefixes?: string[]): (element: IEventTargetLike, listener: (event?: unknown) => void, cancelSignal: CancellationSignal) => void;
|
|
37
|
-
/**
|
|
38
|
-
* Returns a reference:
|
|
39
|
-
* - Set to `true` when the current page is considered visible and active.
|
|
40
|
-
* - Set to `false` otherwise.
|
|
41
|
-
* @param {Object} stopListening - `CancellationSignal` allowing to free the
|
|
42
|
-
* resources allocated to update this value.
|
|
43
|
-
* @returns {Object}
|
|
44
|
-
*/
|
|
45
|
-
declare function getPageActivityRef(stopListening: CancellationSignal): IReadOnlySharedReference<boolean>;
|
|
46
37
|
export interface IPictureInPictureEvent {
|
|
47
38
|
isEnabled: boolean;
|
|
48
39
|
pipWindow: ICompatPictureInPictureWindow | null;
|
|
@@ -83,11 +74,7 @@ declare const onLoadedMetadata: (element: IEventTargetLike, listener: (event?: u
|
|
|
83
74
|
*/
|
|
84
75
|
declare const onTimeUpdate: (element: IEventTargetLike, listener: (event?: unknown) => void, cancelSignal: CancellationSignal) => void;
|
|
85
76
|
/**
|
|
86
|
-
* @param {
|
|
87
|
-
*/
|
|
88
|
-
declare const onFullscreenChange: (element: IEventTargetLike, listener: (event?: unknown) => void, cancelSignal: CancellationSignal) => void;
|
|
89
|
-
/**
|
|
90
|
-
* @param {TextTrackList} textTrackList
|
|
77
|
+
* @param {TextTrackList} mediaElement
|
|
91
78
|
*/
|
|
92
79
|
declare const onTextTrackAdded: (element: IEventTargetLike, listener: (event?: unknown) => void, cancelSignal: CancellationSignal) => void;
|
|
93
80
|
/**
|
|
@@ -163,4 +150,4 @@ declare const onEnded: (element: IEventTargetLike, listener: (event?: unknown) =
|
|
|
163
150
|
* emits
|
|
164
151
|
*/
|
|
165
152
|
declare function addEventListener(elt: IEventEmitterLike, evt: string, listener: (x?: unknown) => void, stopListening: CancellationSignal): void;
|
|
166
|
-
export { addEventListener, createCompatibleEventListener,
|
|
153
|
+
export { addEventListener, createCompatibleEventListener, getPictureOnPictureStateRef, getVideoVisibilityRef, getVideoWidthRef, onEnded, onKeyAdded, onKeyError, onKeyMessage, onKeyStatusesChange, onLoadedMetadata, onRemoveSourceBuffers, onSeeked, onSeeking, onSourceClose, onSourceEnded, onSourceOpen, onTimeUpdate, onSourceBufferUpdate, onTextTrackAdded, onTextTrackRemoved, };
|
|
@@ -166,35 +166,6 @@ function getDocumentVisibilityRef(stopListening) {
|
|
|
166
166
|
}, stopListening);
|
|
167
167
|
return ref;
|
|
168
168
|
}
|
|
169
|
-
/**
|
|
170
|
-
* Returns a reference:
|
|
171
|
-
* - Set to `true` when the current page is considered visible and active.
|
|
172
|
-
* - Set to `false` otherwise.
|
|
173
|
-
* @param {Object} stopListening - `CancellationSignal` allowing to free the
|
|
174
|
-
* resources allocated to update this value.
|
|
175
|
-
* @returns {Object}
|
|
176
|
-
*/
|
|
177
|
-
function getPageActivityRef(stopListening) {
|
|
178
|
-
var isDocVisibleRef = getDocumentVisibilityRef(stopListening);
|
|
179
|
-
var currentTimeout;
|
|
180
|
-
var ref = new SharedReference(true, stopListening);
|
|
181
|
-
stopListening.register(function () {
|
|
182
|
-
clearTimeout(currentTimeout);
|
|
183
|
-
currentTimeout = undefined;
|
|
184
|
-
});
|
|
185
|
-
isDocVisibleRef.onUpdate(function onDocVisibilityChange(isVisible) {
|
|
186
|
-
clearTimeout(currentTimeout); // clear potential previous timeout
|
|
187
|
-
currentTimeout = undefined;
|
|
188
|
-
if (!isVisible) {
|
|
189
|
-
var INACTIVITY_DELAY = config.getCurrent().INACTIVITY_DELAY;
|
|
190
|
-
currentTimeout = window.setTimeout(function () {
|
|
191
|
-
ref.setValueIfChanged(false);
|
|
192
|
-
}, INACTIVITY_DELAY);
|
|
193
|
-
}
|
|
194
|
-
ref.setValueIfChanged(true);
|
|
195
|
-
}, { clearSignal: stopListening, emitCurrentValue: true });
|
|
196
|
-
return ref;
|
|
197
|
-
}
|
|
198
169
|
/**
|
|
199
170
|
* Get video width from Picture-in-Picture window
|
|
200
171
|
* @param {HTMLMediaElement} mediaElement
|
|
@@ -332,13 +303,7 @@ var onLoadedMetadata = createCompatibleEventListener(["loadedmetadata"]);
|
|
|
332
303
|
*/
|
|
333
304
|
var onTimeUpdate = createCompatibleEventListener(["timeupdate"]);
|
|
334
305
|
/**
|
|
335
|
-
* @param {
|
|
336
|
-
*/
|
|
337
|
-
var onFullscreenChange = createCompatibleEventListener(["fullscreenchange", "FullscreenChange"],
|
|
338
|
-
// On IE11, fullscreen change events is called MSFullscreenChange
|
|
339
|
-
BROWSER_PREFIXES.concat("MS"));
|
|
340
|
-
/**
|
|
341
|
-
* @param {TextTrackList} textTrackList
|
|
306
|
+
* @param {TextTrackList} mediaElement
|
|
342
307
|
*/
|
|
343
308
|
var onTextTrackAdded = createCompatibleEventListener(["addtrack"]);
|
|
344
309
|
/**
|
|
@@ -419,4 +384,4 @@ function addEventListener(elt, evt, listener, stopListening) {
|
|
|
419
384
|
elt.removeEventListener(evt, listener);
|
|
420
385
|
});
|
|
421
386
|
}
|
|
422
|
-
export { addEventListener, createCompatibleEventListener,
|
|
387
|
+
export { addEventListener, createCompatibleEventListener, getPictureOnPictureStateRef, getVideoVisibilityRef, getVideoWidthRef, onEnded, onKeyAdded, onKeyError, onKeyMessage, onKeyStatusesChange, onLoadedMetadata, onRemoveSourceBuffers, onSeeked, onSeeking, onSourceClose, onSourceEnded, onSourceOpen, onTimeUpdate, onSourceBufferUpdate, onTextTrackAdded, onTextTrackRemoved, };
|
|
@@ -22,11 +22,9 @@ import tryToChangeSourceBufferType, { ICompatSourceBuffer } from "./change_sourc
|
|
|
22
22
|
import clearElementSrc from "./clear_element_src";
|
|
23
23
|
import enableAudioTrack from "./enable_audio_track";
|
|
24
24
|
import * as events from "./event_listeners";
|
|
25
|
-
import { exitFullscreen, isFullscreen, requestFullscreen } from "./fullscreen";
|
|
26
25
|
import getStartDate from "./get_start_date";
|
|
27
26
|
import isCodecSupported from "./is_codec_supported";
|
|
28
27
|
import isNode from "./is_node";
|
|
29
|
-
import isOffline from "./is_offline";
|
|
30
28
|
import isVTTCue from "./is_vtt_cue";
|
|
31
29
|
import makeVTTCue from "./make_vtt_cue";
|
|
32
30
|
import onHeightWidthChange from "./on_height_width_change";
|
|
@@ -36,4 +34,4 @@ import shouldUnsetMediaKeys from "./should_unset_media_keys";
|
|
|
36
34
|
import shouldValidateMetadata from "./should_validate_metadata";
|
|
37
35
|
import shouldWaitForDataBeforeLoaded from "./should_wait_for_data_before_loaded";
|
|
38
36
|
import shouldWaitForHaveEnoughData from "./should_wait_for_have_enough_data";
|
|
39
|
-
export { addClassName, addTextTrack, canPatchISOBMFFSegment, canReuseMediaKeys, clearElementSrc, enableAudioTrack, events,
|
|
37
|
+
export { addClassName, addTextTrack, canPatchISOBMFFSegment, canReuseMediaKeys, clearElementSrc, enableAudioTrack, events, getStartDate, ICompatTextTrack, ICompatVTTCue, ICompatSourceBuffer, isCodecSupported, isNode, isVTTCue, makeVTTCue, MediaSource_, onHeightWidthChange, shouldReloadMediaSourceOnDecipherabilityUpdate, shouldRenewMediaKeySystemAccess, shouldUnsetMediaKeys, shouldValidateMetadata, shouldWaitForDataBeforeLoaded, shouldWaitForHaveEnoughData, tryToChangeSourceBufferType, };
|
|
@@ -22,11 +22,9 @@ import tryToChangeSourceBufferType from "./change_source_buffer_type";
|
|
|
22
22
|
import clearElementSrc from "./clear_element_src";
|
|
23
23
|
import enableAudioTrack from "./enable_audio_track";
|
|
24
24
|
import * as events from "./event_listeners";
|
|
25
|
-
import { exitFullscreen, isFullscreen, requestFullscreen, } from "./fullscreen";
|
|
26
25
|
import getStartDate from "./get_start_date";
|
|
27
26
|
import isCodecSupported from "./is_codec_supported";
|
|
28
27
|
import isNode from "./is_node";
|
|
29
|
-
import isOffline from "./is_offline";
|
|
30
28
|
import isVTTCue from "./is_vtt_cue";
|
|
31
29
|
import makeVTTCue from "./make_vtt_cue";
|
|
32
30
|
import onHeightWidthChange from "./on_height_width_change";
|
|
@@ -42,4 +40,4 @@ import shouldWaitForHaveEnoughData from "./should_wait_for_have_enough_data";
|
|
|
42
40
|
// we would prefer to disallow (both for the understandability of the code and
|
|
43
41
|
// to better exploit tree shaking.
|
|
44
42
|
patchWebkitSourceBuffer();
|
|
45
|
-
export { addClassName, addTextTrack, canPatchISOBMFFSegment, canReuseMediaKeys, clearElementSrc, enableAudioTrack, events,
|
|
43
|
+
export { addClassName, addTextTrack, canPatchISOBMFFSegment, canReuseMediaKeys, clearElementSrc, enableAudioTrack, events, getStartDate, isCodecSupported, isNode, isVTTCue, makeVTTCue, MediaSource_, onHeightWidthChange, shouldReloadMediaSourceOnDecipherabilityUpdate, shouldRenewMediaKeySystemAccess, shouldUnsetMediaKeys, shouldValidateMetadata, shouldWaitForDataBeforeLoaded, shouldWaitForHaveEnoughData, tryToChangeSourceBufferType, };
|
|
@@ -19,9 +19,7 @@ declare class ConfigHandler {
|
|
|
19
19
|
DEFAULT_UNMUTED_VOLUME: number;
|
|
20
20
|
DEFAULT_REQUEST_TIMEOUT: number;
|
|
21
21
|
DEFAULT_TEXT_TRACK_MODE: "native" | "html";
|
|
22
|
-
DEFAULT_MANUAL_BITRATE_SWITCHING_MODE: "direct" | "seamless";
|
|
23
22
|
DEFAULT_ENABLE_FAST_SWITCHING: boolean;
|
|
24
|
-
DEFAULT_AUDIO_TRACK_SWITCHING_MODE: "direct" | "seamless";
|
|
25
23
|
DELTA_POSITION_AFTER_RELOAD: {
|
|
26
24
|
bitrateSwitch: number;
|
|
27
25
|
trackSwitch: {
|
|
@@ -32,23 +30,14 @@ declare class ConfigHandler {
|
|
|
32
30
|
};
|
|
33
31
|
DEFAULT_CODEC_SWITCHING_BEHAVIOR: "reload" | "continue";
|
|
34
32
|
DEFAULT_AUTO_PLAY: boolean;
|
|
35
|
-
DEFAULT_SHOW_NATIVE_SUBTITLE: boolean;
|
|
36
|
-
DEFAULT_STOP_AT_END: boolean;
|
|
37
33
|
DEFAULT_WANTED_BUFFER_AHEAD: number;
|
|
38
34
|
DEFAULT_MAX_BUFFER_AHEAD: number;
|
|
39
35
|
DEFAULT_MAX_BUFFER_BEHIND: number;
|
|
40
36
|
DEFAULT_MAX_VIDEO_BUFFER_SIZE: number;
|
|
41
|
-
MAXIMUM_MAX_BUFFER_AHEAD: Partial<Record<"audio" | "video" | "
|
|
42
|
-
MAXIMUM_MAX_BUFFER_BEHIND: Partial<Record<"audio" | "video" | "
|
|
43
|
-
|
|
44
|
-
audio: number;
|
|
45
|
-
video: number;
|
|
46
|
-
other: number;
|
|
47
|
-
};
|
|
48
|
-
DEFAULT_MIN_BITRATES: Record<"audio" | "video" | "other", number>;
|
|
49
|
-
DEFAULT_MAX_BITRATES: Record<"audio" | "video" | "other", number>;
|
|
37
|
+
MAXIMUM_MAX_BUFFER_AHEAD: Partial<Record<"audio" | "video" | "text", number>>;
|
|
38
|
+
MAXIMUM_MAX_BUFFER_BEHIND: Partial<Record<"audio" | "video" | "text", number>>;
|
|
39
|
+
DEFAULT_BASE_BANDWIDTH: number;
|
|
50
40
|
INACTIVITY_DELAY: number;
|
|
51
|
-
DEFAULT_THROTTLE_WHEN_HIDDEN: boolean;
|
|
52
41
|
DEFAULT_THROTTLE_VIDEO_BITRATE_WHEN_HIDDEN: boolean;
|
|
53
42
|
DEFAULT_LIMIT_VIDEO_WIDTH: boolean;
|
|
54
43
|
DEFAULT_LIVE_GAP: {
|
|
@@ -65,7 +54,6 @@ declare class ConfigHandler {
|
|
|
65
54
|
DEFAULT_MAX_MANIFEST_REQUEST_RETRY: number;
|
|
66
55
|
DEFAULT_CDN_DOWNGRADE_TIME: number;
|
|
67
56
|
DEFAULT_MAX_REQUESTS_RETRY_ON_ERROR: number;
|
|
68
|
-
DEFAULT_MAX_REQUESTS_RETRY_ON_OFFLINE: number;
|
|
69
57
|
INITIAL_BACKOFF_DELAY_BASE: {
|
|
70
58
|
REGULAR: number;
|
|
71
59
|
LOW_LATENCY: number;
|
|
@@ -141,7 +129,7 @@ declare class ConfigHandler {
|
|
|
141
129
|
EME_DEFAULT_VIDEO_CODECS: string[];
|
|
142
130
|
EME_DEFAULT_AUDIO_CODECS: string[];
|
|
143
131
|
EME_DEFAULT_WIDEVINE_ROBUSTNESSES: string[];
|
|
144
|
-
|
|
132
|
+
EME_DEFAULT_PLAYREADY_RECOMMENDATION_ROBUSTNESSES: string[];
|
|
145
133
|
EME_KEY_SYSTEMS: Partial<Record<string, string[]>>;
|
|
146
134
|
MAX_CONSECUTIVE_MANIFEST_PARSING_IN_UNSAFE_MODE: number;
|
|
147
135
|
MIN_MANIFEST_PARSING_TIME_TO_ENTER_UNSAFE_MODE: number;
|
|
@@ -153,7 +141,7 @@ declare class ConfigHandler {
|
|
|
153
141
|
EME_MAX_STORED_PERSISTENT_SESSION_INFORMATION: number;
|
|
154
142
|
EME_WAITING_DELAY_LOADED_SESSION_EMPTY_KEYSTATUSES: number;
|
|
155
143
|
FORCED_ENDED_THRESHOLD: number;
|
|
156
|
-
|
|
144
|
+
ADAP_REP_SWITCH_BUFFER_PADDINGS: {
|
|
157
145
|
video: {
|
|
158
146
|
before: number;
|
|
159
147
|
after: number;
|
|
@@ -166,10 +154,6 @@ declare class ConfigHandler {
|
|
|
166
154
|
before: number;
|
|
167
155
|
after: number;
|
|
168
156
|
};
|
|
169
|
-
image: {
|
|
170
|
-
before: number;
|
|
171
|
-
after: number;
|
|
172
|
-
};
|
|
173
157
|
};
|
|
174
158
|
SOURCE_BUFFER_FLUSHING_INTERVAL: number;
|
|
175
159
|
CONTENT_REPLACEMENT_PADDING: number;
|
|
@@ -183,6 +167,10 @@ declare class ConfigHandler {
|
|
|
183
167
|
BUFFERED_HISTORY_MAXIMUM_ENTRIES: number;
|
|
184
168
|
MIN_BUFFER_AHEAD: number;
|
|
185
169
|
UPTO_CURRENT_POSITION_CLEANUP: number;
|
|
170
|
+
DEFAULT_VIDEO_REPRESENTATIONS_SWITCHING_MODE: "seamless";
|
|
171
|
+
DEFAULT_AUDIO_REPRESENTATIONS_SWITCHING_MODE: "seamless";
|
|
172
|
+
DEFAULT_VIDEO_TRACK_SWITCHING_MODE: "reload";
|
|
173
|
+
DEFAULT_AUDIO_TRACK_SWITCHING_MODE: "seamless";
|
|
186
174
|
};
|
|
187
175
|
update(config: Partial<IDefaultConfig>): void;
|
|
188
176
|
getCurrent(): IDefaultConfig;
|