rx-player 3.33.4-dev.2024083000 → 3.33.4
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/.prettierignore +1 -0
- package/.prettierrc +4 -0
- package/.vscode/settings.json +9 -0
- package/CHANGELOG.md +1662 -1076
- package/MAINTAINERS.md +9 -12
- package/README.md +111 -127
- package/VERSION +1 -1
- package/dist/_esm5.processed/compat/add_class_name.js +4 -3
- package/dist/_esm5.processed/compat/add_text_track.d.ts +1 -1
- package/dist/_esm5.processed/compat/add_text_track.js +4 -4
- package/dist/_esm5.processed/compat/browser_compatibility_types.d.ts +2 -1
- package/dist/_esm5.processed/compat/browser_compatibility_types.js +15 -10
- package/dist/_esm5.processed/compat/browser_detection.d.ts +3 -1
- package/dist/_esm5.processed/compat/browser_detection.js +18 -10
- package/dist/_esm5.processed/compat/can_reuse_media_keys.d.ts +4 -0
- package/dist/_esm5.processed/compat/can_reuse_media_keys.js +6 -2
- package/dist/_esm5.processed/compat/change_source_buffer_type.d.ts +1 -1
- package/dist/_esm5.processed/compat/eme/close_session.d.ts +1 -1
- package/dist/_esm5.processed/compat/eme/close_session.js +17 -13
- package/dist/_esm5.processed/compat/eme/custom_key_system_access.d.ts +1 -1
- package/dist/_esm5.processed/compat/eme/custom_media_keys/ie11_media_keys.d.ts +1 -1
- package/dist/_esm5.processed/compat/eme/custom_media_keys/ie11_media_keys.js +8 -9
- package/dist/_esm5.processed/compat/eme/custom_media_keys/index.d.ts +3 -2
- package/dist/_esm5.processed/compat/eme/custom_media_keys/index.js +1 -1
- package/dist/_esm5.processed/compat/eme/custom_media_keys/moz_media_keys_constructor.d.ts +1 -1
- package/dist/_esm5.processed/compat/eme/custom_media_keys/old_webkit_media_keys.d.ts +1 -1
- package/dist/_esm5.processed/compat/eme/custom_media_keys/old_webkit_media_keys.js +7 -9
- package/dist/_esm5.processed/compat/eme/custom_media_keys/types.d.ts +4 -1
- package/dist/_esm5.processed/compat/eme/custom_media_keys/webkit_media_keys.d.ts +2 -2
- package/dist/_esm5.processed/compat/eme/custom_media_keys/webkit_media_keys.js +6 -12
- package/dist/_esm5.processed/compat/eme/custom_media_keys/webkit_media_keys_constructor.d.ts +2 -1
- package/dist/_esm5.processed/compat/eme/custom_media_keys/webkit_media_keys_constructor.js +3 -3
- package/dist/_esm5.processed/compat/eme/eme-api-implementation.d.ts +4 -4
- package/dist/_esm5.processed/compat/eme/eme-api-implementation.js +26 -11
- package/dist/_esm5.processed/compat/eme/generate_key_request.d.ts +1 -1
- package/dist/_esm5.processed/compat/eme/generate_key_request.js +17 -20
- package/dist/_esm5.processed/compat/eme/get_init_data.d.ts +3 -1
- package/dist/_esm5.processed/compat/eme/get_init_data.js +7 -9
- package/dist/_esm5.processed/compat/eme/get_uuid_kid_from_keystatus_kid.js +2 -3
- package/dist/_esm5.processed/compat/eme/get_webkit_fairplay_initdata.js +12 -13
- package/dist/_esm5.processed/compat/eme/index.d.ts +8 -5
- package/dist/_esm5.processed/compat/eme/index.js +1 -1
- package/dist/_esm5.processed/compat/eme/load_session.d.ts +1 -1
- package/dist/_esm5.processed/compat/enable_audio_track.d.ts +1 -1
- package/dist/_esm5.processed/compat/event_listeners.d.ts +26 -24
- package/dist/_esm5.processed/compat/event_listeners.js +14 -29
- package/dist/_esm5.processed/compat/fullscreen.d.ts +1 -1
- package/dist/_esm5.processed/compat/fullscreen.js +1 -1
- package/dist/_esm5.processed/compat/generate_init_data.js +3 -5
- package/dist/_esm5.processed/compat/index.d.ts +6 -3
- package/dist/_esm5.processed/compat/index.js +2 -2
- package/dist/_esm5.processed/compat/is_vtt_cue.d.ts +1 -1
- package/dist/_esm5.processed/compat/make_vtt_cue.d.ts +1 -1
- package/dist/_esm5.processed/compat/on_height_width_change.d.ts +2 -2
- package/dist/_esm5.processed/compat/on_height_width_change.js +3 -2
- package/dist/_esm5.processed/compat/patch_webkit_source_buffer.js +28 -29
- package/dist/_esm5.processed/compat/should_favour_custom_safari_EME.js +2 -2
- package/dist/_esm5.processed/compat/should_reload_media_source_on_decipherability_update.js +1 -2
- package/dist/_esm5.processed/config.d.ts +1 -1
- package/dist/_esm5.processed/config.js +0 -15
- package/dist/_esm5.processed/core/adaptive/adaptive_representation_selector.d.ts +7 -6
- package/dist/_esm5.processed/core/adaptive/adaptive_representation_selector.js +45 -22
- package/dist/_esm5.processed/core/adaptive/buffer_based_chooser.d.ts +1 -1
- package/dist/_esm5.processed/core/adaptive/buffer_based_chooser.js +11 -10
- package/dist/_esm5.processed/core/adaptive/guess_based_chooser.d.ts +4 -4
- package/dist/_esm5.processed/core/adaptive/guess_based_chooser.js +7 -6
- package/dist/_esm5.processed/core/adaptive/index.d.ts +3 -2
- package/dist/_esm5.processed/core/adaptive/network_analyzer.d.ts +4 -4
- package/dist/_esm5.processed/core/adaptive/network_analyzer.js +43 -38
- package/dist/_esm5.processed/core/adaptive/utils/bandwidth_estimator.js +1 -1
- package/dist/_esm5.processed/core/adaptive/utils/ewma.js +1 -2
- package/dist/_esm5.processed/core/adaptive/utils/filter_by_bitrate.d.ts +1 -1
- package/dist/_esm5.processed/core/adaptive/utils/filter_by_width.d.ts +1 -1
- package/dist/_esm5.processed/core/adaptive/utils/filter_by_width.js +3 -6
- package/dist/_esm5.processed/core/adaptive/utils/get_buffer_levels.js +7 -4
- package/dist/_esm5.processed/core/adaptive/utils/last_estimate_storage.d.ts +1 -1
- package/dist/_esm5.processed/core/adaptive/utils/pending_requests_store.d.ts +2 -1
- package/dist/_esm5.processed/core/adaptive/utils/representation_score_calculator.d.ts +1 -1
- package/dist/_esm5.processed/core/adaptive/utils/representation_score_calculator.js +8 -5
- package/dist/_esm5.processed/core/adaptive/utils/select_optimal_representation.d.ts +1 -1
- package/dist/_esm5.processed/core/adaptive/utils/select_optimal_representation.js +5 -3
- package/dist/_esm5.processed/core/api/debug/buffer_graph.d.ts +1 -1
- package/dist/_esm5.processed/core/api/debug/buffer_graph.js +3 -8
- package/dist/_esm5.processed/core/api/debug/buffer_size_graph.js +1 -2
- package/dist/_esm5.processed/core/api/debug/modules/general_info.d.ts +2 -2
- package/dist/_esm5.processed/core/api/debug/modules/general_info.js +17 -13
- package/dist/_esm5.processed/core/api/debug/modules/segment_buffer_content.d.ts +3 -3
- package/dist/_esm5.processed/core/api/debug/modules/segment_buffer_content.js +4 -2
- package/dist/_esm5.processed/core/api/debug/modules/segment_buffer_size.d.ts +2 -2
- package/dist/_esm5.processed/core/api/debug/modules/segment_buffer_size.js +1 -1
- package/dist/_esm5.processed/core/api/debug/render.d.ts +2 -2
- package/dist/_esm5.processed/core/api/debug/utils.d.ts +5 -5
- package/dist/_esm5.processed/core/api/index.d.ts +1 -1
- package/dist/_esm5.processed/core/api/option_utils.d.ts +3 -3
- package/dist/_esm5.processed/core/api/option_utils.js +85 -48
- package/dist/_esm5.processed/core/api/playback_observer.d.ts +16 -18
- package/dist/_esm5.processed/core/api/playback_observer.js +65 -42
- package/dist/_esm5.processed/core/api/public_api.d.ts +10 -9
- package/dist/_esm5.processed/core/api/public_api.js +103 -94
- package/dist/_esm5.processed/core/api/tracks_management/media_element_track_choice_manager.d.ts +1 -1
- package/dist/_esm5.processed/core/api/tracks_management/media_element_track_choice_manager.js +25 -14
- package/dist/_esm5.processed/core/api/tracks_management/track_choice_manager.d.ts +3 -3
- package/dist/_esm5.processed/core/api/tracks_management/track_choice_manager.js +72 -80
- package/dist/_esm5.processed/core/api/utils.d.ts +5 -5
- package/dist/_esm5.processed/core/api/utils.js +5 -8
- package/dist/_esm5.processed/core/decrypt/__tests__/__global__/utils.d.ts +12 -54
- package/dist/_esm5.processed/core/decrypt/__tests__/__global__/utils.js +55 -66
- package/dist/_esm5.processed/core/decrypt/attach_media_keys.d.ts +10 -5
- package/dist/_esm5.processed/core/decrypt/attach_media_keys.js +16 -8
- package/dist/_esm5.processed/core/decrypt/content_decryptor.d.ts +11 -2
- package/dist/_esm5.processed/core/decrypt/content_decryptor.js +136 -65
- package/dist/_esm5.processed/core/decrypt/create_or_load_session.d.ts +5 -4
- package/dist/_esm5.processed/core/decrypt/create_or_load_session.js +18 -7
- package/dist/_esm5.processed/core/decrypt/create_session.d.ts +5 -4
- package/dist/_esm5.processed/core/decrypt/create_session.js +6 -12
- package/dist/_esm5.processed/core/decrypt/dispose_decryption_resources.js +1 -2
- package/dist/_esm5.processed/core/decrypt/find_key_system.d.ts +13 -3
- package/dist/_esm5.processed/core/decrypt/find_key_system.js +45 -22
- package/dist/_esm5.processed/core/decrypt/get_key_system_configuration.js +1 -2
- package/dist/_esm5.processed/core/decrypt/get_media_keys.d.ts +9 -4
- package/dist/_esm5.processed/core/decrypt/get_media_keys.js +17 -6
- package/dist/_esm5.processed/core/decrypt/init_media_keys.d.ts +3 -3
- package/dist/_esm5.processed/core/decrypt/session_events_listener.d.ts +2 -2
- package/dist/_esm5.processed/core/decrypt/session_events_listener.js +12 -16
- package/dist/_esm5.processed/core/decrypt/set_server_certificate.d.ts +3 -3
- package/dist/_esm5.processed/core/decrypt/set_server_certificate.js +6 -7
- package/dist/_esm5.processed/core/decrypt/types.d.ts +11 -5
- package/dist/_esm5.processed/core/decrypt/utils/are_init_values_compatible.js +20 -12
- package/dist/_esm5.processed/core/decrypt/utils/check_key_statuses.d.ts +2 -2
- package/dist/_esm5.processed/core/decrypt/utils/check_key_statuses.js +5 -4
- package/dist/_esm5.processed/core/decrypt/utils/clean_old_loaded_sessions.d.ts +1 -1
- package/dist/_esm5.processed/core/decrypt/utils/clean_old_stored_persistent_info.d.ts +1 -1
- package/dist/_esm5.processed/core/decrypt/utils/init_data_values_container.d.ts +1 -1
- package/dist/_esm5.processed/core/decrypt/utils/init_data_values_container.js +16 -9
- package/dist/_esm5.processed/core/decrypt/utils/is_session_usable.d.ts +1 -1
- package/dist/_esm5.processed/core/decrypt/utils/is_session_usable.js +1 -2
- package/dist/_esm5.processed/core/decrypt/utils/key_session_record.d.ts +1 -1
- package/dist/_esm5.processed/core/decrypt/utils/key_session_record.js +1 -2
- package/dist/_esm5.processed/core/decrypt/utils/loaded_sessions_store.d.ts +11 -13
- package/dist/_esm5.processed/core/decrypt/utils/loaded_sessions_store.js +13 -13
- package/dist/_esm5.processed/core/decrypt/utils/media_keys_infos_store.d.ts +8 -3
- package/dist/_esm5.processed/core/decrypt/utils/media_keys_infos_store.js +1 -2
- package/dist/_esm5.processed/core/decrypt/utils/persistent_sessions_store.d.ts +3 -3
- package/dist/_esm5.processed/core/decrypt/utils/persistent_sessions_store.js +27 -16
- package/dist/_esm5.processed/core/decrypt/utils/serializable_bytes.js +1 -1
- package/dist/_esm5.processed/core/decrypt/utils/server_certificate_store.d.ts +1 -1
- package/dist/_esm5.processed/core/decrypt/utils/server_certificate_store.js +19 -12
- package/dist/_esm5.processed/core/fetchers/cdn_prioritizer.d.ts +2 -2
- package/dist/_esm5.processed/core/fetchers/cdn_prioritizer.js +5 -6
- package/dist/_esm5.processed/core/fetchers/index.d.ts +6 -3
- package/dist/_esm5.processed/core/fetchers/index.js +1 -1
- package/dist/_esm5.processed/core/fetchers/manifest/index.d.ts +3 -2
- package/dist/_esm5.processed/core/fetchers/manifest/manifest_fetcher.d.ts +2 -2
- package/dist/_esm5.processed/core/fetchers/manifest/manifest_fetcher.js +68 -61
- package/dist/_esm5.processed/core/fetchers/segment/index.d.ts +4 -3
- package/dist/_esm5.processed/core/fetchers/segment/prioritized_segment_fetcher.d.ts +4 -3
- package/dist/_esm5.processed/core/fetchers/segment/segment_fetcher.d.ts +9 -8
- package/dist/_esm5.processed/core/fetchers/segment/segment_fetcher.js +41 -29
- package/dist/_esm5.processed/core/fetchers/segment/segment_fetcher_creator.d.ts +5 -5
- package/dist/_esm5.processed/core/fetchers/segment/segment_fetcher_creator.js +2 -3
- package/dist/_esm5.processed/core/fetchers/segment/task_prioritizer.d.ts +1 -1
- package/dist/_esm5.processed/core/fetchers/segment/task_prioritizer.js +19 -18
- package/dist/_esm5.processed/core/fetchers/utils/error_selector.d.ts +1 -1
- package/dist/_esm5.processed/core/fetchers/utils/error_selector.js +1 -1
- package/dist/_esm5.processed/core/fetchers/utils/schedule_request.d.ts +3 -3
- package/dist/_esm5.processed/core/fetchers/utils/schedule_request.js +25 -25
- package/dist/_esm5.processed/core/init/directfile_content_initializer.d.ts +4 -4
- package/dist/_esm5.processed/core/init/directfile_content_initializer.js +21 -17
- package/dist/_esm5.processed/core/init/index.d.ts +2 -1
- package/dist/_esm5.processed/core/init/index.js +1 -1
- package/dist/_esm5.processed/core/init/media_source_content_initializer.d.ts +9 -9
- package/dist/_esm5.processed/core/init/media_source_content_initializer.js +64 -32
- package/dist/_esm5.processed/core/init/types.d.ts +10 -12
- package/dist/_esm5.processed/core/init/utils/content_time_boundaries_observer.d.ts +6 -5
- package/dist/_esm5.processed/core/init/utils/content_time_boundaries_observer.js +20 -19
- package/dist/_esm5.processed/core/init/utils/create_media_source.d.ts +1 -1
- package/dist/_esm5.processed/core/init/utils/create_media_source.js +2 -3
- package/dist/_esm5.processed/core/init/utils/create_stream_playback_observer.d.ts +6 -6
- package/dist/_esm5.processed/core/init/utils/create_stream_playback_observer.js +5 -3
- package/dist/_esm5.processed/core/init/utils/end_of_stream.d.ts +1 -1
- package/dist/_esm5.processed/core/init/utils/get_initial_time.d.ts +1 -1
- package/dist/_esm5.processed/core/init/utils/get_initial_time.js +12 -15
- package/dist/_esm5.processed/core/init/utils/get_loaded_reference.d.ts +3 -3
- package/dist/_esm5.processed/core/init/utils/get_loaded_reference.js +1 -2
- package/dist/_esm5.processed/core/init/utils/initial_seek_and_play.d.ts +9 -9
- package/dist/_esm5.processed/core/init/utils/initial_seek_and_play.js +39 -3
- package/dist/_esm5.processed/core/init/utils/initialize_content_decryption.d.ts +9 -8
- package/dist/_esm5.processed/core/init/utils/initialize_content_decryption.js +12 -9
- package/dist/_esm5.processed/core/init/utils/media_source_duration_updater.js +10 -7
- package/dist/_esm5.processed/core/init/utils/rebuffering_controller.d.ts +7 -6
- package/dist/_esm5.processed/core/init/utils/rebuffering_controller.js +24 -24
- package/dist/_esm5.processed/core/init/utils/stream_events_emitter/are_same_stream_events.js +1 -3
- package/dist/_esm5.processed/core/init/utils/stream_events_emitter/index.d.ts +1 -1
- package/dist/_esm5.processed/core/init/utils/stream_events_emitter/refresh_scheduled_events_list.d.ts +2 -2
- package/dist/_esm5.processed/core/init/utils/stream_events_emitter/refresh_scheduled_events_list.js +14 -6
- package/dist/_esm5.processed/core/init/utils/stream_events_emitter/stream_events_emitter.d.ts +3 -3
- package/dist/_esm5.processed/core/init/utils/stream_events_emitter/stream_events_emitter.js +12 -19
- package/dist/_esm5.processed/core/init/utils/stream_events_emitter/types.d.ts +1 -1
- package/dist/_esm5.processed/core/init/utils/throw_on_media_error.d.ts +1 -1
- package/dist/_esm5.processed/core/init/utils/throw_on_media_error.js +11 -6
- package/dist/_esm5.processed/core/segment_buffers/garbage_collector.d.ts +6 -6
- package/dist/_esm5.processed/core/segment_buffers/garbage_collector.js +12 -13
- package/dist/_esm5.processed/core/segment_buffers/implementations/audio_video/audio_video_segment_buffer.d.ts +3 -2
- package/dist/_esm5.processed/core/segment_buffers/implementations/audio_video/audio_video_segment_buffer.js +6 -9
- package/dist/_esm5.processed/core/segment_buffers/implementations/image/image_segment_buffer.d.ts +3 -2
- package/dist/_esm5.processed/core/segment_buffers/implementations/image/image_segment_buffer.js +1 -1
- package/dist/_esm5.processed/core/segment_buffers/implementations/text/html/html_text_segment_buffer.d.ts +2 -1
- package/dist/_esm5.processed/core/segment_buffers/implementations/text/html/html_text_segment_buffer.js +7 -7
- package/dist/_esm5.processed/core/segment_buffers/implementations/text/html/text_track_cues_store.d.ts +1 -1
- package/dist/_esm5.processed/core/segment_buffers/implementations/text/html/text_track_cues_store.js +4 -4
- package/dist/_esm5.processed/core/segment_buffers/implementations/text/html/update_proportional_elements.js +1 -2
- package/dist/_esm5.processed/core/segment_buffers/implementations/text/html/utils.d.ts +1 -1
- package/dist/_esm5.processed/core/segment_buffers/implementations/text/html/utils.js +2 -6
- package/dist/_esm5.processed/core/segment_buffers/implementations/text/native/native_text_segment_buffer.d.ts +2 -1
- package/dist/_esm5.processed/core/segment_buffers/implementations/text/native/native_text_segment_buffer.js +2 -2
- package/dist/_esm5.processed/core/segment_buffers/implementations/text/native/parsers.d.ts +1 -1
- package/dist/_esm5.processed/core/segment_buffers/implementations/types.d.ts +5 -7
- package/dist/_esm5.processed/core/segment_buffers/implementations/utils/manual_time_ranges.js +1 -1
- package/dist/_esm5.processed/core/segment_buffers/index.d.ts +8 -4
- package/dist/_esm5.processed/core/segment_buffers/index.js +2 -2
- package/dist/_esm5.processed/core/segment_buffers/inventory/buffered_history.d.ts +1 -1
- package/dist/_esm5.processed/core/segment_buffers/inventory/index.d.ts +6 -4
- package/dist/_esm5.processed/core/segment_buffers/inventory/segment_inventory.d.ts +4 -4
- package/dist/_esm5.processed/core/segment_buffers/inventory/segment_inventory.js +63 -54
- package/dist/_esm5.processed/core/segment_buffers/inventory/types.d.ts +1 -1
- package/dist/_esm5.processed/core/segment_buffers/segment_buffers_store.d.ts +2 -2
- package/dist/_esm5.processed/core/segment_buffers/segment_buffers_store.js +17 -23
- package/dist/_esm5.processed/core/stream/adaptation/adaptation_stream.d.ts +3 -3
- package/dist/_esm5.processed/core/stream/adaptation/adaptation_stream.js +49 -22
- package/dist/_esm5.processed/core/stream/adaptation/types.d.ts +8 -7
- package/dist/_esm5.processed/core/stream/adaptation/utils/create_representation_estimator.d.ts +7 -6
- package/dist/_esm5.processed/core/stream/adaptation/utils/create_representation_estimator.js +2 -1
- package/dist/_esm5.processed/core/stream/index.d.ts +6 -5
- package/dist/_esm5.processed/core/stream/orchestrator/get_time_ranges_for_content.d.ts +3 -3
- package/dist/_esm5.processed/core/stream/orchestrator/get_time_ranges_for_content.js +2 -2
- package/dist/_esm5.processed/core/stream/orchestrator/index.d.ts +3 -2
- package/dist/_esm5.processed/core/stream/orchestrator/stream_orchestrator.d.ts +9 -7
- package/dist/_esm5.processed/core/stream/orchestrator/stream_orchestrator.js +47 -34
- package/dist/_esm5.processed/core/stream/period/period_stream.d.ts +3 -3
- package/dist/_esm5.processed/core/stream/period/period_stream.js +49 -16
- package/dist/_esm5.processed/core/stream/period/types.d.ts +15 -12
- package/dist/_esm5.processed/core/stream/period/utils/get_adaptation_switch_strategy.d.ts +9 -9
- package/dist/_esm5.processed/core/stream/period/utils/get_adaptation_switch_strategy.js +26 -25
- package/dist/_esm5.processed/core/stream/representation/representation_stream.d.ts +3 -3
- package/dist/_esm5.processed/core/stream/representation/representation_stream.js +47 -23
- package/dist/_esm5.processed/core/stream/representation/types.d.ts +9 -8
- package/dist/_esm5.processed/core/stream/representation/utils/append_segment_to_buffer.d.ts +4 -4
- package/dist/_esm5.processed/core/stream/representation/utils/append_segment_to_buffer.js +10 -7
- package/dist/_esm5.processed/core/stream/representation/utils/check_for_discontinuity.d.ts +4 -3
- package/dist/_esm5.processed/core/stream/representation/utils/check_for_discontinuity.js +16 -18
- package/dist/_esm5.processed/core/stream/representation/utils/downloading_queue.d.ts +7 -6
- package/dist/_esm5.processed/core/stream/representation/utils/downloading_queue.js +11 -11
- package/dist/_esm5.processed/core/stream/representation/utils/force_garbage_collection.d.ts +2 -2
- package/dist/_esm5.processed/core/stream/representation/utils/force_garbage_collection.js +6 -8
- package/dist/_esm5.processed/core/stream/representation/utils/get_buffer_status.d.ts +5 -4
- package/dist/_esm5.processed/core/stream/representation/utils/get_buffer_status.js +40 -19
- package/dist/_esm5.processed/core/stream/representation/utils/get_needed_segments.d.ts +4 -3
- package/dist/_esm5.processed/core/stream/representation/utils/get_needed_segments.js +27 -28
- package/dist/_esm5.processed/core/stream/representation/utils/push_init_segment.d.ts +6 -5
- package/dist/_esm5.processed/core/stream/representation/utils/push_init_segment.js +7 -5
- package/dist/_esm5.processed/core/stream/representation/utils/push_media_segment.d.ts +8 -7
- package/dist/_esm5.processed/core/stream/representation/utils/push_media_segment.js +13 -10
- package/dist/_esm5.processed/default_config.js +20 -16
- package/dist/_esm5.processed/errors/encrypted_media_error.d.ts +2 -2
- package/dist/_esm5.processed/errors/encrypted_media_error.js +1 -1
- package/dist/_esm5.processed/errors/error_codes.d.ts +1 -1
- package/dist/_esm5.processed/errors/error_codes.js +1 -1
- package/dist/_esm5.processed/errors/format_error.d.ts +2 -2
- package/dist/_esm5.processed/errors/format_error.js +1 -2
- package/dist/_esm5.processed/errors/index.d.ts +6 -3
- package/dist/_esm5.processed/errors/index.js +2 -2
- package/dist/_esm5.processed/errors/is_known_error.d.ts +1 -1
- package/dist/_esm5.processed/errors/is_known_error.js +2 -2
- package/dist/_esm5.processed/errors/media_error.d.ts +3 -3
- package/dist/_esm5.processed/errors/media_error.js +4 -7
- package/dist/_esm5.processed/errors/network_error.d.ts +2 -2
- package/dist/_esm5.processed/errors/network_error.js +3 -3
- package/dist/_esm5.processed/errors/other_error.d.ts +1 -1
- package/dist/_esm5.processed/errors/other_error.js +1 -1
- package/dist/_esm5.processed/errors/request_error.d.ts +1 -1
- package/dist/_esm5.processed/experimental/features/dash_wasm.d.ts +2 -2
- package/dist/_esm5.processed/experimental/features/debug_element.d.ts +1 -1
- package/dist/_esm5.processed/experimental/features/local.d.ts +1 -1
- package/dist/_esm5.processed/experimental/features/metaplaylist.d.ts +1 -1
- package/dist/_esm5.processed/experimental/index.d.ts +1 -1
- package/dist/_esm5.processed/experimental/index.js +1 -1
- package/dist/_esm5.processed/experimental/tools/VideoThumbnailLoader/features/dash.d.ts +1 -1
- package/dist/_esm5.processed/experimental/tools/VideoThumbnailLoader/features/metaplaylist.d.ts +1 -1
- package/dist/_esm5.processed/experimental/tools/VideoThumbnailLoader/index.d.ts +1 -1
- package/dist/_esm5.processed/experimental/tools/VideoThumbnailLoader/index.js +2 -2
- package/dist/_esm5.processed/experimental/tools/VideoThumbnailLoader/load_and_push_segment.d.ts +3 -3
- package/dist/_esm5.processed/experimental/tools/VideoThumbnailLoader/load_and_push_segment.js +7 -3
- package/dist/_esm5.processed/experimental/tools/VideoThumbnailLoader/prepare_source_buffer.d.ts +1 -1
- package/dist/_esm5.processed/experimental/tools/VideoThumbnailLoader/prepare_source_buffer.js +1 -2
- package/dist/_esm5.processed/experimental/tools/VideoThumbnailLoader/remove_buffer_around_time.d.ts +2 -2
- package/dist/_esm5.processed/experimental/tools/VideoThumbnailLoader/remove_buffer_around_time.js +2 -2
- package/dist/_esm5.processed/experimental/tools/VideoThumbnailLoader/types.d.ts +3 -2
- package/dist/_esm5.processed/experimental/tools/VideoThumbnailLoader/video_thumbnail_loader.d.ts +2 -2
- package/dist/_esm5.processed/experimental/tools/VideoThumbnailLoader/video_thumbnail_loader.js +12 -18
- package/dist/_esm5.processed/experimental/tools/createMetaplaylist/get_duration_from_manifest.js +13 -23
- package/dist/_esm5.processed/experimental/tools/createMetaplaylist/index.d.ts +1 -1
- package/dist/_esm5.processed/experimental/tools/createMetaplaylist/index.js +8 -7
- package/dist/_esm5.processed/experimental/tools/mediaCapabilitiesProber/api/index.d.ts +1 -1
- package/dist/_esm5.processed/experimental/tools/mediaCapabilitiesProber/api/index.js +9 -13
- package/dist/_esm5.processed/experimental/tools/mediaCapabilitiesProber/api/probeMediaConfiguration.d.ts +4 -3
- package/dist/_esm5.processed/experimental/tools/mediaCapabilitiesProber/api/probeMediaConfiguration.js +5 -3
- package/dist/_esm5.processed/experimental/tools/mediaCapabilitiesProber/capabilities.d.ts +1 -1
- package/dist/_esm5.processed/experimental/tools/mediaCapabilitiesProber/capabilities.js +10 -47
- package/dist/_esm5.processed/experimental/tools/mediaCapabilitiesProber/probers/DRMInfos.d.ts +2 -1
- package/dist/_esm5.processed/experimental/tools/mediaCapabilitiesProber/probers/DRMInfos.js +8 -5
- package/dist/_esm5.processed/experimental/tools/mediaCapabilitiesProber/probers/HDCPPolicy.d.ts +2 -1
- package/dist/_esm5.processed/experimental/tools/mediaCapabilitiesProber/probers/HDCPPolicy.js +21 -13
- package/dist/_esm5.processed/experimental/tools/mediaCapabilitiesProber/probers/decodingInfo.d.ts +2 -1
- package/dist/_esm5.processed/experimental/tools/mediaCapabilitiesProber/probers/decodingInfo.js +22 -18
- package/dist/_esm5.processed/experimental/tools/mediaCapabilitiesProber/probers/defaultCodecsFinder.js +4 -7
- package/dist/_esm5.processed/experimental/tools/mediaCapabilitiesProber/probers/index.d.ts +1 -1
- package/dist/_esm5.processed/experimental/tools/mediaCapabilitiesProber/probers/mediaContentType.d.ts +2 -1
- package/dist/_esm5.processed/experimental/tools/mediaCapabilitiesProber/probers/mediaContentType.js +3 -5
- package/dist/_esm5.processed/experimental/tools/mediaCapabilitiesProber/probers/mediaContentTypeWithFeatures/format.d.ts +1 -1
- package/dist/_esm5.processed/experimental/tools/mediaCapabilitiesProber/probers/mediaContentTypeWithFeatures/format.js +4 -10
- package/dist/_esm5.processed/experimental/tools/mediaCapabilitiesProber/probers/mediaContentTypeWithFeatures/index.d.ts +2 -1
- package/dist/_esm5.processed/experimental/tools/mediaCapabilitiesProber/probers/mediaContentTypeWithFeatures/index.js +2 -3
- package/dist/_esm5.processed/experimental/tools/mediaCapabilitiesProber/probers/mediaDisplayInfos.d.ts +2 -1
- package/dist/_esm5.processed/experimental/tools/mediaCapabilitiesProber/probers/mediaDisplayInfos.js +2 -3
- package/dist/_esm5.processed/experimental/tools/mediaCapabilitiesProber/types.d.ts +2 -2
- package/dist/_esm5.processed/experimental/tools/mediaCapabilitiesProber/utils.d.ts +1 -1
- package/dist/_esm5.processed/experimental/tools/mediaCapabilitiesProber/utils.js +6 -6
- package/dist/_esm5.processed/experimental/tools/parseBIFThumbnails.js +5 -4
- package/dist/_esm5.processed/features/add_features.d.ts +1 -1
- package/dist/_esm5.processed/features/features_object.d.ts +1 -1
- package/dist/_esm5.processed/features/features_object.js +4 -3
- package/dist/_esm5.processed/features/index.d.ts +3 -2
- package/dist/_esm5.processed/features/index.js +1 -1
- package/dist/_esm5.processed/features/list/bif_parser.d.ts +1 -1
- package/dist/_esm5.processed/features/list/dash.d.ts +1 -1
- package/dist/_esm5.processed/features/list/directfile.d.ts +1 -1
- package/dist/_esm5.processed/features/list/eme.d.ts +1 -1
- package/dist/_esm5.processed/features/list/html_sami_parser.d.ts +1 -1
- package/dist/_esm5.processed/features/list/html_srt_parser.d.ts +1 -1
- package/dist/_esm5.processed/features/list/html_text_buffer.d.ts +1 -1
- package/dist/_esm5.processed/features/list/html_ttml_parser.d.ts +1 -1
- package/dist/_esm5.processed/features/list/html_vtt_parser.d.ts +1 -1
- package/dist/_esm5.processed/features/list/image_buffer.d.ts +1 -1
- package/dist/_esm5.processed/features/list/native_sami_parser.d.ts +1 -1
- package/dist/_esm5.processed/features/list/native_srt_parser.d.ts +1 -1
- package/dist/_esm5.processed/features/list/native_text_buffer.d.ts +1 -1
- package/dist/_esm5.processed/features/list/native_ttml_parser.d.ts +1 -1
- package/dist/_esm5.processed/features/list/native_vtt_parser.d.ts +1 -1
- package/dist/_esm5.processed/features/list/smooth.d.ts +1 -1
- package/dist/_esm5.processed/features/types.d.ts +11 -11
- package/dist/_esm5.processed/manifest/adaptation.d.ts +3 -3
- package/dist/_esm5.processed/manifest/adaptation.js +24 -14
- package/dist/_esm5.processed/manifest/index.d.ts +9 -5
- package/dist/_esm5.processed/manifest/index.js +4 -8
- package/dist/_esm5.processed/manifest/manifest.d.ts +8 -7
- package/dist/_esm5.processed/manifest/manifest.js +37 -33
- package/dist/_esm5.processed/manifest/period.d.ts +4 -4
- package/dist/_esm5.processed/manifest/period.js +7 -14
- package/dist/_esm5.processed/manifest/representation.d.ts +4 -4
- package/dist/_esm5.processed/manifest/representation.js +5 -5
- package/dist/_esm5.processed/manifest/representation_index/index.d.ts +3 -2
- package/dist/_esm5.processed/manifest/representation_index/index.js +1 -1
- package/dist/_esm5.processed/manifest/representation_index/static.d.ts +1 -1
- package/dist/_esm5.processed/manifest/representation_index/static.js +6 -2
- package/dist/_esm5.processed/manifest/representation_index/types.d.ts +6 -5
- package/dist/_esm5.processed/manifest/update_period_in_place.d.ts +3 -3
- package/dist/_esm5.processed/manifest/update_period_in_place.js +9 -9
- package/dist/_esm5.processed/manifest/update_periods.d.ts +2 -2
- package/dist/_esm5.processed/manifest/update_periods.js +6 -3
- package/dist/_esm5.processed/manifest/utils.d.ts +4 -4
- package/dist/_esm5.processed/manifest/utils.js +6 -4
- package/dist/_esm5.processed/parsers/containers/isobmff/create_box.d.ts +1 -1
- package/dist/_esm5.processed/parsers/containers/isobmff/create_box.js +5 -4
- package/dist/_esm5.processed/parsers/containers/isobmff/drm/playready.js +2 -3
- package/dist/_esm5.processed/parsers/containers/isobmff/get_box.js +3 -5
- package/dist/_esm5.processed/parsers/containers/isobmff/index.d.ts +5 -4
- package/dist/_esm5.processed/parsers/containers/isobmff/index.js +4 -4
- package/dist/_esm5.processed/parsers/containers/isobmff/read.d.ts +1 -1
- package/dist/_esm5.processed/parsers/containers/isobmff/read.js +9 -9
- package/dist/_esm5.processed/parsers/containers/isobmff/take_pssh_out.js +3 -4
- package/dist/_esm5.processed/parsers/containers/isobmff/utils.js +51 -41
- package/dist/_esm5.processed/parsers/containers/matroska/index.d.ts +2 -1
- package/dist/_esm5.processed/parsers/containers/matroska/index.js +1 -1
- package/dist/_esm5.processed/parsers/containers/matroska/utils.js +29 -16
- package/dist/_esm5.processed/parsers/images/bif.js +15 -5
- package/dist/_esm5.processed/parsers/manifest/dash/common/attach_trickmode_track.d.ts +1 -1
- package/dist/_esm5.processed/parsers/manifest/dash/common/convert_supplemental_codecs.js +1 -3
- package/dist/_esm5.processed/parsers/manifest/dash/common/flatten_overlapping_periods.d.ts +1 -1
- package/dist/_esm5.processed/parsers/manifest/dash/common/flatten_overlapping_periods.js +1 -1
- package/dist/_esm5.processed/parsers/manifest/dash/common/get_hdr_information.js +4 -12
- package/dist/_esm5.processed/parsers/manifest/dash/common/get_http_utc-timing_url.d.ts +1 -1
- package/dist/_esm5.processed/parsers/manifest/dash/common/get_http_utc-timing_url.js +4 -5
- package/dist/_esm5.processed/parsers/manifest/dash/common/get_minimum_and_maximum_positions.d.ts +1 -1
- package/dist/_esm5.processed/parsers/manifest/dash/common/get_minimum_and_maximum_positions.js +5 -2
- package/dist/_esm5.processed/parsers/manifest/dash/common/get_periods_time_infos.d.ts +1 -1
- package/dist/_esm5.processed/parsers/manifest/dash/common/get_periods_time_infos.js +5 -6
- package/dist/_esm5.processed/parsers/manifest/dash/common/index.d.ts +3 -2
- package/dist/_esm5.processed/parsers/manifest/dash/common/indexes/base.d.ts +4 -4
- package/dist/_esm5.processed/parsers/manifest/dash/common/indexes/base.js +34 -28
- package/dist/_esm5.processed/parsers/manifest/dash/common/indexes/get_init_segment.d.ts +2 -2
- package/dist/_esm5.processed/parsers/manifest/dash/common/indexes/get_init_segment.js +7 -4
- package/dist/_esm5.processed/parsers/manifest/dash/common/indexes/get_segments_from_timeline.d.ts +4 -4
- package/dist/_esm5.processed/parsers/manifest/dash/common/indexes/get_segments_from_timeline.js +15 -11
- package/dist/_esm5.processed/parsers/manifest/dash/common/indexes/index.d.ts +10 -5
- package/dist/_esm5.processed/parsers/manifest/dash/common/indexes/list.d.ts +2 -2
- package/dist/_esm5.processed/parsers/manifest/dash/common/indexes/list.js +30 -18
- package/dist/_esm5.processed/parsers/manifest/dash/common/indexes/template.d.ts +3 -3
- package/dist/_esm5.processed/parsers/manifest/dash/common/indexes/template.js +56 -55
- package/dist/_esm5.processed/parsers/manifest/dash/common/indexes/timeline/construct_timeline_from_elements.d.ts +1 -1
- package/dist/_esm5.processed/parsers/manifest/dash/common/indexes/timeline/construct_timeline_from_elements.js +2 -6
- package/dist/_esm5.processed/parsers/manifest/dash/common/indexes/timeline/construct_timeline_from_previous_timeline.d.ts +1 -1
- package/dist/_esm5.processed/parsers/manifest/dash/common/indexes/timeline/construct_timeline_from_previous_timeline.js +11 -15
- package/dist/_esm5.processed/parsers/manifest/dash/common/indexes/timeline/convert_element_to_index_segment.d.ts +1 -1
- package/dist/_esm5.processed/parsers/manifest/dash/common/indexes/timeline/convert_element_to_index_segment.js +12 -9
- package/dist/_esm5.processed/parsers/manifest/dash/common/indexes/timeline/find_first_common_start_time.d.ts +1 -1
- package/dist/_esm5.processed/parsers/manifest/dash/common/indexes/timeline/find_first_common_start_time.js +29 -19
- package/dist/_esm5.processed/parsers/manifest/dash/common/indexes/timeline/index.d.ts +3 -2
- package/dist/_esm5.processed/parsers/manifest/dash/common/indexes/timeline/timeline_representation_index.d.ts +6 -6
- package/dist/_esm5.processed/parsers/manifest/dash/common/indexes/timeline/timeline_representation_index.js +73 -59
- package/dist/_esm5.processed/parsers/manifest/dash/common/indexes/tokens.js +2 -4
- package/dist/_esm5.processed/parsers/manifest/dash/common/infer_adaptation_type.d.ts +1 -1
- package/dist/_esm5.processed/parsers/manifest/dash/common/manifest_bounds_calculator.js +7 -8
- package/dist/_esm5.processed/parsers/manifest/dash/common/parse_adaptation_sets.d.ts +4 -4
- package/dist/_esm5.processed/parsers/manifest/dash/common/parse_adaptation_sets.js +52 -50
- package/dist/_esm5.processed/parsers/manifest/dash/common/parse_availability_start_time.d.ts +1 -1
- package/dist/_esm5.processed/parsers/manifest/dash/common/parse_mpd.d.ts +6 -6
- package/dist/_esm5.processed/parsers/manifest/dash/common/parse_mpd.js +52 -31
- package/dist/_esm5.processed/parsers/manifest/dash/common/parse_periods.d.ts +4 -4
- package/dist/_esm5.processed/parsers/manifest/dash/common/parse_periods.js +41 -30
- package/dist/_esm5.processed/parsers/manifest/dash/common/parse_representation_index.d.ts +4 -4
- package/dist/_esm5.processed/parsers/manifest/dash/common/parse_representation_index.js +1 -2
- package/dist/_esm5.processed/parsers/manifest/dash/common/parse_representations.d.ts +4 -4
- package/dist/_esm5.processed/parsers/manifest/dash/common/parse_representations.js +63 -64
- package/dist/_esm5.processed/parsers/manifest/dash/common/resolve_base_urls.d.ts +1 -1
- package/dist/_esm5.processed/parsers/manifest/dash/common/resolve_base_urls.js +4 -2
- package/dist/_esm5.processed/parsers/manifest/dash/js-parser/node_parsers/AdaptationSet.d.ts +1 -1
- package/dist/_esm5.processed/parsers/manifest/dash/js-parser/node_parsers/AdaptationSet.js +73 -37
- package/dist/_esm5.processed/parsers/manifest/dash/js-parser/node_parsers/BaseURL.d.ts +1 -1
- package/dist/_esm5.processed/parsers/manifest/dash/js-parser/node_parsers/BaseURL.js +1 -2
- package/dist/_esm5.processed/parsers/manifest/dash/js-parser/node_parsers/ContentComponent.d.ts +1 -1
- package/dist/_esm5.processed/parsers/manifest/dash/js-parser/node_parsers/ContentProtection.d.ts +1 -1
- package/dist/_esm5.processed/parsers/manifest/dash/js-parser/node_parsers/EventStream.d.ts +1 -1
- package/dist/_esm5.processed/parsers/manifest/dash/js-parser/node_parsers/EventStream.js +13 -7
- package/dist/_esm5.processed/parsers/manifest/dash/js-parser/node_parsers/Initialization.d.ts +1 -1
- package/dist/_esm5.processed/parsers/manifest/dash/js-parser/node_parsers/Initialization.js +5 -3
- package/dist/_esm5.processed/parsers/manifest/dash/js-parser/node_parsers/MPD.d.ts +1 -1
- package/dist/_esm5.processed/parsers/manifest/dash/js-parser/node_parsers/MPD.js +44 -27
- package/dist/_esm5.processed/parsers/manifest/dash/js-parser/node_parsers/Period.d.ts +1 -1
- package/dist/_esm5.processed/parsers/manifest/dash/js-parser/node_parsers/Period.js +14 -8
- package/dist/_esm5.processed/parsers/manifest/dash/js-parser/node_parsers/Representation.d.ts +1 -1
- package/dist/_esm5.processed/parsers/manifest/dash/js-parser/node_parsers/Representation.js +36 -18
- package/dist/_esm5.processed/parsers/manifest/dash/js-parser/node_parsers/SegmentBase.d.ts +1 -1
- package/dist/_esm5.processed/parsers/manifest/dash/js-parser/node_parsers/SegmentBase.js +36 -18
- package/dist/_esm5.processed/parsers/manifest/dash/js-parser/node_parsers/SegmentList.d.ts +1 -1
- package/dist/_esm5.processed/parsers/manifest/dash/js-parser/node_parsers/SegmentTemplate.d.ts +1 -1
- package/dist/_esm5.processed/parsers/manifest/dash/js-parser/node_parsers/SegmentTemplate.js +17 -8
- package/dist/_esm5.processed/parsers/manifest/dash/js-parser/node_parsers/SegmentTimeline.d.ts +1 -1
- package/dist/_esm5.processed/parsers/manifest/dash/js-parser/node_parsers/SegmentURL.d.ts +1 -1
- package/dist/_esm5.processed/parsers/manifest/dash/js-parser/node_parsers/SegmentURL.js +9 -5
- package/dist/_esm5.processed/parsers/manifest/dash/js-parser/node_parsers/utils.d.ts +8 -26
- package/dist/_esm5.processed/parsers/manifest/dash/js-parser/node_parsers/utils.js +6 -12
- package/dist/_esm5.processed/parsers/manifest/dash/js-parser/parse_from_document.d.ts +2 -2
- package/dist/_esm5.processed/parsers/manifest/dash/js-parser/parse_from_document.js +9 -4
- package/dist/_esm5.processed/parsers/manifest/dash/parsers_types.d.ts +2 -2
- package/dist/_esm5.processed/parsers/manifest/dash/wasm-parser/index.d.ts +3 -2
- package/dist/_esm5.processed/parsers/manifest/dash/wasm-parser/ts/dash-wasm-parser.d.ts +1 -1
- package/dist/_esm5.processed/parsers/manifest/dash/wasm-parser/ts/dash-wasm-parser.js +29 -16
- package/dist/_esm5.processed/parsers/manifest/dash/wasm-parser/ts/generators/AdaptationSet.d.ts +3 -2
- package/dist/_esm5.processed/parsers/manifest/dash/wasm-parser/ts/generators/AdaptationSet.js +22 -35
- package/dist/_esm5.processed/parsers/manifest/dash/wasm-parser/ts/generators/BaseURL.d.ts +2 -2
- package/dist/_esm5.processed/parsers/manifest/dash/wasm-parser/ts/generators/ContentComponent.d.ts +2 -2
- package/dist/_esm5.processed/parsers/manifest/dash/wasm-parser/ts/generators/ContentProtection.d.ts +2 -2
- package/dist/_esm5.processed/parsers/manifest/dash/wasm-parser/ts/generators/ContentProtection.js +3 -1
- package/dist/_esm5.processed/parsers/manifest/dash/wasm-parser/ts/generators/EventStream.d.ts +3 -2
- package/dist/_esm5.processed/parsers/manifest/dash/wasm-parser/ts/generators/EventStream.js +2 -4
- package/dist/_esm5.processed/parsers/manifest/dash/wasm-parser/ts/generators/Label.d.ts +3 -0
- package/dist/_esm5.processed/parsers/manifest/dash/wasm-parser/ts/generators/Label.js +9 -0
- package/dist/_esm5.processed/parsers/manifest/dash/wasm-parser/ts/generators/MPD.d.ts +3 -2
- package/dist/_esm5.processed/parsers/manifest/dash/wasm-parser/ts/generators/MPD.js +5 -5
- package/dist/_esm5.processed/parsers/manifest/dash/wasm-parser/ts/generators/Period.d.ts +3 -2
- package/dist/_esm5.processed/parsers/manifest/dash/wasm-parser/ts/generators/Period.js +9 -6
- package/dist/_esm5.processed/parsers/manifest/dash/wasm-parser/ts/generators/Representation.d.ts +3 -2
- package/dist/_esm5.processed/parsers/manifest/dash/wasm-parser/ts/generators/Representation.js +8 -16
- package/dist/_esm5.processed/parsers/manifest/dash/wasm-parser/ts/generators/Scheme.d.ts +2 -2
- package/dist/_esm5.processed/parsers/manifest/dash/wasm-parser/ts/generators/SegmentBase.d.ts +2 -2
- package/dist/_esm5.processed/parsers/manifest/dash/wasm-parser/ts/generators/SegmentBase.js +5 -10
- package/dist/_esm5.processed/parsers/manifest/dash/wasm-parser/ts/generators/SegmentList.d.ts +3 -2
- package/dist/_esm5.processed/parsers/manifest/dash/wasm-parser/ts/generators/SegmentTemplate.d.ts +2 -2
- package/dist/_esm5.processed/parsers/manifest/dash/wasm-parser/ts/generators/SegmentTemplate.js +11 -18
- package/dist/_esm5.processed/parsers/manifest/dash/wasm-parser/ts/generators/SegmentUrl.d.ts +2 -2
- package/dist/_esm5.processed/parsers/manifest/dash/wasm-parser/ts/generators/SegmentUrl.js +2 -4
- package/dist/_esm5.processed/parsers/manifest/dash/wasm-parser/ts/generators/XLink.d.ts +3 -2
- package/dist/_esm5.processed/parsers/manifest/dash/wasm-parser/ts/generators/XLink.js +5 -5
- package/dist/_esm5.processed/parsers/manifest/dash/wasm-parser/ts/generators/root.d.ts +2 -2
- package/dist/_esm5.processed/parsers/manifest/dash/wasm-parser/ts/generators/root.js +5 -6
- package/dist/_esm5.processed/parsers/manifest/dash/wasm-parser/ts/parsers_stack.d.ts +1 -1
- package/dist/_esm5.processed/parsers/manifest/dash/wasm-parser/ts/parsers_stack.js +1 -2
- package/dist/_esm5.processed/parsers/manifest/dash/wasm-parser/ts/types.d.ts +2 -1
- package/dist/_esm5.processed/parsers/manifest/dash/wasm-parser/ts/utils.d.ts +1 -1
- package/dist/_esm5.processed/parsers/manifest/dash/wasm-parser/ts/utils.js +2 -4
- package/dist/_esm5.processed/parsers/manifest/local/index.d.ts +1 -1
- package/dist/_esm5.processed/parsers/manifest/local/parse_local_manifest.d.ts +2 -2
- package/dist/_esm5.processed/parsers/manifest/local/parse_local_manifest.js +25 -16
- package/dist/_esm5.processed/parsers/manifest/local/representation_index.d.ts +2 -2
- package/dist/_esm5.processed/parsers/manifest/local/representation_index.js +5 -10
- package/dist/_esm5.processed/parsers/manifest/metaplaylist/index.d.ts +3 -2
- package/dist/_esm5.processed/parsers/manifest/metaplaylist/metaplaylist_parser.d.ts +2 -2
- package/dist/_esm5.processed/parsers/manifest/metaplaylist/metaplaylist_parser.js +33 -29
- package/dist/_esm5.processed/parsers/manifest/metaplaylist/representation_index.d.ts +2 -2
- package/dist/_esm5.processed/parsers/manifest/metaplaylist/representation_index.js +9 -7
- package/dist/_esm5.processed/parsers/manifest/smooth/create_parser.d.ts +3 -3
- package/dist/_esm5.processed/parsers/manifest/smooth/create_parser.js +136 -109
- package/dist/_esm5.processed/parsers/manifest/smooth/get_codecs.js +3 -3
- package/dist/_esm5.processed/parsers/manifest/smooth/index.d.ts +4 -2
- package/dist/_esm5.processed/parsers/manifest/smooth/index.js +1 -1
- package/dist/_esm5.processed/parsers/manifest/smooth/parse_C_nodes.js +6 -6
- package/dist/_esm5.processed/parsers/manifest/smooth/parse_protection_node.js +12 -8
- package/dist/_esm5.processed/parsers/manifest/smooth/representation_index.d.ts +2 -2
- package/dist/_esm5.processed/parsers/manifest/smooth/representation_index.js +48 -53
- package/dist/_esm5.processed/parsers/manifest/smooth/utils/add_segment_infos.js +10 -7
- package/dist/_esm5.processed/parsers/manifest/smooth/utils/tokens.d.ts +1 -1
- package/dist/_esm5.processed/parsers/manifest/smooth/utils/tokens.js +2 -3
- package/dist/_esm5.processed/parsers/manifest/types.d.ts +2 -2
- package/dist/_esm5.processed/parsers/manifest/utils/check_manifest_ids.d.ts +1 -1
- package/dist/_esm5.processed/parsers/manifest/utils/clear_timeline_from_position.d.ts +1 -1
- package/dist/_esm5.processed/parsers/manifest/utils/clear_timeline_from_position.js +9 -6
- package/dist/_esm5.processed/parsers/manifest/utils/get_first_time_from_adaptation.d.ts +1 -1
- package/dist/_esm5.processed/parsers/manifest/utils/get_first_time_from_adaptation.js +5 -4
- package/dist/_esm5.processed/parsers/manifest/utils/get_last_time_from_adaptation.d.ts +1 -1
- package/dist/_esm5.processed/parsers/manifest/utils/get_last_time_from_adaptation.js +5 -4
- package/dist/_esm5.processed/parsers/manifest/utils/get_maximum_positions.d.ts +1 -1
- package/dist/_esm5.processed/parsers/manifest/utils/get_maximum_positions.js +10 -16
- package/dist/_esm5.processed/parsers/manifest/utils/get_minimum_position.d.ts +1 -1
- package/dist/_esm5.processed/parsers/manifest/utils/get_minimum_position.js +4 -10
- package/dist/_esm5.processed/parsers/manifest/utils/index_helpers.d.ts +1 -1
- package/dist/_esm5.processed/parsers/manifest/utils/index_helpers.js +4 -5
- package/dist/_esm5.processed/parsers/manifest/utils/update_segment_timeline.d.ts +1 -1
- package/dist/_esm5.processed/parsers/manifest/utils/update_segment_timeline.js +18 -18
- package/dist/_esm5.processed/parsers/texttracks/index.d.ts +1 -1
- package/dist/_esm5.processed/parsers/texttracks/sami/html.d.ts +1 -1
- package/dist/_esm5.processed/parsers/texttracks/sami/html.js +15 -15
- package/dist/_esm5.processed/parsers/texttracks/sami/native.d.ts +1 -1
- package/dist/_esm5.processed/parsers/texttracks/sami/native.js +7 -14
- package/dist/_esm5.processed/parsers/texttracks/srt/html.js +6 -6
- package/dist/_esm5.processed/parsers/texttracks/srt/native.d.ts +1 -1
- package/dist/_esm5.processed/parsers/texttracks/srt/native.js +1 -7
- package/dist/_esm5.processed/parsers/texttracks/srt/parse_cue.js +4 -8
- package/dist/_esm5.processed/parsers/texttracks/ttml/get_parameters.js +4 -8
- package/dist/_esm5.processed/parsers/texttracks/ttml/get_time_delimiters.d.ts +1 -1
- package/dist/_esm5.processed/parsers/texttracks/ttml/get_time_delimiters.js +6 -8
- package/dist/_esm5.processed/parsers/texttracks/ttml/html/apply_default_ttml_paragraph_style.js +2 -2
- package/dist/_esm5.processed/parsers/texttracks/ttml/html/apply_extent.js +2 -6
- package/dist/_esm5.processed/parsers/texttracks/ttml/html/apply_font_size.js +3 -4
- package/dist/_esm5.processed/parsers/texttracks/ttml/html/apply_origin.js +2 -6
- package/dist/_esm5.processed/parsers/texttracks/ttml/html/apply_padding.js +2 -6
- package/dist/_esm5.processed/parsers/texttracks/ttml/html/create_element.d.ts +2 -2
- package/dist/_esm5.processed/parsers/texttracks/ttml/html/create_element.js +22 -21
- package/dist/_esm5.processed/parsers/texttracks/ttml/html/generate_css_test_outline.js +2 -2
- package/dist/_esm5.processed/parsers/texttracks/ttml/html/parse_cue.d.ts +1 -1
- package/dist/_esm5.processed/parsers/texttracks/ttml/html/parse_cue.js +5 -3
- package/dist/_esm5.processed/parsers/texttracks/ttml/html/parse_ttml_to_div.d.ts +1 -1
- package/dist/_esm5.processed/parsers/texttracks/ttml/html/ttml_color_to_css_color.js +34 -19
- package/dist/_esm5.processed/parsers/texttracks/ttml/native/parse_cue.d.ts +2 -2
- package/dist/_esm5.processed/parsers/texttracks/ttml/native/parse_cue.js +9 -10
- package/dist/_esm5.processed/parsers/texttracks/ttml/native/parse_ttml_to_vtt.d.ts +1 -1
- package/dist/_esm5.processed/parsers/texttracks/ttml/parse_ttml.d.ts +3 -3
- package/dist/_esm5.processed/parsers/texttracks/ttml/parse_ttml.js +28 -16
- package/dist/_esm5.processed/parsers/texttracks/ttml/resolve_styles_inheritance.d.ts +1 -1
- package/dist/_esm5.processed/parsers/texttracks/ttml/time_parsing.d.ts +1 -1
- package/dist/_esm5.processed/parsers/texttracks/ttml/time_parsing.js +2 -2
- package/dist/_esm5.processed/parsers/texttracks/types.d.ts +1 -1
- package/dist/_esm5.processed/parsers/texttracks/webvtt/get_cue_blocks.js +1 -1
- package/dist/_esm5.processed/parsers/texttracks/webvtt/get_style_blocks.js +2 -1
- package/dist/_esm5.processed/parsers/texttracks/webvtt/html/convert_payload_to_html.d.ts +1 -1
- package/dist/_esm5.processed/parsers/texttracks/webvtt/html/create_default_style_elements.d.ts +1 -1
- package/dist/_esm5.processed/parsers/texttracks/webvtt/html/create_style_attribute.js +6 -12
- package/dist/_esm5.processed/parsers/texttracks/webvtt/html/create_styled_element.d.ts +1 -1
- package/dist/_esm5.processed/parsers/texttracks/webvtt/html/create_styled_element.js +7 -8
- package/dist/_esm5.processed/parsers/texttracks/webvtt/html/index.d.ts +1 -1
- package/dist/_esm5.processed/parsers/texttracks/webvtt/html/parse_style_block.js +4 -4
- package/dist/_esm5.processed/parsers/texttracks/webvtt/html/parse_webvtt_to_div.d.ts +1 -1
- package/dist/_esm5.processed/parsers/texttracks/webvtt/html/to_html.d.ts +1 -1
- package/dist/_esm5.processed/parsers/texttracks/webvtt/html/to_html.js +4 -10
- package/dist/_esm5.processed/parsers/texttracks/webvtt/native/parse_vtt_to_cues.d.ts +1 -1
- package/dist/_esm5.processed/parsers/texttracks/webvtt/native/parse_vtt_to_cues.js +2 -6
- package/dist/_esm5.processed/parsers/texttracks/webvtt/native/set_settings_on_cue.d.ts +1 -1
- package/dist/_esm5.processed/parsers/texttracks/webvtt/native/to_native_cue.d.ts +1 -1
- package/dist/_esm5.processed/parsers/texttracks/webvtt/native/to_native_cue.js +1 -1
- package/dist/_esm5.processed/parsers/texttracks/webvtt/parse_cue_block.js +2 -4
- package/dist/_esm5.processed/parsers/texttracks/webvtt/parse_timestamp.js +1 -2
- package/dist/_esm5.processed/parsers/texttracks/webvtt/utils.js +6 -6
- package/dist/_esm5.processed/public_types.d.ts +13 -11
- package/dist/_esm5.processed/tools/TextTrackRenderer/index.d.ts +3 -2
- package/dist/_esm5.processed/tools/TextTrackRenderer/text_track_renderer.d.ts +2 -2
- package/dist/_esm5.processed/tools/TextTrackRenderer/text_track_renderer.js +15 -10
- package/dist/_esm5.processed/transports/dash/add_segment_integrity_checks_to_loader.d.ts +1 -1
- package/dist/_esm5.processed/transports/dash/add_segment_integrity_checks_to_loader.js +2 -3
- package/dist/_esm5.processed/transports/dash/construct_segment_url.d.ts +2 -2
- package/dist/_esm5.processed/transports/dash/construct_segment_url.js +5 -3
- package/dist/_esm5.processed/transports/dash/extract_complete_chunks.js +2 -2
- package/dist/_esm5.processed/transports/dash/get_events_out_of_emsgs.d.ts +2 -2
- package/dist/_esm5.processed/transports/dash/get_events_out_of_emsgs.js +9 -10
- package/dist/_esm5.processed/transports/dash/image_pipelines.d.ts +3 -3
- package/dist/_esm5.processed/transports/dash/image_pipelines.js +32 -19
- package/dist/_esm5.processed/transports/dash/init_segment_loader.d.ts +3 -3
- package/dist/_esm5.processed/transports/dash/init_segment_loader.js +46 -22
- package/dist/_esm5.processed/transports/dash/low_latency_segment_loader.d.ts +2 -2
- package/dist/_esm5.processed/transports/dash/low_latency_segment_loader.js +13 -9
- package/dist/_esm5.processed/transports/dash/manifest_parser.d.ts +2 -2
- package/dist/_esm5.processed/transports/dash/manifest_parser.js +35 -22
- package/dist/_esm5.processed/transports/dash/pipelines.d.ts +1 -1
- package/dist/_esm5.processed/transports/dash/pipelines.js +11 -15
- package/dist/_esm5.processed/transports/dash/segment_loader.d.ts +4 -4
- package/dist/_esm5.processed/transports/dash/segment_loader.js +30 -21
- package/dist/_esm5.processed/transports/dash/segment_parser.d.ts +2 -2
- package/dist/_esm5.processed/transports/dash/segment_parser.js +47 -21
- package/dist/_esm5.processed/transports/dash/text_loader.d.ts +2 -2
- package/dist/_esm5.processed/transports/dash/text_loader.js +19 -19
- package/dist/_esm5.processed/transports/dash/text_parser.d.ts +2 -2
- package/dist/_esm5.processed/transports/dash/text_parser.js +45 -24
- package/dist/_esm5.processed/transports/local/pipelines.d.ts +1 -1
- package/dist/_esm5.processed/transports/local/pipelines.js +7 -8
- package/dist/_esm5.processed/transports/local/segment_loader.d.ts +3 -3
- package/dist/_esm5.processed/transports/local/segment_loader.js +14 -6
- package/dist/_esm5.processed/transports/local/segment_parser.d.ts +1 -1
- package/dist/_esm5.processed/transports/local/segment_parser.js +31 -13
- package/dist/_esm5.processed/transports/local/text_parser.d.ts +1 -1
- package/dist/_esm5.processed/transports/local/text_parser.js +44 -19
- package/dist/_esm5.processed/transports/metaplaylist/manifest_loader.d.ts +4 -4
- package/dist/_esm5.processed/transports/metaplaylist/manifest_loader.js +9 -5
- package/dist/_esm5.processed/transports/metaplaylist/pipelines.d.ts +1 -1
- package/dist/_esm5.processed/transports/metaplaylist/pipelines.js +25 -18
- package/dist/_esm5.processed/transports/smooth/extract_timings_infos.d.ts +2 -2
- package/dist/_esm5.processed/transports/smooth/extract_timings_infos.js +16 -15
- package/dist/_esm5.processed/transports/smooth/isobmff/create_audio_init_segment.js +3 -3
- package/dist/_esm5.processed/transports/smooth/isobmff/create_boxes.js +14 -32
- package/dist/_esm5.processed/transports/smooth/isobmff/create_init_segment.js +2 -2
- package/dist/_esm5.processed/transports/smooth/isobmff/create_traf_box.js +2 -2
- package/dist/_esm5.processed/transports/smooth/isobmff/get_aaces_header.js +4 -16
- package/dist/_esm5.processed/transports/smooth/isobmff/index.d.ts +4 -2
- package/dist/_esm5.processed/transports/smooth/isobmff/parse_tfrf.js +2 -2
- package/dist/_esm5.processed/transports/smooth/isobmff/parse_tfxd.js +1 -1
- package/dist/_esm5.processed/transports/smooth/isobmff/patch_segment.js +11 -10
- package/dist/_esm5.processed/transports/smooth/pipelines.d.ts +1 -1
- package/dist/_esm5.processed/transports/smooth/pipelines.js +121 -79
- package/dist/_esm5.processed/transports/smooth/segment_loader.d.ts +3 -3
- package/dist/_esm5.processed/transports/smooth/segment_loader.js +53 -27
- package/dist/_esm5.processed/transports/smooth/utils.d.ts +2 -2
- package/dist/_esm5.processed/transports/smooth/utils.js +7 -5
- package/dist/_esm5.processed/transports/types.d.ts +11 -25
- package/dist/_esm5.processed/transports/utils/byte_range.js +1 -2
- package/dist/_esm5.processed/transports/utils/call_custom_manifest_loader.d.ts +3 -3
- package/dist/_esm5.processed/transports/utils/call_custom_manifest_loader.js +13 -7
- package/dist/_esm5.processed/transports/utils/check_isobmff_integrity.js +3 -3
- package/dist/_esm5.processed/transports/utils/find_complete_box.js +3 -2
- package/dist/_esm5.processed/transports/utils/generate_manifest_loader.d.ts +3 -3
- package/dist/_esm5.processed/transports/utils/generate_manifest_loader.js +18 -6
- package/dist/_esm5.processed/transports/utils/get_isobmff_timing_infos.d.ts +2 -2
- package/dist/_esm5.processed/transports/utils/get_isobmff_timing_infos.js +12 -11
- package/dist/_esm5.processed/transports/utils/infer_segment_container.d.ts +1 -1
- package/dist/_esm5.processed/transports/utils/infer_segment_container.js +1 -3
- package/dist/_esm5.processed/transports/utils/parse_text_track.d.ts +4 -4
- package/dist/_esm5.processed/transports/utils/parse_text_track.js +9 -6
- package/dist/_esm5.processed/utils/are_codecs_compatible.js +5 -1
- package/dist/_esm5.processed/utils/array_includes.js +2 -6
- package/dist/_esm5.processed/utils/assert.js +3 -4
- package/dist/_esm5.processed/utils/base64.js +87 -29
- package/dist/_esm5.processed/utils/byte_parsing.js +60 -56
- package/dist/_esm5.processed/utils/cancellable_sleep.d.ts +1 -1
- package/dist/_esm5.processed/utils/create_cancellable_promise.d.ts +1 -1
- package/dist/_esm5.processed/utils/deep_merge.js +4 -4
- package/dist/_esm5.processed/utils/event_emitter.d.ts +1 -1
- package/dist/_esm5.processed/utils/get_fuzzed_delay.js +1 -1
- package/dist/_esm5.processed/utils/hash_buffer.js +1 -1
- package/dist/_esm5.processed/utils/initialization_segment_cache.d.ts +2 -2
- package/dist/_esm5.processed/utils/languages/index.d.ts +4 -2
- package/dist/_esm5.processed/utils/languages/index.js +2 -2
- package/dist/_esm5.processed/utils/languages/normalize.d.ts +2 -1
- package/dist/_esm5.processed/utils/languages/normalize.js +5 -3
- package/dist/_esm5.processed/utils/logger.js +7 -14
- package/dist/_esm5.processed/utils/object_assign.js +5 -5
- package/dist/_esm5.processed/utils/object_values.d.ts +1 -1
- package/dist/_esm5.processed/utils/object_values.js +2 -3
- package/dist/_esm5.processed/utils/ranges.d.ts +2 -1
- package/dist/_esm5.processed/utils/ranges.js +19 -23
- package/dist/_esm5.processed/utils/reference.d.ts +3 -3
- package/dist/_esm5.processed/utils/reference.js +1 -3
- package/dist/_esm5.processed/utils/request/fetch.d.ts +1 -1
- package/dist/_esm5.processed/utils/request/fetch.js +34 -23
- package/dist/_esm5.processed/utils/request/index.d.ts +6 -3
- package/dist/_esm5.processed/utils/request/index.js +2 -2
- package/dist/_esm5.processed/utils/request/xhr.d.ts +1 -1
- package/dist/_esm5.processed/utils/request/xhr.js +28 -17
- package/dist/_esm5.processed/utils/retry_promise_with_backoff.d.ts +2 -2
- package/dist/_esm5.processed/utils/slice_uint8array.js +3 -3
- package/dist/_esm5.processed/utils/starts_with.js +3 -3
- package/dist/_esm5.processed/utils/string_parsing.js +16 -18
- package/dist/_esm5.processed/utils/task_canceller.js +1 -2
- package/dist/_esm5.processed/utils/uniq.d.ts +1 -1
- package/dist/_esm5.processed/utils/uniq.js +4 -3
- package/dist/_esm5.processed/utils/weak_map_memory.js +0 -1
- package/dist/_esm5.processed/utils/wrapInPromise.d.ts +1 -1
- package/dist/mpd-parser.wasm +0 -0
- package/dist/rx-player.js +345 -236
- package/dist/rx-player.min.js +1 -1
- package/experimental/features/index.d.ts-E +16 -0
- package/experimental/features/index.js-E +16 -0
- package/experimental/index.d.ts +1 -1
- package/experimental/index.d.ts-E +16 -0
- package/experimental/index.js +1 -1
- package/experimental/index.js-E +16 -0
- package/experimental/tools/VideoThumbnailLoader/index.d.ts-E +18 -0
- package/experimental/tools/VideoThumbnailLoader/index.js-E +18 -0
- package/experimental/tools/index.d.ts-E +16 -0
- package/experimental/tools/index.js-E +16 -0
- package/features/index.d.ts-E +16 -0
- package/features/index.js-E +16 -0
- package/logger/index.d.ts-E +17 -0
- package/logger/index.js-E +17 -0
- package/minimal/index.d.ts-E +17 -0
- package/minimal/index.js-E +17 -0
- package/package.json +29 -14
- package/tools/TextTrackRenderer.d.ts-E +18 -0
- package/tools/TextTrackRenderer.js-E +18 -0
- package/tools/index.d.ts-E +16 -0
- package/tools/index.js-E +16 -0
- package/tools/string-utils.d.ts-E +18 -0
- package/tools/string-utils.js-E +18 -0
- package/types/index.d.ts-E +16 -0
- package/types/index.js-E +15 -0
|
@@ -48,16 +48,15 @@ export default function parseMpdIr(mpdIR, args, warnings, hasLoadedClock, xlinkI
|
|
|
48
48
|
if (args.externalClockOffset == null) {
|
|
49
49
|
var isDynamic = rootAttributes.type === "dynamic";
|
|
50
50
|
var directTiming = arrayFind(rootChildren.utcTimings, function (utcTiming) {
|
|
51
|
-
return utcTiming.schemeIdUri === "urn:mpeg:dash:utc:direct:2014" &&
|
|
52
|
-
utcTiming.value != null;
|
|
51
|
+
return (utcTiming.schemeIdUri === "urn:mpeg:dash:utc:direct:2014" &&
|
|
52
|
+
utcTiming.value != null);
|
|
53
53
|
});
|
|
54
|
-
var clockOffsetFromDirectUTCTiming = directTiming != null &&
|
|
55
|
-
|
|
56
|
-
undefined;
|
|
57
|
-
var clockOffset = clockOffsetFromDirectUTCTiming != null &&
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
undefined;
|
|
54
|
+
var clockOffsetFromDirectUTCTiming = directTiming != null && directTiming.value != null
|
|
55
|
+
? getClockOffset(directTiming.value)
|
|
56
|
+
: undefined;
|
|
57
|
+
var clockOffset = clockOffsetFromDirectUTCTiming != null && !isNaN(clockOffsetFromDirectUTCTiming)
|
|
58
|
+
? clockOffsetFromDirectUTCTiming
|
|
59
|
+
: undefined;
|
|
61
60
|
if (clockOffset != null && hasLoadedClock !== true) {
|
|
62
61
|
args.externalClockOffset = clockOffset;
|
|
63
62
|
}
|
|
@@ -137,9 +136,9 @@ function parseCompleteIntermediateRepresentation(mpdIR, args, warnings, xlinkInf
|
|
|
137
136
|
var _a, _b, _c;
|
|
138
137
|
var rootChildren = mpdIR.children, rootAttributes = mpdIR.attributes;
|
|
139
138
|
var isDynamic = rootAttributes.type === "dynamic";
|
|
140
|
-
var initialBaseUrl = args.url !== undefined
|
|
141
|
-
[{ url: args.url.substring(0, getFilenameIndexInUrl(args.url)) }]
|
|
142
|
-
[];
|
|
139
|
+
var initialBaseUrl = args.url !== undefined
|
|
140
|
+
? [{ url: args.url.substring(0, getFilenameIndexInUrl(args.url)) }]
|
|
141
|
+
: [];
|
|
143
142
|
var mpdBaseUrls = resolveBaseURLs(initialBaseUrl, rootChildren.baseURLs);
|
|
144
143
|
var availabilityStartTime = parseAvailabilityStartTime(rootAttributes, args.referenceDateTime);
|
|
145
144
|
var timeShiftBufferDepth = rootAttributes.timeShiftBufferDepth;
|
|
@@ -152,8 +151,21 @@ function parseCompleteIntermediateRepresentation(mpdIR, args, warnings, xlinkInf
|
|
|
152
151
|
timeShiftBufferDepth: timeShiftBufferDepth,
|
|
153
152
|
serverTimestampOffset: externalClockOffset,
|
|
154
153
|
});
|
|
155
|
-
var manifestInfos = {
|
|
156
|
-
|
|
154
|
+
var manifestInfos = {
|
|
155
|
+
aggressiveMode: args.aggressiveMode,
|
|
156
|
+
availabilityStartTime: availabilityStartTime,
|
|
157
|
+
baseURLs: mpdBaseUrls,
|
|
158
|
+
clockOffset: clockOffset,
|
|
159
|
+
duration: rootAttributes.duration,
|
|
160
|
+
isDynamic: isDynamic,
|
|
161
|
+
manifestBoundsCalculator: manifestBoundsCalculator,
|
|
162
|
+
manifestProfiles: mpdIR.attributes.profiles,
|
|
163
|
+
receivedTime: args.manifestReceivedTime,
|
|
164
|
+
timeShiftBufferDepth: timeShiftBufferDepth,
|
|
165
|
+
unsafelyBaseOnPreviousManifest: unsafelyBaseOnPreviousManifest,
|
|
166
|
+
xlinkInfos: xlinkInfos,
|
|
167
|
+
xmlNamespaces: mpdIR.attributes.namespaces,
|
|
168
|
+
};
|
|
157
169
|
var parsedPeriods = parsePeriods(rootChildren.periods, manifestInfos);
|
|
158
170
|
var mediaPresentationDuration = rootAttributes.duration;
|
|
159
171
|
var lifetime;
|
|
@@ -162,22 +174,26 @@ function parseCompleteIntermediateRepresentation(mpdIR, args, warnings, xlinkInf
|
|
|
162
174
|
var maximumTimeData;
|
|
163
175
|
if (rootAttributes.minimumUpdatePeriod !== undefined &&
|
|
164
176
|
rootAttributes.minimumUpdatePeriod >= 0) {
|
|
165
|
-
lifetime =
|
|
166
|
-
|
|
167
|
-
|
|
177
|
+
lifetime =
|
|
178
|
+
rootAttributes.minimumUpdatePeriod === 0
|
|
179
|
+
? config.getCurrent().DASH_FALLBACK_LIFETIME_WHEN_MINIMUM_UPDATE_PERIOD_EQUAL_0
|
|
180
|
+
: rootAttributes.minimumUpdatePeriod;
|
|
168
181
|
}
|
|
169
182
|
var _d = getMinimumAndMaximumPositions(parsedPeriods), minimumSafePosition = _d.minimumSafePosition, maximumSafePosition = _d.maximumSafePosition, maximumUnsafePosition = _d.maximumUnsafePosition;
|
|
170
183
|
var now = performance.now();
|
|
171
184
|
if (!isDynamic) {
|
|
172
|
-
minimumTime =
|
|
173
|
-
|
|
174
|
-
|
|
185
|
+
minimumTime =
|
|
186
|
+
minimumSafePosition !== undefined
|
|
187
|
+
? minimumSafePosition
|
|
188
|
+
: ((_a = parsedPeriods[0]) === null || _a === void 0 ? void 0 : _a.start) !== undefined
|
|
189
|
+
? parsedPeriods[0].start
|
|
190
|
+
: 0;
|
|
175
191
|
var finalMaximumSafePosition = mediaPresentationDuration !== null && mediaPresentationDuration !== void 0 ? mediaPresentationDuration : Infinity;
|
|
176
192
|
if (parsedPeriods[parsedPeriods.length - 1] !== undefined) {
|
|
177
193
|
var lastPeriod = parsedPeriods[parsedPeriods.length - 1];
|
|
178
|
-
var lastPeriodEnd = (_b = lastPeriod.end) !== null && _b !== void 0 ? _b : (lastPeriod.duration !== undefined
|
|
179
|
-
lastPeriod.start + lastPeriod.duration
|
|
180
|
-
undefined);
|
|
194
|
+
var lastPeriodEnd = (_b = lastPeriod.end) !== null && _b !== void 0 ? _b : (lastPeriod.duration !== undefined
|
|
195
|
+
? lastPeriod.start + lastPeriod.duration
|
|
196
|
+
: undefined);
|
|
181
197
|
if (lastPeriodEnd !== undefined && lastPeriodEnd < finalMaximumSafePosition) {
|
|
182
198
|
finalMaximumSafePosition = lastPeriodEnd;
|
|
183
199
|
}
|
|
@@ -186,10 +202,12 @@ function parseCompleteIntermediateRepresentation(mpdIR, args, warnings, xlinkInf
|
|
|
186
202
|
maximumSafePosition < finalMaximumSafePosition) {
|
|
187
203
|
finalMaximumSafePosition = maximumSafePosition;
|
|
188
204
|
}
|
|
189
|
-
maximumTimeData = {
|
|
205
|
+
maximumTimeData = {
|
|
206
|
+
isLinear: false,
|
|
190
207
|
maximumSafePosition: finalMaximumSafePosition,
|
|
191
208
|
livePosition: undefined,
|
|
192
|
-
time: now
|
|
209
|
+
time: now,
|
|
210
|
+
};
|
|
193
211
|
}
|
|
194
212
|
else {
|
|
195
213
|
// Determine the maximum seekable position
|
|
@@ -200,11 +218,11 @@ function parseCompleteIntermediateRepresentation(mpdIR, args, warnings, xlinkInf
|
|
|
200
218
|
else {
|
|
201
219
|
if (externalClockOffset === undefined) {
|
|
202
220
|
log.warn("DASH Parser: use system clock to define maximum position");
|
|
203
|
-
finalMaximumSafePosition =
|
|
221
|
+
finalMaximumSafePosition = Date.now() / 1000 - availabilityStartTime;
|
|
204
222
|
}
|
|
205
223
|
else {
|
|
206
224
|
var serverTime = performance.now() + externalClockOffset;
|
|
207
|
-
finalMaximumSafePosition =
|
|
225
|
+
finalMaximumSafePosition = serverTime / 1000 - availabilityStartTime;
|
|
208
226
|
}
|
|
209
227
|
}
|
|
210
228
|
// Determine live edge (what position corresponds to live content, can be
|
|
@@ -220,8 +238,12 @@ function parseCompleteIntermediateRepresentation(mpdIR, args, warnings, xlinkInf
|
|
|
220
238
|
}
|
|
221
239
|
// manifestBoundsCalculator.forceLiveEdge(livePosition);
|
|
222
240
|
}
|
|
223
|
-
maximumTimeData = {
|
|
224
|
-
|
|
241
|
+
maximumTimeData = {
|
|
242
|
+
isLinear: true,
|
|
243
|
+
maximumSafePosition: finalMaximumSafePosition,
|
|
244
|
+
livePosition: livePosition,
|
|
245
|
+
time: now,
|
|
246
|
+
};
|
|
225
247
|
// if the minimum calculated time is even below the buffer depth, perhaps we
|
|
226
248
|
// can go even lower in terms of depth
|
|
227
249
|
minimumTime = minimumSafePosition;
|
|
@@ -269,8 +291,7 @@ function parseCompleteIntermediateRepresentation(mpdIR, args, warnings, xlinkInf
|
|
|
269
291
|
transportType: "dash",
|
|
270
292
|
timeBounds: { minimumSafePosition: minimumTime, timeshiftDepth: timeshiftDepth, maximumTimeData: maximumTimeData },
|
|
271
293
|
lifetime: lifetime,
|
|
272
|
-
uris: args.url == null ?
|
|
273
|
-
rootChildren.locations : __spreadArray([args.url], rootChildren.locations, true),
|
|
294
|
+
uris: args.url == null ? rootChildren.locations : __spreadArray([args.url], rootChildren.locations, true),
|
|
274
295
|
};
|
|
275
296
|
return { type: "done", value: { parsed: parsedMPD, warnings: warnings } };
|
|
276
297
|
}
|
|
@@ -13,10 +13,10 @@
|
|
|
13
13
|
* See the License for the specific language governing permissions and
|
|
14
14
|
* limitations under the License.
|
|
15
15
|
*/
|
|
16
|
-
import Manifest from "../../../../manifest";
|
|
17
|
-
import { IParsedPeriod } from "../../types";
|
|
18
|
-
import { IPeriodIntermediateRepresentation } from "../node_parser_types";
|
|
19
|
-
import { IAdaptationSetContext } from "./parse_adaptation_sets";
|
|
16
|
+
import type Manifest from "../../../../manifest";
|
|
17
|
+
import type { IParsedPeriod } from "../../types";
|
|
18
|
+
import type { IPeriodIntermediateRepresentation } from "../node_parser_types";
|
|
19
|
+
import type { IAdaptationSetContext } from "./parse_adaptation_sets";
|
|
20
20
|
/** Information about each linked Xlink. */
|
|
21
21
|
export type IXLinkInfos = WeakMap<IPeriodIntermediateRepresentation, {
|
|
22
22
|
/** Real URL (post-redirection) used to download this xlink. */
|
|
@@ -60,23 +60,37 @@ export default function parsePeriods(periodsIR, context) {
|
|
|
60
60
|
while (parsedPeriods.some(function (p) { return p.id === periodID; })) {
|
|
61
61
|
periodID += "-dup";
|
|
62
62
|
}
|
|
63
|
-
var receivedTime = xlinkInfos !== undefined ? xlinkInfos.receivedTime :
|
|
64
|
-
|
|
65
|
-
var unsafelyBaseOnPreviousPeriod = (_b = (_a = context
|
|
66
|
-
.unsafelyBaseOnPreviousManifest) === null || _a === void 0 ? void 0 : _a.getPeriod(periodID)) !== null && _b !== void 0 ? _b : null;
|
|
63
|
+
var receivedTime = xlinkInfos !== undefined ? xlinkInfos.receivedTime : context.receivedTime;
|
|
64
|
+
var unsafelyBaseOnPreviousPeriod = (_b = (_a = context.unsafelyBaseOnPreviousManifest) === null || _a === void 0 ? void 0 : _a.getPeriod(periodID)) !== null && _b !== void 0 ? _b : null;
|
|
67
65
|
var availabilityTimeComplete = periodIR.attributes.availabilityTimeComplete;
|
|
68
66
|
var availabilityTimeOffset = periodIR.attributes.availabilityTimeOffset;
|
|
69
67
|
var manifestProfiles = context.manifestProfiles;
|
|
70
68
|
var segmentTemplate = periodIR.children.segmentTemplate;
|
|
71
|
-
var adapCtxt = {
|
|
69
|
+
var adapCtxt = {
|
|
70
|
+
availabilityTimeComplete: availabilityTimeComplete,
|
|
71
|
+
availabilityTimeOffset: availabilityTimeOffset,
|
|
72
|
+
baseURLs: periodBaseURLs,
|
|
73
|
+
manifestBoundsCalculator: manifestBoundsCalculator,
|
|
74
|
+
end: periodEnd,
|
|
75
|
+
isDynamic: isDynamic,
|
|
76
|
+
isLastPeriod: isLastPeriod,
|
|
77
|
+
manifestProfiles: manifestProfiles,
|
|
78
|
+
receivedTime: receivedTime,
|
|
79
|
+
segmentTemplate: segmentTemplate,
|
|
80
|
+
start: periodStart,
|
|
81
|
+
unsafelyBaseOnPreviousPeriod: unsafelyBaseOnPreviousPeriod,
|
|
82
|
+
};
|
|
72
83
|
var adaptations = parseAdaptationSets(periodIR.children.adaptations, adapCtxt);
|
|
73
|
-
var namespaces = ((_c = context.xmlNamespaces) !== null && _c !== void 0 ? _c : [])
|
|
74
|
-
.concat((_d = periodIR.attributes.namespaces) !== null && _d !== void 0 ? _d : []);
|
|
84
|
+
var namespaces = ((_c = context.xmlNamespaces) !== null && _c !== void 0 ? _c : []).concat((_d = periodIR.attributes.namespaces) !== null && _d !== void 0 ? _d : []);
|
|
75
85
|
var streamEvents = generateStreamEvents(periodIR.children.eventStreams, periodStart, namespaces);
|
|
76
|
-
var parsedPeriod = {
|
|
86
|
+
var parsedPeriod = {
|
|
87
|
+
id: periodID,
|
|
77
88
|
start: periodStart,
|
|
78
89
|
end: periodEnd,
|
|
79
|
-
duration: periodDuration,
|
|
90
|
+
duration: periodDuration,
|
|
91
|
+
adaptations: adaptations,
|
|
92
|
+
streamEvents: streamEvents,
|
|
93
|
+
};
|
|
80
94
|
parsedPeriods.unshift(parsedPeriod);
|
|
81
95
|
if (!manifestBoundsCalculator.lastPositionIsKnown()) {
|
|
82
96
|
var lastPosition = getMaximumLastPosition(adaptations);
|
|
@@ -144,8 +158,7 @@ export default function parsePeriods(periodsIR, context) {
|
|
|
144
158
|
*/
|
|
145
159
|
function guessLastPositionFromClock(context, minimumTime) {
|
|
146
160
|
if (!isNullOrUndefined(context.clockOffset)) {
|
|
147
|
-
var lastPosition = context.clockOffset / 1000 -
|
|
148
|
-
context.availabilityStartTime;
|
|
161
|
+
var lastPosition = context.clockOffset / 1000 - context.availabilityStartTime;
|
|
149
162
|
var positionTime = performance.now() / 1000;
|
|
150
163
|
var timeInSec = positionTime + lastPosition;
|
|
151
164
|
if (timeInSec >= minimumTime) {
|
|
@@ -177,8 +190,7 @@ function guessLastPositionFromClock(context, minimumTime) {
|
|
|
177
190
|
function getMaximumLastPosition(adaptationsPerType) {
|
|
178
191
|
var maxEncounteredPosition = null;
|
|
179
192
|
var allIndexAreEmpty = true;
|
|
180
|
-
var adaptationsVal = objectValues(adaptationsPerType)
|
|
181
|
-
.filter(function (ada) { return !isNullOrUndefined(ada); });
|
|
193
|
+
var adaptationsVal = objectValues(adaptationsPerType).filter(function (ada) { return !isNullOrUndefined(ada); });
|
|
182
194
|
var allAdaptations = flatMap(adaptationsVal, function (adaptationsForType) { return adaptationsForType; });
|
|
183
195
|
for (var _i = 0, allAdaptations_1 = allAdaptations; _i < allAdaptations_1.length; _i++) {
|
|
184
196
|
var adaptation = allAdaptations_1[_i];
|
|
@@ -189,9 +201,9 @@ function getMaximumLastPosition(adaptationsPerType) {
|
|
|
189
201
|
if (position !== null) {
|
|
190
202
|
allIndexAreEmpty = false;
|
|
191
203
|
if (typeof position === "number") {
|
|
192
|
-
maxEncounteredPosition =
|
|
193
|
-
|
|
194
|
-
|
|
204
|
+
maxEncounteredPosition = isNullOrUndefined(maxEncounteredPosition)
|
|
205
|
+
? position
|
|
206
|
+
: Math.max(maxEncounteredPosition, position);
|
|
195
207
|
}
|
|
196
208
|
}
|
|
197
209
|
}
|
|
@@ -219,15 +231,14 @@ function generateStreamEvents(baseIr, periodStart, xmlNamespaces) {
|
|
|
219
231
|
for (var _i = 0, baseIr_1 = baseIr; _i < baseIr_1.length; _i++) {
|
|
220
232
|
var eventStreamIr = baseIr_1[_i];
|
|
221
233
|
var _c = eventStreamIr.attributes, _d = _c.schemeIdUri, schemeIdUri = _d === void 0 ? "" : _d, _e = _c.timescale, timescale = _e === void 0 ? 1 : _e;
|
|
222
|
-
var allNamespaces = xmlNamespaces
|
|
223
|
-
.concat((_a = eventStreamIr.attributes.namespaces) !== null && _a !== void 0 ? _a : []);
|
|
234
|
+
var allNamespaces = xmlNamespaces.concat((_a = eventStreamIr.attributes.namespaces) !== null && _a !== void 0 ? _a : []);
|
|
224
235
|
for (var _f = 0, _g = eventStreamIr.children.events; _f < _g.length; _f++) {
|
|
225
236
|
var eventIr = _g[_f];
|
|
226
237
|
if (eventIr.eventStreamData !== undefined) {
|
|
227
|
-
var start = ((
|
|
228
|
-
var end = eventIr.duration === undefined
|
|
229
|
-
undefined
|
|
230
|
-
start +
|
|
238
|
+
var start = ((_b = eventIr.presentationTime) !== null && _b !== void 0 ? _b : 0) / timescale + periodStart;
|
|
239
|
+
var end = eventIr.duration === undefined
|
|
240
|
+
? undefined
|
|
241
|
+
: start + eventIr.duration / timescale;
|
|
231
242
|
var element = void 0;
|
|
232
243
|
if (eventIr.eventStreamData instanceof Element) {
|
|
233
244
|
element = eventIr.eventStreamData;
|
|
@@ -239,18 +250,18 @@ function generateStreamEvents(baseIr, periodStart, xmlNamespaces) {
|
|
|
239
250
|
// encountering unknown namespaced attributes or elements in the given
|
|
240
251
|
// `<Event>` xml subset.
|
|
241
252
|
var parentNode = allNamespaces.reduce(function (acc, ns) {
|
|
242
|
-
return acc + "xmlns:" + ns.key + "
|
|
253
|
+
return acc + "xmlns:" + ns.key + '="' + ns.value + '" ';
|
|
243
254
|
}, "<toremove ");
|
|
244
255
|
parentNode += ">";
|
|
245
256
|
var elementToString = utf8ToStr(new Uint8Array(eventIr.eventStreamData));
|
|
246
|
-
element = new DOMParser()
|
|
247
|
-
.parseFromString(parentNode + elementToString + "</toremove>", "application/xml")
|
|
248
|
-
.documentElement
|
|
249
|
-
.childNodes[0]; // unwrap from the `<toremove>` element
|
|
257
|
+
element = new DOMParser().parseFromString(parentNode + elementToString + "</toremove>", "application/xml").documentElement.childNodes[0]; // unwrap from the `<toremove>` element
|
|
250
258
|
}
|
|
251
|
-
res.push({
|
|
252
|
-
|
|
253
|
-
|
|
259
|
+
res.push({
|
|
260
|
+
start: start,
|
|
261
|
+
end: end,
|
|
262
|
+
id: eventIr.id,
|
|
263
|
+
data: { type: "dash-event-stream", value: { schemeIdUri: schemeIdUri, timescale: timescale, element: element } },
|
|
264
|
+
});
|
|
254
265
|
}
|
|
255
266
|
}
|
|
256
267
|
}
|
|
@@ -13,10 +13,10 @@
|
|
|
13
13
|
* See the License for the specific language governing permissions and
|
|
14
14
|
* limitations under the License.
|
|
15
15
|
*/
|
|
16
|
-
import { IRepresentationIndex, Representation } from "../../../../manifest";
|
|
17
|
-
import { IAdaptationSetIntermediateRepresentation, IRepresentationIntermediateRepresentation, ISegmentTemplateIntermediateRepresentation, IScheme } from "../node_parser_types";
|
|
18
|
-
import ManifestBoundsCalculator from "./manifest_bounds_calculator";
|
|
19
|
-
import { IResolvedBaseUrl } from "./resolve_base_urls";
|
|
16
|
+
import type { IRepresentationIndex, Representation } from "../../../../manifest";
|
|
17
|
+
import type { IAdaptationSetIntermediateRepresentation, IRepresentationIntermediateRepresentation, ISegmentTemplateIntermediateRepresentation, IScheme } from "../node_parser_types";
|
|
18
|
+
import type ManifestBoundsCalculator from "./manifest_bounds_calculator";
|
|
19
|
+
import type { IResolvedBaseUrl } from "./resolve_base_urls";
|
|
20
20
|
/**
|
|
21
21
|
* Parse the specific segment indexing information found in a representation
|
|
22
22
|
* into a IRepresentationIndex implementation.
|
|
@@ -38,8 +38,7 @@ export default function parseRepresentationIndex(representation, context) {
|
|
|
38
38
|
if (inbandEventStreams === undefined) {
|
|
39
39
|
return false;
|
|
40
40
|
}
|
|
41
|
-
return inbandEventStreams
|
|
42
|
-
.some(function (_a) {
|
|
41
|
+
return inbandEventStreams.some(function (_a) {
|
|
43
42
|
var schemeIdUri = _a.schemeIdUri;
|
|
44
43
|
return schemeIdUri === inbandEvent.schemeIdUri;
|
|
45
44
|
});
|
|
@@ -13,10 +13,10 @@
|
|
|
13
13
|
* See the License for the specific language governing permissions and
|
|
14
14
|
* limitations under the License.
|
|
15
15
|
*/
|
|
16
|
-
import { Adaptation } from "../../../../manifest";
|
|
17
|
-
import { IParsedRepresentation } from "../../types";
|
|
18
|
-
import { IAdaptationSetIntermediateRepresentation, IRepresentationIntermediateRepresentation } from "../node_parser_types";
|
|
19
|
-
import { IRepresentationIndexContext } from "./parse_representation_index";
|
|
16
|
+
import type { Adaptation } from "../../../../manifest";
|
|
17
|
+
import type { IParsedRepresentation } from "../../types";
|
|
18
|
+
import type { IAdaptationSetIntermediateRepresentation, IRepresentationIntermediateRepresentation } from "../node_parser_types";
|
|
19
|
+
import type { IRepresentationIndexContext } from "./parse_representation_index";
|
|
20
20
|
/**
|
|
21
21
|
* Process intermediate representations to create final parsed representations.
|
|
22
22
|
* @param {Array.<Object>} representationsIR
|
|
@@ -58,11 +58,8 @@ function getHDRInformation(_a) {
|
|
|
58
58
|
var adaptationProfiles = _a.adaptationProfiles, essentialProperties = _a.essentialProperties, supplementalProperties = _a.supplementalProperties, manifestProfiles = _a.manifestProfiles, codecs = _a.codecs;
|
|
59
59
|
var profiles = (adaptationProfiles !== null && adaptationProfiles !== void 0 ? adaptationProfiles : "") + (manifestProfiles !== null && manifestProfiles !== void 0 ? manifestProfiles : "");
|
|
60
60
|
if (profiles.indexOf("http://dashif.org/guidelines/dash-if-uhd#hevc-hdr-pq10") !== -1) {
|
|
61
|
-
if (codecs === "hvc1.2.4.L153.B0" ||
|
|
62
|
-
|
|
63
|
-
return { colorDepth: 10,
|
|
64
|
-
eotf: "pq",
|
|
65
|
-
colorSpace: "rec2020" };
|
|
61
|
+
if (codecs === "hvc1.2.4.L153.B0" || codecs === "hev1.2.4.L153.B0") {
|
|
62
|
+
return { colorDepth: 10, eotf: "pq", colorSpace: "rec2020" };
|
|
66
63
|
}
|
|
67
64
|
}
|
|
68
65
|
var transferCharacteristicScheme = arrayFind(__spreadArray(__spreadArray([], (essentialProperties !== null && essentialProperties !== void 0 ? essentialProperties : []), true), (supplementalProperties !== null && supplementalProperties !== void 0 ? supplementalProperties : []), true), function (p) { return p.schemeIdUri === "urn:mpeg:mpegB:cicp:TransferCharacteristics"; });
|
|
@@ -91,37 +88,43 @@ export default function parseRepresentations(representationsIR, adaptation, cont
|
|
|
91
88
|
var parsedRepresentations = [];
|
|
92
89
|
var _loop_1 = function (representation) {
|
|
93
90
|
// Compute Representation ID
|
|
94
|
-
var representationID = representation.attributes.id !== undefined
|
|
95
|
-
representation.attributes.id
|
|
96
|
-
|
|
97
|
-
(representation.attributes.height !== undefined
|
|
98
|
-
|
|
99
|
-
"") +
|
|
100
|
-
(representation.attributes.width !== undefined
|
|
101
|
-
|
|
102
|
-
"") +
|
|
103
|
-
(representation.attributes.mimeType !== undefined
|
|
104
|
-
|
|
105
|
-
"") +
|
|
106
|
-
(representation.attributes.codecs !== undefined
|
|
107
|
-
|
|
108
|
-
"")
|
|
91
|
+
var representationID = representation.attributes.id !== undefined
|
|
92
|
+
? representation.attributes.id
|
|
93
|
+
: String(representation.attributes.bitrate) +
|
|
94
|
+
(representation.attributes.height !== undefined
|
|
95
|
+
? "-".concat(representation.attributes.height)
|
|
96
|
+
: "") +
|
|
97
|
+
(representation.attributes.width !== undefined
|
|
98
|
+
? "-".concat(representation.attributes.width)
|
|
99
|
+
: "") +
|
|
100
|
+
(representation.attributes.mimeType !== undefined
|
|
101
|
+
? "-".concat(representation.attributes.mimeType)
|
|
102
|
+
: "") +
|
|
103
|
+
(representation.attributes.codecs !== undefined
|
|
104
|
+
? "-".concat(representation.attributes.codecs)
|
|
105
|
+
: "");
|
|
109
106
|
// Avoid duplicate IDs
|
|
110
107
|
while (parsedRepresentations.some(function (r) { return r.id === representationID; })) {
|
|
111
108
|
representationID += "-dup";
|
|
112
109
|
}
|
|
113
110
|
// Retrieve previous version of the Representation, if one.
|
|
114
|
-
var unsafelyBaseOnPreviousRepresentation = (_b = (_a = context
|
|
115
|
-
.unsafelyBaseOnPreviousAdaptation) === null || _a === void 0 ? void 0 : _a.getRepresentation(representationID)) !== null && _b !== void 0 ? _b : null;
|
|
111
|
+
var unsafelyBaseOnPreviousRepresentation = (_b = (_a = context.unsafelyBaseOnPreviousAdaptation) === null || _a === void 0 ? void 0 : _a.getRepresentation(representationID)) !== null && _b !== void 0 ? _b : null;
|
|
116
112
|
var inbandEventStreams = combineInbandEventStreams(representation, adaptation);
|
|
117
113
|
var availabilityTimeComplete = (_c = representation.attributes.availabilityTimeComplete) !== null && _c !== void 0 ? _c : context.availabilityTimeComplete;
|
|
118
114
|
var availabilityTimeOffset = void 0;
|
|
119
115
|
if (representation.attributes.availabilityTimeOffset !== undefined ||
|
|
120
116
|
context.availabilityTimeOffset !== undefined) {
|
|
121
|
-
availabilityTimeOffset =
|
|
122
|
-
((
|
|
117
|
+
availabilityTimeOffset =
|
|
118
|
+
((_d = representation.attributes.availabilityTimeOffset) !== null && _d !== void 0 ? _d : 0) +
|
|
119
|
+
((_e = context.availabilityTimeOffset) !== null && _e !== void 0 ? _e : 0);
|
|
123
120
|
}
|
|
124
|
-
var reprIndexCtxt = objectAssign({}, context, {
|
|
121
|
+
var reprIndexCtxt = objectAssign({}, context, {
|
|
122
|
+
availabilityTimeOffset: availabilityTimeOffset,
|
|
123
|
+
availabilityTimeComplete: availabilityTimeComplete,
|
|
124
|
+
unsafelyBaseOnPreviousRepresentation: unsafelyBaseOnPreviousRepresentation,
|
|
125
|
+
adaptation: adaptation,
|
|
126
|
+
inbandEventStreams: inbandEventStreams,
|
|
127
|
+
});
|
|
125
128
|
var representationIndex = parseRepresentationIndex(representation, reprIndexCtxt);
|
|
126
129
|
// Find bitrate
|
|
127
130
|
var representationBitrate = void 0;
|
|
@@ -133,16 +136,20 @@ export default function parseRepresentations(representationsIR, adaptation, cont
|
|
|
133
136
|
representationBitrate = representation.attributes.bitrate;
|
|
134
137
|
}
|
|
135
138
|
var representationBaseURLs = resolveBaseURLs(context.baseURLs, representation.children.baseURLs);
|
|
136
|
-
var cdnMetadata = representationBaseURLs.length === 0
|
|
137
|
-
// No BaseURL seems to be associated to this Representation, nor to the MPD,
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
representationBaseURLs.map(function (x) { return ({ baseUrl: x.url, id: x.serviceLocation }); });
|
|
139
|
+
var cdnMetadata = representationBaseURLs.length === 0
|
|
140
|
+
? // No BaseURL seems to be associated to this Representation, nor to the MPD,
|
|
141
|
+
// but underlying segments might have one. To indicate that segments should
|
|
142
|
+
// still be available through a CDN without giving any root CDN URL here,
|
|
143
|
+
// we just communicate about an empty `baseUrl`, as documented.
|
|
144
|
+
[{ baseUrl: "", id: undefined }]
|
|
145
|
+
: representationBaseURLs.map(function (x) { return ({ baseUrl: x.url, id: x.serviceLocation }); });
|
|
143
146
|
// Construct Representation Base
|
|
144
|
-
var parsedRepresentation = {
|
|
145
|
-
|
|
147
|
+
var parsedRepresentation = {
|
|
148
|
+
bitrate: representationBitrate,
|
|
149
|
+
cdnMetadata: cdnMetadata,
|
|
150
|
+
index: representationIndex,
|
|
151
|
+
id: representationID,
|
|
152
|
+
};
|
|
146
153
|
if (representation.children.supplementalProperties !== undefined &&
|
|
147
154
|
arrayFind(representation.children.supplementalProperties, function (r) {
|
|
148
155
|
return r.schemeIdUri === "tag:dolby.com,2018:dash:EC3_ExtensionType:2018" &&
|
|
@@ -174,51 +181,43 @@ export default function parseRepresentations(representationsIR, adaptation, cont
|
|
|
174
181
|
convertSupplementalCodecsToRFC6381(supplementalCodecs);
|
|
175
182
|
}
|
|
176
183
|
if (representation.attributes.frameRate !== undefined) {
|
|
177
|
-
parsedRepresentation.frameRate =
|
|
178
|
-
representation.attributes.frameRate;
|
|
184
|
+
parsedRepresentation.frameRate = representation.attributes.frameRate;
|
|
179
185
|
}
|
|
180
186
|
else if (adaptation.attributes.frameRate !== undefined) {
|
|
181
|
-
parsedRepresentation.frameRate =
|
|
182
|
-
adaptation.attributes.frameRate;
|
|
187
|
+
parsedRepresentation.frameRate = adaptation.attributes.frameRate;
|
|
183
188
|
}
|
|
184
189
|
if (representation.attributes.height !== undefined) {
|
|
185
|
-
parsedRepresentation.height =
|
|
186
|
-
representation.attributes.height;
|
|
190
|
+
parsedRepresentation.height = representation.attributes.height;
|
|
187
191
|
}
|
|
188
192
|
else if (adaptation.attributes.height !== undefined) {
|
|
189
|
-
parsedRepresentation.height =
|
|
190
|
-
adaptation.attributes.height;
|
|
193
|
+
parsedRepresentation.height = adaptation.attributes.height;
|
|
191
194
|
}
|
|
192
195
|
if (representation.attributes.mimeType !== undefined) {
|
|
193
|
-
parsedRepresentation.mimeType =
|
|
194
|
-
representation.attributes.mimeType;
|
|
196
|
+
parsedRepresentation.mimeType = representation.attributes.mimeType;
|
|
195
197
|
}
|
|
196
198
|
else if (adaptation.attributes.mimeType !== undefined) {
|
|
197
|
-
parsedRepresentation.mimeType =
|
|
198
|
-
adaptation.attributes.mimeType;
|
|
199
|
+
parsedRepresentation.mimeType = adaptation.attributes.mimeType;
|
|
199
200
|
}
|
|
200
201
|
if (representation.attributes.width !== undefined) {
|
|
201
|
-
parsedRepresentation.width =
|
|
202
|
-
representation.attributes.width;
|
|
202
|
+
parsedRepresentation.width = representation.attributes.width;
|
|
203
203
|
}
|
|
204
204
|
else if (adaptation.attributes.width !== undefined) {
|
|
205
|
-
parsedRepresentation.width =
|
|
206
|
-
adaptation.attributes.width;
|
|
205
|
+
parsedRepresentation.width = adaptation.attributes.width;
|
|
207
206
|
}
|
|
208
|
-
var contentProtectionsIr = adaptation.children.contentProtections !== undefined
|
|
209
|
-
adaptation.children.contentProtections
|
|
210
|
-
[];
|
|
207
|
+
var contentProtectionsIr = adaptation.children.contentProtections !== undefined
|
|
208
|
+
? adaptation.children.contentProtections
|
|
209
|
+
: [];
|
|
211
210
|
if (representation.children.contentProtections !== undefined) {
|
|
212
211
|
contentProtectionsIr.push.apply(contentProtectionsIr, representation.children.contentProtections);
|
|
213
212
|
}
|
|
214
213
|
if (contentProtectionsIr.length > 0) {
|
|
215
|
-
var contentProtections = contentProtectionsIr
|
|
216
|
-
.reduce(function (acc, cp) {
|
|
214
|
+
var contentProtections = contentProtectionsIr.reduce(function (acc, cp) {
|
|
217
215
|
var _a;
|
|
218
216
|
var systemId;
|
|
219
217
|
if (cp.attributes.schemeIdUri !== undefined &&
|
|
220
218
|
cp.attributes.schemeIdUri.substring(0, 9) === "urn:uuid:") {
|
|
221
|
-
systemId = cp.attributes.schemeIdUri
|
|
219
|
+
systemId = cp.attributes.schemeIdUri
|
|
220
|
+
.substring(9)
|
|
222
221
|
.replace(/-/g, "")
|
|
223
222
|
.toLowerCase();
|
|
224
223
|
}
|
|
@@ -251,17 +250,17 @@ export default function parseRepresentations(representationsIR, adaptation, cont
|
|
|
251
250
|
return acc;
|
|
252
251
|
}, { keyIds: undefined, initData: [] });
|
|
253
252
|
if (Object.keys(contentProtections.initData).length > 0 ||
|
|
254
|
-
(contentProtections.keyIds !== undefined &&
|
|
255
|
-
contentProtections.keyIds.length > 0)) {
|
|
253
|
+
(contentProtections.keyIds !== undefined && contentProtections.keyIds.length > 0)) {
|
|
256
254
|
parsedRepresentation.contentProtections = contentProtections;
|
|
257
255
|
}
|
|
258
256
|
}
|
|
259
|
-
parsedRepresentation.hdrInfo =
|
|
260
|
-
|
|
261
|
-
|
|
262
|
-
|
|
263
|
-
|
|
264
|
-
|
|
257
|
+
parsedRepresentation.hdrInfo = getHDRInformation({
|
|
258
|
+
adaptationProfiles: adaptation.attributes.profiles,
|
|
259
|
+
supplementalProperties: adaptation.children.supplementalProperties,
|
|
260
|
+
essentialProperties: adaptation.children.essentialProperties,
|
|
261
|
+
manifestProfiles: context.manifestProfiles,
|
|
262
|
+
codecs: codecs,
|
|
263
|
+
});
|
|
265
264
|
parsedRepresentations.push(parsedRepresentation);
|
|
266
265
|
};
|
|
267
266
|
for (var _i = 0, representationsIR_1 = representationsIR; _i < representationsIR_1.length; _i++) {
|
|
@@ -13,7 +13,7 @@
|
|
|
13
13
|
* See the License for the specific language governing permissions and
|
|
14
14
|
* limitations under the License.
|
|
15
15
|
*/
|
|
16
|
-
import { IBaseUrlIntermediateRepresentation } from "../node_parser_types";
|
|
16
|
+
import type { IBaseUrlIntermediateRepresentation } from "../node_parser_types";
|
|
17
17
|
export interface IResolvedBaseUrl {
|
|
18
18
|
url: string;
|
|
19
19
|
serviceLocation?: string | undefined;
|
|
@@ -36,8 +36,10 @@ export default function resolveBaseURLs(currentBaseURLs, newBaseUrlsIR) {
|
|
|
36
36
|
for (var j = 0; j < newBaseUrls.length; j++) {
|
|
37
37
|
var newBaseUrl = newBaseUrls[j];
|
|
38
38
|
var newUrl = resolveURL(curBaseUrl.url, newBaseUrl.url);
|
|
39
|
-
result.push({
|
|
40
|
-
|
|
39
|
+
result.push({
|
|
40
|
+
url: newUrl,
|
|
41
|
+
serviceLocation: (_a = newBaseUrl.serviceLocation) !== null && _a !== void 0 ? _a : curBaseUrl.serviceLocation,
|
|
42
|
+
});
|
|
41
43
|
}
|
|
42
44
|
}
|
|
43
45
|
return result;
|
package/dist/_esm5.processed/parsers/manifest/dash/js-parser/node_parsers/AdaptationSet.d.ts
CHANGED
|
@@ -13,7 +13,7 @@
|
|
|
13
13
|
* See the License for the specific language governing permissions and
|
|
14
14
|
* limitations under the License.
|
|
15
15
|
*/
|
|
16
|
-
import { IAdaptationSetIntermediateRepresentation } from "../../node_parser_types";
|
|
16
|
+
import type { IAdaptationSetIntermediateRepresentation } from "../../node_parser_types";
|
|
17
17
|
/**
|
|
18
18
|
* Parse an AdaptationSet element into an AdaptationSet intermediate
|
|
19
19
|
* representation.
|