rx-player 4.0.0-dev.2023121900 → 4.0.0-dev.2024022000

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.
Files changed (4171) hide show
  1. package/.prettierrc +4 -0
  2. package/CHANGELOG.md +1736 -1145
  3. package/MAINTAINERS.md +9 -12
  4. package/README.md +107 -122
  5. package/VERSION +1 -1
  6. package/dist/commonjs/__GENERATED_CODE/embedded_dash_wasm.d.ts +3 -0
  7. package/dist/commonjs/__GENERATED_CODE/embedded_dash_wasm.js +6 -0
  8. package/dist/commonjs/__GENERATED_CODE/embedded_worker.d.ts +3 -0
  9. package/dist/commonjs/__GENERATED_CODE/embedded_worker.js +6 -0
  10. package/dist/commonjs/__GENERATED_CODE/index.d.ts +2 -0
  11. package/dist/commonjs/__GENERATED_CODE/index.js +7 -0
  12. package/dist/commonjs/compat/add_class_name.js +4 -3
  13. package/dist/commonjs/compat/add_text_track.d.ts +1 -1
  14. package/dist/commonjs/compat/add_text_track.js +3 -2
  15. package/dist/commonjs/compat/browser_compatibility_types.js +14 -8
  16. package/dist/commonjs/compat/browser_detection.d.ts +3 -1
  17. package/dist/commonjs/compat/browser_detection.js +29 -10
  18. package/dist/commonjs/compat/change_source_buffer_type.d.ts +1 -1
  19. package/dist/commonjs/compat/eme/close_session.d.ts +1 -1
  20. package/dist/commonjs/compat/eme/close_session.js +16 -12
  21. package/dist/commonjs/compat/eme/custom_key_system_access.d.ts +1 -1
  22. package/dist/commonjs/compat/eme/custom_media_keys/ie11_media_keys.d.ts +1 -1
  23. package/dist/commonjs/compat/eme/custom_media_keys/ie11_media_keys.js +14 -9
  24. package/dist/commonjs/compat/eme/custom_media_keys/moz_media_keys_constructor.d.ts +1 -1
  25. package/dist/commonjs/compat/eme/custom_media_keys/moz_media_keys_constructor.js +1 -1
  26. package/dist/commonjs/compat/eme/custom_media_keys/ms_media_keys_constructor.js +1 -1
  27. package/dist/commonjs/compat/eme/custom_media_keys/old_webkit_media_keys.d.ts +2 -2
  28. package/dist/commonjs/compat/eme/custom_media_keys/old_webkit_media_keys.js +13 -12
  29. package/dist/commonjs/compat/eme/custom_media_keys/types.d.ts +1 -1
  30. package/dist/commonjs/compat/eme/custom_media_keys/webkit_media_keys.d.ts +1 -1
  31. package/dist/commonjs/compat/eme/custom_media_keys/webkit_media_keys.js +5 -11
  32. package/dist/commonjs/compat/eme/custom_media_keys/webkit_media_keys_constructor.d.ts +1 -1
  33. package/dist/commonjs/compat/eme/custom_media_keys/webkit_media_keys_constructor.js +3 -3
  34. package/dist/commonjs/compat/eme/eme-api-implementation.d.ts +3 -3
  35. package/dist/commonjs/compat/eme/eme-api-implementation.js +17 -12
  36. package/dist/commonjs/compat/eme/generate_key_request.d.ts +1 -1
  37. package/dist/commonjs/compat/eme/generate_key_request.js +16 -19
  38. package/dist/commonjs/compat/eme/get_init_data.js +5 -7
  39. package/dist/commonjs/compat/eme/get_uuid_kid_from_keystatus_kid.js +1 -2
  40. package/dist/commonjs/compat/eme/get_webkit_fairplay_initdata.js +10 -11
  41. package/dist/commonjs/compat/eme/load_session.d.ts +1 -1
  42. package/dist/commonjs/compat/enable_audio_track.d.ts +1 -1
  43. package/dist/commonjs/compat/event_listeners.d.ts +4 -4
  44. package/dist/commonjs/compat/event_listeners.js +43 -34
  45. package/dist/commonjs/compat/has_mse_in_worker.d.ts +2 -0
  46. package/dist/commonjs/compat/has_mse_in_worker.js +6 -0
  47. package/dist/commonjs/compat/has_webassembly.d.ts +6 -0
  48. package/dist/commonjs/compat/has_webassembly.js +8 -0
  49. package/dist/commonjs/compat/is_codec_supported.js +7 -1
  50. package/dist/commonjs/compat/is_vtt_cue.d.ts +1 -1
  51. package/dist/commonjs/compat/is_vtt_cue.js +1 -1
  52. package/dist/commonjs/compat/make_vtt_cue.d.ts +1 -1
  53. package/dist/commonjs/compat/make_vtt_cue.js +1 -1
  54. package/dist/commonjs/compat/on_height_width_change.d.ts +2 -2
  55. package/dist/commonjs/compat/on_height_width_change.js +1 -1
  56. package/dist/commonjs/compat/patch_webkit_source_buffer.js +31 -31
  57. package/dist/commonjs/compat/should_reload_media_source_on_decipherability_update.js +1 -2
  58. package/dist/commonjs/config.d.ts +7 -18
  59. package/dist/commonjs/config.js +4 -12
  60. package/dist/commonjs/core/adaptive/adaptive_representation_selector.d.ts +26 -22
  61. package/dist/commonjs/core/adaptive/adaptive_representation_selector.js +48 -26
  62. package/dist/commonjs/core/adaptive/buffer_based_chooser.d.ts +1 -1
  63. package/dist/commonjs/core/adaptive/buffer_based_chooser.js +13 -11
  64. package/dist/commonjs/core/adaptive/guess_based_chooser.d.ts +6 -6
  65. package/dist/commonjs/core/adaptive/guess_based_chooser.js +7 -6
  66. package/dist/commonjs/core/adaptive/index.d.ts +2 -2
  67. package/dist/commonjs/core/adaptive/network_analyzer.d.ts +6 -6
  68. package/dist/commonjs/core/adaptive/network_analyzer.js +44 -40
  69. package/dist/commonjs/core/adaptive/utils/bandwidth_estimator.js +1 -1
  70. package/dist/commonjs/core/adaptive/utils/ewma.js +1 -2
  71. package/dist/commonjs/core/adaptive/utils/filter_by_bitrate.d.ts +2 -2
  72. package/dist/commonjs/core/adaptive/utils/filter_by_resolution.d.ts +2 -2
  73. package/dist/commonjs/core/adaptive/utils/filter_by_resolution.js +2 -4
  74. package/dist/commonjs/core/adaptive/utils/get_buffer_levels.js +7 -4
  75. package/dist/commonjs/core/adaptive/utils/last_estimate_storage.d.ts +3 -3
  76. package/dist/commonjs/core/adaptive/utils/pending_requests_store.d.ts +5 -5
  77. package/dist/commonjs/core/adaptive/utils/pending_requests_store.js +4 -3
  78. package/dist/commonjs/core/adaptive/utils/representation_score_calculator.d.ts +7 -7
  79. package/dist/commonjs/core/adaptive/utils/representation_score_calculator.js +11 -8
  80. package/dist/commonjs/core/adaptive/utils/select_optimal_representation.d.ts +4 -4
  81. package/dist/commonjs/core/adaptive/utils/select_optimal_representation.js +2 -2
  82. package/dist/commonjs/core/fetchers/cdn_prioritizer.d.ts +2 -2
  83. package/dist/commonjs/core/fetchers/cdn_prioritizer.js +5 -6
  84. package/dist/commonjs/core/fetchers/manifest/index.d.ts +1 -1
  85. package/dist/commonjs/core/fetchers/manifest/manifest_fetcher.d.ts +3 -3
  86. package/dist/commonjs/core/fetchers/manifest/manifest_fetcher.js +80 -65
  87. package/dist/commonjs/core/fetchers/segment/index.d.ts +1 -1
  88. package/dist/commonjs/core/fetchers/segment/initialization_segment_cache.d.ts +42 -0
  89. package/dist/commonjs/core/fetchers/segment/prioritized_segment_fetcher.d.ts +4 -3
  90. package/dist/commonjs/core/fetchers/segment/segment_fetcher.d.ts +12 -12
  91. package/dist/commonjs/core/fetchers/segment/segment_fetcher.js +51 -34
  92. package/dist/commonjs/core/fetchers/segment/segment_fetcher_creator.d.ts +5 -5
  93. package/dist/commonjs/core/fetchers/segment/segment_fetcher_creator.js +4 -2
  94. package/dist/commonjs/core/fetchers/segment/task_prioritizer.d.ts +1 -1
  95. package/dist/commonjs/core/fetchers/segment/task_prioritizer.js +18 -17
  96. package/dist/commonjs/core/fetchers/utils/error_selector.d.ts +1 -2
  97. package/dist/commonjs/core/fetchers/utils/error_selector.js +2 -2
  98. package/dist/commonjs/core/fetchers/utils/schedule_request.d.ts +3 -3
  99. package/dist/commonjs/core/fetchers/utils/schedule_request.js +22 -22
  100. package/dist/commonjs/core/main/common/DecipherabilityFreezeDetector.d.ts +79 -0
  101. package/dist/commonjs/core/main/common/DecipherabilityFreezeDetector.js +127 -0
  102. package/dist/commonjs/core/main/common/content_time_boundaries_observer.d.ts +191 -0
  103. package/dist/commonjs/core/main/common/content_time_boundaries_observer.js +519 -0
  104. package/dist/commonjs/core/main/common/create_content_time_boundaries_observer.d.ts +27 -0
  105. package/dist/commonjs/core/main/common/create_content_time_boundaries_observer.js +48 -0
  106. package/dist/commonjs/core/main/common/get_buffered_data_per_media_buffer.d.ts +14 -0
  107. package/dist/commonjs/core/main/common/get_buffered_data_per_media_buffer.js +37 -0
  108. package/dist/commonjs/core/main/worker/content_preparer.d.ts +93 -0
  109. package/dist/commonjs/core/main/worker/content_preparer.js +273 -0
  110. package/dist/commonjs/core/main/worker/globals.d.ts +13 -0
  111. package/dist/commonjs/core/main/worker/globals.js +26 -0
  112. package/dist/commonjs/core/main/worker/index.d.ts +2 -0
  113. package/dist/commonjs/core/main/worker/index.js +4 -0
  114. package/dist/commonjs/core/main/worker/send_message.d.ts +3 -0
  115. package/dist/commonjs/core/main/worker/send_message.js +25 -0
  116. package/dist/commonjs/core/main/worker/track_choice_setter.d.ts +19 -0
  117. package/dist/commonjs/core/main/worker/track_choice_setter.js +140 -0
  118. package/dist/commonjs/core/main/worker/worker_main.d.ts +1 -0
  119. package/dist/commonjs/core/main/worker/worker_main.js +787 -0
  120. package/dist/commonjs/core/main/worker/worker_text_displayer_interface.d.ts +64 -0
  121. package/dist/commonjs/core/main/worker/worker_text_displayer_interface.js +126 -0
  122. package/dist/commonjs/core/segment_sinks/garbage_collector.d.ts +43 -0
  123. package/dist/commonjs/core/segment_sinks/garbage_collector.js +226 -0
  124. package/dist/commonjs/core/segment_sinks/implementations/audio_video/audio_video_segment_buffer.d.ts +135 -0
  125. package/dist/commonjs/core/segment_sinks/implementations/audio_video/audio_video_segment_buffer.js +358 -0
  126. package/dist/commonjs/core/segment_sinks/implementations/audio_video/index.d.ts +17 -0
  127. package/dist/commonjs/core/segment_sinks/implementations/index.d.ts +19 -0
  128. package/dist/commonjs/core/segment_sinks/implementations/index.js +35 -0
  129. package/dist/commonjs/core/segment_sinks/implementations/text/index.d.ts +3 -0
  130. package/dist/commonjs/core/segment_sinks/implementations/text/index.js +4 -0
  131. package/dist/commonjs/core/segment_sinks/implementations/text/text_segment_buffer.d.ts +90 -0
  132. package/dist/commonjs/core/segment_sinks/implementations/text/text_segment_buffer.js +257 -0
  133. package/dist/commonjs/core/segment_sinks/implementations/types.d.ts +307 -0
  134. package/dist/commonjs/core/segment_sinks/implementations/types.js +117 -0
  135. package/dist/commonjs/core/segment_sinks/index.d.ts +21 -0
  136. package/dist/commonjs/core/segment_sinks/index.js +28 -0
  137. package/dist/commonjs/core/segment_sinks/inventory/buffered_history.d.ts +89 -0
  138. package/dist/commonjs/core/segment_sinks/inventory/index.d.ts +21 -0
  139. package/dist/commonjs/core/segment_sinks/inventory/segment_inventory.d.ts +238 -0
  140. package/dist/commonjs/core/segment_sinks/inventory/segment_inventory.js +917 -0
  141. package/dist/commonjs/core/segment_sinks/inventory/types.d.ts +27 -0
  142. package/dist/commonjs/core/segment_sinks/inventory/utils.d.ts +33 -0
  143. package/dist/commonjs/core/segment_sinks/inventory/utils.js +53 -0
  144. package/dist/commonjs/core/segment_sinks/segment_buffers_store.d.ts +171 -0
  145. package/dist/commonjs/core/segment_sinks/segment_buffers_store.js +288 -0
  146. package/dist/commonjs/core/stream/adaptation/adaptation_stream.d.ts +4 -4
  147. package/dist/commonjs/core/stream/adaptation/adaptation_stream.js +61 -26
  148. package/dist/commonjs/core/stream/adaptation/get_representations_switch_strategy.d.ts +23 -9
  149. package/dist/commonjs/core/stream/adaptation/get_representations_switch_strategy.js +84 -80
  150. package/dist/commonjs/core/stream/adaptation/types.d.ts +34 -45
  151. package/dist/commonjs/core/stream/index.d.ts +3 -2
  152. package/dist/commonjs/core/stream/orchestrator/get_time_ranges_for_content.d.ts +8 -8
  153. package/dist/commonjs/core/stream/orchestrator/get_time_ranges_for_content.js +5 -6
  154. package/dist/commonjs/core/stream/orchestrator/stream_orchestrator.d.ts +20 -19
  155. package/dist/commonjs/core/stream/orchestrator/stream_orchestrator.js +86 -53
  156. package/dist/commonjs/core/stream/period/period_stream.d.ts +5 -5
  157. package/dist/commonjs/core/stream/period/period_stream.js +126 -54
  158. package/dist/commonjs/core/stream/period/types.d.ts +29 -20
  159. package/dist/commonjs/core/stream/period/utils/get_adaptation_switch_strategy.d.ts +13 -13
  160. package/dist/commonjs/core/stream/period/utils/get_adaptation_switch_strategy.js +94 -95
  161. package/dist/commonjs/core/stream/representation/representation_stream.d.ts +5 -5
  162. package/dist/commonjs/core/stream/representation/representation_stream.js +58 -32
  163. package/dist/commonjs/core/stream/representation/types.d.ts +52 -25
  164. package/dist/commonjs/core/stream/representation/utils/append_segment_to_buffer.d.ts +12 -9
  165. package/dist/commonjs/core/stream/representation/utils/append_segment_to_buffer.js +43 -27
  166. package/dist/commonjs/core/stream/representation/utils/check_for_discontinuity.d.ts +7 -7
  167. package/dist/commonjs/core/stream/representation/utils/check_for_discontinuity.js +16 -18
  168. package/dist/commonjs/core/stream/representation/utils/downloading_queue.d.ts +10 -10
  169. package/dist/commonjs/core/stream/representation/utils/downloading_queue.js +11 -11
  170. package/dist/commonjs/core/stream/representation/utils/get_buffer_status.d.ts +11 -11
  171. package/dist/commonjs/core/stream/representation/utils/get_buffer_status.js +66 -35
  172. package/dist/commonjs/core/stream/representation/utils/get_needed_segments.d.ts +7 -8
  173. package/dist/commonjs/core/stream/representation/utils/get_needed_segments.js +31 -36
  174. package/dist/commonjs/core/stream/representation/utils/push_init_segment.d.ts +14 -12
  175. package/dist/commonjs/core/stream/representation/utils/push_init_segment.js +11 -10
  176. package/dist/commonjs/core/stream/representation/utils/push_media_segment.d.ts +15 -13
  177. package/dist/commonjs/core/stream/representation/utils/push_media_segment.js +17 -15
  178. package/dist/commonjs/core/types.d.ts +8 -0
  179. package/dist/commonjs/core/types.js +2 -0
  180. package/dist/commonjs/default_config.d.ts +31 -34
  181. package/dist/commonjs/default_config.js +61 -61
  182. package/dist/commonjs/errors/encrypted_media_error.d.ts +19 -2
  183. package/dist/commonjs/errors/encrypted_media_error.js +15 -0
  184. package/dist/commonjs/errors/error_codes.d.ts +4 -3
  185. package/dist/commonjs/errors/error_codes.js +3 -8
  186. package/dist/commonjs/errors/format_error.d.ts +2 -2
  187. package/dist/commonjs/errors/format_error.js +1 -2
  188. package/dist/commonjs/errors/index.d.ts +7 -8
  189. package/dist/commonjs/errors/index.js +3 -5
  190. package/dist/commonjs/errors/is_known_error.d.ts +1 -1
  191. package/dist/commonjs/errors/is_known_error.js +2 -2
  192. package/dist/commonjs/errors/media_error.d.ts +22 -19
  193. package/dist/commonjs/errors/media_error.js +17 -19
  194. package/dist/commonjs/errors/network_error.d.ts +16 -2
  195. package/dist/commonjs/errors/network_error.js +16 -2
  196. package/dist/commonjs/errors/other_error.d.ts +15 -1
  197. package/dist/commonjs/errors/other_error.js +10 -0
  198. package/dist/commonjs/errors/source_buffer_error.d.ts +40 -0
  199. package/dist/commonjs/errors/source_buffer_error.js +64 -0
  200. package/dist/commonjs/errors/worker_initialization_error.d.ts +19 -0
  201. package/dist/commonjs/errors/worker_initialization_error.js +43 -0
  202. package/dist/commonjs/experimental/features/index.d.ts +1 -2
  203. package/dist/commonjs/experimental/features/index.js +3 -5
  204. package/dist/commonjs/experimental/features/local.d.ts +1 -1
  205. package/dist/commonjs/experimental/features/local.js +4 -3
  206. package/dist/commonjs/experimental/features/metaplaylist.d.ts +1 -1
  207. package/dist/commonjs/experimental/features/metaplaylist.js +4 -3
  208. package/dist/commonjs/experimental/features/multi_thread.d.ts +8 -0
  209. package/dist/commonjs/experimental/features/multi_thread.js +13 -0
  210. package/dist/commonjs/experimental/index.d.ts +1 -1
  211. package/dist/commonjs/experimental/tools/VideoThumbnailLoader/features/dash.d.ts +1 -1
  212. package/dist/commonjs/experimental/tools/VideoThumbnailLoader/features/metaplaylist.d.ts +1 -1
  213. package/dist/commonjs/experimental/tools/VideoThumbnailLoader/index.d.ts +1 -1
  214. package/dist/commonjs/experimental/tools/VideoThumbnailLoader/load_and_push_segment.d.ts +5 -5
  215. package/dist/commonjs/experimental/tools/VideoThumbnailLoader/load_and_push_segment.js +13 -14
  216. package/dist/commonjs/experimental/tools/VideoThumbnailLoader/prepare_source_buffer.d.ts +4 -4
  217. package/dist/commonjs/experimental/tools/VideoThumbnailLoader/prepare_source_buffer.js +29 -22
  218. package/dist/commonjs/experimental/tools/VideoThumbnailLoader/remove_buffer_around_time.d.ts +3 -5
  219. package/dist/commonjs/experimental/tools/VideoThumbnailLoader/remove_buffer_around_time.js +6 -7
  220. package/dist/commonjs/experimental/tools/VideoThumbnailLoader/types.d.ts +6 -6
  221. package/dist/commonjs/experimental/tools/VideoThumbnailLoader/video_thumbnail_loader.d.ts +3 -3
  222. package/dist/commonjs/experimental/tools/VideoThumbnailLoader/video_thumbnail_loader.js +25 -27
  223. package/dist/commonjs/experimental/tools/createMetaplaylist/get_duration_from_manifest.js +13 -23
  224. package/dist/commonjs/experimental/tools/createMetaplaylist/index.d.ts +1 -1
  225. package/dist/commonjs/experimental/tools/createMetaplaylist/index.js +8 -7
  226. package/dist/commonjs/experimental/tools/index.d.ts +1 -2
  227. package/dist/commonjs/experimental/tools/index.js +1 -3
  228. package/dist/commonjs/experimental/tools/mediaCapabilitiesProber/api/index.d.ts +1 -1
  229. package/dist/commonjs/experimental/tools/mediaCapabilitiesProber/api/index.js +9 -15
  230. package/dist/commonjs/experimental/tools/mediaCapabilitiesProber/api/probeMediaConfiguration.d.ts +4 -3
  231. package/dist/commonjs/experimental/tools/mediaCapabilitiesProber/api/probeMediaConfiguration.js +6 -3
  232. package/dist/commonjs/experimental/tools/mediaCapabilitiesProber/capabilities.d.ts +1 -1
  233. package/dist/commonjs/experimental/tools/mediaCapabilitiesProber/capabilities.js +9 -46
  234. package/dist/commonjs/experimental/tools/mediaCapabilitiesProber/index.d.ts +2 -0
  235. package/dist/commonjs/experimental/tools/mediaCapabilitiesProber/probers/DRMInfos.d.ts +2 -1
  236. package/dist/commonjs/experimental/tools/mediaCapabilitiesProber/probers/DRMInfos.js +8 -5
  237. package/dist/commonjs/experimental/tools/mediaCapabilitiesProber/probers/HDCPPolicy.d.ts +2 -1
  238. package/dist/commonjs/experimental/tools/mediaCapabilitiesProber/probers/HDCPPolicy.js +21 -13
  239. package/dist/commonjs/experimental/tools/mediaCapabilitiesProber/probers/decodingInfo.d.ts +2 -1
  240. package/dist/commonjs/experimental/tools/mediaCapabilitiesProber/probers/decodingInfo.js +25 -21
  241. package/dist/commonjs/experimental/tools/mediaCapabilitiesProber/probers/defaultCodecsFinder.js +12 -12
  242. package/dist/commonjs/experimental/tools/mediaCapabilitiesProber/probers/index.d.ts +1 -1
  243. package/dist/commonjs/experimental/tools/mediaCapabilitiesProber/probers/mediaContentType.d.ts +2 -1
  244. package/dist/commonjs/experimental/tools/mediaCapabilitiesProber/probers/mediaContentType.js +7 -8
  245. package/dist/commonjs/experimental/tools/mediaCapabilitiesProber/probers/mediaContentTypeWithFeatures/format.d.ts +1 -1
  246. package/dist/commonjs/experimental/tools/mediaCapabilitiesProber/probers/mediaContentTypeWithFeatures/format.js +6 -11
  247. package/dist/commonjs/experimental/tools/mediaCapabilitiesProber/probers/mediaContentTypeWithFeatures/index.d.ts +2 -1
  248. package/dist/commonjs/experimental/tools/mediaCapabilitiesProber/probers/mediaContentTypeWithFeatures/index.js +2 -3
  249. package/dist/commonjs/experimental/tools/mediaCapabilitiesProber/probers/mediaDisplayInfos.d.ts +2 -1
  250. package/dist/commonjs/experimental/tools/mediaCapabilitiesProber/probers/mediaDisplayInfos.js +4 -4
  251. package/dist/commonjs/experimental/tools/mediaCapabilitiesProber/types.d.ts +2 -2
  252. package/dist/commonjs/experimental/tools/mediaCapabilitiesProber/utils.d.ts +1 -1
  253. package/dist/commonjs/experimental/tools/mediaCapabilitiesProber/utils.js +8 -7
  254. package/dist/commonjs/features/add_features.d.ts +1 -1
  255. package/dist/commonjs/features/features_object.d.ts +1 -1
  256. package/dist/commonjs/features/features_object.js +9 -6
  257. package/dist/commonjs/features/index.d.ts +1 -1
  258. package/dist/commonjs/features/list/dash.d.ts +1 -1
  259. package/dist/commonjs/features/list/dash.js +6 -5
  260. package/dist/commonjs/features/list/dash_wasm.d.ts +23 -0
  261. package/dist/commonjs/features/list/dash_wasm.js +38 -0
  262. package/dist/commonjs/features/list/debug_element.d.ts +8 -0
  263. package/dist/commonjs/features/list/debug_element.js +13 -0
  264. package/dist/commonjs/features/list/directfile.d.ts +1 -1
  265. package/dist/commonjs/features/list/directfile.js +2 -3
  266. package/dist/commonjs/features/list/eme.d.ts +1 -1
  267. package/dist/commonjs/features/list/eme.js +1 -1
  268. package/dist/commonjs/features/list/html_sami_parser.d.ts +1 -1
  269. package/dist/commonjs/features/list/html_sami_parser.js +2 -2
  270. package/dist/commonjs/features/list/html_srt_parser.d.ts +1 -1
  271. package/dist/commonjs/features/list/html_srt_parser.js +2 -2
  272. package/dist/commonjs/features/list/html_text_buffer.d.ts +1 -1
  273. package/dist/commonjs/features/list/html_text_buffer.js +2 -2
  274. package/dist/commonjs/features/list/html_ttml_parser.d.ts +1 -1
  275. package/dist/commonjs/features/list/html_ttml_parser.js +2 -2
  276. package/dist/commonjs/features/list/html_vtt_parser.d.ts +1 -1
  277. package/dist/commonjs/features/list/html_vtt_parser.js +2 -2
  278. package/dist/commonjs/features/list/index.d.ts +3 -0
  279. package/dist/commonjs/features/list/index.js +7 -1
  280. package/dist/commonjs/features/list/media_source_main.d.ts +8 -0
  281. package/dist/commonjs/features/list/media_source_main.js +13 -0
  282. package/dist/commonjs/features/list/native_sami_parser.d.ts +1 -1
  283. package/dist/commonjs/features/list/native_sami_parser.js +2 -3
  284. package/dist/commonjs/features/list/native_srt_parser.d.ts +1 -1
  285. package/dist/commonjs/features/list/native_srt_parser.js +2 -3
  286. package/dist/commonjs/features/list/native_text_buffer.d.ts +1 -1
  287. package/dist/commonjs/features/list/native_text_buffer.js +2 -3
  288. package/dist/commonjs/features/list/native_ttml_parser.d.ts +1 -1
  289. package/dist/commonjs/features/list/native_ttml_parser.js +2 -3
  290. package/dist/commonjs/features/list/native_vtt_parser.d.ts +1 -1
  291. package/dist/commonjs/features/list/native_vtt_parser.js +2 -3
  292. package/dist/commonjs/features/list/smooth.d.ts +2 -2
  293. package/dist/commonjs/features/list/smooth.js +8 -5
  294. package/dist/commonjs/features/types.d.ts +52 -24
  295. package/dist/commonjs/index.d.ts +1 -1
  296. package/dist/commonjs/index.js +3 -1
  297. package/dist/commonjs/main_thread/api/debug/buffer_graph.d.ts +28 -0
  298. package/dist/commonjs/main_thread/api/debug/buffer_graph.js +168 -0
  299. package/dist/commonjs/main_thread/api/debug/buffer_size_graph.js +131 -0
  300. package/dist/commonjs/main_thread/api/debug/modules/general_info.d.ts +3 -0
  301. package/dist/commonjs/main_thread/api/debug/modules/general_info.js +236 -0
  302. package/dist/commonjs/main_thread/api/debug/modules/segment_buffer_content.d.ts +4 -0
  303. package/dist/commonjs/main_thread/api/debug/modules/segment_buffer_content.js +127 -0
  304. package/dist/commonjs/main_thread/api/debug/modules/segment_buffer_size.d.ts +3 -0
  305. package/dist/commonjs/main_thread/api/debug/modules/segment_buffer_size.js +38 -0
  306. package/dist/commonjs/main_thread/api/debug/render.d.ts +3 -0
  307. package/dist/commonjs/main_thread/api/index.d.ts +17 -0
  308. package/dist/commonjs/main_thread/api/index.js +19 -0
  309. package/dist/commonjs/main_thread/api/option_utils.d.ts +124 -0
  310. package/dist/commonjs/main_thread/api/option_utils.js +335 -0
  311. package/dist/commonjs/main_thread/api/public_api.d.ts +751 -0
  312. package/dist/commonjs/main_thread/api/public_api.js +2518 -0
  313. package/dist/commonjs/main_thread/api/utils.d.ts +66 -0
  314. package/dist/commonjs/main_thread/api/utils.js +178 -0
  315. package/dist/commonjs/main_thread/decrypt/__tests__/__global__/utils.d.ts +184 -0
  316. package/dist/commonjs/main_thread/decrypt/__tests__/__global__/utils.js +439 -0
  317. package/dist/commonjs/main_thread/decrypt/attach_media_keys.d.ts +53 -0
  318. package/dist/commonjs/main_thread/decrypt/attach_media_keys.js +128 -0
  319. package/dist/commonjs/main_thread/decrypt/clear_on_stop.js +43 -0
  320. package/dist/commonjs/main_thread/decrypt/content_decryptor.d.ts +185 -0
  321. package/dist/commonjs/main_thread/decrypt/content_decryptor.js +1053 -0
  322. package/dist/commonjs/main_thread/decrypt/create_or_load_session.d.ts +64 -0
  323. package/dist/commonjs/main_thread/decrypt/create_or_load_session.js +135 -0
  324. package/dist/commonjs/main_thread/decrypt/create_session.d.ts +54 -0
  325. package/dist/commonjs/main_thread/decrypt/create_session.js +215 -0
  326. package/dist/commonjs/main_thread/decrypt/dispose_decryption_resources.js +90 -0
  327. package/dist/commonjs/main_thread/decrypt/find_key_system.d.ts +48 -0
  328. package/dist/commonjs/main_thread/decrypt/find_key_system.js +375 -0
  329. package/dist/commonjs/main_thread/decrypt/get_media_keys.d.ts +44 -0
  330. package/dist/commonjs/main_thread/decrypt/get_media_keys.js +165 -0
  331. package/dist/commonjs/main_thread/decrypt/index.d.ts +26 -0
  332. package/dist/commonjs/main_thread/decrypt/init_media_keys.d.ts +26 -0
  333. package/dist/commonjs/main_thread/decrypt/init_media_keys.js +93 -0
  334. package/dist/commonjs/main_thread/decrypt/session_events_listener.d.ts +75 -0
  335. package/dist/commonjs/main_thread/decrypt/session_events_listener.js +325 -0
  336. package/dist/commonjs/main_thread/decrypt/set_server_certificate.d.ts +51 -0
  337. package/dist/commonjs/main_thread/decrypt/set_server_certificate.js +145 -0
  338. package/dist/commonjs/main_thread/decrypt/types.d.ts +374 -0
  339. package/dist/commonjs/main_thread/decrypt/utils/are_init_values_compatible.js +144 -0
  340. package/dist/commonjs/main_thread/decrypt/utils/check_key_statuses.d.ts +52 -0
  341. package/dist/commonjs/main_thread/decrypt/utils/check_key_statuses.js +211 -0
  342. package/dist/commonjs/main_thread/decrypt/utils/clean_old_loaded_sessions.d.ts +26 -0
  343. package/dist/commonjs/main_thread/decrypt/utils/clean_old_stored_persistent_info.d.ts +32 -0
  344. package/dist/commonjs/main_thread/decrypt/utils/init_data_values_container.d.ts +69 -0
  345. package/dist/commonjs/main_thread/decrypt/utils/init_data_values_container.js +137 -0
  346. package/dist/commonjs/main_thread/decrypt/utils/is_session_usable.d.ts +24 -0
  347. package/dist/commonjs/main_thread/decrypt/utils/is_session_usable.js +51 -0
  348. package/dist/commonjs/main_thread/decrypt/utils/key_session_record.d.ts +104 -0
  349. package/dist/commonjs/main_thread/decrypt/utils/key_session_record.js +189 -0
  350. package/dist/commonjs/main_thread/decrypt/utils/loaded_sessions_store.d.ts +213 -0
  351. package/dist/commonjs/main_thread/decrypt/utils/loaded_sessions_store.js +518 -0
  352. package/dist/commonjs/main_thread/decrypt/utils/media_keys_infos_store.d.ts +56 -0
  353. package/dist/commonjs/main_thread/decrypt/utils/media_keys_infos_store.js +45 -0
  354. package/dist/commonjs/main_thread/decrypt/utils/persistent_sessions_store.d.ts +94 -0
  355. package/dist/commonjs/main_thread/decrypt/utils/persistent_sessions_store.js +356 -0
  356. package/dist/commonjs/main_thread/decrypt/utils/serializable_bytes.d.ts +44 -0
  357. package/dist/commonjs/main_thread/decrypt/utils/serializable_bytes.js +50 -0
  358. package/dist/commonjs/main_thread/decrypt/utils/server_certificate_store.d.ts +64 -0
  359. package/dist/commonjs/main_thread/decrypt/utils/server_certificate_store.js +123 -0
  360. package/dist/commonjs/main_thread/init/directfile_content_initializer.d.ts +97 -0
  361. package/dist/commonjs/main_thread/init/directfile_content_initializer.js +264 -0
  362. package/dist/commonjs/main_thread/init/media_source_content_initializer.d.ts +166 -0
  363. package/dist/commonjs/main_thread/init/media_source_content_initializer.js +897 -0
  364. package/dist/commonjs/main_thread/init/multi_thread_content_initializer.d.ts +167 -0
  365. package/dist/commonjs/main_thread/init/multi_thread_content_initializer.js +1452 -0
  366. package/dist/commonjs/main_thread/init/send_message.d.ts +2 -0
  367. package/dist/commonjs/main_thread/init/send_message.js +13 -0
  368. package/dist/commonjs/main_thread/init/types.d.ts +221 -0
  369. package/dist/commonjs/main_thread/init/types.js +53 -0
  370. package/dist/commonjs/main_thread/init/utils/create_core_playback_observer.d.ts +83 -0
  371. package/dist/commonjs/main_thread/init/utils/create_core_playback_observer.js +105 -0
  372. package/dist/commonjs/main_thread/init/utils/create_media_source.d.ts +37 -0
  373. package/dist/commonjs/main_thread/init/utils/create_media_source.js +106 -0
  374. package/dist/commonjs/main_thread/init/utils/get_initial_time.d.ts +76 -0
  375. package/dist/commonjs/main_thread/init/utils/get_initial_time.js +109 -0
  376. package/dist/commonjs/main_thread/init/utils/get_loaded_reference.d.ts +28 -0
  377. package/dist/commonjs/main_thread/init/utils/get_loaded_reference.js +62 -0
  378. package/dist/commonjs/main_thread/init/utils/initial_seek_and_play.d.ts +61 -0
  379. package/dist/commonjs/main_thread/init/utils/initial_seek_and_play.js +207 -0
  380. package/dist/commonjs/main_thread/init/utils/initialize_content_decryption.d.ts +87 -0
  381. package/dist/commonjs/main_thread/init/utils/initialize_content_decryption.js +119 -0
  382. package/dist/commonjs/main_thread/init/utils/main_thread_text_displayer_interface.d.ts +35 -0
  383. package/dist/commonjs/main_thread/init/utils/main_thread_text_displayer_interface.js +54 -0
  384. package/dist/commonjs/main_thread/init/utils/rebuffering_controller.d.ts +114 -0
  385. package/dist/commonjs/main_thread/init/utils/rebuffering_controller.js +450 -0
  386. package/dist/commonjs/main_thread/init/utils/stream_events_emitter/are_same_stream_events.js +35 -0
  387. package/dist/commonjs/main_thread/init/utils/stream_events_emitter/index.d.ts +18 -0
  388. package/dist/commonjs/main_thread/init/utils/stream_events_emitter/refresh_scheduled_events_list.d.ts +25 -0
  389. package/dist/commonjs/main_thread/init/utils/stream_events_emitter/refresh_scheduled_events_list.js +98 -0
  390. package/dist/commonjs/main_thread/init/utils/stream_events_emitter/stream_events_emitter.d.ts +53 -0
  391. package/dist/commonjs/main_thread/init/utils/stream_events_emitter/stream_events_emitter.js +230 -0
  392. package/dist/commonjs/main_thread/init/utils/stream_events_emitter/types.d.ts +41 -0
  393. package/dist/commonjs/main_thread/init/utils/throw_on_media_error.d.ts +23 -0
  394. package/dist/commonjs/main_thread/init/utils/throw_on_media_error.js +66 -0
  395. package/dist/commonjs/main_thread/text_displayer/html/html_parsers.d.ts +15 -0
  396. package/dist/commonjs/main_thread/text_displayer/html/html_parsers.js +25 -0
  397. package/dist/commonjs/main_thread/text_displayer/html/html_text_displayer.d.ts +100 -0
  398. package/dist/commonjs/main_thread/text_displayer/html/html_text_displayer.js +318 -0
  399. package/dist/commonjs/main_thread/text_displayer/html/index.d.ts +2 -0
  400. package/dist/commonjs/main_thread/text_displayer/html/index.js +4 -0
  401. package/dist/commonjs/main_thread/text_displayer/html/text_track_cues_store.d.ts +65 -0
  402. package/dist/commonjs/main_thread/text_displayer/html/text_track_cues_store.js +378 -0
  403. package/dist/commonjs/main_thread/text_displayer/html/update_proportional_elements.d.ts +15 -0
  404. package/dist/commonjs/main_thread/text_displayer/html/update_proportional_elements.js +64 -0
  405. package/dist/commonjs/main_thread/text_displayer/html/utils.d.ts +39 -0
  406. package/dist/commonjs/main_thread/text_displayer/html/utils.js +119 -0
  407. package/dist/commonjs/main_thread/text_displayer/index.d.ts +2 -0
  408. package/dist/commonjs/main_thread/text_displayer/index.js +2 -0
  409. package/dist/commonjs/main_thread/text_displayer/manual_time_ranges.d.ts +14 -0
  410. package/dist/commonjs/main_thread/text_displayer/manual_time_ranges.js +52 -0
  411. package/dist/commonjs/main_thread/text_displayer/native/index.d.ts +2 -0
  412. package/dist/commonjs/main_thread/text_displayer/native/index.js +4 -0
  413. package/dist/commonjs/main_thread/text_displayer/native/native_parsers.d.ts +11 -0
  414. package/dist/commonjs/main_thread/text_displayer/native/native_parsers.js +25 -0
  415. package/dist/commonjs/main_thread/text_displayer/native/native_text_displayer.d.ts +56 -0
  416. package/dist/commonjs/main_thread/text_displayer/native/native_text_displayer.js +207 -0
  417. package/dist/commonjs/main_thread/text_displayer/types.d.ts +71 -0
  418. package/dist/commonjs/main_thread/text_displayer/types.js +2 -0
  419. package/dist/commonjs/main_thread/tracks_store/index.d.ts +20 -0
  420. package/dist/commonjs/main_thread/tracks_store/media_element_tracks_store.d.ts +197 -0
  421. package/dist/commonjs/main_thread/tracks_store/media_element_tracks_store.js +691 -0
  422. package/dist/commonjs/main_thread/tracks_store/track_dispatcher.d.ts +101 -0
  423. package/dist/commonjs/main_thread/tracks_store/track_dispatcher.js +198 -0
  424. package/dist/commonjs/main_thread/tracks_store/tracks_store.d.ts +448 -0
  425. package/dist/commonjs/main_thread/tracks_store/tracks_store.js +1096 -0
  426. package/dist/commonjs/main_thread/types.d.ts +5 -0
  427. package/dist/commonjs/main_thread/types.js +2 -0
  428. package/dist/commonjs/manifest/classes/adaptation.d.ts +134 -0
  429. package/dist/commonjs/manifest/classes/adaptation.js +237 -0
  430. package/dist/commonjs/manifest/classes/index.d.ts +25 -0
  431. package/dist/commonjs/manifest/classes/index.js +46 -0
  432. package/dist/commonjs/manifest/classes/manifest.d.ts +391 -0
  433. package/dist/commonjs/manifest/classes/manifest.js +494 -0
  434. package/dist/commonjs/manifest/classes/period.d.ts +106 -0
  435. package/dist/commonjs/manifest/classes/period.js +235 -0
  436. package/dist/commonjs/manifest/classes/representation.d.ts +238 -0
  437. package/dist/commonjs/manifest/classes/representation.js +382 -0
  438. package/dist/commonjs/manifest/classes/representation_index/index.d.ts +18 -0
  439. package/dist/commonjs/manifest/classes/representation_index/static.d.ts +101 -0
  440. package/dist/commonjs/manifest/classes/representation_index/static.js +147 -0
  441. package/dist/commonjs/manifest/classes/representation_index/types.d.ts +420 -0
  442. package/dist/commonjs/manifest/classes/types.d.ts +29 -0
  443. package/dist/commonjs/manifest/classes/types.js +33 -0
  444. package/dist/commonjs/manifest/classes/update_period_in_place.d.ts +53 -0
  445. package/dist/commonjs/manifest/classes/update_period_in_place.js +172 -0
  446. package/dist/commonjs/manifest/classes/update_periods.d.ts +50 -0
  447. package/dist/commonjs/manifest/classes/update_periods.js +229 -0
  448. package/dist/commonjs/manifest/classes/utils.d.ts +39 -0
  449. package/dist/commonjs/manifest/classes/utils.js +54 -0
  450. package/dist/commonjs/manifest/index.d.ts +15 -24
  451. package/dist/commonjs/manifest/index.js +5 -31
  452. package/dist/commonjs/manifest/types.d.ts +372 -19
  453. package/dist/commonjs/manifest/types.js +0 -31
  454. package/dist/commonjs/manifest/utils.d.ts +149 -31
  455. package/dist/commonjs/manifest/utils.js +698 -34
  456. package/dist/commonjs/minimal.d.ts +4 -1
  457. package/dist/commonjs/minimal.js +12 -1
  458. package/dist/commonjs/mse/index.d.ts +1 -0
  459. package/dist/commonjs/mse/index.js +2 -0
  460. package/dist/commonjs/mse/main_codec_support_prober.d.ts +26 -0
  461. package/dist/commonjs/mse/main_codec_support_prober.js +44 -0
  462. package/dist/commonjs/mse/main_media_source_interface.d.ts +112 -0
  463. package/dist/commonjs/mse/main_media_source_interface.js +529 -0
  464. package/dist/commonjs/mse/types.d.ts +301 -0
  465. package/dist/commonjs/mse/types.js +2 -0
  466. package/dist/commonjs/mse/utils/end_of_stream.d.ts +33 -0
  467. package/dist/commonjs/mse/utils/end_of_stream.js +114 -0
  468. package/dist/commonjs/mse/utils/media_source_duration_updater.js +272 -0
  469. package/dist/commonjs/mse/worker_codec_support_prober.d.ts +42 -0
  470. package/dist/commonjs/mse/worker_codec_support_prober.js +61 -0
  471. package/dist/commonjs/mse/worker_media_source_interface.d.ts +105 -0
  472. package/dist/commonjs/mse/worker_media_source_interface.js +370 -0
  473. package/dist/commonjs/multithread_types.d.ts +815 -0
  474. package/dist/commonjs/multithread_types.js +7 -0
  475. package/dist/commonjs/parsers/containers/isobmff/create_box.d.ts +1 -1
  476. package/dist/commonjs/parsers/containers/isobmff/create_box.js +4 -3
  477. package/dist/commonjs/parsers/containers/isobmff/drm/playready.js +1 -2
  478. package/dist/commonjs/parsers/containers/isobmff/get_box.js +2 -4
  479. package/dist/commonjs/parsers/containers/isobmff/index.d.ts +3 -3
  480. package/dist/commonjs/parsers/containers/isobmff/read.d.ts +1 -1
  481. package/dist/commonjs/parsers/containers/isobmff/read.js +7 -7
  482. package/dist/commonjs/parsers/containers/isobmff/take_pssh_out.js +3 -4
  483. package/dist/commonjs/parsers/containers/isobmff/utils.js +64 -40
  484. package/dist/commonjs/parsers/containers/matroska/index.d.ts +1 -1
  485. package/dist/commonjs/parsers/containers/matroska/utils.js +42 -29
  486. package/dist/commonjs/parsers/images/bif.js +17 -4
  487. package/dist/commonjs/parsers/manifest/dash/common/attach_trickmode_track.d.ts +1 -1
  488. package/dist/commonjs/parsers/manifest/dash/common/convert_supplemental_codecs.js +1 -3
  489. package/dist/commonjs/parsers/manifest/dash/common/flatten_overlapping_periods.d.ts +1 -1
  490. package/dist/commonjs/parsers/manifest/dash/common/flatten_overlapping_periods.js +1 -1
  491. package/dist/commonjs/parsers/manifest/dash/common/get_hdr_information.js +4 -12
  492. package/dist/commonjs/parsers/manifest/dash/common/get_http_utc-timing_url.d.ts +1 -1
  493. package/dist/commonjs/parsers/manifest/dash/common/get_http_utc-timing_url.js +4 -5
  494. package/dist/commonjs/parsers/manifest/dash/common/get_minimum_and_maximum_positions.d.ts +1 -1
  495. package/dist/commonjs/parsers/manifest/dash/common/get_minimum_and_maximum_positions.js +5 -2
  496. package/dist/commonjs/parsers/manifest/dash/common/get_periods_time_infos.d.ts +1 -1
  497. package/dist/commonjs/parsers/manifest/dash/common/get_periods_time_infos.js +14 -10
  498. package/dist/commonjs/parsers/manifest/dash/common/index.d.ts +1 -1
  499. package/dist/commonjs/parsers/manifest/dash/common/indexes/base.d.ts +5 -5
  500. package/dist/commonjs/parsers/manifest/dash/common/indexes/base.js +39 -29
  501. package/dist/commonjs/parsers/manifest/dash/common/indexes/get_init_segment.d.ts +2 -2
  502. package/dist/commonjs/parsers/manifest/dash/common/indexes/get_init_segment.js +8 -4
  503. package/dist/commonjs/parsers/manifest/dash/common/indexes/get_segments_from_timeline.d.ts +4 -4
  504. package/dist/commonjs/parsers/manifest/dash/common/indexes/get_segments_from_timeline.js +14 -10
  505. package/dist/commonjs/parsers/manifest/dash/common/indexes/list.d.ts +2 -2
  506. package/dist/commonjs/parsers/manifest/dash/common/indexes/list.js +33 -20
  507. package/dist/commonjs/parsers/manifest/dash/common/indexes/template.d.ts +3 -3
  508. package/dist/commonjs/parsers/manifest/dash/common/indexes/template.js +58 -57
  509. package/dist/commonjs/parsers/manifest/dash/common/indexes/timeline/construct_timeline_from_elements.d.ts +5 -4
  510. package/dist/commonjs/parsers/manifest/dash/common/indexes/timeline/construct_timeline_from_elements.js +13 -10
  511. package/dist/commonjs/parsers/manifest/dash/common/indexes/timeline/construct_timeline_from_previous_timeline.d.ts +3 -2
  512. package/dist/commonjs/parsers/manifest/dash/common/indexes/timeline/construct_timeline_from_previous_timeline.js +23 -18
  513. package/dist/commonjs/parsers/manifest/dash/common/indexes/timeline/convert_element_to_index_segment.d.ts +1 -1
  514. package/dist/commonjs/parsers/manifest/dash/common/indexes/timeline/convert_element_to_index_segment.js +16 -9
  515. package/dist/commonjs/parsers/manifest/dash/common/indexes/timeline/find_first_common_start_time.d.ts +4 -3
  516. package/dist/commonjs/parsers/manifest/dash/common/indexes/timeline/find_first_common_start_time.js +47 -26
  517. package/dist/commonjs/parsers/manifest/dash/common/indexes/timeline/parse_s_element.d.ts +11 -2
  518. package/dist/commonjs/parsers/manifest/dash/common/indexes/timeline/parse_s_element.js +74 -3
  519. package/dist/commonjs/parsers/manifest/dash/common/indexes/timeline/timeline_representation_index.d.ts +9 -8
  520. package/dist/commonjs/parsers/manifest/dash/common/indexes/timeline/timeline_representation_index.js +85 -66
  521. package/dist/commonjs/parsers/manifest/dash/common/indexes/tokens.js +2 -4
  522. package/dist/commonjs/parsers/manifest/dash/common/infer_adaptation_type.d.ts +1 -1
  523. package/dist/commonjs/parsers/manifest/dash/common/infer_adaptation_type.js +2 -2
  524. package/dist/commonjs/parsers/manifest/dash/common/manifest_bounds_calculator.js +9 -10
  525. package/dist/commonjs/parsers/manifest/dash/common/parse_adaptation_sets.d.ts +5 -5
  526. package/dist/commonjs/parsers/manifest/dash/common/parse_adaptation_sets.js +63 -56
  527. package/dist/commonjs/parsers/manifest/dash/common/parse_availability_start_time.d.ts +3 -2
  528. package/dist/commonjs/parsers/manifest/dash/common/parse_availability_start_time.js +5 -3
  529. package/dist/commonjs/parsers/manifest/dash/common/parse_mpd.d.ts +6 -6
  530. package/dist/commonjs/parsers/manifest/dash/common/parse_mpd.js +67 -41
  531. package/dist/commonjs/parsers/manifest/dash/common/parse_periods.d.ts +5 -5
  532. package/dist/commonjs/parsers/manifest/dash/common/parse_periods.js +56 -41
  533. package/dist/commonjs/parsers/manifest/dash/common/parse_representation_index.d.ts +5 -5
  534. package/dist/commonjs/parsers/manifest/dash/common/parse_representation_index.js +4 -6
  535. package/dist/commonjs/parsers/manifest/dash/common/parse_representations.d.ts +5 -5
  536. package/dist/commonjs/parsers/manifest/dash/common/parse_representations.js +66 -64
  537. package/dist/commonjs/parsers/manifest/dash/common/resolve_base_urls.d.ts +1 -1
  538. package/dist/commonjs/parsers/manifest/dash/common/resolve_base_urls.js +4 -2
  539. package/dist/commonjs/parsers/manifest/dash/fast-js-parser/index.d.ts +17 -0
  540. package/dist/commonjs/parsers/manifest/dash/fast-js-parser/index.js +19 -0
  541. package/dist/commonjs/parsers/manifest/dash/fast-js-parser/node_parsers/AdaptationSet.d.ts +24 -0
  542. package/dist/commonjs/parsers/manifest/dash/fast-js-parser/node_parsers/AdaptationSet.js +400 -0
  543. package/dist/commonjs/parsers/manifest/dash/fast-js-parser/node_parsers/BaseURL.d.ts +24 -0
  544. package/dist/commonjs/parsers/manifest/dash/fast-js-parser/node_parsers/BaseURL.js +33 -0
  545. package/dist/commonjs/parsers/manifest/dash/fast-js-parser/node_parsers/ContentComponent.d.ts +23 -0
  546. package/dist/commonjs/parsers/manifest/dash/fast-js-parser/node_parsers/ContentComponent.js +70 -0
  547. package/dist/commonjs/parsers/manifest/dash/fast-js-parser/node_parsers/ContentProtection.d.ts +22 -0
  548. package/dist/commonjs/parsers/manifest/dash/fast-js-parser/node_parsers/ContentProtection.js +118 -0
  549. package/dist/commonjs/parsers/manifest/dash/fast-js-parser/node_parsers/EventStream.d.ts +23 -0
  550. package/dist/commonjs/parsers/manifest/dash/fast-js-parser/node_parsers/EventStream.js +154 -0
  551. package/dist/commonjs/parsers/manifest/dash/fast-js-parser/node_parsers/Initialization.d.ts +22 -0
  552. package/dist/commonjs/parsers/manifest/dash/fast-js-parser/node_parsers/Initialization.js +70 -0
  553. package/dist/commonjs/parsers/manifest/dash/fast-js-parser/node_parsers/MPD.d.ts +23 -0
  554. package/dist/commonjs/parsers/manifest/dash/fast-js-parser/node_parsers/MPD.js +221 -0
  555. package/dist/commonjs/parsers/manifest/dash/fast-js-parser/node_parsers/Period.d.ts +23 -0
  556. package/dist/commonjs/parsers/manifest/dash/fast-js-parser/node_parsers/Period.js +179 -0
  557. package/dist/commonjs/parsers/manifest/dash/fast-js-parser/node_parsers/Representation.d.ts +22 -0
  558. package/dist/commonjs/parsers/manifest/dash/fast-js-parser/node_parsers/Representation.js +256 -0
  559. package/dist/commonjs/parsers/manifest/dash/fast-js-parser/node_parsers/SegmentBase.d.ts +23 -0
  560. package/dist/commonjs/parsers/manifest/dash/fast-js-parser/node_parsers/SegmentBase.js +152 -0
  561. package/dist/commonjs/parsers/manifest/dash/fast-js-parser/node_parsers/SegmentList.d.ts +22 -0
  562. package/dist/commonjs/parsers/manifest/dash/fast-js-parser/node_parsers/SegmentList.js +60 -0
  563. package/dist/commonjs/parsers/manifest/dash/fast-js-parser/node_parsers/SegmentTemplate.d.ts +24 -0
  564. package/dist/commonjs/parsers/manifest/dash/fast-js-parser/node_parsers/SegmentTemplate.js +125 -0
  565. package/dist/commonjs/parsers/manifest/dash/fast-js-parser/node_parsers/SegmentTimeline.d.ts +22 -0
  566. package/dist/commonjs/parsers/manifest/dash/fast-js-parser/node_parsers/SegmentTimeline.js +36 -0
  567. package/dist/commonjs/parsers/manifest/dash/fast-js-parser/node_parsers/SegmentURL.d.ts +24 -0
  568. package/dist/commonjs/parsers/manifest/dash/fast-js-parser/node_parsers/SegmentURL.js +82 -0
  569. package/dist/commonjs/parsers/manifest/dash/fast-js-parser/node_parsers/utils.d.ts +176 -0
  570. package/dist/commonjs/parsers/manifest/dash/fast-js-parser/node_parsers/utils.js +382 -0
  571. package/dist/commonjs/parsers/manifest/dash/fast-js-parser/parse_from_xml_string.d.ts +24 -0
  572. package/dist/commonjs/parsers/manifest/dash/fast-js-parser/parse_from_xml_string.js +142 -0
  573. package/dist/commonjs/parsers/manifest/dash/native-parser/node_parsers/AdaptationSet.d.ts +23 -0
  574. package/dist/commonjs/parsers/manifest/dash/native-parser/node_parsers/AdaptationSet.js +374 -0
  575. package/dist/commonjs/parsers/manifest/dash/native-parser/node_parsers/BaseURL.d.ts +23 -0
  576. package/dist/commonjs/parsers/manifest/dash/native-parser/node_parsers/BaseURL.js +32 -0
  577. package/dist/commonjs/parsers/manifest/dash/native-parser/node_parsers/ContentComponent.d.ts +22 -0
  578. package/dist/commonjs/parsers/manifest/dash/native-parser/node_parsers/ContentProtection.d.ts +21 -0
  579. package/dist/commonjs/parsers/manifest/dash/native-parser/node_parsers/EventStream.d.ts +23 -0
  580. package/dist/commonjs/parsers/manifest/dash/native-parser/node_parsers/EventStream.js +119 -0
  581. package/dist/commonjs/parsers/manifest/dash/native-parser/node_parsers/Initialization.d.ts +21 -0
  582. package/dist/commonjs/parsers/manifest/dash/native-parser/node_parsers/Initialization.js +44 -0
  583. package/dist/commonjs/parsers/manifest/dash/native-parser/node_parsers/MPD.d.ts +21 -0
  584. package/dist/commonjs/parsers/manifest/dash/native-parser/node_parsers/MPD.js +181 -0
  585. package/dist/commonjs/parsers/manifest/dash/native-parser/node_parsers/Period.d.ts +21 -0
  586. package/dist/commonjs/parsers/manifest/dash/native-parser/node_parsers/Period.js +138 -0
  587. package/dist/commonjs/parsers/manifest/dash/native-parser/node_parsers/Representation.d.ts +21 -0
  588. package/dist/commonjs/parsers/manifest/dash/native-parser/node_parsers/Representation.js +230 -0
  589. package/dist/commonjs/parsers/manifest/dash/native-parser/node_parsers/SegmentBase.d.ts +22 -0
  590. package/dist/commonjs/parsers/manifest/dash/native-parser/node_parsers/SegmentBase.js +126 -0
  591. package/dist/commonjs/parsers/manifest/dash/native-parser/node_parsers/SegmentList.d.ts +21 -0
  592. package/dist/commonjs/parsers/manifest/dash/native-parser/node_parsers/SegmentTemplate.d.ts +23 -0
  593. package/dist/commonjs/parsers/manifest/dash/native-parser/node_parsers/SegmentTemplate.js +102 -0
  594. package/dist/commonjs/parsers/manifest/dash/native-parser/node_parsers/SegmentTimeline.d.ts +21 -0
  595. package/dist/commonjs/parsers/manifest/dash/native-parser/node_parsers/SegmentURL.d.ts +23 -0
  596. package/dist/commonjs/parsers/manifest/dash/native-parser/node_parsers/SegmentURL.js +56 -0
  597. package/dist/commonjs/parsers/manifest/dash/native-parser/node_parsers/utils.d.ts +169 -0
  598. package/dist/commonjs/parsers/manifest/dash/native-parser/node_parsers/utils.js +346 -0
  599. package/dist/commonjs/parsers/manifest/dash/native-parser/parse_from_document.d.ts +24 -0
  600. package/dist/commonjs/parsers/manifest/dash/native-parser/parse_from_document.js +136 -0
  601. package/dist/commonjs/parsers/manifest/dash/node_parser_types.d.ts +5 -3
  602. package/dist/commonjs/parsers/manifest/dash/parsers_types.d.ts +1 -1
  603. package/dist/commonjs/parsers/manifest/dash/wasm-parser/ts/dash-wasm-parser.d.ts +2 -2
  604. package/dist/commonjs/parsers/manifest/dash/wasm-parser/ts/dash-wasm-parser.js +52 -23
  605. package/dist/commonjs/parsers/manifest/dash/wasm-parser/ts/generators/AdaptationSet.d.ts +3 -2
  606. package/dist/commonjs/parsers/manifest/dash/wasm-parser/ts/generators/AdaptationSet.js +21 -25
  607. package/dist/commonjs/parsers/manifest/dash/wasm-parser/ts/generators/BaseURL.d.ts +2 -2
  608. package/dist/commonjs/parsers/manifest/dash/wasm-parser/ts/generators/ContentComponent.d.ts +3 -3
  609. package/dist/commonjs/parsers/manifest/dash/wasm-parser/ts/generators/ContentComponent.js +1 -1
  610. package/dist/commonjs/parsers/manifest/dash/wasm-parser/ts/generators/ContentProtection.d.ts +3 -3
  611. package/dist/commonjs/parsers/manifest/dash/wasm-parser/ts/generators/ContentProtection.js +4 -2
  612. package/dist/commonjs/parsers/manifest/dash/wasm-parser/ts/generators/EventStream.d.ts +3 -2
  613. package/dist/commonjs/parsers/manifest/dash/wasm-parser/ts/generators/EventStream.js +2 -4
  614. package/dist/commonjs/parsers/manifest/dash/wasm-parser/ts/generators/MPD.d.ts +3 -2
  615. package/dist/commonjs/parsers/manifest/dash/wasm-parser/ts/generators/MPD.js +4 -4
  616. package/dist/commonjs/parsers/manifest/dash/wasm-parser/ts/generators/Period.d.ts +3 -2
  617. package/dist/commonjs/parsers/manifest/dash/wasm-parser/ts/generators/Period.js +9 -6
  618. package/dist/commonjs/parsers/manifest/dash/wasm-parser/ts/generators/Representation.d.ts +3 -2
  619. package/dist/commonjs/parsers/manifest/dash/wasm-parser/ts/generators/Representation.js +13 -15
  620. package/dist/commonjs/parsers/manifest/dash/wasm-parser/ts/generators/Scheme.d.ts +3 -3
  621. package/dist/commonjs/parsers/manifest/dash/wasm-parser/ts/generators/Scheme.js +1 -1
  622. package/dist/commonjs/parsers/manifest/dash/wasm-parser/ts/generators/SegmentBase.d.ts +2 -2
  623. package/dist/commonjs/parsers/manifest/dash/wasm-parser/ts/generators/SegmentBase.js +5 -10
  624. package/dist/commonjs/parsers/manifest/dash/wasm-parser/ts/generators/SegmentList.d.ts +3 -2
  625. package/dist/commonjs/parsers/manifest/dash/wasm-parser/ts/generators/SegmentTemplate.d.ts +2 -2
  626. package/dist/commonjs/parsers/manifest/dash/wasm-parser/ts/generators/SegmentTemplate.js +11 -18
  627. package/dist/commonjs/parsers/manifest/dash/wasm-parser/ts/generators/SegmentUrl.d.ts +2 -2
  628. package/dist/commonjs/parsers/manifest/dash/wasm-parser/ts/generators/SegmentUrl.js +2 -4
  629. package/dist/commonjs/parsers/manifest/dash/wasm-parser/ts/generators/XLink.d.ts +3 -2
  630. package/dist/commonjs/parsers/manifest/dash/wasm-parser/ts/generators/XLink.js +4 -4
  631. package/dist/commonjs/parsers/manifest/dash/wasm-parser/ts/generators/root.d.ts +2 -2
  632. package/dist/commonjs/parsers/manifest/dash/wasm-parser/ts/generators/root.js +7 -3
  633. package/dist/commonjs/parsers/manifest/dash/wasm-parser/ts/parsers_stack.js +5 -2
  634. package/dist/commonjs/parsers/manifest/dash/wasm-parser/ts/types.d.ts +55 -55
  635. package/dist/commonjs/parsers/manifest/dash/wasm-parser/ts/utils.d.ts +1 -1
  636. package/dist/commonjs/parsers/manifest/dash/wasm-parser/ts/utils.js +7 -3
  637. package/dist/commonjs/parsers/manifest/local/parse_local_manifest.d.ts +2 -2
  638. package/dist/commonjs/parsers/manifest/local/parse_local_manifest.js +25 -16
  639. package/dist/commonjs/parsers/manifest/local/representation_index.d.ts +2 -2
  640. package/dist/commonjs/parsers/manifest/local/representation_index.js +8 -10
  641. package/dist/commonjs/parsers/manifest/metaplaylist/index.d.ts +1 -1
  642. package/dist/commonjs/parsers/manifest/metaplaylist/metaplaylist_parser.d.ts +4 -4
  643. package/dist/commonjs/parsers/manifest/metaplaylist/metaplaylist_parser.js +59 -42
  644. package/dist/commonjs/parsers/manifest/metaplaylist/representation_index.d.ts +3 -3
  645. package/dist/commonjs/parsers/manifest/metaplaylist/representation_index.js +10 -7
  646. package/dist/commonjs/parsers/manifest/smooth/create_parser.d.ts +2 -2
  647. package/dist/commonjs/parsers/manifest/smooth/create_parser.js +130 -108
  648. package/dist/commonjs/parsers/manifest/smooth/get_codecs.js +3 -3
  649. package/dist/commonjs/parsers/manifest/smooth/index.d.ts +1 -1
  650. package/dist/commonjs/parsers/manifest/smooth/parse_C_nodes.js +9 -9
  651. package/dist/commonjs/parsers/manifest/smooth/parse_protection_node.js +12 -8
  652. package/dist/commonjs/parsers/manifest/smooth/representation_index.d.ts +3 -3
  653. package/dist/commonjs/parsers/manifest/smooth/representation_index.js +37 -37
  654. package/dist/commonjs/parsers/manifest/smooth/shared_smooth_segment_timeline.d.ts +1 -1
  655. package/dist/commonjs/parsers/manifest/smooth/shared_smooth_segment_timeline.js +8 -9
  656. package/dist/commonjs/parsers/manifest/smooth/utils/add_segment_infos.js +10 -7
  657. package/dist/commonjs/parsers/manifest/smooth/utils/parseBoolean.d.ts +1 -1
  658. package/dist/commonjs/parsers/manifest/smooth/utils/parseBoolean.js +1 -1
  659. package/dist/commonjs/parsers/manifest/smooth/utils/tokens.d.ts +1 -1
  660. package/dist/commonjs/parsers/manifest/smooth/utils/tokens.js +1 -2
  661. package/dist/commonjs/parsers/manifest/types.d.ts +10 -3
  662. package/dist/commonjs/parsers/manifest/utils/check_manifest_ids.d.ts +1 -1
  663. package/dist/commonjs/parsers/manifest/utils/clear_timeline_from_position.d.ts +3 -2
  664. package/dist/commonjs/parsers/manifest/utils/clear_timeline_from_position.js +11 -7
  665. package/dist/commonjs/parsers/manifest/utils/get_first_time_from_adaptation.d.ts +1 -1
  666. package/dist/commonjs/parsers/manifest/utils/get_first_time_from_adaptation.js +5 -4
  667. package/dist/commonjs/parsers/manifest/utils/get_last_time_from_adaptation.d.ts +1 -1
  668. package/dist/commonjs/parsers/manifest/utils/get_last_time_from_adaptation.js +5 -4
  669. package/dist/commonjs/parsers/manifest/utils/get_maximum_positions.d.ts +2 -2
  670. package/dist/commonjs/parsers/manifest/utils/get_maximum_positions.js +11 -17
  671. package/dist/commonjs/parsers/manifest/utils/get_minimum_position.d.ts +2 -2
  672. package/dist/commonjs/parsers/manifest/utils/get_minimum_position.js +5 -11
  673. package/dist/commonjs/parsers/manifest/utils/index_helpers.js +4 -5
  674. package/dist/commonjs/parsers/manifest/utils/update_segment_timeline.d.ts +1 -1
  675. package/dist/commonjs/parsers/manifest/utils/update_segment_timeline.js +17 -17
  676. package/dist/commonjs/parsers/texttracks/index.d.ts +1 -1
  677. package/dist/commonjs/parsers/texttracks/sami/html.d.ts +1 -1
  678. package/dist/commonjs/parsers/texttracks/sami/html.js +17 -16
  679. package/dist/commonjs/parsers/texttracks/sami/native.d.ts +1 -1
  680. package/dist/commonjs/parsers/texttracks/sami/native.js +12 -18
  681. package/dist/commonjs/parsers/texttracks/srt/html.js +12 -10
  682. package/dist/commonjs/parsers/texttracks/srt/native.d.ts +1 -1
  683. package/dist/commonjs/parsers/texttracks/srt/native.js +2 -8
  684. package/dist/commonjs/parsers/texttracks/srt/parse_cue.js +4 -8
  685. package/dist/commonjs/parsers/texttracks/ttml/get_parameters.js +7 -8
  686. package/dist/commonjs/parsers/texttracks/ttml/get_time_delimiters.d.ts +1 -1
  687. package/dist/commonjs/parsers/texttracks/ttml/get_time_delimiters.js +9 -10
  688. package/dist/commonjs/parsers/texttracks/ttml/html/apply_default_ttml_paragraph_style.js +2 -2
  689. package/dist/commonjs/parsers/texttracks/ttml/html/apply_extent.js +5 -9
  690. package/dist/commonjs/parsers/texttracks/ttml/html/apply_font_size.js +6 -7
  691. package/dist/commonjs/parsers/texttracks/ttml/html/apply_line_height.js +2 -2
  692. package/dist/commonjs/parsers/texttracks/ttml/html/apply_origin.js +5 -9
  693. package/dist/commonjs/parsers/texttracks/ttml/html/apply_padding.js +7 -11
  694. package/dist/commonjs/parsers/texttracks/ttml/html/create_element.d.ts +2 -2
  695. package/dist/commonjs/parsers/texttracks/ttml/html/create_element.js +29 -22
  696. package/dist/commonjs/parsers/texttracks/ttml/html/generate_css_test_outline.js +2 -2
  697. package/dist/commonjs/parsers/texttracks/ttml/html/parse_cue.d.ts +1 -1
  698. package/dist/commonjs/parsers/texttracks/ttml/html/parse_cue.js +5 -3
  699. package/dist/commonjs/parsers/texttracks/ttml/html/parse_ttml_to_div.d.ts +1 -1
  700. package/dist/commonjs/parsers/texttracks/ttml/html/ttml_color_to_css_color.js +39 -23
  701. package/dist/commonjs/parsers/texttracks/ttml/native/parse_cue.d.ts +2 -2
  702. package/dist/commonjs/parsers/texttracks/ttml/native/parse_cue.js +14 -13
  703. package/dist/commonjs/parsers/texttracks/ttml/native/parse_ttml_to_vtt.d.ts +1 -1
  704. package/dist/commonjs/parsers/texttracks/ttml/parse_ttml.d.ts +3 -3
  705. package/dist/commonjs/parsers/texttracks/ttml/parse_ttml.js +27 -15
  706. package/dist/commonjs/parsers/texttracks/ttml/resolve_styles_inheritance.d.ts +1 -1
  707. package/dist/commonjs/parsers/texttracks/ttml/time_parsing.d.ts +1 -1
  708. package/dist/commonjs/parsers/texttracks/ttml/time_parsing.js +2 -2
  709. package/dist/commonjs/parsers/texttracks/ttml/xml_utils.js +2 -1
  710. package/dist/commonjs/parsers/texttracks/types.d.ts +1 -1
  711. package/dist/commonjs/parsers/texttracks/webvtt/get_style_blocks.js +2 -1
  712. package/dist/commonjs/parsers/texttracks/webvtt/html/convert_payload_to_html.d.ts +1 -1
  713. package/dist/commonjs/parsers/texttracks/webvtt/html/create_default_style_elements.d.ts +1 -1
  714. package/dist/commonjs/parsers/texttracks/webvtt/html/create_style_attribute.js +6 -12
  715. package/dist/commonjs/parsers/texttracks/webvtt/html/create_styled_element.d.ts +1 -1
  716. package/dist/commonjs/parsers/texttracks/webvtt/html/create_styled_element.js +7 -8
  717. package/dist/commonjs/parsers/texttracks/webvtt/html/parse_style_block.js +4 -4
  718. package/dist/commonjs/parsers/texttracks/webvtt/html/parse_webvtt_to_div.d.ts +1 -1
  719. package/dist/commonjs/parsers/texttracks/webvtt/html/parse_webvtt_to_div.js +1 -1
  720. package/dist/commonjs/parsers/texttracks/webvtt/html/to_html.d.ts +1 -1
  721. package/dist/commonjs/parsers/texttracks/webvtt/html/to_html.js +4 -10
  722. package/dist/commonjs/parsers/texttracks/webvtt/native/parse_vtt_to_cues.d.ts +1 -1
  723. package/dist/commonjs/parsers/texttracks/webvtt/native/parse_vtt_to_cues.js +5 -9
  724. package/dist/commonjs/parsers/texttracks/webvtt/native/set_settings_on_cue.d.ts +1 -1
  725. package/dist/commonjs/parsers/texttracks/webvtt/native/to_native_cue.d.ts +2 -2
  726. package/dist/commonjs/parsers/texttracks/webvtt/native/to_native_cue.js +3 -3
  727. package/dist/commonjs/parsers/texttracks/webvtt/parse_cue_block.js +9 -5
  728. package/dist/commonjs/parsers/texttracks/webvtt/parse_timestamp.js +1 -2
  729. package/dist/commonjs/parsers/texttracks/webvtt/utils.js +6 -6
  730. package/dist/commonjs/playback_observer/index.d.ts +6 -0
  731. package/dist/commonjs/playback_observer/index.js +5 -0
  732. package/dist/commonjs/playback_observer/media_element_playback_observer.d.ts +203 -0
  733. package/dist/commonjs/playback_observer/media_element_playback_observer.js +685 -0
  734. package/dist/commonjs/playback_observer/types.d.ts +223 -0
  735. package/dist/commonjs/playback_observer/types.js +2 -0
  736. package/dist/commonjs/playback_observer/utils/generate_read_only_observer.d.ts +11 -0
  737. package/dist/commonjs/playback_observer/utils/generate_read_only_observer.js +44 -0
  738. package/dist/commonjs/playback_observer/utils/observation_position.d.ts +87 -0
  739. package/dist/commonjs/playback_observer/utils/observation_position.js +88 -0
  740. package/dist/commonjs/playback_observer/worker_playback_observer.d.ts +72 -0
  741. package/dist/commonjs/playback_observer/worker_playback_observer.js +49 -0
  742. package/dist/commonjs/public_types.d.ts +75 -33
  743. package/dist/commonjs/public_types.js +2 -13
  744. package/dist/commonjs/tools/TextTrackRenderer/text_track_renderer.d.ts +3 -3
  745. package/dist/commonjs/tools/TextTrackRenderer/text_track_renderer.js +17 -18
  746. package/dist/commonjs/tools/index.d.ts +2 -1
  747. package/dist/commonjs/tools/index.js +3 -1
  748. package/dist/commonjs/tools/parseBIFThumbnails/index.js +33 -0
  749. package/dist/commonjs/transports/dash/add_segment_integrity_checks_to_loader.d.ts +1 -1
  750. package/dist/commonjs/transports/dash/add_segment_integrity_checks_to_loader.js +2 -3
  751. package/dist/commonjs/transports/dash/construct_segment_url.d.ts +2 -2
  752. package/dist/commonjs/transports/dash/construct_segment_url.js +7 -3
  753. package/dist/commonjs/transports/dash/extract_complete_chunks.d.ts +1 -1
  754. package/dist/commonjs/transports/dash/extract_complete_chunks.js +37 -8
  755. package/dist/commonjs/transports/dash/get_events_out_of_emsgs.d.ts +2 -2
  756. package/dist/commonjs/transports/dash/get_events_out_of_emsgs.js +12 -11
  757. package/dist/commonjs/transports/dash/init_segment_loader.d.ts +3 -3
  758. package/dist/commonjs/transports/dash/init_segment_loader.js +46 -22
  759. package/dist/commonjs/transports/dash/low_latency_segment_loader.d.ts +2 -2
  760. package/dist/commonjs/transports/dash/low_latency_segment_loader.js +18 -11
  761. package/dist/commonjs/transports/dash/manifest_parser.d.ts +2 -2
  762. package/dist/commonjs/transports/dash/manifest_parser.js +69 -28
  763. package/dist/commonjs/transports/dash/pipelines.d.ts +1 -1
  764. package/dist/commonjs/transports/dash/pipelines.js +15 -12
  765. package/dist/commonjs/transports/dash/segment_loader.d.ts +4 -4
  766. package/dist/commonjs/transports/dash/segment_loader.js +35 -21
  767. package/dist/commonjs/transports/dash/segment_parser.d.ts +2 -2
  768. package/dist/commonjs/transports/dash/segment_parser.js +54 -22
  769. package/dist/commonjs/transports/dash/text_loader.d.ts +2 -2
  770. package/dist/commonjs/transports/dash/text_loader.js +21 -18
  771. package/dist/commonjs/transports/dash/text_parser.d.ts +2 -2
  772. package/dist/commonjs/transports/dash/text_parser.js +49 -23
  773. package/dist/commonjs/transports/index.d.ts +1 -1
  774. package/dist/commonjs/transports/index.js +0 -15
  775. package/dist/commonjs/transports/local/pipelines.d.ts +1 -1
  776. package/dist/commonjs/transports/local/pipelines.js +15 -10
  777. package/dist/commonjs/transports/local/segment_loader.d.ts +3 -3
  778. package/dist/commonjs/transports/local/segment_loader.js +14 -6
  779. package/dist/commonjs/transports/local/segment_parser.d.ts +1 -1
  780. package/dist/commonjs/transports/local/segment_parser.js +30 -12
  781. package/dist/commonjs/transports/local/text_parser.d.ts +1 -1
  782. package/dist/commonjs/transports/local/text_parser.js +48 -18
  783. package/dist/commonjs/transports/metaplaylist/manifest_loader.d.ts +4 -4
  784. package/dist/commonjs/transports/metaplaylist/manifest_loader.js +9 -5
  785. package/dist/commonjs/transports/metaplaylist/pipelines.d.ts +1 -1
  786. package/dist/commonjs/transports/metaplaylist/pipelines.js +38 -22
  787. package/dist/commonjs/transports/smooth/extract_timings_infos.d.ts +2 -2
  788. package/dist/commonjs/transports/smooth/extract_timings_infos.js +14 -13
  789. package/dist/commonjs/transports/smooth/is_mp4_embedded_track.d.ts +1 -1
  790. package/dist/commonjs/transports/smooth/is_mp4_embedded_track.js +1 -1
  791. package/dist/commonjs/transports/smooth/isobmff/create_audio_init_segment.d.ts +0 -1
  792. package/dist/commonjs/transports/smooth/isobmff/create_audio_init_segment.js +3 -4
  793. package/dist/commonjs/transports/smooth/isobmff/create_boxes.js +22 -31
  794. package/dist/commonjs/transports/smooth/isobmff/create_init_segment.js +1 -1
  795. package/dist/commonjs/transports/smooth/isobmff/get_aaces_header.js +4 -16
  796. package/dist/commonjs/transports/smooth/isobmff/parse_tfrf.js +1 -1
  797. package/dist/commonjs/transports/smooth/isobmff/parse_tfxd.js +1 -1
  798. package/dist/commonjs/transports/smooth/isobmff/patch_segment.js +12 -11
  799. package/dist/commonjs/transports/smooth/pipelines.d.ts +1 -1
  800. package/dist/commonjs/transports/smooth/pipelines.js +101 -60
  801. package/dist/commonjs/transports/smooth/segment_loader.d.ts +3 -3
  802. package/dist/commonjs/transports/smooth/segment_loader.js +50 -27
  803. package/dist/commonjs/transports/smooth/utils.d.ts +4 -4
  804. package/dist/commonjs/transports/smooth/utils.js +9 -5
  805. package/dist/commonjs/transports/types.d.ts +22 -27
  806. package/dist/commonjs/transports/utils/byte_range.js +1 -2
  807. package/dist/commonjs/transports/utils/call_custom_manifest_loader.d.ts +3 -3
  808. package/dist/commonjs/transports/utils/call_custom_manifest_loader.js +10 -6
  809. package/dist/commonjs/transports/utils/check_isobmff_integrity.js +3 -3
  810. package/dist/commonjs/transports/utils/find_complete_box.js +2 -1
  811. package/dist/commonjs/transports/utils/generate_manifest_loader.d.ts +3 -3
  812. package/dist/commonjs/transports/utils/generate_manifest_loader.js +20 -8
  813. package/dist/commonjs/transports/utils/get_isobmff_timing_infos.d.ts +2 -2
  814. package/dist/commonjs/transports/utils/get_isobmff_timing_infos.js +12 -11
  815. package/dist/commonjs/transports/utils/infer_segment_container.d.ts +1 -1
  816. package/dist/commonjs/transports/utils/infer_segment_container.js +1 -3
  817. package/dist/commonjs/transports/utils/parse_text_track.d.ts +4 -4
  818. package/dist/commonjs/transports/utils/parse_text_track.js +4 -7
  819. package/dist/commonjs/utils/array_includes.js +2 -6
  820. package/dist/commonjs/utils/assert.d.ts +41 -0
  821. package/dist/commonjs/utils/assert.js +71 -8
  822. package/dist/commonjs/utils/base64.js +87 -29
  823. package/dist/commonjs/utils/byte_parsing.js +64 -56
  824. package/dist/commonjs/utils/cancellable_sleep.d.ts +1 -1
  825. package/dist/commonjs/utils/create_cancellable_promise.d.ts +1 -1
  826. package/dist/commonjs/utils/deep_merge.js +4 -4
  827. package/dist/commonjs/utils/event_emitter.d.ts +1 -1
  828. package/dist/commonjs/utils/event_emitter.js +7 -2
  829. package/dist/commonjs/utils/get_fuzzed_delay.js +1 -1
  830. package/dist/commonjs/utils/global_scope.d.ts +9 -0
  831. package/dist/commonjs/utils/global_scope.js +22 -0
  832. package/dist/commonjs/utils/hash_buffer.js +1 -1
  833. package/dist/commonjs/utils/languages/ISO_639-1_to_ISO_639-3.js +182 -182
  834. package/dist/commonjs/utils/languages/ISO_639-2_to_ISO_639-3.js +19 -19
  835. package/dist/commonjs/utils/languages/normalize.js +4 -2
  836. package/dist/commonjs/utils/logger.d.ts +13 -3
  837. package/dist/commonjs/utils/logger.js +73 -26
  838. package/dist/commonjs/utils/monotonic_timestamp.d.ts +20 -4
  839. package/dist/commonjs/utils/monotonic_timestamp.js +22 -5
  840. package/dist/commonjs/utils/object_assign.d.ts +29 -5
  841. package/dist/commonjs/utils/object_assign.js +17 -8
  842. package/dist/commonjs/utils/object_values.d.ts +1 -1
  843. package/dist/commonjs/utils/object_values.js +2 -3
  844. package/dist/commonjs/utils/queue_microtask.js +3 -3
  845. package/dist/commonjs/utils/ranges.js +22 -29
  846. package/dist/commonjs/utils/reference.d.ts +1 -1
  847. package/dist/commonjs/utils/reference.js +1 -3
  848. package/dist/commonjs/utils/request/fetch.d.ts +1 -1
  849. package/dist/commonjs/utils/request/fetch.js +41 -30
  850. package/dist/commonjs/utils/request/index.d.ts +2 -1
  851. package/dist/commonjs/utils/request/index.js +4 -1
  852. package/dist/commonjs/utils/request/request_error.d.ts +47 -0
  853. package/dist/commonjs/utils/request/request_error.js +87 -0
  854. package/dist/commonjs/utils/request/xhr.d.ts +5 -5
  855. package/dist/commonjs/utils/request/xhr.js +35 -24
  856. package/dist/commonjs/utils/retry_promise_with_backoff.d.ts +11 -3
  857. package/dist/commonjs/utils/retry_promise_with_backoff.js +18 -4
  858. package/dist/commonjs/utils/slice_uint8array.js +3 -3
  859. package/dist/commonjs/utils/starts_with.js +3 -3
  860. package/dist/commonjs/utils/string_parsing.js +17 -19
  861. package/dist/commonjs/utils/sync_or_async.d.ts +70 -0
  862. package/dist/commonjs/utils/sync_or_async.js +51 -0
  863. package/dist/commonjs/utils/task_canceller.js +1 -2
  864. package/dist/commonjs/utils/wrapInPromise.d.ts +1 -1
  865. package/dist/commonjs/utils/xml-parser.d.ts +70 -0
  866. package/dist/commonjs/utils/xml-parser.js +357 -0
  867. package/dist/commonjs/worker_entry_point.d.ts +5 -0
  868. package/dist/commonjs/worker_entry_point.js +8 -0
  869. package/dist/es2017/__GENERATED_CODE/embedded_dash_wasm.d.ts +3 -0
  870. package/dist/es2017/__GENERATED_CODE/embedded_dash_wasm.js +3 -0
  871. package/dist/es2017/__GENERATED_CODE/embedded_worker.d.ts +3 -0
  872. package/dist/es2017/__GENERATED_CODE/embedded_worker.js +3 -0
  873. package/dist/es2017/__GENERATED_CODE/index.d.ts +2 -0
  874. package/dist/es2017/__GENERATED_CODE/index.js +2 -0
  875. package/dist/es2017/compat/add_class_name.js +4 -3
  876. package/dist/es2017/compat/add_text_track.d.ts +1 -1
  877. package/dist/es2017/compat/add_text_track.js +3 -2
  878. package/dist/es2017/compat/browser_compatibility_types.js +14 -8
  879. package/dist/es2017/compat/browser_detection.d.ts +3 -1
  880. package/dist/es2017/compat/browser_detection.js +28 -10
  881. package/dist/es2017/compat/can_reuse_media_keys.js +1 -1
  882. package/dist/es2017/compat/change_source_buffer_type.d.ts +1 -1
  883. package/dist/es2017/compat/eme/close_session.d.ts +1 -1
  884. package/dist/es2017/compat/eme/close_session.js +17 -13
  885. package/dist/es2017/compat/eme/custom_key_system_access.d.ts +1 -1
  886. package/dist/es2017/compat/eme/custom_media_keys/ie11_media_keys.d.ts +1 -1
  887. package/dist/es2017/compat/eme/custom_media_keys/ie11_media_keys.js +14 -7
  888. package/dist/es2017/compat/eme/custom_media_keys/index.js +1 -1
  889. package/dist/es2017/compat/eme/custom_media_keys/moz_media_keys_constructor.d.ts +1 -1
  890. package/dist/es2017/compat/eme/custom_media_keys/moz_media_keys_constructor.js +1 -1
  891. package/dist/es2017/compat/eme/custom_media_keys/ms_media_keys_constructor.js +1 -1
  892. package/dist/es2017/compat/eme/custom_media_keys/old_webkit_media_keys.d.ts +2 -2
  893. package/dist/es2017/compat/eme/custom_media_keys/old_webkit_media_keys.js +10 -11
  894. package/dist/es2017/compat/eme/custom_media_keys/types.d.ts +1 -1
  895. package/dist/es2017/compat/eme/custom_media_keys/webkit_media_keys.d.ts +1 -1
  896. package/dist/es2017/compat/eme/custom_media_keys/webkit_media_keys.js +5 -9
  897. package/dist/es2017/compat/eme/custom_media_keys/webkit_media_keys_constructor.d.ts +1 -1
  898. package/dist/es2017/compat/eme/custom_media_keys/webkit_media_keys_constructor.js +4 -4
  899. package/dist/es2017/compat/eme/eme-api-implementation.d.ts +3 -3
  900. package/dist/es2017/compat/eme/eme-api-implementation.js +17 -15
  901. package/dist/es2017/compat/eme/generate_key_request.d.ts +1 -1
  902. package/dist/es2017/compat/eme/generate_key_request.js +17 -20
  903. package/dist/es2017/compat/eme/get_init_data.js +5 -7
  904. package/dist/es2017/compat/eme/get_uuid_kid_from_keystatus_kid.js +2 -3
  905. package/dist/es2017/compat/eme/get_webkit_fairplay_initdata.js +12 -13
  906. package/dist/es2017/compat/eme/load_session.d.ts +1 -1
  907. package/dist/es2017/compat/enable_audio_track.d.ts +1 -1
  908. package/dist/es2017/compat/event_listeners.d.ts +4 -4
  909. package/dist/es2017/compat/event_listeners.js +40 -37
  910. package/dist/es2017/compat/has_mse_in_worker.d.ts +2 -0
  911. package/dist/es2017/compat/has_mse_in_worker.js +4 -0
  912. package/dist/es2017/compat/has_webassembly.d.ts +6 -0
  913. package/dist/es2017/compat/has_webassembly.js +6 -0
  914. package/dist/es2017/compat/is_codec_supported.js +7 -1
  915. package/dist/es2017/compat/is_vtt_cue.d.ts +1 -1
  916. package/dist/es2017/compat/is_vtt_cue.js +1 -1
  917. package/dist/es2017/compat/make_vtt_cue.d.ts +1 -1
  918. package/dist/es2017/compat/make_vtt_cue.js +1 -1
  919. package/dist/es2017/compat/on_height_width_change.d.ts +2 -2
  920. package/dist/es2017/compat/on_height_width_change.js +2 -2
  921. package/dist/es2017/compat/patch_webkit_source_buffer.js +30 -30
  922. package/dist/es2017/compat/should_favour_custom_safari_EME.js +2 -2
  923. package/dist/es2017/compat/should_reload_media_source_on_decipherability_update.js +1 -2
  924. package/dist/es2017/config.d.ts +7 -18
  925. package/dist/es2017/config.js +4 -12
  926. package/dist/es2017/core/adaptive/adaptive_representation_selector.d.ts +26 -22
  927. package/dist/es2017/core/adaptive/adaptive_representation_selector.js +42 -30
  928. package/dist/es2017/core/adaptive/buffer_based_chooser.d.ts +1 -1
  929. package/dist/es2017/core/adaptive/buffer_based_chooser.js +14 -12
  930. package/dist/es2017/core/adaptive/guess_based_chooser.d.ts +6 -6
  931. package/dist/es2017/core/adaptive/guess_based_chooser.js +8 -7
  932. package/dist/es2017/core/adaptive/index.d.ts +2 -2
  933. package/dist/es2017/core/adaptive/network_analyzer.d.ts +6 -6
  934. package/dist/es2017/core/adaptive/network_analyzer.js +45 -41
  935. package/dist/es2017/core/adaptive/utils/bandwidth_estimator.js +1 -1
  936. package/dist/es2017/core/adaptive/utils/ewma.js +1 -2
  937. package/dist/es2017/core/adaptive/utils/filter_by_bitrate.d.ts +2 -2
  938. package/dist/es2017/core/adaptive/utils/filter_by_resolution.d.ts +2 -2
  939. package/dist/es2017/core/adaptive/utils/filter_by_resolution.js +2 -4
  940. package/dist/es2017/core/adaptive/utils/get_buffer_levels.js +8 -5
  941. package/dist/es2017/core/adaptive/utils/last_estimate_storage.d.ts +3 -3
  942. package/dist/es2017/core/adaptive/utils/pending_requests_store.d.ts +5 -5
  943. package/dist/es2017/core/adaptive/utils/pending_requests_store.js +5 -6
  944. package/dist/es2017/core/adaptive/utils/representation_score_calculator.d.ts +7 -7
  945. package/dist/es2017/core/adaptive/utils/representation_score_calculator.js +10 -8
  946. package/dist/es2017/core/adaptive/utils/select_optimal_representation.d.ts +4 -4
  947. package/dist/es2017/core/adaptive/utils/select_optimal_representation.js +2 -2
  948. package/dist/es2017/core/fetchers/cdn_prioritizer.d.ts +2 -2
  949. package/dist/es2017/core/fetchers/cdn_prioritizer.js +5 -6
  950. package/dist/es2017/core/fetchers/manifest/index.d.ts +1 -1
  951. package/dist/es2017/core/fetchers/manifest/manifest_fetcher.d.ts +3 -3
  952. package/dist/es2017/core/fetchers/manifest/manifest_fetcher.js +76 -76
  953. package/dist/es2017/core/fetchers/segment/index.d.ts +1 -1
  954. package/dist/es2017/core/fetchers/segment/initialization_segment_cache.d.ts +42 -0
  955. package/dist/es2017/core/fetchers/segment/initialization_segment_cache.js +48 -0
  956. package/dist/es2017/core/fetchers/segment/prioritized_segment_fetcher.d.ts +4 -3
  957. package/dist/es2017/core/fetchers/segment/segment_fetcher.d.ts +12 -12
  958. package/dist/es2017/core/fetchers/segment/segment_fetcher.js +54 -39
  959. package/dist/es2017/core/fetchers/segment/segment_fetcher_creator.d.ts +5 -5
  960. package/dist/es2017/core/fetchers/segment/segment_fetcher_creator.js +5 -3
  961. package/dist/es2017/core/fetchers/segment/task_prioritizer.d.ts +1 -1
  962. package/dist/es2017/core/fetchers/segment/task_prioritizer.js +22 -21
  963. package/dist/es2017/core/fetchers/utils/error_selector.d.ts +1 -2
  964. package/dist/es2017/core/fetchers/utils/error_selector.js +2 -2
  965. package/dist/es2017/core/fetchers/utils/schedule_request.d.ts +3 -3
  966. package/dist/es2017/core/fetchers/utils/schedule_request.js +23 -23
  967. package/dist/es2017/core/main/common/DecipherabilityFreezeDetector.d.ts +79 -0
  968. package/dist/es2017/core/main/common/DecipherabilityFreezeDetector.js +91 -0
  969. package/dist/es2017/core/main/common/content_time_boundaries_observer.d.ts +191 -0
  970. package/dist/es2017/core/main/common/content_time_boundaries_observer.js +467 -0
  971. package/dist/es2017/core/main/common/create_content_time_boundaries_observer.d.ts +27 -0
  972. package/dist/es2017/core/main/common/create_content_time_boundaries_observer.js +41 -0
  973. package/dist/es2017/core/main/common/get_buffered_data_per_media_buffer.d.ts +14 -0
  974. package/dist/es2017/core/main/common/get_buffered_data_per_media_buffer.js +34 -0
  975. package/dist/es2017/core/main/worker/content_preparer.d.ts +93 -0
  976. package/dist/es2017/core/main/worker/content_preparer.js +239 -0
  977. package/dist/es2017/core/main/worker/globals.d.ts +13 -0
  978. package/dist/es2017/core/main/worker/globals.js +18 -0
  979. package/dist/es2017/core/main/worker/index.d.ts +2 -0
  980. package/dist/es2017/core/main/worker/index.js +2 -0
  981. package/dist/es2017/core/main/worker/send_message.d.ts +3 -0
  982. package/dist/es2017/core/main/worker/send_message.js +20 -0
  983. package/dist/es2017/core/main/worker/track_choice_setter.d.ts +19 -0
  984. package/dist/es2017/core/main/worker/track_choice_setter.js +114 -0
  985. package/dist/es2017/core/main/worker/worker_main.d.ts +1 -0
  986. package/dist/es2017/core/main/worker/worker_main.js +702 -0
  987. package/dist/es2017/core/main/worker/worker_text_displayer_interface.d.ts +64 -0
  988. package/dist/es2017/core/main/worker/worker_text_displayer_interface.js +120 -0
  989. package/dist/es2017/core/segment_sinks/garbage_collector.d.ts +43 -0
  990. package/dist/es2017/core/segment_sinks/garbage_collector.js +143 -0
  991. package/dist/es2017/core/segment_sinks/implementations/audio_video/audio_video_segment_buffer.d.ts +135 -0
  992. package/dist/es2017/core/segment_sinks/implementations/audio_video/audio_video_segment_buffer.js +265 -0
  993. package/dist/es2017/core/segment_sinks/implementations/audio_video/index.d.ts +17 -0
  994. package/dist/es2017/core/segment_sinks/implementations/audio_video/index.js +17 -0
  995. package/dist/es2017/core/segment_sinks/implementations/index.d.ts +19 -0
  996. package/dist/es2017/core/segment_sinks/implementations/index.js +18 -0
  997. package/dist/es2017/core/segment_sinks/implementations/text/index.d.ts +3 -0
  998. package/dist/es2017/core/segment_sinks/implementations/text/index.js +2 -0
  999. package/dist/es2017/core/segment_sinks/implementations/text/text_segment_buffer.d.ts +90 -0
  1000. package/dist/es2017/core/segment_sinks/implementations/text/text_segment_buffer.js +156 -0
  1001. package/dist/es2017/core/segment_sinks/implementations/types.d.ts +307 -0
  1002. package/dist/es2017/core/segment_sinks/implementations/types.js +112 -0
  1003. package/dist/es2017/core/segment_sinks/implementations/utils/manual_time_ranges.js +63 -0
  1004. package/dist/es2017/core/segment_sinks/index.d.ts +21 -0
  1005. package/dist/es2017/core/segment_sinks/index.js +21 -0
  1006. package/dist/es2017/core/segment_sinks/inventory/buffered_history.d.ts +89 -0
  1007. package/dist/es2017/core/segment_sinks/inventory/buffered_history.js +88 -0
  1008. package/dist/es2017/core/segment_sinks/inventory/index.d.ts +21 -0
  1009. package/dist/es2017/core/segment_sinks/inventory/index.js +18 -0
  1010. package/dist/es2017/core/segment_sinks/inventory/segment_inventory.d.ts +238 -0
  1011. package/dist/es2017/core/segment_sinks/inventory/segment_inventory.js +868 -0
  1012. package/dist/es2017/core/segment_sinks/inventory/types.d.ts +27 -0
  1013. package/dist/es2017/core/segment_sinks/inventory/utils.d.ts +33 -0
  1014. package/dist/es2017/core/segment_sinks/inventory/utils.js +48 -0
  1015. package/dist/es2017/core/segment_sinks/segment_buffers_store.d.ts +171 -0
  1016. package/dist/es2017/core/segment_sinks/segment_buffers_store.js +281 -0
  1017. package/dist/es2017/core/stream/adaptation/adaptation_stream.d.ts +4 -4
  1018. package/dist/es2017/core/stream/adaptation/adaptation_stream.js +53 -35
  1019. package/dist/es2017/core/stream/adaptation/get_representations_switch_strategy.d.ts +23 -9
  1020. package/dist/es2017/core/stream/adaptation/get_representations_switch_strategy.js +51 -79
  1021. package/dist/es2017/core/stream/adaptation/types.d.ts +34 -45
  1022. package/dist/es2017/core/stream/index.d.ts +3 -2
  1023. package/dist/es2017/core/stream/orchestrator/get_time_ranges_for_content.d.ts +8 -8
  1024. package/dist/es2017/core/stream/orchestrator/get_time_ranges_for_content.js +6 -7
  1025. package/dist/es2017/core/stream/orchestrator/stream_orchestrator.d.ts +20 -19
  1026. package/dist/es2017/core/stream/orchestrator/stream_orchestrator.js +78 -58
  1027. package/dist/es2017/core/stream/period/period_stream.d.ts +5 -5
  1028. package/dist/es2017/core/stream/period/period_stream.js +119 -65
  1029. package/dist/es2017/core/stream/period/types.d.ts +29 -20
  1030. package/dist/es2017/core/stream/period/utils/get_adaptation_switch_strategy.d.ts +13 -13
  1031. package/dist/es2017/core/stream/period/utils/get_adaptation_switch_strategy.js +60 -93
  1032. package/dist/es2017/core/stream/representation/representation_stream.d.ts +5 -5
  1033. package/dist/es2017/core/stream/representation/representation_stream.js +50 -35
  1034. package/dist/es2017/core/stream/representation/types.d.ts +52 -25
  1035. package/dist/es2017/core/stream/representation/utils/append_segment_to_buffer.d.ts +12 -9
  1036. package/dist/es2017/core/stream/representation/utils/append_segment_to_buffer.js +35 -19
  1037. package/dist/es2017/core/stream/representation/utils/check_for_discontinuity.d.ts +7 -7
  1038. package/dist/es2017/core/stream/representation/utils/check_for_discontinuity.js +16 -18
  1039. package/dist/es2017/core/stream/representation/utils/downloading_queue.d.ts +10 -10
  1040. package/dist/es2017/core/stream/representation/utils/downloading_queue.js +11 -11
  1041. package/dist/es2017/core/stream/representation/utils/get_buffer_status.d.ts +11 -11
  1042. package/dist/es2017/core/stream/representation/utils/get_buffer_status.js +57 -38
  1043. package/dist/es2017/core/stream/representation/utils/get_needed_segments.d.ts +7 -8
  1044. package/dist/es2017/core/stream/representation/utils/get_needed_segments.js +28 -37
  1045. package/dist/es2017/core/stream/representation/utils/push_init_segment.d.ts +14 -12
  1046. package/dist/es2017/core/stream/representation/utils/push_init_segment.js +8 -10
  1047. package/dist/es2017/core/stream/representation/utils/push_media_segment.d.ts +15 -13
  1048. package/dist/es2017/core/stream/representation/utils/push_media_segment.js +14 -16
  1049. package/dist/es2017/core/types.d.ts +8 -0
  1050. package/dist/es2017/default_config.d.ts +31 -34
  1051. package/dist/es2017/default_config.js +61 -61
  1052. package/dist/es2017/errors/encrypted_media_error.d.ts +19 -2
  1053. package/dist/es2017/errors/encrypted_media_error.js +16 -1
  1054. package/dist/es2017/errors/error_codes.d.ts +4 -3
  1055. package/dist/es2017/errors/error_codes.js +3 -7
  1056. package/dist/es2017/errors/format_error.d.ts +2 -2
  1057. package/dist/es2017/errors/format_error.js +2 -3
  1058. package/dist/es2017/errors/index.d.ts +7 -8
  1059. package/dist/es2017/errors/index.js +2 -3
  1060. package/dist/es2017/errors/is_known_error.d.ts +1 -1
  1061. package/dist/es2017/errors/is_known_error.js +2 -2
  1062. package/dist/es2017/errors/media_error.d.ts +22 -19
  1063. package/dist/es2017/errors/media_error.js +18 -20
  1064. package/dist/es2017/errors/network_error.d.ts +16 -2
  1065. package/dist/es2017/errors/network_error.js +17 -3
  1066. package/dist/es2017/errors/other_error.d.ts +15 -1
  1067. package/dist/es2017/errors/other_error.js +11 -1
  1068. package/dist/es2017/errors/source_buffer_error.d.ts +40 -0
  1069. package/dist/es2017/errors/source_buffer_error.js +43 -0
  1070. package/dist/es2017/errors/worker_initialization_error.d.ts +19 -0
  1071. package/dist/es2017/errors/worker_initialization_error.js +22 -0
  1072. package/dist/es2017/experimental/features/index.d.ts +1 -2
  1073. package/dist/es2017/experimental/features/index.js +1 -2
  1074. package/dist/es2017/experimental/features/local.d.ts +1 -1
  1075. package/dist/es2017/experimental/features/local.js +4 -3
  1076. package/dist/es2017/experimental/features/metaplaylist.d.ts +1 -1
  1077. package/dist/es2017/experimental/features/metaplaylist.js +4 -3
  1078. package/dist/es2017/experimental/features/multi_thread.d.ts +8 -0
  1079. package/dist/es2017/experimental/features/multi_thread.js +10 -0
  1080. package/dist/es2017/experimental/index.d.ts +1 -1
  1081. package/dist/es2017/experimental/index.js +1 -1
  1082. package/dist/es2017/experimental/tools/VideoThumbnailLoader/features/dash.d.ts +1 -1
  1083. package/dist/es2017/experimental/tools/VideoThumbnailLoader/features/metaplaylist.d.ts +1 -1
  1084. package/dist/es2017/experimental/tools/VideoThumbnailLoader/index.d.ts +1 -1
  1085. package/dist/es2017/experimental/tools/VideoThumbnailLoader/index.js +2 -2
  1086. package/dist/es2017/experimental/tools/VideoThumbnailLoader/load_and_push_segment.d.ts +5 -5
  1087. package/dist/es2017/experimental/tools/VideoThumbnailLoader/load_and_push_segment.js +11 -15
  1088. package/dist/es2017/experimental/tools/VideoThumbnailLoader/prepare_source_buffer.d.ts +4 -4
  1089. package/dist/es2017/experimental/tools/VideoThumbnailLoader/prepare_source_buffer.js +29 -22
  1090. package/dist/es2017/experimental/tools/VideoThumbnailLoader/remove_buffer_around_time.d.ts +3 -5
  1091. package/dist/es2017/experimental/tools/VideoThumbnailLoader/remove_buffer_around_time.js +6 -7
  1092. package/dist/es2017/experimental/tools/VideoThumbnailLoader/types.d.ts +6 -6
  1093. package/dist/es2017/experimental/tools/VideoThumbnailLoader/video_thumbnail_loader.d.ts +3 -3
  1094. package/dist/es2017/experimental/tools/VideoThumbnailLoader/video_thumbnail_loader.js +29 -32
  1095. package/dist/es2017/experimental/tools/createMetaplaylist/get_duration_from_manifest.js +13 -23
  1096. package/dist/es2017/experimental/tools/createMetaplaylist/index.d.ts +1 -1
  1097. package/dist/es2017/experimental/tools/createMetaplaylist/index.js +8 -14
  1098. package/dist/es2017/experimental/tools/index.d.ts +1 -2
  1099. package/dist/es2017/experimental/tools/index.js +1 -2
  1100. package/dist/es2017/experimental/tools/mediaCapabilitiesProber/api/index.d.ts +1 -1
  1101. package/dist/es2017/experimental/tools/mediaCapabilitiesProber/api/index.js +9 -13
  1102. package/dist/es2017/experimental/tools/mediaCapabilitiesProber/api/probeMediaConfiguration.d.ts +4 -3
  1103. package/dist/es2017/experimental/tools/mediaCapabilitiesProber/api/probeMediaConfiguration.js +7 -4
  1104. package/dist/es2017/experimental/tools/mediaCapabilitiesProber/capabilities.d.ts +1 -1
  1105. package/dist/es2017/experimental/tools/mediaCapabilitiesProber/capabilities.js +10 -47
  1106. package/dist/es2017/experimental/tools/mediaCapabilitiesProber/index.d.ts +2 -0
  1107. package/dist/es2017/experimental/tools/mediaCapabilitiesProber/probers/DRMInfos.d.ts +2 -1
  1108. package/dist/es2017/experimental/tools/mediaCapabilitiesProber/probers/DRMInfos.js +9 -6
  1109. package/dist/es2017/experimental/tools/mediaCapabilitiesProber/probers/HDCPPolicy.d.ts +2 -1
  1110. package/dist/es2017/experimental/tools/mediaCapabilitiesProber/probers/HDCPPolicy.js +22 -14
  1111. package/dist/es2017/experimental/tools/mediaCapabilitiesProber/probers/decodingInfo.d.ts +2 -1
  1112. package/dist/es2017/experimental/tools/mediaCapabilitiesProber/probers/decodingInfo.js +26 -22
  1113. package/dist/es2017/experimental/tools/mediaCapabilitiesProber/probers/defaultCodecsFinder.js +10 -10
  1114. package/dist/es2017/experimental/tools/mediaCapabilitiesProber/probers/index.d.ts +1 -1
  1115. package/dist/es2017/experimental/tools/mediaCapabilitiesProber/probers/mediaContentType.d.ts +2 -1
  1116. package/dist/es2017/experimental/tools/mediaCapabilitiesProber/probers/mediaContentType.js +6 -7
  1117. package/dist/es2017/experimental/tools/mediaCapabilitiesProber/probers/mediaContentTypeWithFeatures/format.d.ts +1 -1
  1118. package/dist/es2017/experimental/tools/mediaCapabilitiesProber/probers/mediaContentTypeWithFeatures/format.js +6 -11
  1119. package/dist/es2017/experimental/tools/mediaCapabilitiesProber/probers/mediaContentTypeWithFeatures/index.d.ts +2 -1
  1120. package/dist/es2017/experimental/tools/mediaCapabilitiesProber/probers/mediaContentTypeWithFeatures/index.js +3 -4
  1121. package/dist/es2017/experimental/tools/mediaCapabilitiesProber/probers/mediaDisplayInfos.d.ts +2 -1
  1122. package/dist/es2017/experimental/tools/mediaCapabilitiesProber/probers/mediaDisplayInfos.js +5 -5
  1123. package/dist/es2017/experimental/tools/mediaCapabilitiesProber/types.d.ts +2 -2
  1124. package/dist/es2017/experimental/tools/mediaCapabilitiesProber/utils.d.ts +1 -1
  1125. package/dist/es2017/experimental/tools/mediaCapabilitiesProber/utils.js +8 -7
  1126. package/dist/es2017/features/add_features.d.ts +1 -1
  1127. package/dist/es2017/features/features_object.d.ts +1 -1
  1128. package/dist/es2017/features/features_object.js +9 -6
  1129. package/dist/es2017/features/index.d.ts +1 -1
  1130. package/dist/es2017/features/index.js +1 -1
  1131. package/dist/es2017/features/list/dash.d.ts +1 -1
  1132. package/dist/es2017/features/list/dash.js +6 -5
  1133. package/dist/es2017/features/list/dash_wasm.d.ts +23 -0
  1134. package/dist/es2017/features/list/dash_wasm.js +35 -0
  1135. package/dist/es2017/features/list/debug_element.d.ts +8 -0
  1136. package/dist/es2017/features/list/debug_element.js +10 -0
  1137. package/dist/es2017/features/list/directfile.d.ts +1 -1
  1138. package/dist/es2017/features/list/directfile.js +3 -5
  1139. package/dist/es2017/features/list/eme.d.ts +1 -1
  1140. package/dist/es2017/features/list/eme.js +1 -1
  1141. package/dist/es2017/features/list/html_sami_parser.d.ts +1 -1
  1142. package/dist/es2017/features/list/html_sami_parser.js +2 -2
  1143. package/dist/es2017/features/list/html_srt_parser.d.ts +1 -1
  1144. package/dist/es2017/features/list/html_srt_parser.js +2 -2
  1145. package/dist/es2017/features/list/html_text_buffer.d.ts +1 -1
  1146. package/dist/es2017/features/list/html_text_buffer.js +2 -2
  1147. package/dist/es2017/features/list/html_ttml_parser.d.ts +1 -1
  1148. package/dist/es2017/features/list/html_ttml_parser.js +2 -2
  1149. package/dist/es2017/features/list/html_vtt_parser.d.ts +1 -1
  1150. package/dist/es2017/features/list/html_vtt_parser.js +2 -2
  1151. package/dist/es2017/features/list/index.d.ts +3 -0
  1152. package/dist/es2017/features/list/index.js +3 -0
  1153. package/dist/es2017/features/list/media_source_main.d.ts +8 -0
  1154. package/dist/es2017/features/list/media_source_main.js +10 -0
  1155. package/dist/es2017/features/list/native_sami_parser.d.ts +1 -1
  1156. package/dist/es2017/features/list/native_sami_parser.js +2 -3
  1157. package/dist/es2017/features/list/native_srt_parser.d.ts +1 -1
  1158. package/dist/es2017/features/list/native_srt_parser.js +2 -3
  1159. package/dist/es2017/features/list/native_text_buffer.d.ts +1 -1
  1160. package/dist/es2017/features/list/native_text_buffer.js +2 -3
  1161. package/dist/es2017/features/list/native_ttml_parser.d.ts +1 -1
  1162. package/dist/es2017/features/list/native_ttml_parser.js +2 -3
  1163. package/dist/es2017/features/list/native_vtt_parser.d.ts +1 -1
  1164. package/dist/es2017/features/list/native_vtt_parser.js +2 -3
  1165. package/dist/es2017/features/list/smooth.d.ts +2 -2
  1166. package/dist/es2017/features/list/smooth.js +8 -5
  1167. package/dist/es2017/features/types.d.ts +52 -24
  1168. package/dist/es2017/index.d.ts +1 -1
  1169. package/dist/es2017/index.js +3 -1
  1170. package/dist/es2017/main_thread/api/debug/buffer_graph.d.ts +28 -0
  1171. package/dist/es2017/main_thread/api/debug/buffer_graph.js +164 -0
  1172. package/dist/es2017/main_thread/api/debug/buffer_size_graph.js +102 -0
  1173. package/dist/es2017/main_thread/api/debug/modules/general_info.d.ts +3 -0
  1174. package/dist/es2017/main_thread/api/debug/modules/general_info.js +192 -0
  1175. package/dist/es2017/main_thread/api/debug/modules/segment_buffer_content.d.ts +4 -0
  1176. package/dist/es2017/main_thread/api/debug/modules/segment_buffer_content.js +124 -0
  1177. package/dist/es2017/main_thread/api/debug/modules/segment_buffer_size.d.ts +3 -0
  1178. package/dist/es2017/main_thread/api/debug/modules/segment_buffer_size.js +35 -0
  1179. package/dist/es2017/main_thread/api/debug/render.d.ts +3 -0
  1180. package/dist/es2017/main_thread/api/debug/render.js +32 -0
  1181. package/dist/es2017/main_thread/api/debug/utils.js +54 -0
  1182. package/dist/es2017/main_thread/api/index.d.ts +17 -0
  1183. package/dist/es2017/main_thread/api/index.js +17 -0
  1184. package/dist/es2017/main_thread/api/option_utils.d.ts +124 -0
  1185. package/dist/es2017/main_thread/api/option_utils.js +308 -0
  1186. package/dist/es2017/main_thread/api/public_api.d.ts +751 -0
  1187. package/dist/es2017/main_thread/api/public_api.js +2347 -0
  1188. package/dist/es2017/main_thread/api/utils.d.ts +66 -0
  1189. package/dist/es2017/main_thread/api/utils.js +170 -0
  1190. package/dist/es2017/main_thread/decrypt/__tests__/__global__/utils.d.ts +184 -0
  1191. package/dist/es2017/main_thread/decrypt/__tests__/__global__/utils.js +378 -0
  1192. package/dist/es2017/main_thread/decrypt/attach_media_keys.d.ts +53 -0
  1193. package/dist/es2017/main_thread/decrypt/attach_media_keys.js +75 -0
  1194. package/dist/es2017/main_thread/decrypt/clear_on_stop.js +40 -0
  1195. package/dist/es2017/main_thread/decrypt/content_decryptor.d.ts +185 -0
  1196. package/dist/es2017/main_thread/decrypt/content_decryptor.js +799 -0
  1197. package/dist/es2017/main_thread/decrypt/create_or_load_session.d.ts +64 -0
  1198. package/dist/es2017/main_thread/decrypt/create_or_load_session.js +83 -0
  1199. package/dist/es2017/main_thread/decrypt/create_session.d.ts +54 -0
  1200. package/dist/es2017/main_thread/decrypt/create_session.js +150 -0
  1201. package/dist/es2017/main_thread/decrypt/dispose_decryption_resources.js +41 -0
  1202. package/dist/es2017/main_thread/decrypt/find_key_system.d.ts +48 -0
  1203. package/dist/es2017/main_thread/decrypt/find_key_system.js +287 -0
  1204. package/dist/es2017/main_thread/decrypt/get_media_keys.d.ts +44 -0
  1205. package/dist/es2017/main_thread/decrypt/get_media_keys.js +103 -0
  1206. package/dist/es2017/main_thread/decrypt/index.d.ts +26 -0
  1207. package/dist/es2017/main_thread/decrypt/index.js +26 -0
  1208. package/dist/es2017/main_thread/decrypt/init_media_keys.d.ts +26 -0
  1209. package/dist/es2017/main_thread/decrypt/init_media_keys.js +47 -0
  1210. package/dist/es2017/main_thread/decrypt/session_events_listener.d.ts +75 -0
  1211. package/dist/es2017/main_thread/decrypt/session_events_listener.js +246 -0
  1212. package/dist/es2017/main_thread/decrypt/set_server_certificate.d.ts +51 -0
  1213. package/dist/es2017/main_thread/decrypt/set_server_certificate.js +82 -0
  1214. package/dist/es2017/main_thread/decrypt/types.d.ts +374 -0
  1215. package/dist/es2017/main_thread/decrypt/utils/are_init_values_compatible.js +141 -0
  1216. package/dist/es2017/main_thread/decrypt/utils/check_key_statuses.d.ts +52 -0
  1217. package/dist/es2017/main_thread/decrypt/utils/check_key_statuses.js +163 -0
  1218. package/dist/es2017/main_thread/decrypt/utils/clean_old_loaded_sessions.d.ts +26 -0
  1219. package/dist/es2017/main_thread/decrypt/utils/clean_old_stored_persistent_info.d.ts +32 -0
  1220. package/dist/es2017/main_thread/decrypt/utils/init_data_values_container.d.ts +69 -0
  1221. package/dist/es2017/main_thread/decrypt/utils/init_data_values_container.js +105 -0
  1222. package/dist/es2017/main_thread/decrypt/utils/is_session_usable.d.ts +24 -0
  1223. package/dist/es2017/main_thread/decrypt/utils/is_session_usable.js +48 -0
  1224. package/dist/es2017/main_thread/decrypt/utils/key_id_comparison.js +48 -0
  1225. package/dist/es2017/main_thread/decrypt/utils/key_session_record.d.ts +104 -0
  1226. package/dist/es2017/main_thread/decrypt/utils/key_session_record.js +152 -0
  1227. package/dist/es2017/main_thread/decrypt/utils/loaded_sessions_store.d.ts +213 -0
  1228. package/dist/es2017/main_thread/decrypt/utils/loaded_sessions_store.js +365 -0
  1229. package/dist/es2017/main_thread/decrypt/utils/media_keys_infos_store.d.ts +56 -0
  1230. package/dist/es2017/main_thread/decrypt/utils/media_keys_infos_store.js +43 -0
  1231. package/dist/es2017/main_thread/decrypt/utils/persistent_sessions_store.d.ts +94 -0
  1232. package/dist/es2017/main_thread/decrypt/utils/persistent_sessions_store.js +325 -0
  1233. package/dist/es2017/main_thread/decrypt/utils/serializable_bytes.d.ts +44 -0
  1234. package/dist/es2017/main_thread/decrypt/utils/serializable_bytes.js +46 -0
  1235. package/dist/es2017/main_thread/decrypt/utils/server_certificate_store.d.ts +64 -0
  1236. package/dist/es2017/main_thread/decrypt/utils/server_certificate_store.js +121 -0
  1237. package/dist/es2017/main_thread/init/directfile_content_initializer.d.ts +97 -0
  1238. package/dist/es2017/main_thread/init/directfile_content_initializer.js +233 -0
  1239. package/dist/es2017/main_thread/init/media_source_content_initializer.d.ts +166 -0
  1240. package/dist/es2017/main_thread/init/media_source_content_initializer.js +691 -0
  1241. package/dist/es2017/main_thread/init/multi_thread_content_initializer.d.ts +167 -0
  1242. package/dist/es2017/main_thread/init/multi_thread_content_initializer.js +1369 -0
  1243. package/dist/es2017/main_thread/init/send_message.d.ts +2 -0
  1244. package/dist/es2017/main_thread/init/send_message.js +10 -0
  1245. package/dist/es2017/main_thread/init/types.d.ts +221 -0
  1246. package/dist/es2017/main_thread/init/types.js +29 -0
  1247. package/dist/es2017/main_thread/init/utils/create_core_playback_observer.d.ts +83 -0
  1248. package/dist/es2017/main_thread/init/utils/create_core_playback_observer.js +98 -0
  1249. package/dist/es2017/main_thread/init/utils/create_media_source.d.ts +37 -0
  1250. package/dist/es2017/main_thread/init/utils/create_media_source.js +101 -0
  1251. package/dist/es2017/main_thread/init/utils/get_initial_time.d.ts +76 -0
  1252. package/dist/es2017/main_thread/init/utils/get_initial_time.js +106 -0
  1253. package/dist/es2017/main_thread/init/utils/get_loaded_reference.d.ts +28 -0
  1254. package/dist/es2017/main_thread/init/utils/get_loaded_reference.js +59 -0
  1255. package/dist/es2017/main_thread/init/utils/initial_seek_and_play.d.ts +61 -0
  1256. package/dist/es2017/main_thread/init/utils/initial_seek_and_play.js +203 -0
  1257. package/dist/es2017/main_thread/init/utils/initialize_content_decryption.d.ts +87 -0
  1258. package/dist/es2017/main_thread/init/utils/initialize_content_decryption.js +116 -0
  1259. package/dist/es2017/main_thread/init/utils/main_thread_text_displayer_interface.d.ts +35 -0
  1260. package/dist/es2017/main_thread/init/utils/main_thread_text_displayer_interface.js +50 -0
  1261. package/dist/es2017/main_thread/init/utils/rebuffering_controller.d.ts +114 -0
  1262. package/dist/es2017/main_thread/init/utils/rebuffering_controller.js +426 -0
  1263. package/dist/es2017/main_thread/init/utils/stream_events_emitter/are_same_stream_events.js +33 -0
  1264. package/dist/es2017/main_thread/init/utils/stream_events_emitter/index.d.ts +18 -0
  1265. package/dist/es2017/main_thread/init/utils/stream_events_emitter/refresh_scheduled_events_list.d.ts +25 -0
  1266. package/dist/es2017/main_thread/init/utils/stream_events_emitter/refresh_scheduled_events_list.js +84 -0
  1267. package/dist/es2017/main_thread/init/utils/stream_events_emitter/stream_events_emitter.d.ts +53 -0
  1268. package/dist/es2017/main_thread/init/utils/stream_events_emitter/stream_events_emitter.js +175 -0
  1269. package/dist/es2017/main_thread/init/utils/stream_events_emitter/types.d.ts +41 -0
  1270. package/dist/es2017/main_thread/init/utils/throw_on_media_error.d.ts +23 -0
  1271. package/dist/es2017/main_thread/init/utils/throw_on_media_error.js +63 -0
  1272. package/dist/es2017/main_thread/text_displayer/html/html_parsers.d.ts +15 -0
  1273. package/dist/es2017/main_thread/text_displayer/html/html_parsers.js +22 -0
  1274. package/dist/es2017/main_thread/text_displayer/html/html_text_displayer.d.ts +100 -0
  1275. package/dist/es2017/main_thread/text_displayer/html/html_text_displayer.js +312 -0
  1276. package/dist/es2017/main_thread/text_displayer/html/index.d.ts +2 -0
  1277. package/dist/es2017/main_thread/text_displayer/html/index.js +2 -0
  1278. package/dist/es2017/main_thread/text_displayer/html/text_track_cues_store.d.ts +65 -0
  1279. package/dist/es2017/main_thread/text_displayer/html/text_track_cues_store.js +358 -0
  1280. package/dist/es2017/main_thread/text_displayer/html/update_proportional_elements.d.ts +15 -0
  1281. package/dist/es2017/main_thread/text_displayer/html/update_proportional_elements.js +61 -0
  1282. package/dist/es2017/main_thread/text_displayer/html/utils.d.ts +39 -0
  1283. package/dist/es2017/main_thread/text_displayer/html/utils.js +111 -0
  1284. package/dist/es2017/main_thread/text_displayer/index.d.ts +2 -0
  1285. package/dist/es2017/main_thread/text_displayer/manual_time_ranges.d.ts +14 -0
  1286. package/dist/es2017/main_thread/text_displayer/manual_time_ranges.js +48 -0
  1287. package/dist/es2017/main_thread/text_displayer/native/index.d.ts +2 -0
  1288. package/dist/es2017/main_thread/text_displayer/native/index.js +2 -0
  1289. package/dist/es2017/main_thread/text_displayer/native/native_parsers.d.ts +11 -0
  1290. package/dist/es2017/main_thread/text_displayer/native/native_parsers.js +22 -0
  1291. package/dist/es2017/main_thread/text_displayer/native/native_text_displayer.d.ts +56 -0
  1292. package/dist/es2017/main_thread/text_displayer/native/native_text_displayer.js +203 -0
  1293. package/dist/es2017/main_thread/text_displayer/types.d.ts +71 -0
  1294. package/dist/es2017/main_thread/tracks_store/index.d.ts +20 -0
  1295. package/dist/es2017/main_thread/tracks_store/media_element_tracks_store.d.ts +197 -0
  1296. package/dist/es2017/main_thread/tracks_store/media_element_tracks_store.js +663 -0
  1297. package/dist/es2017/main_thread/tracks_store/track_dispatcher.d.ts +101 -0
  1298. package/dist/es2017/main_thread/tracks_store/track_dispatcher.js +175 -0
  1299. package/dist/es2017/main_thread/tracks_store/tracks_store.d.ts +448 -0
  1300. package/dist/es2017/main_thread/tracks_store/tracks_store.js +998 -0
  1301. package/dist/es2017/main_thread/types.d.ts +5 -0
  1302. package/dist/es2017/main_thread/types.js +1 -0
  1303. package/dist/es2017/manifest/classes/adaptation.d.ts +134 -0
  1304. package/dist/es2017/manifest/classes/adaptation.js +193 -0
  1305. package/dist/es2017/manifest/classes/index.d.ts +25 -0
  1306. package/dist/es2017/manifest/classes/index.js +28 -0
  1307. package/dist/es2017/manifest/classes/manifest.d.ts +391 -0
  1308. package/dist/es2017/manifest/classes/manifest.js +381 -0
  1309. package/dist/es2017/manifest/classes/period.d.ts +106 -0
  1310. package/dist/es2017/manifest/classes/period.js +194 -0
  1311. package/dist/es2017/manifest/classes/representation.d.ts +238 -0
  1312. package/dist/es2017/manifest/classes/representation.js +346 -0
  1313. package/dist/es2017/manifest/classes/representation_index/index.d.ts +18 -0
  1314. package/dist/es2017/manifest/classes/representation_index/static.d.ts +101 -0
  1315. package/dist/es2017/manifest/classes/representation_index/static.js +143 -0
  1316. package/dist/es2017/manifest/classes/representation_index/types.d.ts +420 -0
  1317. package/dist/es2017/manifest/classes/types.d.ts +29 -0
  1318. package/dist/es2017/manifest/classes/update_period_in_place.d.ts +53 -0
  1319. package/dist/es2017/manifest/classes/update_period_in_place.js +109 -0
  1320. package/dist/es2017/manifest/classes/update_periods.d.ts +50 -0
  1321. package/dist/es2017/manifest/classes/update_periods.js +193 -0
  1322. package/dist/es2017/manifest/classes/utils.d.ts +39 -0
  1323. package/dist/es2017/manifest/classes/utils.js +49 -0
  1324. package/dist/es2017/manifest/index.d.ts +15 -24
  1325. package/dist/es2017/manifest/index.js +3 -28
  1326. package/dist/es2017/manifest/types.d.ts +372 -19
  1327. package/dist/es2017/manifest/types.js +1 -30
  1328. package/dist/es2017/manifest/utils.d.ts +149 -31
  1329. package/dist/es2017/manifest/utils.js +458 -30
  1330. package/dist/es2017/minimal.d.ts +4 -1
  1331. package/dist/es2017/minimal.js +12 -1
  1332. package/dist/es2017/mse/index.d.ts +1 -0
  1333. package/dist/es2017/mse/index.js +1 -0
  1334. package/dist/es2017/mse/main_codec_support_prober.d.ts +26 -0
  1335. package/dist/es2017/mse/main_codec_support_prober.js +41 -0
  1336. package/dist/es2017/mse/main_media_source_interface.d.ts +112 -0
  1337. package/dist/es2017/mse/main_media_source_interface.js +431 -0
  1338. package/dist/es2017/mse/types.d.ts +301 -0
  1339. package/dist/es2017/mse/types.js +1 -0
  1340. package/dist/es2017/mse/utils/end_of_stream.d.ts +33 -0
  1341. package/dist/es2017/mse/utils/end_of_stream.js +87 -0
  1342. package/dist/es2017/mse/utils/media_source_duration_updater.js +265 -0
  1343. package/dist/es2017/mse/worker_codec_support_prober.d.ts +42 -0
  1344. package/dist/es2017/mse/worker_codec_support_prober.js +58 -0
  1345. package/dist/es2017/mse/worker_media_source_interface.d.ts +105 -0
  1346. package/dist/es2017/mse/worker_media_source_interface.js +305 -0
  1347. package/dist/es2017/multithread_types.d.ts +815 -0
  1348. package/dist/es2017/multithread_types.js +6 -0
  1349. package/dist/es2017/parsers/containers/isobmff/create_box.d.ts +1 -1
  1350. package/dist/es2017/parsers/containers/isobmff/create_box.js +6 -5
  1351. package/dist/es2017/parsers/containers/isobmff/drm/playready.js +2 -3
  1352. package/dist/es2017/parsers/containers/isobmff/get_box.js +3 -5
  1353. package/dist/es2017/parsers/containers/isobmff/index.d.ts +3 -3
  1354. package/dist/es2017/parsers/containers/isobmff/index.js +4 -4
  1355. package/dist/es2017/parsers/containers/isobmff/read.d.ts +1 -1
  1356. package/dist/es2017/parsers/containers/isobmff/read.js +9 -9
  1357. package/dist/es2017/parsers/containers/isobmff/take_pssh_out.js +4 -5
  1358. package/dist/es2017/parsers/containers/isobmff/utils.js +60 -45
  1359. package/dist/es2017/parsers/containers/matroska/index.d.ts +1 -1
  1360. package/dist/es2017/parsers/containers/matroska/index.js +1 -1
  1361. package/dist/es2017/parsers/containers/matroska/utils.js +42 -29
  1362. package/dist/es2017/parsers/images/bif.js +10 -6
  1363. package/dist/es2017/parsers/manifest/dash/common/attach_trickmode_track.d.ts +1 -1
  1364. package/dist/es2017/parsers/manifest/dash/common/convert_supplemental_codecs.js +1 -3
  1365. package/dist/es2017/parsers/manifest/dash/common/flatten_overlapping_periods.d.ts +1 -1
  1366. package/dist/es2017/parsers/manifest/dash/common/flatten_overlapping_periods.js +1 -1
  1367. package/dist/es2017/parsers/manifest/dash/common/get_hdr_information.js +4 -12
  1368. package/dist/es2017/parsers/manifest/dash/common/get_http_utc-timing_url.d.ts +1 -1
  1369. package/dist/es2017/parsers/manifest/dash/common/get_http_utc-timing_url.js +4 -5
  1370. package/dist/es2017/parsers/manifest/dash/common/get_minimum_and_maximum_positions.d.ts +1 -1
  1371. package/dist/es2017/parsers/manifest/dash/common/get_minimum_and_maximum_positions.js +4 -2
  1372. package/dist/es2017/parsers/manifest/dash/common/get_periods_time_infos.d.ts +1 -1
  1373. package/dist/es2017/parsers/manifest/dash/common/get_periods_time_infos.js +15 -13
  1374. package/dist/es2017/parsers/manifest/dash/common/index.d.ts +1 -1
  1375. package/dist/es2017/parsers/manifest/dash/common/indexes/base.d.ts +5 -5
  1376. package/dist/es2017/parsers/manifest/dash/common/indexes/base.js +36 -31
  1377. package/dist/es2017/parsers/manifest/dash/common/indexes/get_init_segment.d.ts +2 -2
  1378. package/dist/es2017/parsers/manifest/dash/common/indexes/get_init_segment.js +6 -4
  1379. package/dist/es2017/parsers/manifest/dash/common/indexes/get_segments_from_timeline.d.ts +4 -4
  1380. package/dist/es2017/parsers/manifest/dash/common/indexes/get_segments_from_timeline.js +10 -10
  1381. package/dist/es2017/parsers/manifest/dash/common/indexes/list.d.ts +2 -2
  1382. package/dist/es2017/parsers/manifest/dash/common/indexes/list.js +23 -20
  1383. package/dist/es2017/parsers/manifest/dash/common/indexes/template.d.ts +3 -3
  1384. package/dist/es2017/parsers/manifest/dash/common/indexes/template.js +54 -59
  1385. package/dist/es2017/parsers/manifest/dash/common/indexes/timeline/construct_timeline_from_elements.d.ts +5 -4
  1386. package/dist/es2017/parsers/manifest/dash/common/indexes/timeline/construct_timeline_from_elements.js +14 -11
  1387. package/dist/es2017/parsers/manifest/dash/common/indexes/timeline/construct_timeline_from_previous_timeline.d.ts +3 -2
  1388. package/dist/es2017/parsers/manifest/dash/common/indexes/timeline/construct_timeline_from_previous_timeline.js +25 -20
  1389. package/dist/es2017/parsers/manifest/dash/common/indexes/timeline/convert_element_to_index_segment.d.ts +1 -1
  1390. package/dist/es2017/parsers/manifest/dash/common/indexes/timeline/convert_element_to_index_segment.js +15 -10
  1391. package/dist/es2017/parsers/manifest/dash/common/indexes/timeline/find_first_common_start_time.d.ts +4 -3
  1392. package/dist/es2017/parsers/manifest/dash/common/indexes/timeline/find_first_common_start_time.js +43 -27
  1393. package/dist/es2017/parsers/manifest/dash/common/indexes/timeline/parse_s_element.d.ts +11 -2
  1394. package/dist/es2017/parsers/manifest/dash/common/indexes/timeline/parse_s_element.js +49 -2
  1395. package/dist/es2017/parsers/manifest/dash/common/indexes/timeline/timeline_representation_index.d.ts +9 -8
  1396. package/dist/es2017/parsers/manifest/dash/common/indexes/timeline/timeline_representation_index.js +77 -69
  1397. package/dist/es2017/parsers/manifest/dash/common/indexes/tokens.js +2 -4
  1398. package/dist/es2017/parsers/manifest/dash/common/infer_adaptation_type.d.ts +1 -1
  1399. package/dist/es2017/parsers/manifest/dash/common/infer_adaptation_type.js +2 -2
  1400. package/dist/es2017/parsers/manifest/dash/common/manifest_bounds_calculator.js +9 -10
  1401. package/dist/es2017/parsers/manifest/dash/common/parse_adaptation_sets.d.ts +5 -5
  1402. package/dist/es2017/parsers/manifest/dash/common/parse_adaptation_sets.js +61 -66
  1403. package/dist/es2017/parsers/manifest/dash/common/parse_availability_start_time.d.ts +3 -2
  1404. package/dist/es2017/parsers/manifest/dash/common/parse_availability_start_time.js +5 -3
  1405. package/dist/es2017/parsers/manifest/dash/common/parse_mpd.d.ts +6 -6
  1406. package/dist/es2017/parsers/manifest/dash/common/parse_mpd.js +54 -42
  1407. package/dist/es2017/parsers/manifest/dash/common/parse_periods.d.ts +5 -5
  1408. package/dist/es2017/parsers/manifest/dash/common/parse_periods.js +43 -45
  1409. package/dist/es2017/parsers/manifest/dash/common/parse_representation_index.d.ts +5 -5
  1410. package/dist/es2017/parsers/manifest/dash/common/parse_representation_index.js +5 -7
  1411. package/dist/es2017/parsers/manifest/dash/common/parse_representations.d.ts +5 -5
  1412. package/dist/es2017/parsers/manifest/dash/common/parse_representations.js +63 -68
  1413. package/dist/es2017/parsers/manifest/dash/common/resolve_base_urls.d.ts +1 -1
  1414. package/dist/es2017/parsers/manifest/dash/common/resolve_base_urls.js +5 -3
  1415. package/dist/es2017/parsers/manifest/dash/fast-js-parser/index.d.ts +17 -0
  1416. package/dist/es2017/parsers/manifest/dash/fast-js-parser/index.js +17 -0
  1417. package/dist/es2017/parsers/manifest/dash/fast-js-parser/node_parsers/AdaptationSet.d.ts +24 -0
  1418. package/dist/es2017/parsers/manifest/dash/fast-js-parser/node_parsers/AdaptationSet.js +358 -0
  1419. package/dist/es2017/parsers/manifest/dash/fast-js-parser/node_parsers/BaseURL.d.ts +24 -0
  1420. package/dist/es2017/parsers/manifest/dash/fast-js-parser/node_parsers/BaseURL.js +30 -0
  1421. package/dist/es2017/parsers/manifest/dash/fast-js-parser/node_parsers/ContentComponent.d.ts +23 -0
  1422. package/dist/es2017/parsers/manifest/dash/fast-js-parser/node_parsers/ContentComponent.js +45 -0
  1423. package/dist/es2017/parsers/manifest/dash/fast-js-parser/node_parsers/ContentProtection.d.ts +22 -0
  1424. package/dist/es2017/parsers/manifest/dash/fast-js-parser/node_parsers/ContentProtection.js +77 -0
  1425. package/dist/es2017/parsers/manifest/dash/fast-js-parser/node_parsers/EventStream.d.ts +23 -0
  1426. package/dist/es2017/parsers/manifest/dash/fast-js-parser/node_parsers/EventStream.js +101 -0
  1427. package/dist/es2017/parsers/manifest/dash/fast-js-parser/node_parsers/Initialization.d.ts +22 -0
  1428. package/dist/es2017/parsers/manifest/dash/fast-js-parser/node_parsers/Initialization.js +45 -0
  1429. package/dist/es2017/parsers/manifest/dash/fast-js-parser/node_parsers/MPD.d.ts +23 -0
  1430. package/dist/es2017/parsers/manifest/dash/fast-js-parser/node_parsers/MPD.js +179 -0
  1431. package/dist/es2017/parsers/manifest/dash/fast-js-parser/node_parsers/Period.d.ts +23 -0
  1432. package/dist/es2017/parsers/manifest/dash/fast-js-parser/node_parsers/Period.js +137 -0
  1433. package/dist/es2017/parsers/manifest/dash/fast-js-parser/node_parsers/Representation.d.ts +22 -0
  1434. package/dist/es2017/parsers/manifest/dash/fast-js-parser/node_parsers/Representation.js +214 -0
  1435. package/dist/es2017/parsers/manifest/dash/fast-js-parser/node_parsers/SegmentBase.d.ts +23 -0
  1436. package/dist/es2017/parsers/manifest/dash/fast-js-parser/node_parsers/SegmentBase.js +111 -0
  1437. package/dist/es2017/parsers/manifest/dash/fast-js-parser/node_parsers/SegmentList.d.ts +22 -0
  1438. package/dist/es2017/parsers/manifest/dash/fast-js-parser/node_parsers/SegmentList.js +41 -0
  1439. package/dist/es2017/parsers/manifest/dash/fast-js-parser/node_parsers/SegmentTemplate.d.ts +24 -0
  1440. package/dist/es2017/parsers/manifest/dash/fast-js-parser/node_parsers/SegmentTemplate.js +84 -0
  1441. package/dist/es2017/parsers/manifest/dash/fast-js-parser/node_parsers/SegmentTimeline.d.ts +22 -0
  1442. package/dist/es2017/parsers/manifest/dash/fast-js-parser/node_parsers/SegmentTimeline.js +33 -0
  1443. package/dist/es2017/parsers/manifest/dash/fast-js-parser/node_parsers/SegmentURL.d.ts +24 -0
  1444. package/dist/es2017/parsers/manifest/dash/fast-js-parser/node_parsers/SegmentURL.js +57 -0
  1445. package/dist/es2017/parsers/manifest/dash/fast-js-parser/node_parsers/utils.d.ts +176 -0
  1446. package/dist/es2017/parsers/manifest/dash/fast-js-parser/node_parsers/utils.js +310 -0
  1447. package/dist/es2017/parsers/manifest/dash/fast-js-parser/parse_from_xml_string.d.ts +24 -0
  1448. package/dist/es2017/parsers/manifest/dash/fast-js-parser/parse_from_xml_string.js +114 -0
  1449. package/dist/es2017/parsers/manifest/dash/native-parser/node_parsers/AdaptationSet.d.ts +23 -0
  1450. package/dist/es2017/parsers/manifest/dash/native-parser/node_parsers/AdaptationSet.js +354 -0
  1451. package/dist/es2017/parsers/manifest/dash/native-parser/node_parsers/BaseURL.d.ts +23 -0
  1452. package/dist/es2017/parsers/manifest/dash/native-parser/node_parsers/BaseURL.js +29 -0
  1453. package/dist/es2017/parsers/manifest/dash/native-parser/node_parsers/ContentComponent.d.ts +22 -0
  1454. package/dist/es2017/parsers/manifest/dash/native-parser/node_parsers/ContentProtection.d.ts +21 -0
  1455. package/dist/es2017/parsers/manifest/dash/native-parser/node_parsers/EventStream.d.ts +23 -0
  1456. package/dist/es2017/parsers/manifest/dash/native-parser/node_parsers/EventStream.js +100 -0
  1457. package/dist/es2017/parsers/manifest/dash/native-parser/node_parsers/Initialization.d.ts +21 -0
  1458. package/dist/es2017/parsers/manifest/dash/native-parser/node_parsers/Initialization.js +41 -0
  1459. package/dist/es2017/parsers/manifest/dash/native-parser/node_parsers/MPD.d.ts +21 -0
  1460. package/dist/es2017/parsers/manifest/dash/native-parser/node_parsers/MPD.js +161 -0
  1461. package/dist/es2017/parsers/manifest/dash/native-parser/node_parsers/Period.d.ts +21 -0
  1462. package/dist/es2017/parsers/manifest/dash/native-parser/node_parsers/Period.js +118 -0
  1463. package/dist/es2017/parsers/manifest/dash/native-parser/node_parsers/Representation.d.ts +21 -0
  1464. package/dist/es2017/parsers/manifest/dash/native-parser/node_parsers/Representation.js +210 -0
  1465. package/dist/es2017/parsers/manifest/dash/native-parser/node_parsers/SegmentBase.d.ts +22 -0
  1466. package/dist/es2017/parsers/manifest/dash/native-parser/node_parsers/SegmentBase.js +107 -0
  1467. package/dist/es2017/parsers/manifest/dash/native-parser/node_parsers/SegmentList.d.ts +21 -0
  1468. package/dist/es2017/parsers/manifest/dash/native-parser/node_parsers/SegmentTemplate.d.ts +23 -0
  1469. package/dist/es2017/parsers/manifest/dash/native-parser/node_parsers/SegmentTemplate.js +83 -0
  1470. package/dist/es2017/parsers/manifest/dash/native-parser/node_parsers/SegmentTimeline.d.ts +21 -0
  1471. package/dist/es2017/parsers/manifest/dash/native-parser/node_parsers/SegmentURL.d.ts +23 -0
  1472. package/dist/es2017/parsers/manifest/dash/native-parser/node_parsers/SegmentURL.js +53 -0
  1473. package/dist/es2017/parsers/manifest/dash/native-parser/node_parsers/utils.d.ts +169 -0
  1474. package/dist/es2017/parsers/manifest/dash/native-parser/node_parsers/utils.js +297 -0
  1475. package/dist/es2017/parsers/manifest/dash/native-parser/parse_from_document.d.ts +24 -0
  1476. package/dist/es2017/parsers/manifest/dash/native-parser/parse_from_document.js +108 -0
  1477. package/dist/es2017/parsers/manifest/dash/node_parser_types.d.ts +5 -3
  1478. package/dist/es2017/parsers/manifest/dash/parsers_types.d.ts +1 -1
  1479. package/dist/es2017/parsers/manifest/dash/wasm-parser/ts/dash-wasm-parser.d.ts +2 -2
  1480. package/dist/es2017/parsers/manifest/dash/wasm-parser/ts/dash-wasm-parser.js +49 -22
  1481. package/dist/es2017/parsers/manifest/dash/wasm-parser/ts/generators/AdaptationSet.d.ts +3 -2
  1482. package/dist/es2017/parsers/manifest/dash/wasm-parser/ts/generators/AdaptationSet.js +22 -26
  1483. package/dist/es2017/parsers/manifest/dash/wasm-parser/ts/generators/BaseURL.d.ts +2 -2
  1484. package/dist/es2017/parsers/manifest/dash/wasm-parser/ts/generators/ContentComponent.d.ts +3 -3
  1485. package/dist/es2017/parsers/manifest/dash/wasm-parser/ts/generators/ContentComponent.js +1 -1
  1486. package/dist/es2017/parsers/manifest/dash/wasm-parser/ts/generators/ContentProtection.d.ts +3 -3
  1487. package/dist/es2017/parsers/manifest/dash/wasm-parser/ts/generators/ContentProtection.js +4 -2
  1488. package/dist/es2017/parsers/manifest/dash/wasm-parser/ts/generators/EventStream.d.ts +3 -2
  1489. package/dist/es2017/parsers/manifest/dash/wasm-parser/ts/generators/EventStream.js +2 -4
  1490. package/dist/es2017/parsers/manifest/dash/wasm-parser/ts/generators/MPD.d.ts +3 -2
  1491. package/dist/es2017/parsers/manifest/dash/wasm-parser/ts/generators/MPD.js +5 -5
  1492. package/dist/es2017/parsers/manifest/dash/wasm-parser/ts/generators/Period.d.ts +3 -2
  1493. package/dist/es2017/parsers/manifest/dash/wasm-parser/ts/generators/Period.js +9 -6
  1494. package/dist/es2017/parsers/manifest/dash/wasm-parser/ts/generators/Representation.d.ts +3 -2
  1495. package/dist/es2017/parsers/manifest/dash/wasm-parser/ts/generators/Representation.js +13 -15
  1496. package/dist/es2017/parsers/manifest/dash/wasm-parser/ts/generators/Scheme.d.ts +3 -3
  1497. package/dist/es2017/parsers/manifest/dash/wasm-parser/ts/generators/Scheme.js +1 -1
  1498. package/dist/es2017/parsers/manifest/dash/wasm-parser/ts/generators/SegmentBase.d.ts +2 -2
  1499. package/dist/es2017/parsers/manifest/dash/wasm-parser/ts/generators/SegmentBase.js +5 -10
  1500. package/dist/es2017/parsers/manifest/dash/wasm-parser/ts/generators/SegmentList.d.ts +3 -2
  1501. package/dist/es2017/parsers/manifest/dash/wasm-parser/ts/generators/SegmentTemplate.d.ts +2 -2
  1502. package/dist/es2017/parsers/manifest/dash/wasm-parser/ts/generators/SegmentTemplate.js +11 -18
  1503. package/dist/es2017/parsers/manifest/dash/wasm-parser/ts/generators/SegmentUrl.d.ts +2 -2
  1504. package/dist/es2017/parsers/manifest/dash/wasm-parser/ts/generators/SegmentUrl.js +2 -4
  1505. package/dist/es2017/parsers/manifest/dash/wasm-parser/ts/generators/XLink.d.ts +3 -2
  1506. package/dist/es2017/parsers/manifest/dash/wasm-parser/ts/generators/XLink.js +5 -5
  1507. package/dist/es2017/parsers/manifest/dash/wasm-parser/ts/generators/root.d.ts +2 -2
  1508. package/dist/es2017/parsers/manifest/dash/wasm-parser/ts/generators/root.js +8 -4
  1509. package/dist/es2017/parsers/manifest/dash/wasm-parser/ts/parsers_stack.js +4 -2
  1510. package/dist/es2017/parsers/manifest/dash/wasm-parser/ts/types.d.ts +55 -55
  1511. package/dist/es2017/parsers/manifest/dash/wasm-parser/ts/utils.d.ts +1 -1
  1512. package/dist/es2017/parsers/manifest/dash/wasm-parser/ts/utils.js +8 -4
  1513. package/dist/es2017/parsers/manifest/local/parse_local_manifest.d.ts +2 -2
  1514. package/dist/es2017/parsers/manifest/local/parse_local_manifest.js +21 -16
  1515. package/dist/es2017/parsers/manifest/local/representation_index.d.ts +2 -2
  1516. package/dist/es2017/parsers/manifest/local/representation_index.js +7 -7
  1517. package/dist/es2017/parsers/manifest/metaplaylist/index.d.ts +1 -1
  1518. package/dist/es2017/parsers/manifest/metaplaylist/metaplaylist_parser.d.ts +4 -4
  1519. package/dist/es2017/parsers/manifest/metaplaylist/metaplaylist_parser.js +52 -42
  1520. package/dist/es2017/parsers/manifest/metaplaylist/representation_index.d.ts +3 -3
  1521. package/dist/es2017/parsers/manifest/metaplaylist/representation_index.js +10 -7
  1522. package/dist/es2017/parsers/manifest/smooth/create_parser.d.ts +2 -2
  1523. package/dist/es2017/parsers/manifest/smooth/create_parser.js +120 -121
  1524. package/dist/es2017/parsers/manifest/smooth/get_codecs.js +3 -3
  1525. package/dist/es2017/parsers/manifest/smooth/index.d.ts +1 -1
  1526. package/dist/es2017/parsers/manifest/smooth/index.js +1 -1
  1527. package/dist/es2017/parsers/manifest/smooth/parse_C_nodes.js +9 -9
  1528. package/dist/es2017/parsers/manifest/smooth/parse_protection_node.js +12 -8
  1529. package/dist/es2017/parsers/manifest/smooth/representation_index.d.ts +3 -3
  1530. package/dist/es2017/parsers/manifest/smooth/representation_index.js +35 -38
  1531. package/dist/es2017/parsers/manifest/smooth/shared_smooth_segment_timeline.d.ts +1 -1
  1532. package/dist/es2017/parsers/manifest/smooth/shared_smooth_segment_timeline.js +8 -9
  1533. package/dist/es2017/parsers/manifest/smooth/utils/add_segment_infos.js +10 -7
  1534. package/dist/es2017/parsers/manifest/smooth/utils/parseBoolean.d.ts +1 -1
  1535. package/dist/es2017/parsers/manifest/smooth/utils/parseBoolean.js +1 -1
  1536. package/dist/es2017/parsers/manifest/smooth/utils/tokens.d.ts +1 -1
  1537. package/dist/es2017/parsers/manifest/smooth/utils/tokens.js +2 -3
  1538. package/dist/es2017/parsers/manifest/types.d.ts +10 -3
  1539. package/dist/es2017/parsers/manifest/utils/check_manifest_ids.d.ts +1 -1
  1540. package/dist/es2017/parsers/manifest/utils/check_manifest_ids.js +2 -2
  1541. package/dist/es2017/parsers/manifest/utils/clear_timeline_from_position.d.ts +3 -2
  1542. package/dist/es2017/parsers/manifest/utils/clear_timeline_from_position.js +11 -7
  1543. package/dist/es2017/parsers/manifest/utils/get_first_time_from_adaptation.d.ts +1 -1
  1544. package/dist/es2017/parsers/manifest/utils/get_first_time_from_adaptation.js +5 -4
  1545. package/dist/es2017/parsers/manifest/utils/get_last_time_from_adaptation.d.ts +1 -1
  1546. package/dist/es2017/parsers/manifest/utils/get_last_time_from_adaptation.js +5 -4
  1547. package/dist/es2017/parsers/manifest/utils/get_maximum_positions.d.ts +2 -2
  1548. package/dist/es2017/parsers/manifest/utils/get_maximum_positions.js +11 -17
  1549. package/dist/es2017/parsers/manifest/utils/get_minimum_position.d.ts +2 -2
  1550. package/dist/es2017/parsers/manifest/utils/get_minimum_position.js +5 -11
  1551. package/dist/es2017/parsers/manifest/utils/index_helpers.js +4 -5
  1552. package/dist/es2017/parsers/manifest/utils/update_segment_timeline.d.ts +1 -1
  1553. package/dist/es2017/parsers/manifest/utils/update_segment_timeline.js +17 -16
  1554. package/dist/es2017/parsers/texttracks/index.d.ts +1 -1
  1555. package/dist/es2017/parsers/texttracks/sami/html.d.ts +1 -1
  1556. package/dist/es2017/parsers/texttracks/sami/html.js +17 -16
  1557. package/dist/es2017/parsers/texttracks/sami/native.d.ts +1 -1
  1558. package/dist/es2017/parsers/texttracks/sami/native.js +11 -17
  1559. package/dist/es2017/parsers/texttracks/srt/html.js +12 -10
  1560. package/dist/es2017/parsers/texttracks/srt/native.d.ts +1 -1
  1561. package/dist/es2017/parsers/texttracks/srt/native.js +1 -7
  1562. package/dist/es2017/parsers/texttracks/srt/parse_cue.js +4 -9
  1563. package/dist/es2017/parsers/texttracks/ttml/get_parameters.js +8 -13
  1564. package/dist/es2017/parsers/texttracks/ttml/get_time_delimiters.d.ts +1 -1
  1565. package/dist/es2017/parsers/texttracks/ttml/get_time_delimiters.js +9 -10
  1566. package/dist/es2017/parsers/texttracks/ttml/html/apply_default_ttml_paragraph_style.js +2 -2
  1567. package/dist/es2017/parsers/texttracks/ttml/html/apply_extent.js +3 -7
  1568. package/dist/es2017/parsers/texttracks/ttml/html/apply_font_size.js +4 -5
  1569. package/dist/es2017/parsers/texttracks/ttml/html/apply_line_height.js +1 -1
  1570. package/dist/es2017/parsers/texttracks/ttml/html/apply_origin.js +3 -7
  1571. package/dist/es2017/parsers/texttracks/ttml/html/apply_padding.js +3 -7
  1572. package/dist/es2017/parsers/texttracks/ttml/html/create_element.d.ts +2 -2
  1573. package/dist/es2017/parsers/texttracks/ttml/html/create_element.js +30 -23
  1574. package/dist/es2017/parsers/texttracks/ttml/html/generate_css_test_outline.js +2 -2
  1575. package/dist/es2017/parsers/texttracks/ttml/html/parse_cue.d.ts +1 -1
  1576. package/dist/es2017/parsers/texttracks/ttml/html/parse_cue.js +5 -4
  1577. package/dist/es2017/parsers/texttracks/ttml/html/parse_ttml_to_div.d.ts +1 -1
  1578. package/dist/es2017/parsers/texttracks/ttml/html/ttml_color_to_css_color.js +39 -23
  1579. package/dist/es2017/parsers/texttracks/ttml/native/parse_cue.d.ts +2 -2
  1580. package/dist/es2017/parsers/texttracks/ttml/native/parse_cue.js +14 -13
  1581. package/dist/es2017/parsers/texttracks/ttml/native/parse_ttml_to_vtt.d.ts +1 -1
  1582. package/dist/es2017/parsers/texttracks/ttml/parse_ttml.d.ts +3 -3
  1583. package/dist/es2017/parsers/texttracks/ttml/parse_ttml.js +22 -19
  1584. package/dist/es2017/parsers/texttracks/ttml/resolve_styles_inheritance.d.ts +1 -1
  1585. package/dist/es2017/parsers/texttracks/ttml/time_parsing.d.ts +1 -1
  1586. package/dist/es2017/parsers/texttracks/ttml/time_parsing.js +2 -2
  1587. package/dist/es2017/parsers/texttracks/ttml/xml_utils.js +2 -1
  1588. package/dist/es2017/parsers/texttracks/types.d.ts +1 -1
  1589. package/dist/es2017/parsers/texttracks/webvtt/get_cue_blocks.js +1 -1
  1590. package/dist/es2017/parsers/texttracks/webvtt/get_style_blocks.js +2 -1
  1591. package/dist/es2017/parsers/texttracks/webvtt/html/convert_payload_to_html.d.ts +1 -1
  1592. package/dist/es2017/parsers/texttracks/webvtt/html/create_default_style_elements.d.ts +1 -1
  1593. package/dist/es2017/parsers/texttracks/webvtt/html/create_style_attribute.js +6 -12
  1594. package/dist/es2017/parsers/texttracks/webvtt/html/create_styled_element.d.ts +1 -1
  1595. package/dist/es2017/parsers/texttracks/webvtt/html/create_styled_element.js +8 -9
  1596. package/dist/es2017/parsers/texttracks/webvtt/html/parse_style_block.js +4 -4
  1597. package/dist/es2017/parsers/texttracks/webvtt/html/parse_webvtt_to_div.d.ts +1 -1
  1598. package/dist/es2017/parsers/texttracks/webvtt/html/parse_webvtt_to_div.js +1 -1
  1599. package/dist/es2017/parsers/texttracks/webvtt/html/to_html.d.ts +1 -1
  1600. package/dist/es2017/parsers/texttracks/webvtt/html/to_html.js +5 -13
  1601. package/dist/es2017/parsers/texttracks/webvtt/native/parse_vtt_to_cues.d.ts +1 -1
  1602. package/dist/es2017/parsers/texttracks/webvtt/native/parse_vtt_to_cues.js +4 -8
  1603. package/dist/es2017/parsers/texttracks/webvtt/native/set_settings_on_cue.d.ts +1 -1
  1604. package/dist/es2017/parsers/texttracks/webvtt/native/to_native_cue.d.ts +2 -2
  1605. package/dist/es2017/parsers/texttracks/webvtt/native/to_native_cue.js +2 -2
  1606. package/dist/es2017/parsers/texttracks/webvtt/parse_cue_block.js +7 -8
  1607. package/dist/es2017/parsers/texttracks/webvtt/parse_timestamp.js +1 -2
  1608. package/dist/es2017/parsers/texttracks/webvtt/utils.js +6 -6
  1609. package/dist/es2017/playback_observer/index.d.ts +6 -0
  1610. package/dist/es2017/playback_observer/index.js +2 -0
  1611. package/dist/es2017/playback_observer/media_element_playback_observer.d.ts +203 -0
  1612. package/dist/es2017/playback_observer/media_element_playback_observer.js +678 -0
  1613. package/dist/es2017/playback_observer/types.d.ts +223 -0
  1614. package/dist/es2017/playback_observer/types.js +1 -0
  1615. package/dist/es2017/playback_observer/utils/generate_read_only_observer.d.ts +11 -0
  1616. package/dist/es2017/playback_observer/utils/generate_read_only_observer.js +41 -0
  1617. package/dist/es2017/playback_observer/utils/observation_position.d.ts +87 -0
  1618. package/dist/es2017/playback_observer/utils/observation_position.js +84 -0
  1619. package/dist/es2017/playback_observer/worker_playback_observer.d.ts +72 -0
  1620. package/dist/es2017/playback_observer/worker_playback_observer.js +45 -0
  1621. package/dist/es2017/public_types.d.ts +75 -33
  1622. package/dist/es2017/public_types.js +2 -13
  1623. package/dist/es2017/tools/TextTrackRenderer/text_track_renderer.d.ts +3 -3
  1624. package/dist/es2017/tools/TextTrackRenderer/text_track_renderer.js +19 -22
  1625. package/dist/es2017/tools/index.d.ts +2 -1
  1626. package/dist/es2017/tools/index.js +4 -2
  1627. package/dist/es2017/tools/parseBIFThumbnails/index.js +30 -0
  1628. package/dist/es2017/transports/dash/add_segment_integrity_checks_to_loader.d.ts +1 -1
  1629. package/dist/es2017/transports/dash/add_segment_integrity_checks_to_loader.js +2 -3
  1630. package/dist/es2017/transports/dash/construct_segment_url.d.ts +2 -2
  1631. package/dist/es2017/transports/dash/construct_segment_url.js +7 -3
  1632. package/dist/es2017/transports/dash/extract_complete_chunks.d.ts +1 -1
  1633. package/dist/es2017/transports/dash/extract_complete_chunks.js +13 -9
  1634. package/dist/es2017/transports/dash/get_events_out_of_emsgs.d.ts +2 -2
  1635. package/dist/es2017/transports/dash/get_events_out_of_emsgs.js +12 -11
  1636. package/dist/es2017/transports/dash/init_segment_loader.d.ts +3 -3
  1637. package/dist/es2017/transports/dash/init_segment_loader.js +29 -23
  1638. package/dist/es2017/transports/dash/low_latency_segment_loader.d.ts +2 -2
  1639. package/dist/es2017/transports/dash/low_latency_segment_loader.js +15 -12
  1640. package/dist/es2017/transports/dash/manifest_parser.d.ts +2 -2
  1641. package/dist/es2017/transports/dash/manifest_parser.js +68 -32
  1642. package/dist/es2017/transports/dash/pipelines.d.ts +1 -1
  1643. package/dist/es2017/transports/dash/pipelines.js +15 -12
  1644. package/dist/es2017/transports/dash/segment_loader.d.ts +4 -4
  1645. package/dist/es2017/transports/dash/segment_loader.js +31 -23
  1646. package/dist/es2017/transports/dash/segment_parser.d.ts +2 -2
  1647. package/dist/es2017/transports/dash/segment_parser.js +40 -25
  1648. package/dist/es2017/transports/dash/text_loader.d.ts +2 -2
  1649. package/dist/es2017/transports/dash/text_loader.js +19 -20
  1650. package/dist/es2017/transports/dash/text_parser.d.ts +2 -2
  1651. package/dist/es2017/transports/dash/text_parser.js +44 -26
  1652. package/dist/es2017/transports/index.d.ts +1 -1
  1653. package/dist/es2017/transports/index.js +1 -1
  1654. package/dist/es2017/transports/local/pipelines.d.ts +1 -1
  1655. package/dist/es2017/transports/local/pipelines.js +14 -9
  1656. package/dist/es2017/transports/local/segment_loader.d.ts +3 -3
  1657. package/dist/es2017/transports/local/segment_loader.js +14 -6
  1658. package/dist/es2017/transports/local/segment_parser.d.ts +1 -1
  1659. package/dist/es2017/transports/local/segment_parser.js +24 -14
  1660. package/dist/es2017/transports/local/text_parser.d.ts +1 -1
  1661. package/dist/es2017/transports/local/text_parser.js +36 -18
  1662. package/dist/es2017/transports/metaplaylist/manifest_loader.d.ts +4 -4
  1663. package/dist/es2017/transports/metaplaylist/manifest_loader.js +8 -6
  1664. package/dist/es2017/transports/metaplaylist/pipelines.d.ts +1 -1
  1665. package/dist/es2017/transports/metaplaylist/pipelines.js +35 -24
  1666. package/dist/es2017/transports/smooth/extract_timings_infos.d.ts +2 -2
  1667. package/dist/es2017/transports/smooth/extract_timings_infos.js +17 -19
  1668. package/dist/es2017/transports/smooth/is_mp4_embedded_track.d.ts +1 -1
  1669. package/dist/es2017/transports/smooth/is_mp4_embedded_track.js +1 -1
  1670. package/dist/es2017/transports/smooth/isobmff/create_audio_init_segment.d.ts +0 -1
  1671. package/dist/es2017/transports/smooth/isobmff/create_audio_init_segment.js +3 -4
  1672. package/dist/es2017/transports/smooth/isobmff/create_boxes.js +23 -32
  1673. package/dist/es2017/transports/smooth/isobmff/create_init_segment.js +2 -2
  1674. package/dist/es2017/transports/smooth/isobmff/create_traf_box.js +2 -2
  1675. package/dist/es2017/transports/smooth/isobmff/get_aaces_header.js +4 -16
  1676. package/dist/es2017/transports/smooth/isobmff/parse_tfrf.js +2 -2
  1677. package/dist/es2017/transports/smooth/isobmff/parse_tfxd.js +1 -1
  1678. package/dist/es2017/transports/smooth/isobmff/patch_segment.js +12 -11
  1679. package/dist/es2017/transports/smooth/pipelines.d.ts +1 -1
  1680. package/dist/es2017/transports/smooth/pipelines.js +84 -61
  1681. package/dist/es2017/transports/smooth/segment_loader.d.ts +3 -3
  1682. package/dist/es2017/transports/smooth/segment_loader.js +44 -29
  1683. package/dist/es2017/transports/smooth/utils.d.ts +4 -4
  1684. package/dist/es2017/transports/smooth/utils.js +10 -6
  1685. package/dist/es2017/transports/types.d.ts +22 -27
  1686. package/dist/es2017/transports/utils/byte_range.js +1 -2
  1687. package/dist/es2017/transports/utils/call_custom_manifest_loader.d.ts +3 -3
  1688. package/dist/es2017/transports/utils/call_custom_manifest_loader.js +10 -8
  1689. package/dist/es2017/transports/utils/check_isobmff_integrity.js +3 -3
  1690. package/dist/es2017/transports/utils/find_complete_box.js +3 -2
  1691. package/dist/es2017/transports/utils/generate_manifest_loader.d.ts +3 -3
  1692. package/dist/es2017/transports/utils/generate_manifest_loader.js +13 -7
  1693. package/dist/es2017/transports/utils/get_isobmff_timing_infos.d.ts +2 -2
  1694. package/dist/es2017/transports/utils/get_isobmff_timing_infos.js +12 -11
  1695. package/dist/es2017/transports/utils/infer_segment_container.d.ts +1 -1
  1696. package/dist/es2017/transports/utils/infer_segment_container.js +1 -3
  1697. package/dist/es2017/transports/utils/parse_text_track.d.ts +4 -4
  1698. package/dist/es2017/transports/utils/parse_text_track.js +6 -16
  1699. package/dist/es2017/utils/array_includes.js +2 -6
  1700. package/dist/es2017/utils/assert.d.ts +41 -0
  1701. package/dist/es2017/utils/assert.js +50 -7
  1702. package/dist/es2017/utils/base64.js +87 -29
  1703. package/dist/es2017/utils/byte_parsing.js +64 -56
  1704. package/dist/es2017/utils/cancellable_sleep.d.ts +1 -1
  1705. package/dist/es2017/utils/create_cancellable_promise.d.ts +1 -1
  1706. package/dist/es2017/utils/deep_merge.js +4 -4
  1707. package/dist/es2017/utils/event_emitter.d.ts +1 -1
  1708. package/dist/es2017/utils/event_emitter.js +7 -2
  1709. package/dist/es2017/utils/get_fuzzed_delay.js +1 -1
  1710. package/dist/es2017/utils/global_scope.d.ts +9 -0
  1711. package/dist/es2017/utils/global_scope.js +20 -0
  1712. package/dist/es2017/utils/hash_buffer.js +1 -1
  1713. package/dist/es2017/utils/languages/ISO_639-1_to_ISO_639-3.js +182 -182
  1714. package/dist/es2017/utils/languages/ISO_639-2_to_ISO_639-3.js +19 -19
  1715. package/dist/es2017/utils/languages/normalize.js +5 -5
  1716. package/dist/es2017/utils/logger.d.ts +13 -3
  1717. package/dist/es2017/utils/logger.js +26 -20
  1718. package/dist/es2017/utils/monotonic_timestamp.d.ts +20 -4
  1719. package/dist/es2017/utils/monotonic_timestamp.js +21 -5
  1720. package/dist/es2017/utils/object_assign.d.ts +29 -5
  1721. package/dist/es2017/utils/object_assign.js +17 -8
  1722. package/dist/es2017/utils/object_values.d.ts +1 -1
  1723. package/dist/es2017/utils/object_values.js +4 -4
  1724. package/dist/es2017/utils/queue_microtask.js +3 -3
  1725. package/dist/es2017/utils/ranges.js +22 -29
  1726. package/dist/es2017/utils/reference.d.ts +1 -1
  1727. package/dist/es2017/utils/reference.js +1 -3
  1728. package/dist/es2017/utils/request/fetch.d.ts +1 -1
  1729. package/dist/es2017/utils/request/fetch.js +30 -29
  1730. package/dist/es2017/utils/request/index.d.ts +2 -1
  1731. package/dist/es2017/utils/request/index.js +2 -1
  1732. package/dist/es2017/utils/request/request_error.d.ts +47 -0
  1733. package/dist/es2017/utils/request/request_error.js +65 -0
  1734. package/dist/es2017/utils/request/xhr.d.ts +5 -5
  1735. package/dist/es2017/utils/request/xhr.js +25 -23
  1736. package/dist/es2017/utils/retry_promise_with_backoff.d.ts +11 -3
  1737. package/dist/es2017/utils/retry_promise_with_backoff.js +15 -3
  1738. package/dist/es2017/utils/slice_uint8array.js +3 -3
  1739. package/dist/es2017/utils/starts_with.js +3 -3
  1740. package/dist/es2017/utils/string_parsing.js +17 -19
  1741. package/dist/es2017/utils/sync_or_async.d.ts +70 -0
  1742. package/dist/es2017/utils/sync_or_async.js +49 -0
  1743. package/dist/es2017/utils/task_canceller.js +1 -2
  1744. package/dist/es2017/utils/wrapInPromise.d.ts +1 -1
  1745. package/dist/es2017/utils/xml-parser.d.ts +70 -0
  1746. package/dist/es2017/utils/xml-parser.js +322 -0
  1747. package/dist/es2017/worker_entry_point.d.ts +5 -0
  1748. package/dist/es2017/worker_entry_point.js +6 -0
  1749. package/dist/mpd-parser.wasm +0 -0
  1750. package/dist/rx-player.js +46134 -43766
  1751. package/dist/rx-player.min.js +1 -1
  1752. package/dist/worker.js +8 -0
  1753. package/package.json +119 -92
  1754. package/.editorconfig +0 -22
  1755. package/.eslintrc.js +0 -415
  1756. package/.github/workflows/checks.yml +0 -101
  1757. package/.github/workflows/perfs.yml +0 -22
  1758. package/.github/workflows/sonarcloud_analysis.yml +0 -20
  1759. package/CONTRIBUTING.md +0 -272
  1760. package/FILES.md +0 -277
  1761. package/dist/_esm5.processed/compat/add_class_name.d.ts +0 -22
  1762. package/dist/_esm5.processed/compat/add_class_name.js +0 -39
  1763. package/dist/_esm5.processed/compat/add_text_track.d.ts +0 -33
  1764. package/dist/_esm5.processed/compat/add_text_track.js +0 -50
  1765. package/dist/_esm5.processed/compat/browser_compatibility_types.d.ts +0 -172
  1766. package/dist/_esm5.processed/compat/browser_compatibility_types.js +0 -32
  1767. package/dist/_esm5.processed/compat/browser_detection.d.ts +0 -42
  1768. package/dist/_esm5.processed/compat/browser_detection.js +0 -103
  1769. package/dist/_esm5.processed/compat/browser_version.d.ts +0 -24
  1770. package/dist/_esm5.processed/compat/browser_version.js +0 -41
  1771. package/dist/_esm5.processed/compat/can_patch_isobmff.d.ts +0 -25
  1772. package/dist/_esm5.processed/compat/can_patch_isobmff.js +0 -28
  1773. package/dist/_esm5.processed/compat/can_rely_on_video_visibility_and_size.d.ts +0 -37
  1774. package/dist/_esm5.processed/compat/can_rely_on_video_visibility_and_size.js +0 -49
  1775. package/dist/_esm5.processed/compat/can_reuse_media_keys.d.ts +0 -13
  1776. package/dist/_esm5.processed/compat/can_reuse_media_keys.js +0 -16
  1777. package/dist/_esm5.processed/compat/change_source_buffer_type.d.ts +0 -48
  1778. package/dist/_esm5.processed/compat/change_source_buffer_type.js +0 -37
  1779. package/dist/_esm5.processed/compat/clear_element_src.d.ts +0 -20
  1780. package/dist/_esm5.processed/compat/clear_element_src.js +0 -53
  1781. package/dist/_esm5.processed/compat/eme/close_session.d.ts +0 -30
  1782. package/dist/_esm5.processed/compat/eme/close_session.js +0 -162
  1783. package/dist/_esm5.processed/compat/eme/constants.d.ts +0 -16
  1784. package/dist/_esm5.processed/compat/eme/constants.js +0 -19
  1785. package/dist/_esm5.processed/compat/eme/custom_key_system_access.d.ts +0 -54
  1786. package/dist/_esm5.processed/compat/eme/custom_key_system_access.js +0 -47
  1787. package/dist/_esm5.processed/compat/eme/custom_media_keys/ie11_media_keys.d.ts +0 -31
  1788. package/dist/_esm5.processed/compat/eme/custom_media_keys/ie11_media_keys.js +0 -170
  1789. package/dist/_esm5.processed/compat/eme/custom_media_keys/index.d.ts +0 -7
  1790. package/dist/_esm5.processed/compat/eme/custom_media_keys/index.js +0 -6
  1791. package/dist/_esm5.processed/compat/eme/custom_media_keys/moz_media_keys_constructor.d.ts +0 -27
  1792. package/dist/_esm5.processed/compat/eme/custom_media_keys/moz_media_keys_constructor.js +0 -63
  1793. package/dist/_esm5.processed/compat/eme/custom_media_keys/ms_media_keys_constructor.d.ts +0 -43
  1794. package/dist/_esm5.processed/compat/eme/custom_media_keys/ms_media_keys_constructor.js +0 -30
  1795. package/dist/_esm5.processed/compat/eme/custom_media_keys/old_webkit_media_keys.d.ts +0 -41
  1796. package/dist/_esm5.processed/compat/eme/custom_media_keys/old_webkit_media_keys.js +0 -192
  1797. package/dist/_esm5.processed/compat/eme/custom_media_keys/types.d.ts +0 -43
  1798. package/dist/_esm5.processed/compat/eme/custom_media_keys/webkit_media_keys.d.ts +0 -37
  1799. package/dist/_esm5.processed/compat/eme/custom_media_keys/webkit_media_keys.js +0 -260
  1800. package/dist/_esm5.processed/compat/eme/custom_media_keys/webkit_media_keys_constructor.d.ts +0 -22
  1801. package/dist/_esm5.processed/compat/eme/custom_media_keys/webkit_media_keys_constructor.js +0 -32
  1802. package/dist/_esm5.processed/compat/eme/eme-api-implementation.d.ts +0 -78
  1803. package/dist/_esm5.processed/compat/eme/eme-api-implementation.js +0 -198
  1804. package/dist/_esm5.processed/compat/eme/generate_key_request.d.ts +0 -54
  1805. package/dist/_esm5.processed/compat/eme/generate_key_request.js +0 -147
  1806. package/dist/_esm5.processed/compat/eme/get_init_data.d.ts +0 -57
  1807. package/dist/_esm5.processed/compat/eme/get_init_data.js +0 -112
  1808. package/dist/_esm5.processed/compat/eme/get_uuid_kid_from_keystatus_kid.d.ts +0 -23
  1809. package/dist/_esm5.processed/compat/eme/get_uuid_kid_from_keystatus_kid.js +0 -31
  1810. package/dist/_esm5.processed/compat/eme/get_webkit_fairplay_initdata.d.ts +0 -25
  1811. package/dist/_esm5.processed/compat/eme/get_webkit_fairplay_initdata.js +0 -57
  1812. package/dist/_esm5.processed/compat/eme/index.d.ts +0 -24
  1813. package/dist/_esm5.processed/compat/eme/index.js +0 -22
  1814. package/dist/_esm5.processed/compat/eme/load_session.d.ts +0 -30
  1815. package/dist/_esm5.processed/compat/eme/load_session.js +0 -99
  1816. package/dist/_esm5.processed/compat/enable_audio_track.d.ts +0 -11
  1817. package/dist/_esm5.processed/compat/enable_audio_track.js +0 -26
  1818. package/dist/_esm5.processed/compat/event_listeners.d.ts +0 -166
  1819. package/dist/_esm5.processed/compat/event_listeners.js +0 -422
  1820. package/dist/_esm5.processed/compat/fullscreen.d.ts +0 -32
  1821. package/dist/_esm5.processed/compat/fullscreen.js +0 -78
  1822. package/dist/_esm5.processed/compat/get_start_date.d.ts +0 -30
  1823. package/dist/_esm5.processed/compat/get_start_date.js +0 -44
  1824. package/dist/_esm5.processed/compat/has_issues_with_high_media_source_duration.d.ts +0 -21
  1825. package/dist/_esm5.processed/compat/has_issues_with_high_media_source_duration.js +0 -26
  1826. package/dist/_esm5.processed/compat/index.d.ts +0 -39
  1827. package/dist/_esm5.processed/compat/index.js +0 -45
  1828. package/dist/_esm5.processed/compat/is_codec_supported.d.ts +0 -25
  1829. package/dist/_esm5.processed/compat/is_codec_supported.js +0 -36
  1830. package/dist/_esm5.processed/compat/is_debug_mode_enabled.d.ts +0 -7
  1831. package/dist/_esm5.processed/compat/is_debug_mode_enabled.js +0 -9
  1832. package/dist/_esm5.processed/compat/is_node.d.ts +0 -17
  1833. package/dist/_esm5.processed/compat/is_node.js +0 -17
  1834. package/dist/_esm5.processed/compat/is_offline.d.ts +0 -39
  1835. package/dist/_esm5.processed/compat/is_offline.js +0 -43
  1836. package/dist/_esm5.processed/compat/is_seeking_approximate.d.ts +0 -28
  1837. package/dist/_esm5.processed/compat/is_seeking_approximate.js +0 -29
  1838. package/dist/_esm5.processed/compat/is_vtt_cue.d.ts +0 -22
  1839. package/dist/_esm5.processed/compat/is_vtt_cue.js +0 -25
  1840. package/dist/_esm5.processed/compat/make_vtt_cue.d.ts +0 -26
  1841. package/dist/_esm5.processed/compat/make_vtt_cue.js +0 -43
  1842. package/dist/_esm5.processed/compat/on_height_width_change.d.ts +0 -33
  1843. package/dist/_esm5.processed/compat/on_height_width_change.js +0 -77
  1844. package/dist/_esm5.processed/compat/patch_webkit_source_buffer.d.ts +0 -16
  1845. package/dist/_esm5.processed/compat/patch_webkit_source_buffer.js +0 -74
  1846. package/dist/_esm5.processed/compat/remove_cue.d.ts +0 -21
  1847. package/dist/_esm5.processed/compat/remove_cue.js +0 -63
  1848. package/dist/_esm5.processed/compat/should_favour_custom_safari_EME.d.ts +0 -23
  1849. package/dist/_esm5.processed/compat/should_favour_custom_safari_EME.js +0 -27
  1850. package/dist/_esm5.processed/compat/should_reload_media_source_on_decipherability_update.d.ts +0 -26
  1851. package/dist/_esm5.processed/compat/should_reload_media_source_on_decipherability_update.js +0 -29
  1852. package/dist/_esm5.processed/compat/should_renew_media_key_system_access.d.ts +0 -21
  1853. package/dist/_esm5.processed/compat/should_renew_media_key_system_access.js +0 -24
  1854. package/dist/_esm5.processed/compat/should_unset_media_keys.d.ts +0 -22
  1855. package/dist/_esm5.processed/compat/should_unset_media_keys.js +0 -25
  1856. package/dist/_esm5.processed/compat/should_validate_metadata.d.ts +0 -22
  1857. package/dist/_esm5.processed/compat/should_validate_metadata.js +0 -25
  1858. package/dist/_esm5.processed/compat/should_wait_for_data_before_loaded.d.ts +0 -24
  1859. package/dist/_esm5.processed/compat/should_wait_for_data_before_loaded.js +0 -30
  1860. package/dist/_esm5.processed/compat/should_wait_for_have_enough_data.d.ts +0 -13
  1861. package/dist/_esm5.processed/compat/should_wait_for_have_enough_data.js +0 -16
  1862. package/dist/_esm5.processed/config.d.ts +0 -191
  1863. package/dist/_esm5.processed/config.js +0 -32
  1864. package/dist/_esm5.processed/core/adaptive/adaptive_representation_selector.d.ts +0 -363
  1865. package/dist/_esm5.processed/core/adaptive/adaptive_representation_selector.js +0 -399
  1866. package/dist/_esm5.processed/core/adaptive/buffer_based_chooser.d.ts +0 -89
  1867. package/dist/_esm5.processed/core/adaptive/buffer_based_chooser.js +0 -192
  1868. package/dist/_esm5.processed/core/adaptive/guess_based_chooser.d.ts +0 -95
  1869. package/dist/_esm5.processed/core/adaptive/guess_based_chooser.js +0 -242
  1870. package/dist/_esm5.processed/core/adaptive/index.d.ts +0 -18
  1871. package/dist/_esm5.processed/core/adaptive/index.js +0 -17
  1872. package/dist/_esm5.processed/core/adaptive/network_analyzer.d.ts +0 -73
  1873. package/dist/_esm5.processed/core/adaptive/network_analyzer.js +0 -336
  1874. package/dist/_esm5.processed/core/adaptive/utils/bandwidth_estimator.d.ts +0 -47
  1875. package/dist/_esm5.processed/core/adaptive/utils/bandwidth_estimator.js +0 -70
  1876. package/dist/_esm5.processed/core/adaptive/utils/ewma.d.ts +0 -39
  1877. package/dist/_esm5.processed/core/adaptive/utils/ewma.js +0 -52
  1878. package/dist/_esm5.processed/core/adaptive/utils/filter_by_bitrate.d.ts +0 -25
  1879. package/dist/_esm5.processed/core/adaptive/utils/filter_by_bitrate.js +0 -37
  1880. package/dist/_esm5.processed/core/adaptive/utils/filter_by_width.d.ts +0 -25
  1881. package/dist/_esm5.processed/core/adaptive/utils/filter_by_width.js +0 -42
  1882. package/dist/_esm5.processed/core/adaptive/utils/get_buffer_levels.d.ts +0 -24
  1883. package/dist/_esm5.processed/core/adaptive/utils/get_buffer_levels.js +0 -47
  1884. package/dist/_esm5.processed/core/adaptive/utils/last_estimate_storage.d.ts +0 -61
  1885. package/dist/_esm5.processed/core/adaptive/utils/last_estimate_storage.js +0 -37
  1886. package/dist/_esm5.processed/core/adaptive/utils/pending_requests_store.d.ts +0 -100
  1887. package/dist/_esm5.processed/core/adaptive/utils/pending_requests_store.js +0 -76
  1888. package/dist/_esm5.processed/core/adaptive/utils/representation_score_calculator.d.ts +0 -104
  1889. package/dist/_esm5.processed/core/adaptive/utils/representation_score_calculator.js +0 -114
  1890. package/dist/_esm5.processed/core/adaptive/utils/select_optimal_representation.d.ts +0 -33
  1891. package/dist/_esm5.processed/core/adaptive/utils/select_optimal_representation.js +0 -45
  1892. package/dist/_esm5.processed/core/api/debug/buffer_graph.d.ts +0 -28
  1893. package/dist/_esm5.processed/core/api/debug/buffer_graph.js +0 -171
  1894. package/dist/_esm5.processed/core/api/debug/buffer_size_graph.js +0 -104
  1895. package/dist/_esm5.processed/core/api/debug/constants.js +0 -2
  1896. package/dist/_esm5.processed/core/api/debug/modules/general_info.d.ts +0 -3
  1897. package/dist/_esm5.processed/core/api/debug/modules/general_info.js +0 -209
  1898. package/dist/_esm5.processed/core/api/debug/modules/segment_buffer_content.d.ts +0 -4
  1899. package/dist/_esm5.processed/core/api/debug/modules/segment_buffer_content.js +0 -121
  1900. package/dist/_esm5.processed/core/api/debug/modules/segment_buffer_size.d.ts +0 -3
  1901. package/dist/_esm5.processed/core/api/debug/modules/segment_buffer_size.js +0 -35
  1902. package/dist/_esm5.processed/core/api/debug/render.d.ts +0 -3
  1903. package/dist/_esm5.processed/core/api/debug/render.js +0 -32
  1904. package/dist/_esm5.processed/core/api/debug/utils.js +0 -57
  1905. package/dist/_esm5.processed/core/api/index.d.ts +0 -20
  1906. package/dist/_esm5.processed/core/api/index.js +0 -19
  1907. package/dist/_esm5.processed/core/api/option_utils.d.ts +0 -142
  1908. package/dist/_esm5.processed/core/api/option_utils.js +0 -476
  1909. package/dist/_esm5.processed/core/api/playback_observer.d.ts +0 -364
  1910. package/dist/_esm5.processed/core/api/playback_observer.js +0 -582
  1911. package/dist/_esm5.processed/core/api/public_api.d.ts +0 -879
  1912. package/dist/_esm5.processed/core/api/public_api.js +0 -2445
  1913. package/dist/_esm5.processed/core/api/tracks_management/media_element_track_choice_manager.d.ts +0 -257
  1914. package/dist/_esm5.processed/core/api/tracks_management/media_element_track_choice_manager.js +0 -805
  1915. package/dist/_esm5.processed/core/api/tracks_management/track_choice_manager.d.ts +0 -258
  1916. package/dist/_esm5.processed/core/api/tracks_management/track_choice_manager.js +0 -989
  1917. package/dist/_esm5.processed/core/api/utils.d.ts +0 -65
  1918. package/dist/_esm5.processed/core/api/utils.js +0 -156
  1919. package/dist/_esm5.processed/core/decrypt/__tests__/__global__/utils.d.ts +0 -178
  1920. package/dist/_esm5.processed/core/decrypt/__tests__/__global__/utils.js +0 -405
  1921. package/dist/_esm5.processed/core/decrypt/attach_media_keys.d.ts +0 -52
  1922. package/dist/_esm5.processed/core/decrypt/attach_media_keys.js +0 -115
  1923. package/dist/_esm5.processed/core/decrypt/clear_on_stop.js +0 -40
  1924. package/dist/_esm5.processed/core/decrypt/content_decryptor.d.ts +0 -184
  1925. package/dist/_esm5.processed/core/decrypt/content_decryptor.js +0 -967
  1926. package/dist/_esm5.processed/core/decrypt/create_or_load_session.d.ts +0 -63
  1927. package/dist/_esm5.processed/core/decrypt/create_or_load_session.js +0 -124
  1928. package/dist/_esm5.processed/core/decrypt/create_session.d.ts +0 -53
  1929. package/dist/_esm5.processed/core/decrypt/create_session.js +0 -212
  1930. package/dist/_esm5.processed/core/decrypt/dispose_decryption_resources.js +0 -88
  1931. package/dist/_esm5.processed/core/decrypt/find_key_system.d.ts +0 -48
  1932. package/dist/_esm5.processed/core/decrypt/find_key_system.js +0 -333
  1933. package/dist/_esm5.processed/core/decrypt/get_key_system_configuration.d.ts +0 -30
  1934. package/dist/_esm5.processed/core/decrypt/get_key_system_configuration.js +0 -44
  1935. package/dist/_esm5.processed/core/decrypt/get_media_keys.d.ts +0 -44
  1936. package/dist/_esm5.processed/core/decrypt/get_media_keys.js +0 -156
  1937. package/dist/_esm5.processed/core/decrypt/index.d.ts +0 -26
  1938. package/dist/_esm5.processed/core/decrypt/index.js +0 -26
  1939. package/dist/_esm5.processed/core/decrypt/init_media_keys.d.ts +0 -26
  1940. package/dist/_esm5.processed/core/decrypt/init_media_keys.js +0 -82
  1941. package/dist/_esm5.processed/core/decrypt/session_events_listener.d.ts +0 -75
  1942. package/dist/_esm5.processed/core/decrypt/session_events_listener.js +0 -388
  1943. package/dist/_esm5.processed/core/decrypt/set_server_certificate.d.ts +0 -51
  1944. package/dist/_esm5.processed/core/decrypt/set_server_certificate.js +0 -141
  1945. package/dist/_esm5.processed/core/decrypt/types.d.ts +0 -368
  1946. package/dist/_esm5.processed/core/decrypt/utils/are_init_values_compatible.js +0 -113
  1947. package/dist/_esm5.processed/core/decrypt/utils/check_key_statuses.d.ts +0 -52
  1948. package/dist/_esm5.processed/core/decrypt/utils/check_key_statuses.js +0 -156
  1949. package/dist/_esm5.processed/core/decrypt/utils/clean_old_loaded_sessions.d.ts +0 -26
  1950. package/dist/_esm5.processed/core/decrypt/utils/clean_old_loaded_sessions.js +0 -86
  1951. package/dist/_esm5.processed/core/decrypt/utils/clean_old_stored_persistent_info.d.ts +0 -32
  1952. package/dist/_esm5.processed/core/decrypt/utils/clean_old_stored_persistent_info.js +0 -40
  1953. package/dist/_esm5.processed/core/decrypt/utils/init_data_values_container.d.ts +0 -69
  1954. package/dist/_esm5.processed/core/decrypt/utils/init_data_values_container.js +0 -99
  1955. package/dist/_esm5.processed/core/decrypt/utils/is_session_usable.d.ts +0 -24
  1956. package/dist/_esm5.processed/core/decrypt/utils/is_session_usable.js +0 -49
  1957. package/dist/_esm5.processed/core/decrypt/utils/key_id_comparison.js +0 -60
  1958. package/dist/_esm5.processed/core/decrypt/utils/key_session_record.d.ts +0 -104
  1959. package/dist/_esm5.processed/core/decrypt/utils/key_session_record.js +0 -157
  1960. package/dist/_esm5.processed/core/decrypt/utils/loaded_sessions_store.d.ts +0 -215
  1961. package/dist/_esm5.processed/core/decrypt/utils/loaded_sessions_store.js +0 -472
  1962. package/dist/_esm5.processed/core/decrypt/utils/media_keys_infos_store.d.ts +0 -56
  1963. package/dist/_esm5.processed/core/decrypt/utils/media_keys_infos_store.js +0 -44
  1964. package/dist/_esm5.processed/core/decrypt/utils/persistent_sessions_store.d.ts +0 -94
  1965. package/dist/_esm5.processed/core/decrypt/utils/persistent_sessions_store.js +0 -321
  1966. package/dist/_esm5.processed/core/decrypt/utils/serializable_bytes.d.ts +0 -44
  1967. package/dist/_esm5.processed/core/decrypt/utils/serializable_bytes.js +0 -48
  1968. package/dist/_esm5.processed/core/decrypt/utils/server_certificate_store.d.ts +0 -64
  1969. package/dist/_esm5.processed/core/decrypt/utils/server_certificate_store.js +0 -112
  1970. package/dist/_esm5.processed/core/fetchers/cdn_prioritizer.d.ts +0 -107
  1971. package/dist/_esm5.processed/core/fetchers/cdn_prioritizer.js +0 -177
  1972. package/dist/_esm5.processed/core/fetchers/index.d.ts +0 -18
  1973. package/dist/_esm5.processed/core/fetchers/index.js +0 -18
  1974. package/dist/_esm5.processed/core/fetchers/manifest/index.d.ts +0 -18
  1975. package/dist/_esm5.processed/core/fetchers/manifest/index.js +0 -17
  1976. package/dist/_esm5.processed/core/fetchers/manifest/manifest_fetcher.d.ts +0 -223
  1977. package/dist/_esm5.processed/core/fetchers/manifest/manifest_fetcher.js +0 -624
  1978. package/dist/_esm5.processed/core/fetchers/segment/index.d.ts +0 -19
  1979. package/dist/_esm5.processed/core/fetchers/segment/index.js +0 -17
  1980. package/dist/_esm5.processed/core/fetchers/segment/prioritized_segment_fetcher.d.ts +0 -38
  1981. package/dist/_esm5.processed/core/fetchers/segment/prioritized_segment_fetcher.js +0 -67
  1982. package/dist/_esm5.processed/core/fetchers/segment/segment_fetcher.d.ts +0 -154
  1983. package/dist/_esm5.processed/core/fetchers/segment/segment_fetcher.js +0 -308
  1984. package/dist/_esm5.processed/core/fetchers/segment/segment_fetcher_creator.d.ts +0 -79
  1985. package/dist/_esm5.processed/core/fetchers/segment/segment_fetcher_creator.js +0 -58
  1986. package/dist/_esm5.processed/core/fetchers/segment/task_prioritizer.d.ts +0 -145
  1987. package/dist/_esm5.processed/core/fetchers/segment/task_prioritizer.js +0 -323
  1988. package/dist/_esm5.processed/core/fetchers/utils/error_selector.d.ts +0 -23
  1989. package/dist/_esm5.processed/core/fetchers/utils/error_selector.js +0 -31
  1990. package/dist/_esm5.processed/core/fetchers/utils/schedule_request.d.ts +0 -103
  1991. package/dist/_esm5.processed/core/fetchers/utils/schedule_request.js +0 -424
  1992. package/dist/_esm5.processed/core/init/directfile_content_initializer.d.ts +0 -97
  1993. package/dist/_esm5.processed/core/init/directfile_content_initializer.js +0 -239
  1994. package/dist/_esm5.processed/core/init/media_source_content_initializer.d.ts +0 -181
  1995. package/dist/_esm5.processed/core/init/media_source_content_initializer.js +0 -625
  1996. package/dist/_esm5.processed/core/init/types.d.ts +0 -241
  1997. package/dist/_esm5.processed/core/init/types.js +0 -51
  1998. package/dist/_esm5.processed/core/init/utils/content_time_boundaries_observer.d.ts +0 -191
  1999. package/dist/_esm5.processed/core/init/utils/content_time_boundaries_observer.js +0 -497
  2000. package/dist/_esm5.processed/core/init/utils/create_media_source.d.ts +0 -37
  2001. package/dist/_esm5.processed/core/init/utils/create_media_source.js +0 -112
  2002. package/dist/_esm5.processed/core/init/utils/create_stream_playback_observer.d.ts +0 -45
  2003. package/dist/_esm5.processed/core/init/utils/create_stream_playback_observer.js +0 -86
  2004. package/dist/_esm5.processed/core/init/utils/end_of_stream.d.ts +0 -33
  2005. package/dist/_esm5.processed/core/init/utils/end_of_stream.js +0 -89
  2006. package/dist/_esm5.processed/core/init/utils/get_initial_time.d.ts +0 -62
  2007. package/dist/_esm5.processed/core/init/utils/get_initial_time.js +0 -109
  2008. package/dist/_esm5.processed/core/init/utils/get_loaded_reference.d.ts +0 -28
  2009. package/dist/_esm5.processed/core/init/utils/get_loaded_reference.js +0 -56
  2010. package/dist/_esm5.processed/core/init/utils/initial_seek_and_play.d.ts +0 -63
  2011. package/dist/_esm5.processed/core/init/utils/initial_seek_and_play.js +0 -128
  2012. package/dist/_esm5.processed/core/init/utils/initialize_content_decryption.d.ts +0 -80
  2013. package/dist/_esm5.processed/core/init/utils/initialize_content_decryption.js +0 -104
  2014. package/dist/_esm5.processed/core/init/utils/media_source_duration_updater.js +0 -268
  2015. package/dist/_esm5.processed/core/init/utils/rebuffering_controller.d.ts +0 -113
  2016. package/dist/_esm5.processed/core/init/utils/rebuffering_controller.js +0 -483
  2017. package/dist/_esm5.processed/core/init/utils/stream_events_emitter/are_same_stream_events.js +0 -35
  2018. package/dist/_esm5.processed/core/init/utils/stream_events_emitter/index.d.ts +0 -18
  2019. package/dist/_esm5.processed/core/init/utils/stream_events_emitter/refresh_scheduled_events_list.d.ts +0 -25
  2020. package/dist/_esm5.processed/core/init/utils/stream_events_emitter/refresh_scheduled_events_list.js +0 -66
  2021. package/dist/_esm5.processed/core/init/utils/stream_events_emitter/stream_events_emitter.d.ts +0 -52
  2022. package/dist/_esm5.processed/core/init/utils/stream_events_emitter/stream_events_emitter.js +0 -200
  2023. package/dist/_esm5.processed/core/init/utils/stream_events_emitter/types.d.ts +0 -41
  2024. package/dist/_esm5.processed/core/init/utils/throw_on_media_error.d.ts +0 -23
  2025. package/dist/_esm5.processed/core/init/utils/throw_on_media_error.js +0 -58
  2026. package/dist/_esm5.processed/core/segment_buffers/garbage_collector.d.ts +0 -41
  2027. package/dist/_esm5.processed/core/segment_buffers/garbage_collector.js +0 -183
  2028. package/dist/_esm5.processed/core/segment_buffers/implementations/audio_video/audio_video_segment_buffer.d.ts +0 -182
  2029. package/dist/_esm5.processed/core/segment_buffers/implementations/audio_video/audio_video_segment_buffer.js +0 -462
  2030. package/dist/_esm5.processed/core/segment_buffers/implementations/audio_video/index.d.ts +0 -17
  2031. package/dist/_esm5.processed/core/segment_buffers/implementations/audio_video/index.js +0 -17
  2032. package/dist/_esm5.processed/core/segment_buffers/implementations/image/image_segment_buffer.d.ts +0 -75
  2033. package/dist/_esm5.processed/core/segment_buffers/implementations/image/image_segment_buffer.js +0 -133
  2034. package/dist/_esm5.processed/core/segment_buffers/implementations/image/index.d.ts +0 -17
  2035. package/dist/_esm5.processed/core/segment_buffers/implementations/image/index.js +0 -17
  2036. package/dist/_esm5.processed/core/segment_buffers/implementations/index.d.ts +0 -18
  2037. package/dist/_esm5.processed/core/segment_buffers/implementations/index.js +0 -18
  2038. package/dist/_esm5.processed/core/segment_buffers/implementations/text/html/html_text_segment_buffer.d.ts +0 -141
  2039. package/dist/_esm5.processed/core/segment_buffers/implementations/text/html/html_text_segment_buffer.js +0 -405
  2040. package/dist/_esm5.processed/core/segment_buffers/implementations/text/html/index.d.ts +0 -21
  2041. package/dist/_esm5.processed/core/segment_buffers/implementations/text/html/index.js +0 -21
  2042. package/dist/_esm5.processed/core/segment_buffers/implementations/text/html/parsers.d.ts +0 -30
  2043. package/dist/_esm5.processed/core/segment_buffers/implementations/text/html/parsers.js +0 -37
  2044. package/dist/_esm5.processed/core/segment_buffers/implementations/text/html/text_track_cues_store.d.ts +0 -79
  2045. package/dist/_esm5.processed/core/segment_buffers/implementations/text/html/text_track_cues_store.js +0 -372
  2046. package/dist/_esm5.processed/core/segment_buffers/implementations/text/html/types.d.ts +0 -25
  2047. package/dist/_esm5.processed/core/segment_buffers/implementations/text/html/update_proportional_elements.d.ts +0 -30
  2048. package/dist/_esm5.processed/core/segment_buffers/implementations/text/html/update_proportional_elements.js +0 -77
  2049. package/dist/_esm5.processed/core/segment_buffers/implementations/text/html/utils.d.ts +0 -45
  2050. package/dist/_esm5.processed/core/segment_buffers/implementations/text/html/utils.js +0 -124
  2051. package/dist/_esm5.processed/core/segment_buffers/implementations/text/native/index.d.ts +0 -17
  2052. package/dist/_esm5.processed/core/segment_buffers/implementations/text/native/index.js +0 -17
  2053. package/dist/_esm5.processed/core/segment_buffers/implementations/text/native/native_text_segment_buffer.d.ts +0 -84
  2054. package/dist/_esm5.processed/core/segment_buffers/implementations/text/native/native_text_segment_buffer.js +0 -272
  2055. package/dist/_esm5.processed/core/segment_buffers/implementations/text/native/parsers.d.ts +0 -26
  2056. package/dist/_esm5.processed/core/segment_buffers/implementations/text/native/parsers.js +0 -37
  2057. package/dist/_esm5.processed/core/segment_buffers/implementations/types.d.ts +0 -320
  2058. package/dist/_esm5.processed/core/segment_buffers/implementations/types.js +0 -121
  2059. package/dist/_esm5.processed/core/segment_buffers/implementations/utils/manual_time_ranges.js +0 -65
  2060. package/dist/_esm5.processed/core/segment_buffers/index.d.ts +0 -21
  2061. package/dist/_esm5.processed/core/segment_buffers/index.js +0 -20
  2062. package/dist/_esm5.processed/core/segment_buffers/inventory/buffered_history.d.ts +0 -89
  2063. package/dist/_esm5.processed/core/segment_buffers/inventory/buffered_history.js +0 -90
  2064. package/dist/_esm5.processed/core/segment_buffers/inventory/index.d.ts +0 -20
  2065. package/dist/_esm5.processed/core/segment_buffers/inventory/index.js +0 -17
  2066. package/dist/_esm5.processed/core/segment_buffers/inventory/segment_inventory.d.ts +0 -224
  2067. package/dist/_esm5.processed/core/segment_buffers/inventory/segment_inventory.js +0 -833
  2068. package/dist/_esm5.processed/core/segment_buffers/inventory/types.d.ts +0 -27
  2069. package/dist/_esm5.processed/core/segment_buffers/inventory/types.js +0 -16
  2070. package/dist/_esm5.processed/core/segment_buffers/segment_buffers_store.d.ts +0 -181
  2071. package/dist/_esm5.processed/core/segment_buffers/segment_buffers_store.js +0 -314
  2072. package/dist/_esm5.processed/core/stream/adaptation/adaptation_stream.d.ts +0 -48
  2073. package/dist/_esm5.processed/core/stream/adaptation/adaptation_stream.js +0 -292
  2074. package/dist/_esm5.processed/core/stream/adaptation/index.d.ts +0 -18
  2075. package/dist/_esm5.processed/core/stream/adaptation/index.js +0 -18
  2076. package/dist/_esm5.processed/core/stream/adaptation/types.d.ts +0 -178
  2077. package/dist/_esm5.processed/core/stream/adaptation/utils/create_representation_estimator.d.ts +0 -47
  2078. package/dist/_esm5.processed/core/stream/adaptation/utils/create_representation_estimator.js +0 -70
  2079. package/dist/_esm5.processed/core/stream/index.d.ts +0 -21
  2080. package/dist/_esm5.processed/core/stream/index.js +0 -17
  2081. package/dist/_esm5.processed/core/stream/orchestrator/get_time_ranges_for_content.d.ts +0 -30
  2082. package/dist/_esm5.processed/core/stream/orchestrator/get_time_ranges_for_content.js +0 -60
  2083. package/dist/_esm5.processed/core/stream/orchestrator/index.d.ts +0 -18
  2084. package/dist/_esm5.processed/core/stream/orchestrator/index.js +0 -17
  2085. package/dist/_esm5.processed/core/stream/orchestrator/stream_orchestrator.d.ts +0 -172
  2086. package/dist/_esm5.processed/core/stream/orchestrator/stream_orchestrator.js +0 -481
  2087. package/dist/_esm5.processed/core/stream/period/index.d.ts +0 -18
  2088. package/dist/_esm5.processed/core/stream/period/index.js +0 -18
  2089. package/dist/_esm5.processed/core/stream/period/period_stream.d.ts +0 -49
  2090. package/dist/_esm5.processed/core/stream/period/period_stream.js +0 -384
  2091. package/dist/_esm5.processed/core/stream/period/types.d.ts +0 -110
  2092. package/dist/_esm5.processed/core/stream/period/utils/get_adaptation_switch_strategy.d.ts +0 -70
  2093. package/dist/_esm5.processed/core/stream/period/utils/get_adaptation_switch_strategy.js +0 -198
  2094. package/dist/_esm5.processed/core/stream/representation/index.d.ts +0 -18
  2095. package/dist/_esm5.processed/core/stream/representation/index.js +0 -18
  2096. package/dist/_esm5.processed/core/stream/representation/representation_stream.d.ts +0 -53
  2097. package/dist/_esm5.processed/core/stream/representation/representation_stream.js +0 -369
  2098. package/dist/_esm5.processed/core/stream/representation/types.d.ts +0 -267
  2099. package/dist/_esm5.processed/core/stream/representation/utils/append_segment_to_buffer.d.ts +0 -32
  2100. package/dist/_esm5.processed/core/stream/representation/utils/append_segment_to_buffer.js +0 -114
  2101. package/dist/_esm5.processed/core/stream/representation/utils/check_for_discontinuity.d.ts +0 -53
  2102. package/dist/_esm5.processed/core/stream/representation/utils/check_for_discontinuity.js +0 -235
  2103. package/dist/_esm5.processed/core/stream/representation/utils/downloading_queue.d.ts +0 -231
  2104. package/dist/_esm5.processed/core/stream/representation/utils/downloading_queue.js +0 -388
  2105. package/dist/_esm5.processed/core/stream/representation/utils/force_garbage_collection.d.ts +0 -29
  2106. package/dist/_esm5.processed/core/stream/representation/utils/force_garbage_collection.js +0 -150
  2107. package/dist/_esm5.processed/core/stream/representation/utils/get_buffer_status.d.ts +0 -72
  2108. package/dist/_esm5.processed/core/stream/representation/utils/get_buffer_status.js +0 -203
  2109. package/dist/_esm5.processed/core/stream/representation/utils/get_needed_segments.d.ts +0 -92
  2110. package/dist/_esm5.processed/core/stream/representation/utils/get_needed_segments.js +0 -426
  2111. package/dist/_esm5.processed/core/stream/representation/utils/get_segment_priority.d.ts +0 -28
  2112. package/dist/_esm5.processed/core/stream/representation/utils/get_segment_priority.js +0 -38
  2113. package/dist/_esm5.processed/core/stream/representation/utils/push_init_segment.d.ts +0 -39
  2114. package/dist/_esm5.processed/core/stream/representation/utils/push_init_segment.js +0 -85
  2115. package/dist/_esm5.processed/core/stream/representation/utils/push_media_segment.d.ts +0 -40
  2116. package/dist/_esm5.processed/core/stream/representation/utils/push_media_segment.js +0 -108
  2117. package/dist/_esm5.processed/default_config.d.ts +0 -1143
  2118. package/dist/_esm5.processed/default_config.js +0 -1178
  2119. package/dist/_esm5.processed/errors/assertion_error.d.ts +0 -31
  2120. package/dist/_esm5.processed/errors/assertion_error.js +0 -54
  2121. package/dist/_esm5.processed/errors/custom_loader_error.d.ts +0 -38
  2122. package/dist/_esm5.processed/errors/custom_loader_error.js +0 -61
  2123. package/dist/_esm5.processed/errors/encrypted_media_error.d.ts +0 -39
  2124. package/dist/_esm5.processed/errors/encrypted_media_error.js +0 -57
  2125. package/dist/_esm5.processed/errors/error_codes.d.ts +0 -31
  2126. package/dist/_esm5.processed/errors/error_codes.js +0 -70
  2127. package/dist/_esm5.processed/errors/error_message.d.ts +0 -23
  2128. package/dist/_esm5.processed/errors/error_message.js +0 -25
  2129. package/dist/_esm5.processed/errors/format_error.d.ts +0 -20
  2130. package/dist/_esm5.processed/errors/format_error.js +0 -31
  2131. package/dist/_esm5.processed/errors/index.d.ts +0 -26
  2132. package/dist/_esm5.processed/errors/index.js +0 -26
  2133. package/dist/_esm5.processed/errors/is_known_error.d.ts +0 -22
  2134. package/dist/_esm5.processed/errors/is_known_error.js +0 -32
  2135. package/dist/_esm5.processed/errors/media_error.d.ts +0 -56
  2136. package/dist/_esm5.processed/errors/media_error.js +0 -71
  2137. package/dist/_esm5.processed/errors/network_error.d.ts +0 -45
  2138. package/dist/_esm5.processed/errors/network_error.js +0 -71
  2139. package/dist/_esm5.processed/errors/other_error.d.ts +0 -32
  2140. package/dist/_esm5.processed/errors/other_error.js +0 -56
  2141. package/dist/_esm5.processed/errors/request_error.d.ts +0 -39
  2142. package/dist/_esm5.processed/errors/request_error.js +0 -77
  2143. package/dist/_esm5.processed/experimental/features/dash_wasm.d.ts +0 -23
  2144. package/dist/_esm5.processed/experimental/features/dash_wasm.js +0 -34
  2145. package/dist/_esm5.processed/experimental/features/debug_element.d.ts +0 -8
  2146. package/dist/_esm5.processed/experimental/features/debug_element.js +0 -10
  2147. package/dist/_esm5.processed/experimental/features/index.d.ts +0 -19
  2148. package/dist/_esm5.processed/experimental/features/index.js +0 -19
  2149. package/dist/_esm5.processed/experimental/features/local.d.ts +0 -19
  2150. package/dist/_esm5.processed/experimental/features/local.js +0 -24
  2151. package/dist/_esm5.processed/experimental/features/metaplaylist.d.ts +0 -19
  2152. package/dist/_esm5.processed/experimental/features/metaplaylist.js +0 -24
  2153. package/dist/_esm5.processed/experimental/index.d.ts +0 -2
  2154. package/dist/_esm5.processed/experimental/index.js +0 -2
  2155. package/dist/_esm5.processed/experimental/tools/VideoThumbnailLoader/features/dash.d.ts +0 -17
  2156. package/dist/_esm5.processed/experimental/tools/VideoThumbnailLoader/features/dash.js +0 -20
  2157. package/dist/_esm5.processed/experimental/tools/VideoThumbnailLoader/features/metaplaylist.d.ts +0 -17
  2158. package/dist/_esm5.processed/experimental/tools/VideoThumbnailLoader/features/metaplaylist.js +0 -20
  2159. package/dist/_esm5.processed/experimental/tools/VideoThumbnailLoader/index.d.ts +0 -18
  2160. package/dist/_esm5.processed/experimental/tools/VideoThumbnailLoader/index.js +0 -18
  2161. package/dist/_esm5.processed/experimental/tools/VideoThumbnailLoader/load_and_push_segment.d.ts +0 -26
  2162. package/dist/_esm5.processed/experimental/tools/VideoThumbnailLoader/load_and_push_segment.js +0 -61
  2163. package/dist/_esm5.processed/experimental/tools/VideoThumbnailLoader/prepare_source_buffer.d.ts +0 -25
  2164. package/dist/_esm5.processed/experimental/tools/VideoThumbnailLoader/prepare_source_buffer.js +0 -63
  2165. package/dist/_esm5.processed/experimental/tools/VideoThumbnailLoader/remove_buffer_around_time.d.ts +0 -30
  2166. package/dist/_esm5.processed/experimental/tools/VideoThumbnailLoader/remove_buffer_around_time.js +0 -41
  2167. package/dist/_esm5.processed/experimental/tools/VideoThumbnailLoader/types.d.ts +0 -25
  2168. package/dist/_esm5.processed/experimental/tools/VideoThumbnailLoader/types.js +0 -16
  2169. package/dist/_esm5.processed/experimental/tools/VideoThumbnailLoader/video_thumbnail_loader.d.ts +0 -54
  2170. package/dist/_esm5.processed/experimental/tools/VideoThumbnailLoader/video_thumbnail_loader.js +0 -343
  2171. package/dist/_esm5.processed/experimental/tools/VideoThumbnailLoader/video_thumbnail_loader_error.d.ts +0 -25
  2172. package/dist/_esm5.processed/experimental/tools/VideoThumbnailLoader/video_thumbnail_loader_error.js +0 -48
  2173. package/dist/_esm5.processed/experimental/tools/createMetaplaylist/get_duration_from_manifest.d.ts +0 -23
  2174. package/dist/_esm5.processed/experimental/tools/createMetaplaylist/get_duration_from_manifest.js +0 -169
  2175. package/dist/_esm5.processed/experimental/tools/createMetaplaylist/index.d.ts +0 -30
  2176. package/dist/_esm5.processed/experimental/tools/createMetaplaylist/index.js +0 -50
  2177. package/dist/_esm5.processed/experimental/tools/index.d.ts +0 -20
  2178. package/dist/_esm5.processed/experimental/tools/index.js +0 -20
  2179. package/dist/_esm5.processed/experimental/tools/mediaCapabilitiesProber/api/index.d.ts +0 -60
  2180. package/dist/_esm5.processed/experimental/tools/mediaCapabilitiesProber/api/index.js +0 -158
  2181. package/dist/_esm5.processed/experimental/tools/mediaCapabilitiesProber/api/probeMediaConfiguration.d.ts +0 -45
  2182. package/dist/_esm5.processed/experimental/tools/mediaCapabilitiesProber/api/probeMediaConfiguration.js +0 -102
  2183. package/dist/_esm5.processed/experimental/tools/mediaCapabilitiesProber/capabilities.d.ts +0 -24
  2184. package/dist/_esm5.processed/experimental/tools/mediaCapabilitiesProber/capabilities.js +0 -142
  2185. package/dist/_esm5.processed/experimental/tools/mediaCapabilitiesProber/index.d.ts +0 -17
  2186. package/dist/_esm5.processed/experimental/tools/mediaCapabilitiesProber/index.js +0 -17
  2187. package/dist/_esm5.processed/experimental/tools/mediaCapabilitiesProber/log.d.ts +0 -18
  2188. package/dist/_esm5.processed/experimental/tools/mediaCapabilitiesProber/log.js +0 -18
  2189. package/dist/_esm5.processed/experimental/tools/mediaCapabilitiesProber/probers/DRMInfos.d.ts +0 -25
  2190. package/dist/_esm5.processed/experimental/tools/mediaCapabilitiesProber/probers/DRMInfos.js +0 -50
  2191. package/dist/_esm5.processed/experimental/tools/mediaCapabilitiesProber/probers/HDCPPolicy.d.ts +0 -22
  2192. package/dist/_esm5.processed/experimental/tools/mediaCapabilitiesProber/probers/HDCPPolicy.js +0 -69
  2193. package/dist/_esm5.processed/experimental/tools/mediaCapabilitiesProber/probers/decodingInfo.d.ts +0 -26
  2194. package/dist/_esm5.processed/experimental/tools/mediaCapabilitiesProber/probers/decodingInfo.js +0 -79
  2195. package/dist/_esm5.processed/experimental/tools/mediaCapabilitiesProber/probers/defaultCodecsFinder.d.ts +0 -29
  2196. package/dist/_esm5.processed/experimental/tools/mediaCapabilitiesProber/probers/defaultCodecsFinder.js +0 -65
  2197. package/dist/_esm5.processed/experimental/tools/mediaCapabilitiesProber/probers/index.d.ts +0 -21
  2198. package/dist/_esm5.processed/experimental/tools/mediaCapabilitiesProber/probers/index.js +0 -30
  2199. package/dist/_esm5.processed/experimental/tools/mediaCapabilitiesProber/probers/mediaContentType.d.ts +0 -21
  2200. package/dist/_esm5.processed/experimental/tools/mediaCapabilitiesProber/probers/mediaContentType.js +0 -57
  2201. package/dist/_esm5.processed/experimental/tools/mediaCapabilitiesProber/probers/mediaContentTypeWithFeatures/format.d.ts +0 -21
  2202. package/dist/_esm5.processed/experimental/tools/mediaCapabilitiesProber/probers/mediaContentTypeWithFeatures/format.js +0 -89
  2203. package/dist/_esm5.processed/experimental/tools/mediaCapabilitiesProber/probers/mediaContentTypeWithFeatures/index.d.ts +0 -26
  2204. package/dist/_esm5.processed/experimental/tools/mediaCapabilitiesProber/probers/mediaContentTypeWithFeatures/index.js +0 -83
  2205. package/dist/_esm5.processed/experimental/tools/mediaCapabilitiesProber/probers/mediaDisplayInfos.d.ts +0 -21
  2206. package/dist/_esm5.processed/experimental/tools/mediaCapabilitiesProber/probers/mediaDisplayInfos.js +0 -45
  2207. package/dist/_esm5.processed/experimental/tools/mediaCapabilitiesProber/types.d.ts +0 -69
  2208. package/dist/_esm5.processed/experimental/tools/mediaCapabilitiesProber/types.js +0 -21
  2209. package/dist/_esm5.processed/experimental/tools/mediaCapabilitiesProber/utils.d.ts +0 -31
  2210. package/dist/_esm5.processed/experimental/tools/mediaCapabilitiesProber/utils.js +0 -83
  2211. package/dist/_esm5.processed/experimental/tools/parseBIFThumbnails.d.ts +0 -29
  2212. package/dist/_esm5.processed/experimental/tools/parseBIFThumbnails.js +0 -29
  2213. package/dist/_esm5.processed/features/add_features.d.ts +0 -20
  2214. package/dist/_esm5.processed/features/add_features.js +0 -35
  2215. package/dist/_esm5.processed/features/features_object.d.ts +0 -22
  2216. package/dist/_esm5.processed/features/features_object.js +0 -33
  2217. package/dist/_esm5.processed/features/index.d.ts +0 -34
  2218. package/dist/_esm5.processed/features/index.js +0 -33
  2219. package/dist/_esm5.processed/features/list/bif_parser.d.ts +0 -23
  2220. package/dist/_esm5.processed/features/list/bif_parser.js +0 -27
  2221. package/dist/_esm5.processed/features/list/dash.d.ts +0 -23
  2222. package/dist/_esm5.processed/features/list/dash.js +0 -32
  2223. package/dist/_esm5.processed/features/list/directfile.d.ts +0 -24
  2224. package/dist/_esm5.processed/features/list/directfile.js +0 -31
  2225. package/dist/_esm5.processed/features/list/eme.d.ts +0 -23
  2226. package/dist/_esm5.processed/features/list/eme.js +0 -25
  2227. package/dist/_esm5.processed/features/list/html_sami_parser.d.ts +0 -23
  2228. package/dist/_esm5.processed/features/list/html_sami_parser.js +0 -27
  2229. package/dist/_esm5.processed/features/list/html_srt_parser.d.ts +0 -23
  2230. package/dist/_esm5.processed/features/list/html_srt_parser.js +0 -27
  2231. package/dist/_esm5.processed/features/list/html_text_buffer.d.ts +0 -23
  2232. package/dist/_esm5.processed/features/list/html_text_buffer.js +0 -25
  2233. package/dist/_esm5.processed/features/list/html_ttml_parser.d.ts +0 -23
  2234. package/dist/_esm5.processed/features/list/html_ttml_parser.js +0 -27
  2235. package/dist/_esm5.processed/features/list/html_vtt_parser.d.ts +0 -23
  2236. package/dist/_esm5.processed/features/list/html_vtt_parser.js +0 -27
  2237. package/dist/_esm5.processed/features/list/image_buffer.d.ts +0 -23
  2238. package/dist/_esm5.processed/features/list/image_buffer.js +0 -25
  2239. package/dist/_esm5.processed/features/list/index.d.ts +0 -31
  2240. package/dist/_esm5.processed/features/list/index.js +0 -31
  2241. package/dist/_esm5.processed/features/list/native_sami_parser.d.ts +0 -23
  2242. package/dist/_esm5.processed/features/list/native_sami_parser.js +0 -28
  2243. package/dist/_esm5.processed/features/list/native_srt_parser.d.ts +0 -23
  2244. package/dist/_esm5.processed/features/list/native_srt_parser.js +0 -28
  2245. package/dist/_esm5.processed/features/list/native_text_buffer.d.ts +0 -23
  2246. package/dist/_esm5.processed/features/list/native_text_buffer.js +0 -26
  2247. package/dist/_esm5.processed/features/list/native_ttml_parser.d.ts +0 -23
  2248. package/dist/_esm5.processed/features/list/native_ttml_parser.js +0 -28
  2249. package/dist/_esm5.processed/features/list/native_vtt_parser.d.ts +0 -23
  2250. package/dist/_esm5.processed/features/list/native_vtt_parser.js +0 -28
  2251. package/dist/_esm5.processed/features/list/smooth.d.ts +0 -23
  2252. package/dist/_esm5.processed/features/list/smooth.js +0 -28
  2253. package/dist/_esm5.processed/features/types.d.ts +0 -154
  2254. package/dist/_esm5.processed/features/types.js +0 -16
  2255. package/dist/_esm5.processed/log.d.ts +0 -18
  2256. package/dist/_esm5.processed/log.js +0 -19
  2257. package/dist/_esm5.processed/manifest/adaptation.d.ts +0 -115
  2258. package/dist/_esm5.processed/manifest/adaptation.js +0 -208
  2259. package/dist/_esm5.processed/manifest/index.d.ts +0 -25
  2260. package/dist/_esm5.processed/manifest/index.js +0 -28
  2261. package/dist/_esm5.processed/manifest/manifest.d.ts +0 -317
  2262. package/dist/_esm5.processed/manifest/manifest.js +0 -487
  2263. package/dist/_esm5.processed/manifest/period.d.ts +0 -74
  2264. package/dist/_esm5.processed/manifest/period.js +0 -141
  2265. package/dist/_esm5.processed/manifest/representation.d.ts +0 -246
  2266. package/dist/_esm5.processed/manifest/representation.js +0 -265
  2267. package/dist/_esm5.processed/manifest/representation_index/index.d.ts +0 -18
  2268. package/dist/_esm5.processed/manifest/representation_index/static.d.ts +0 -99
  2269. package/dist/_esm5.processed/manifest/representation_index/static.js +0 -135
  2270. package/dist/_esm5.processed/manifest/representation_index/types.d.ts +0 -399
  2271. package/dist/_esm5.processed/manifest/representation_index/types.js +0 -16
  2272. package/dist/_esm5.processed/manifest/types.d.ts +0 -31
  2273. package/dist/_esm5.processed/manifest/update_period_in_place.d.ts +0 -49
  2274. package/dist/_esm5.processed/manifest/update_period_in_place.js +0 -119
  2275. package/dist/_esm5.processed/manifest/update_periods.d.ts +0 -47
  2276. package/dist/_esm5.processed/manifest/update_periods.js +0 -168
  2277. package/dist/_esm5.processed/manifest/utils.d.ts +0 -39
  2278. package/dist/_esm5.processed/manifest/utils.js +0 -42
  2279. package/dist/_esm5.processed/minimal.d.ts +0 -17
  2280. package/dist/_esm5.processed/minimal.js +0 -31
  2281. package/dist/_esm5.processed/parsers/containers/isobmff/constants.d.ts +0 -23
  2282. package/dist/_esm5.processed/parsers/containers/isobmff/constants.js +0 -23
  2283. package/dist/_esm5.processed/parsers/containers/isobmff/create_box.d.ts +0 -30
  2284. package/dist/_esm5.processed/parsers/containers/isobmff/create_box.js +0 -64
  2285. package/dist/_esm5.processed/parsers/containers/isobmff/drm/index.d.ts +0 -16
  2286. package/dist/_esm5.processed/parsers/containers/isobmff/drm/index.js +0 -16
  2287. package/dist/_esm5.processed/parsers/containers/isobmff/drm/playready.d.ts +0 -21
  2288. package/dist/_esm5.processed/parsers/containers/isobmff/drm/playready.js +0 -36
  2289. package/dist/_esm5.processed/parsers/containers/isobmff/get_box.d.ts +0 -107
  2290. package/dist/_esm5.processed/parsers/containers/isobmff/get_box.js +0 -228
  2291. package/dist/_esm5.processed/parsers/containers/isobmff/index.d.ts +0 -21
  2292. package/dist/_esm5.processed/parsers/containers/isobmff/index.js +0 -21
  2293. package/dist/_esm5.processed/parsers/containers/isobmff/read.d.ts +0 -57
  2294. package/dist/_esm5.processed/parsers/containers/isobmff/read.js +0 -88
  2295. package/dist/_esm5.processed/parsers/containers/isobmff/take_pssh_out.d.ts +0 -41
  2296. package/dist/_esm5.processed/parsers/containers/isobmff/take_pssh_out.js +0 -83
  2297. package/dist/_esm5.processed/parsers/containers/isobmff/utils.d.ts +0 -123
  2298. package/dist/_esm5.processed/parsers/containers/isobmff/utils.js +0 -434
  2299. package/dist/_esm5.processed/parsers/containers/matroska/index.d.ts +0 -16
  2300. package/dist/_esm5.processed/parsers/containers/matroska/index.js +0 -16
  2301. package/dist/_esm5.processed/parsers/containers/matroska/utils.d.ts +0 -34
  2302. package/dist/_esm5.processed/parsers/containers/matroska/utils.js +0 -236
  2303. package/dist/_esm5.processed/parsers/images/bif.d.ts +0 -39
  2304. package/dist/_esm5.processed/parsers/images/bif.js +0 -88
  2305. package/dist/_esm5.processed/parsers/manifest/dash/common/attach_trickmode_track.d.ts +0 -28
  2306. package/dist/_esm5.processed/parsers/manifest/dash/common/attach_trickmode_track.js +0 -48
  2307. package/dist/_esm5.processed/parsers/manifest/dash/common/convert_supplemental_codecs.d.ts +0 -17
  2308. package/dist/_esm5.processed/parsers/manifest/dash/common/convert_supplemental_codecs.js +0 -26
  2309. package/dist/_esm5.processed/parsers/manifest/dash/common/flatten_overlapping_periods.d.ts +0 -43
  2310. package/dist/_esm5.processed/parsers/manifest/dash/common/flatten_overlapping_periods.js +0 -79
  2311. package/dist/_esm5.processed/parsers/manifest/dash/common/get_clock_offset.d.ts +0 -29
  2312. package/dist/_esm5.processed/parsers/manifest/dash/common/get_clock_offset.js +0 -37
  2313. package/dist/_esm5.processed/parsers/manifest/dash/common/get_hdr_information.d.ts +0 -50
  2314. package/dist/_esm5.processed/parsers/manifest/dash/common/get_hdr_information.js +0 -58
  2315. package/dist/_esm5.processed/parsers/manifest/dash/common/get_http_utc-timing_url.d.ts +0 -21
  2316. package/dist/_esm5.processed/parsers/manifest/dash/common/get_http_utc-timing_url.js +0 -28
  2317. package/dist/_esm5.processed/parsers/manifest/dash/common/get_minimum_and_maximum_positions.d.ts +0 -25
  2318. package/dist/_esm5.processed/parsers/manifest/dash/common/get_minimum_and_maximum_positions.js +0 -30
  2319. package/dist/_esm5.processed/parsers/manifest/dash/common/get_periods_time_infos.d.ts +0 -43
  2320. package/dist/_esm5.processed/parsers/manifest/dash/common/get_periods_time_infos.js +0 -64
  2321. package/dist/_esm5.processed/parsers/manifest/dash/common/index.d.ts +0 -20
  2322. package/dist/_esm5.processed/parsers/manifest/dash/common/index.js +0 -19
  2323. package/dist/_esm5.processed/parsers/manifest/dash/common/indexes/base.d.ts +0 -260
  2324. package/dist/_esm5.processed/parsers/manifest/dash/common/indexes/base.js +0 -247
  2325. package/dist/_esm5.processed/parsers/manifest/dash/common/indexes/get_init_segment.d.ts +0 -32
  2326. package/dist/_esm5.processed/parsers/manifest/dash/common/indexes/get_init_segment.js +0 -40
  2327. package/dist/_esm5.processed/parsers/manifest/dash/common/indexes/get_segments_from_timeline.d.ts +0 -36
  2328. package/dist/_esm5.processed/parsers/manifest/dash/common/indexes/get_segments_from_timeline.js +0 -94
  2329. package/dist/_esm5.processed/parsers/manifest/dash/common/indexes/index.d.ts +0 -20
  2330. package/dist/_esm5.processed/parsers/manifest/dash/common/indexes/index.js +0 -20
  2331. package/dist/_esm5.processed/parsers/manifest/dash/common/indexes/list.d.ts +0 -191
  2332. package/dist/_esm5.processed/parsers/manifest/dash/common/indexes/list.js +0 -192
  2333. package/dist/_esm5.processed/parsers/manifest/dash/common/indexes/template.d.ts +0 -258
  2334. package/dist/_esm5.processed/parsers/manifest/dash/common/indexes/template.js +0 -422
  2335. package/dist/_esm5.processed/parsers/manifest/dash/common/indexes/timeline/construct_timeline_from_elements.d.ts +0 -26
  2336. package/dist/_esm5.processed/parsers/manifest/dash/common/indexes/timeline/construct_timeline_from_elements.js +0 -47
  2337. package/dist/_esm5.processed/parsers/manifest/dash/common/indexes/timeline/construct_timeline_from_previous_timeline.d.ts +0 -17
  2338. package/dist/_esm5.processed/parsers/manifest/dash/common/indexes/timeline/construct_timeline_from_previous_timeline.js +0 -83
  2339. package/dist/_esm5.processed/parsers/manifest/dash/common/indexes/timeline/convert_element_to_index_segment.d.ts +0 -37
  2340. package/dist/_esm5.processed/parsers/manifest/dash/common/indexes/timeline/convert_element_to_index_segment.js +0 -56
  2341. package/dist/_esm5.processed/parsers/manifest/dash/common/indexes/timeline/find_first_common_start_time.d.ts +0 -41
  2342. package/dist/_esm5.processed/parsers/manifest/dash/common/indexes/timeline/find_first_common_start_time.js +0 -127
  2343. package/dist/_esm5.processed/parsers/manifest/dash/common/indexes/timeline/index.d.ts +0 -17
  2344. package/dist/_esm5.processed/parsers/manifest/dash/common/indexes/timeline/index.js +0 -17
  2345. package/dist/_esm5.processed/parsers/manifest/dash/common/indexes/timeline/parse_s_element.d.ts +0 -34
  2346. package/dist/_esm5.processed/parsers/manifest/dash/common/indexes/timeline/parse_s_element.js +0 -57
  2347. package/dist/_esm5.processed/parsers/manifest/dash/common/indexes/timeline/timeline_representation_index.d.ts +0 -334
  2348. package/dist/_esm5.processed/parsers/manifest/dash/common/indexes/timeline/timeline_representation_index.js +0 -458
  2349. package/dist/_esm5.processed/parsers/manifest/dash/common/indexes/tokens.d.ts +0 -40
  2350. package/dist/_esm5.processed/parsers/manifest/dash/common/indexes/tokens.js +0 -109
  2351. package/dist/_esm5.processed/parsers/manifest/dash/common/indexes/utils.d.ts +0 -25
  2352. package/dist/_esm5.processed/parsers/manifest/dash/common/indexes/utils.js +0 -28
  2353. package/dist/_esm5.processed/parsers/manifest/dash/common/infer_adaptation_type.d.ts +0 -42
  2354. package/dist/_esm5.processed/parsers/manifest/dash/common/infer_adaptation_type.js +0 -114
  2355. package/dist/_esm5.processed/parsers/manifest/dash/common/manifest_bounds_calculator.d.ts +0 -88
  2356. package/dist/_esm5.processed/parsers/manifest/dash/common/manifest_bounds_calculator.js +0 -111
  2357. package/dist/_esm5.processed/parsers/manifest/dash/common/parse_adaptation_sets.d.ts +0 -49
  2358. package/dist/_esm5.processed/parsers/manifest/dash/common/parse_adaptation_sets.js +0 -373
  2359. package/dist/_esm5.processed/parsers/manifest/dash/common/parse_availability_start_time.d.ts +0 -22
  2360. package/dist/_esm5.processed/parsers/manifest/dash/common/parse_availability_start_time.js +0 -29
  2361. package/dist/_esm5.processed/parsers/manifest/dash/common/parse_mpd.d.ts +0 -97
  2362. package/dist/_esm5.processed/parsers/manifest/dash/common/parse_mpd.js +0 -247
  2363. package/dist/_esm5.processed/parsers/manifest/dash/common/parse_periods.d.ts +0 -63
  2364. package/dist/_esm5.processed/parsers/manifest/dash/common/parse_periods.js +0 -259
  2365. package/dist/_esm5.processed/parsers/manifest/dash/common/parse_representation_index.d.ts +0 -75
  2366. package/dist/_esm5.processed/parsers/manifest/dash/common/parse_representation_index.js +0 -96
  2367. package/dist/_esm5.processed/parsers/manifest/dash/common/parse_representations.d.ts +0 -46
  2368. package/dist/_esm5.processed/parsers/manifest/dash/common/parse_representations.js +0 -268
  2369. package/dist/_esm5.processed/parsers/manifest/dash/common/resolve_base_urls.d.ts +0 -26
  2370. package/dist/_esm5.processed/parsers/manifest/dash/common/resolve_base_urls.js +0 -44
  2371. package/dist/_esm5.processed/parsers/manifest/dash/index.d.ts +0 -16
  2372. package/dist/_esm5.processed/parsers/manifest/dash/index.js +0 -16
  2373. package/dist/_esm5.processed/parsers/manifest/dash/js-parser/node_parsers/AdaptationSet.d.ts +0 -23
  2374. package/dist/_esm5.processed/parsers/manifest/dash/js-parser/node_parsers/AdaptationSet.js +0 -307
  2375. package/dist/_esm5.processed/parsers/manifest/dash/js-parser/node_parsers/BaseURL.d.ts +0 -23
  2376. package/dist/_esm5.processed/parsers/manifest/dash/js-parser/node_parsers/BaseURL.js +0 -30
  2377. package/dist/_esm5.processed/parsers/manifest/dash/js-parser/node_parsers/ContentComponent.d.ts +0 -22
  2378. package/dist/_esm5.processed/parsers/manifest/dash/js-parser/node_parsers/ContentComponent.js +0 -41
  2379. package/dist/_esm5.processed/parsers/manifest/dash/js-parser/node_parsers/ContentProtection.d.ts +0 -21
  2380. package/dist/_esm5.processed/parsers/manifest/dash/js-parser/node_parsers/ContentProtection.js +0 -75
  2381. package/dist/_esm5.processed/parsers/manifest/dash/js-parser/node_parsers/EventStream.d.ts +0 -23
  2382. package/dist/_esm5.processed/parsers/manifest/dash/js-parser/node_parsers/EventStream.js +0 -94
  2383. package/dist/_esm5.processed/parsers/manifest/dash/js-parser/node_parsers/Initialization.d.ts +0 -21
  2384. package/dist/_esm5.processed/parsers/manifest/dash/js-parser/node_parsers/Initialization.js +0 -39
  2385. package/dist/_esm5.processed/parsers/manifest/dash/js-parser/node_parsers/MPD.d.ts +0 -21
  2386. package/dist/_esm5.processed/parsers/manifest/dash/js-parser/node_parsers/MPD.js +0 -144
  2387. package/dist/_esm5.processed/parsers/manifest/dash/js-parser/node_parsers/Period.d.ts +0 -21
  2388. package/dist/_esm5.processed/parsers/manifest/dash/js-parser/node_parsers/Period.js +0 -112
  2389. package/dist/_esm5.processed/parsers/manifest/dash/js-parser/node_parsers/Representation.d.ts +0 -21
  2390. package/dist/_esm5.processed/parsers/manifest/dash/js-parser/node_parsers/Representation.js +0 -187
  2391. package/dist/_esm5.processed/parsers/manifest/dash/js-parser/node_parsers/SegmentBase.d.ts +0 -22
  2392. package/dist/_esm5.processed/parsers/manifest/dash/js-parser/node_parsers/SegmentBase.js +0 -89
  2393. package/dist/_esm5.processed/parsers/manifest/dash/js-parser/node_parsers/SegmentList.d.ts +0 -21
  2394. package/dist/_esm5.processed/parsers/manifest/dash/js-parser/node_parsers/SegmentList.js +0 -40
  2395. package/dist/_esm5.processed/parsers/manifest/dash/js-parser/node_parsers/SegmentTemplate.d.ts +0 -23
  2396. package/dist/_esm5.processed/parsers/manifest/dash/js-parser/node_parsers/SegmentTemplate.js +0 -73
  2397. package/dist/_esm5.processed/parsers/manifest/dash/js-parser/node_parsers/SegmentTimeline.d.ts +0 -21
  2398. package/dist/_esm5.processed/parsers/manifest/dash/js-parser/node_parsers/SegmentTimeline.js +0 -30
  2399. package/dist/_esm5.processed/parsers/manifest/dash/js-parser/node_parsers/SegmentURL.d.ts +0 -23
  2400. package/dist/_esm5.processed/parsers/manifest/dash/js-parser/node_parsers/SegmentURL.js +0 -49
  2401. package/dist/_esm5.processed/parsers/manifest/dash/js-parser/node_parsers/utils.d.ts +0 -178
  2402. package/dist/_esm5.processed/parsers/manifest/dash/js-parser/node_parsers/utils.js +0 -308
  2403. package/dist/_esm5.processed/parsers/manifest/dash/js-parser/parse_from_document.d.ts +0 -24
  2404. package/dist/_esm5.processed/parsers/manifest/dash/js-parser/parse_from_document.js +0 -103
  2405. package/dist/_esm5.processed/parsers/manifest/dash/node_parser_types.d.ts +0 -395
  2406. package/dist/_esm5.processed/parsers/manifest/dash/node_parser_types.js +0 -16
  2407. package/dist/_esm5.processed/parsers/manifest/dash/parsers_types.d.ts +0 -83
  2408. package/dist/_esm5.processed/parsers/manifest/dash/parsers_types.js +0 -16
  2409. package/dist/_esm5.processed/parsers/manifest/dash/wasm-parser/index.d.ts +0 -18
  2410. package/dist/_esm5.processed/parsers/manifest/dash/wasm-parser/index.js +0 -17
  2411. package/dist/_esm5.processed/parsers/manifest/dash/wasm-parser/ts/dash-wasm-parser.d.ts +0 -111
  2412. package/dist/_esm5.processed/parsers/manifest/dash/wasm-parser/ts/dash-wasm-parser.js +0 -377
  2413. package/dist/_esm5.processed/parsers/manifest/dash/wasm-parser/ts/generators/AdaptationSet.d.ts +0 -31
  2414. package/dist/_esm5.processed/parsers/manifest/dash/wasm-parser/ts/generators/AdaptationSet.js +0 -277
  2415. package/dist/_esm5.processed/parsers/manifest/dash/wasm-parser/ts/generators/BaseURL.d.ts +0 -24
  2416. package/dist/_esm5.processed/parsers/manifest/dash/wasm-parser/ts/generators/BaseURL.js +0 -30
  2417. package/dist/_esm5.processed/parsers/manifest/dash/wasm-parser/ts/generators/ContentComponent.d.ts +0 -24
  2418. package/dist/_esm5.processed/parsers/manifest/dash/wasm-parser/ts/generators/ContentComponent.js +0 -41
  2419. package/dist/_esm5.processed/parsers/manifest/dash/wasm-parser/ts/generators/ContentProtection.d.ts +0 -23
  2420. package/dist/_esm5.processed/parsers/manifest/dash/wasm-parser/ts/generators/ContentProtection.js +0 -49
  2421. package/dist/_esm5.processed/parsers/manifest/dash/wasm-parser/ts/generators/EventStream.d.ts +0 -32
  2422. package/dist/_esm5.processed/parsers/manifest/dash/wasm-parser/ts/generators/EventStream.js +0 -112
  2423. package/dist/_esm5.processed/parsers/manifest/dash/wasm-parser/ts/generators/MPD.d.ts +0 -27
  2424. package/dist/_esm5.processed/parsers/manifest/dash/wasm-parser/ts/generators/MPD.js +0 -145
  2425. package/dist/_esm5.processed/parsers/manifest/dash/wasm-parser/ts/generators/Period.d.ts +0 -32
  2426. package/dist/_esm5.processed/parsers/manifest/dash/wasm-parser/ts/generators/Period.js +0 -130
  2427. package/dist/_esm5.processed/parsers/manifest/dash/wasm-parser/ts/generators/Representation.d.ts +0 -31
  2428. package/dist/_esm5.processed/parsers/manifest/dash/wasm-parser/ts/generators/Representation.js +0 -172
  2429. package/dist/_esm5.processed/parsers/manifest/dash/wasm-parser/ts/generators/Scheme.d.ts +0 -24
  2430. package/dist/_esm5.processed/parsers/manifest/dash/wasm-parser/ts/generators/Scheme.js +0 -35
  2431. package/dist/_esm5.processed/parsers/manifest/dash/wasm-parser/ts/generators/SegmentBase.d.ts +0 -18
  2432. package/dist/_esm5.processed/parsers/manifest/dash/wasm-parser/ts/generators/SegmentBase.js +0 -93
  2433. package/dist/_esm5.processed/parsers/manifest/dash/wasm-parser/ts/generators/SegmentList.d.ts +0 -25
  2434. package/dist/_esm5.processed/parsers/manifest/dash/wasm-parser/ts/generators/SegmentList.js +0 -45
  2435. package/dist/_esm5.processed/parsers/manifest/dash/wasm-parser/ts/generators/SegmentTemplate.d.ts +0 -18
  2436. package/dist/_esm5.processed/parsers/manifest/dash/wasm-parser/ts/generators/SegmentTemplate.js +0 -108
  2437. package/dist/_esm5.processed/parsers/manifest/dash/wasm-parser/ts/generators/SegmentUrl.d.ts +0 -25
  2438. package/dist/_esm5.processed/parsers/manifest/dash/wasm-parser/ts/generators/SegmentUrl.js +0 -54
  2439. package/dist/_esm5.processed/parsers/manifest/dash/wasm-parser/ts/generators/XLink.d.ts +0 -28
  2440. package/dist/_esm5.processed/parsers/manifest/dash/wasm-parser/ts/generators/XLink.js +0 -47
  2441. package/dist/_esm5.processed/parsers/manifest/dash/wasm-parser/ts/generators/index.d.ts +0 -16
  2442. package/dist/_esm5.processed/parsers/manifest/dash/wasm-parser/ts/generators/index.js +0 -16
  2443. package/dist/_esm5.processed/parsers/manifest/dash/wasm-parser/ts/generators/root.d.ts +0 -27
  2444. package/dist/_esm5.processed/parsers/manifest/dash/wasm-parser/ts/generators/root.js +0 -45
  2445. package/dist/_esm5.processed/parsers/manifest/dash/wasm-parser/ts/parsers_stack.d.ts +0 -38
  2446. package/dist/_esm5.processed/parsers/manifest/dash/wasm-parser/ts/parsers_stack.js +0 -57
  2447. package/dist/_esm5.processed/parsers/manifest/dash/wasm-parser/ts/types.d.ts +0 -145
  2448. package/dist/_esm5.processed/parsers/manifest/dash/wasm-parser/ts/types.js +0 -16
  2449. package/dist/_esm5.processed/parsers/manifest/dash/wasm-parser/ts/utils.d.ts +0 -29
  2450. package/dist/_esm5.processed/parsers/manifest/dash/wasm-parser/ts/utils.js +0 -36
  2451. package/dist/_esm5.processed/parsers/manifest/index.d.ts +0 -16
  2452. package/dist/_esm5.processed/parsers/manifest/index.js +0 -16
  2453. package/dist/_esm5.processed/parsers/manifest/local/index.d.ts +0 -18
  2454. package/dist/_esm5.processed/parsers/manifest/local/index.js +0 -17
  2455. package/dist/_esm5.processed/parsers/manifest/local/parse_local_manifest.d.ts +0 -22
  2456. package/dist/_esm5.processed/parsers/manifest/local/parse_local_manifest.js +0 -125
  2457. package/dist/_esm5.processed/parsers/manifest/local/representation_index.d.ts +0 -81
  2458. package/dist/_esm5.processed/parsers/manifest/local/representation_index.js +0 -234
  2459. package/dist/_esm5.processed/parsers/manifest/local/types.d.ts +0 -285
  2460. package/dist/_esm5.processed/parsers/manifest/local/types.js +0 -16
  2461. package/dist/_esm5.processed/parsers/manifest/metaplaylist/index.d.ts +0 -18
  2462. package/dist/_esm5.processed/parsers/manifest/metaplaylist/index.js +0 -17
  2463. package/dist/_esm5.processed/parsers/manifest/metaplaylist/metaplaylist_parser.d.ts +0 -64
  2464. package/dist/_esm5.processed/parsers/manifest/metaplaylist/metaplaylist_parser.js +0 -254
  2465. package/dist/_esm5.processed/parsers/manifest/metaplaylist/representation_index.d.ts +0 -145
  2466. package/dist/_esm5.processed/parsers/manifest/metaplaylist/representation_index.js +0 -216
  2467. package/dist/_esm5.processed/parsers/manifest/smooth/create_parser.d.ts +0 -34
  2468. package/dist/_esm5.processed/parsers/manifest/smooth/create_parser.js +0 -499
  2469. package/dist/_esm5.processed/parsers/manifest/smooth/get_codecs.d.ts +0 -26
  2470. package/dist/_esm5.processed/parsers/manifest/smooth/get_codecs.js +0 -50
  2471. package/dist/_esm5.processed/parsers/manifest/smooth/index.d.ts +0 -19
  2472. package/dist/_esm5.processed/parsers/manifest/smooth/index.js +0 -19
  2473. package/dist/_esm5.processed/parsers/manifest/smooth/parse_C_nodes.d.ts +0 -26
  2474. package/dist/_esm5.processed/parsers/manifest/smooth/parse_C_nodes.js +0 -60
  2475. package/dist/_esm5.processed/parsers/manifest/smooth/parse_protection_node.d.ts +0 -29
  2476. package/dist/_esm5.processed/parsers/manifest/smooth/parse_protection_node.js +0 -58
  2477. package/dist/_esm5.processed/parsers/manifest/smooth/representation_index.d.ts +0 -288
  2478. package/dist/_esm5.processed/parsers/manifest/smooth/representation_index.js +0 -454
  2479. package/dist/_esm5.processed/parsers/manifest/smooth/utils/add_segment_infos.d.ts +0 -41
  2480. package/dist/_esm5.processed/parsers/manifest/smooth/utils/add_segment_infos.js +0 -60
  2481. package/dist/_esm5.processed/parsers/manifest/smooth/utils/parseBoolean.d.ts +0 -20
  2482. package/dist/_esm5.processed/parsers/manifest/smooth/utils/parseBoolean.js +0 -30
  2483. package/dist/_esm5.processed/parsers/manifest/smooth/utils/reduceChildren.d.ts +0 -23
  2484. package/dist/_esm5.processed/parsers/manifest/smooth/utils/reduceChildren.js +0 -31
  2485. package/dist/_esm5.processed/parsers/manifest/smooth/utils/tokens.d.ts +0 -28
  2486. package/dist/_esm5.processed/parsers/manifest/smooth/utils/tokens.js +0 -35
  2487. package/dist/_esm5.processed/parsers/manifest/types.d.ts +0 -379
  2488. package/dist/_esm5.processed/parsers/manifest/types.js +0 -16
  2489. package/dist/_esm5.processed/parsers/manifest/utils/check_manifest_ids.d.ts +0 -25
  2490. package/dist/_esm5.processed/parsers/manifest/utils/check_manifest_ids.js +0 -76
  2491. package/dist/_esm5.processed/parsers/manifest/utils/clear_timeline_from_position.d.ts +0 -24
  2492. package/dist/_esm5.processed/parsers/manifest/utils/clear_timeline_from_position.js +0 -69
  2493. package/dist/_esm5.processed/parsers/manifest/utils/get_first_time_from_adaptation.d.ts +0 -27
  2494. package/dist/_esm5.processed/parsers/manifest/utils/get_first_time_from_adaptation.js +0 -43
  2495. package/dist/_esm5.processed/parsers/manifest/utils/get_last_time_from_adaptation.d.ts +0 -29
  2496. package/dist/_esm5.processed/parsers/manifest/utils/get_last_time_from_adaptation.js +0 -45
  2497. package/dist/_esm5.processed/parsers/manifest/utils/get_maximum_positions.d.ts +0 -24
  2498. package/dist/_esm5.processed/parsers/manifest/utils/get_maximum_positions.js +0 -72
  2499. package/dist/_esm5.processed/parsers/manifest/utils/get_minimum_position.d.ts +0 -21
  2500. package/dist/_esm5.processed/parsers/manifest/utils/get_minimum_position.js +0 -68
  2501. package/dist/_esm5.processed/parsers/manifest/utils/index_helpers.d.ts +0 -88
  2502. package/dist/_esm5.processed/parsers/manifest/utils/index_helpers.js +0 -147
  2503. package/dist/_esm5.processed/parsers/manifest/utils/is_segment_still_available.d.ts +0 -29
  2504. package/dist/_esm5.processed/parsers/manifest/utils/is_segment_still_available.js +0 -51
  2505. package/dist/_esm5.processed/parsers/manifest/utils/update_segment_timeline.d.ts +0 -33
  2506. package/dist/_esm5.processed/parsers/manifest/utils/update_segment_timeline.js +0 -138
  2507. package/dist/_esm5.processed/parsers/texttracks/index.d.ts +0 -16
  2508. package/dist/_esm5.processed/parsers/texttracks/index.js +0 -16
  2509. package/dist/_esm5.processed/parsers/texttracks/sami/html.d.ts +0 -29
  2510. package/dist/_esm5.processed/parsers/texttracks/sami/html.js +0 -189
  2511. package/dist/_esm5.processed/parsers/texttracks/sami/native.d.ts +0 -34
  2512. package/dist/_esm5.processed/parsers/texttracks/sami/native.js +0 -160
  2513. package/dist/_esm5.processed/parsers/texttracks/srt/find_end_of_cue_block.d.ts +0 -29
  2514. package/dist/_esm5.processed/parsers/texttracks/srt/find_end_of_cue_block.js +0 -39
  2515. package/dist/_esm5.processed/parsers/texttracks/srt/get_cue_blocks.d.ts +0 -22
  2516. package/dist/_esm5.processed/parsers/texttracks/srt/get_cue_blocks.js +0 -47
  2517. package/dist/_esm5.processed/parsers/texttracks/srt/html.d.ts +0 -26
  2518. package/dist/_esm5.processed/parsers/texttracks/srt/html.js +0 -153
  2519. package/dist/_esm5.processed/parsers/texttracks/srt/native.d.ts +0 -28
  2520. package/dist/_esm5.processed/parsers/texttracks/srt/native.js +0 -57
  2521. package/dist/_esm5.processed/parsers/texttracks/srt/parse_cue.d.ts +0 -30
  2522. package/dist/_esm5.processed/parsers/texttracks/srt/parse_cue.js +0 -60
  2523. package/dist/_esm5.processed/parsers/texttracks/srt/parse_timestamp.d.ts +0 -21
  2524. package/dist/_esm5.processed/parsers/texttracks/srt/parse_timestamp.js +0 -33
  2525. package/dist/_esm5.processed/parsers/texttracks/ttml/get_parameters.d.ts +0 -32
  2526. package/dist/_esm5.processed/parsers/texttracks/ttml/get_parameters.js +0 -84
  2527. package/dist/_esm5.processed/parsers/texttracks/ttml/get_styling.d.ts +0 -41
  2528. package/dist/_esm5.processed/parsers/texttracks/ttml/get_styling.js +0 -132
  2529. package/dist/_esm5.processed/parsers/texttracks/ttml/get_time_delimiters.d.ts +0 -26
  2530. package/dist/_esm5.processed/parsers/texttracks/ttml/get_time_delimiters.js +0 -41
  2531. package/dist/_esm5.processed/parsers/texttracks/ttml/html/apply_default_ttml_paragraph_style.d.ts +0 -48
  2532. package/dist/_esm5.processed/parsers/texttracks/ttml/html/apply_default_ttml_paragraph_style.js +0 -61
  2533. package/dist/_esm5.processed/parsers/texttracks/ttml/html/apply_extent.d.ts +0 -21
  2534. package/dist/_esm5.processed/parsers/texttracks/ttml/html/apply_extent.js +0 -61
  2535. package/dist/_esm5.processed/parsers/texttracks/ttml/html/apply_font_size.d.ts +0 -21
  2536. package/dist/_esm5.processed/parsers/texttracks/ttml/html/apply_font_size.js +0 -59
  2537. package/dist/_esm5.processed/parsers/texttracks/ttml/html/apply_line_height.d.ts +0 -20
  2538. package/dist/_esm5.processed/parsers/texttracks/ttml/html/apply_line_height.js +0 -45
  2539. package/dist/_esm5.processed/parsers/texttracks/ttml/html/apply_origin.d.ts +0 -20
  2540. package/dist/_esm5.processed/parsers/texttracks/ttml/html/apply_origin.js +0 -60
  2541. package/dist/_esm5.processed/parsers/texttracks/ttml/html/apply_padding.d.ts +0 -20
  2542. package/dist/_esm5.processed/parsers/texttracks/ttml/html/apply_padding.js +0 -139
  2543. package/dist/_esm5.processed/parsers/texttracks/ttml/html/create_element.d.ts +0 -32
  2544. package/dist/_esm5.processed/parsers/texttracks/ttml/html/create_element.js +0 -451
  2545. package/dist/_esm5.processed/parsers/texttracks/ttml/html/generate_css_test_outline.d.ts +0 -26
  2546. package/dist/_esm5.processed/parsers/texttracks/ttml/html/generate_css_test_outline.js +0 -41
  2547. package/dist/_esm5.processed/parsers/texttracks/ttml/html/index.d.ts +0 -21
  2548. package/dist/_esm5.processed/parsers/texttracks/ttml/html/index.js +0 -21
  2549. package/dist/_esm5.processed/parsers/texttracks/ttml/html/parse_cue.d.ts +0 -26
  2550. package/dist/_esm5.processed/parsers/texttracks/ttml/html/parse_cue.js +0 -38
  2551. package/dist/_esm5.processed/parsers/texttracks/ttml/html/parse_ttml_to_div.d.ts +0 -34
  2552. package/dist/_esm5.processed/parsers/texttracks/ttml/html/parse_ttml_to_div.js +0 -50
  2553. package/dist/_esm5.processed/parsers/texttracks/ttml/html/ttml_color_to_css_color.d.ts +0 -21
  2554. package/dist/_esm5.processed/parsers/texttracks/ttml/html/ttml_color_to_css_color.js +0 -57
  2555. package/dist/_esm5.processed/parsers/texttracks/ttml/native/index.d.ts +0 -21
  2556. package/dist/_esm5.processed/parsers/texttracks/ttml/native/index.js +0 -21
  2557. package/dist/_esm5.processed/parsers/texttracks/ttml/native/parse_cue.d.ts +0 -30
  2558. package/dist/_esm5.processed/parsers/texttracks/ttml/native/parse_cue.js +0 -202
  2559. package/dist/_esm5.processed/parsers/texttracks/ttml/native/parse_ttml_to_vtt.d.ts +0 -21
  2560. package/dist/_esm5.processed/parsers/texttracks/ttml/native/parse_ttml_to_vtt.js +0 -33
  2561. package/dist/_esm5.processed/parsers/texttracks/ttml/parse_ttml.d.ts +0 -43
  2562. package/dist/_esm5.processed/parsers/texttracks/ttml/parse_ttml.js +0 -156
  2563. package/dist/_esm5.processed/parsers/texttracks/ttml/regexps.d.ts +0 -28
  2564. package/dist/_esm5.processed/parsers/texttracks/ttml/regexps.js +0 -35
  2565. package/dist/_esm5.processed/parsers/texttracks/ttml/resolve_styles_inheritance.d.ts +0 -49
  2566. package/dist/_esm5.processed/parsers/texttracks/ttml/resolve_styles_inheritance.js +0 -83
  2567. package/dist/_esm5.processed/parsers/texttracks/ttml/time_parsing.d.ts +0 -30
  2568. package/dist/_esm5.processed/parsers/texttracks/ttml/time_parsing.js +0 -124
  2569. package/dist/_esm5.processed/parsers/texttracks/ttml/xml_utils.d.ts +0 -70
  2570. package/dist/_esm5.processed/parsers/texttracks/ttml/xml_utils.js +0 -149
  2571. package/dist/_esm5.processed/parsers/texttracks/types.d.ts +0 -23
  2572. package/dist/_esm5.processed/parsers/texttracks/types.js +0 -16
  2573. package/dist/_esm5.processed/parsers/texttracks/webvtt/get_cue_blocks.d.ts +0 -24
  2574. package/dist/_esm5.processed/parsers/texttracks/webvtt/get_cue_blocks.js +0 -44
  2575. package/dist/_esm5.processed/parsers/texttracks/webvtt/get_style_blocks.d.ts +0 -24
  2576. package/dist/_esm5.processed/parsers/texttracks/webvtt/get_style_blocks.js +0 -51
  2577. package/dist/_esm5.processed/parsers/texttracks/webvtt/html/convert_payload_to_html.d.ts +0 -22
  2578. package/dist/_esm5.processed/parsers/texttracks/webvtt/html/convert_payload_to_html.js +0 -35
  2579. package/dist/_esm5.processed/parsers/texttracks/webvtt/html/create_default_style_elements.d.ts +0 -2
  2580. package/dist/_esm5.processed/parsers/texttracks/webvtt/html/create_default_style_elements.js +0 -22
  2581. package/dist/_esm5.processed/parsers/texttracks/webvtt/html/create_style_attribute.d.ts +0 -21
  2582. package/dist/_esm5.processed/parsers/texttracks/webvtt/html/create_style_attribute.js +0 -175
  2583. package/dist/_esm5.processed/parsers/texttracks/webvtt/html/create_styled_element.d.ts +0 -25
  2584. package/dist/_esm5.processed/parsers/texttracks/webvtt/html/create_styled_element.js +0 -83
  2585. package/dist/_esm5.processed/parsers/texttracks/webvtt/html/index.d.ts +0 -22
  2586. package/dist/_esm5.processed/parsers/texttracks/webvtt/html/index.js +0 -21
  2587. package/dist/_esm5.processed/parsers/texttracks/webvtt/html/parse_style_block.d.ts +0 -27
  2588. package/dist/_esm5.processed/parsers/texttracks/webvtt/html/parse_style_block.js +0 -72
  2589. package/dist/_esm5.processed/parsers/texttracks/webvtt/html/parse_webvtt_to_div.d.ts +0 -31
  2590. package/dist/_esm5.processed/parsers/texttracks/webvtt/html/parse_webvtt_to_div.js +0 -55
  2591. package/dist/_esm5.processed/parsers/texttracks/webvtt/html/to_html.d.ts +0 -43
  2592. package/dist/_esm5.processed/parsers/texttracks/webvtt/html/to_html.js +0 -70
  2593. package/dist/_esm5.processed/parsers/texttracks/webvtt/native/index.d.ts +0 -21
  2594. package/dist/_esm5.processed/parsers/texttracks/webvtt/native/index.js +0 -21
  2595. package/dist/_esm5.processed/parsers/texttracks/webvtt/native/parse_vtt_to_cues.d.ts +0 -28
  2596. package/dist/_esm5.processed/parsers/texttracks/webvtt/native/parse_vtt_to_cues.js +0 -58
  2597. package/dist/_esm5.processed/parsers/texttracks/webvtt/native/set_settings_on_cue.d.ts +0 -23
  2598. package/dist/_esm5.processed/parsers/texttracks/webvtt/native/set_settings_on_cue.js +0 -80
  2599. package/dist/_esm5.processed/parsers/texttracks/webvtt/native/to_native_cue.d.ts +0 -25
  2600. package/dist/_esm5.processed/parsers/texttracks/webvtt/native/to_native_cue.js +0 -25
  2601. package/dist/_esm5.processed/parsers/texttracks/webvtt/parse_cue_block.d.ts +0 -33
  2602. package/dist/_esm5.processed/parsers/texttracks/webvtt/parse_cue_block.js +0 -96
  2603. package/dist/_esm5.processed/parsers/texttracks/webvtt/parse_timestamp.d.ts +0 -21
  2604. package/dist/_esm5.processed/parsers/texttracks/webvtt/parse_timestamp.js +0 -34
  2605. package/dist/_esm5.processed/parsers/texttracks/webvtt/utils.d.ts +0 -56
  2606. package/dist/_esm5.processed/parsers/texttracks/webvtt/utils.js +0 -113
  2607. package/dist/_esm5.processed/public_types.d.ts +0 -737
  2608. package/dist/_esm5.processed/public_types.js +0 -16
  2609. package/dist/_esm5.processed/tools/TextTrackRenderer/index.d.ts +0 -22
  2610. package/dist/_esm5.processed/tools/TextTrackRenderer/index.js +0 -22
  2611. package/dist/_esm5.processed/tools/TextTrackRenderer/text_track_renderer.d.ts +0 -69
  2612. package/dist/_esm5.processed/tools/TextTrackRenderer/text_track_renderer.js +0 -78
  2613. package/dist/_esm5.processed/tools/index.d.ts +0 -18
  2614. package/dist/_esm5.processed/tools/index.js +0 -19
  2615. package/dist/_esm5.processed/tools/string_utils.d.ts +0 -16
  2616. package/dist/_esm5.processed/tools/string_utils.js +0 -16
  2617. package/dist/_esm5.processed/transports/dash/add_segment_integrity_checks_to_loader.d.ts +0 -24
  2618. package/dist/_esm5.processed/transports/dash/add_segment_integrity_checks_to_loader.js +0 -93
  2619. package/dist/_esm5.processed/transports/dash/construct_segment_url.d.ts +0 -18
  2620. package/dist/_esm5.processed/transports/dash/construct_segment_url.js +0 -21
  2621. package/dist/_esm5.processed/transports/dash/extract_complete_chunks.d.ts +0 -24
  2622. package/dist/_esm5.processed/transports/dash/extract_complete_chunks.js +0 -59
  2623. package/dist/_esm5.processed/transports/dash/get_events_out_of_emsgs.d.ts +0 -28
  2624. package/dist/_esm5.processed/transports/dash/get_events_out_of_emsgs.js +0 -92
  2625. package/dist/_esm5.processed/transports/dash/image_pipelines.d.ts +0 -38
  2626. package/dist/_esm5.processed/transports/dash/image_pipelines.js +0 -129
  2627. package/dist/_esm5.processed/transports/dash/index.d.ts +0 -21
  2628. package/dist/_esm5.processed/transports/dash/index.js +0 -21
  2629. package/dist/_esm5.processed/transports/dash/init_segment_loader.d.ts +0 -28
  2630. package/dist/_esm5.processed/transports/dash/init_segment_loader.js +0 -68
  2631. package/dist/_esm5.processed/transports/dash/low_latency_segment_loader.d.ts +0 -30
  2632. package/dist/_esm5.processed/transports/dash/low_latency_segment_loader.js +0 -64
  2633. package/dist/_esm5.processed/transports/dash/manifest_parser.d.ts +0 -18
  2634. package/dist/_esm5.processed/transports/dash/manifest_parser.js +0 -277
  2635. package/dist/_esm5.processed/transports/dash/pipelines.d.ts +0 -23
  2636. package/dist/_esm5.processed/transports/dash/pipelines.js +0 -58
  2637. package/dist/_esm5.processed/transports/dash/segment_loader.d.ts +0 -38
  2638. package/dist/_esm5.processed/transports/dash/segment_loader.js +0 -162
  2639. package/dist/_esm5.processed/transports/dash/segment_parser.d.ts +0 -23
  2640. package/dist/_esm5.processed/transports/dash/segment_parser.js +0 -129
  2641. package/dist/_esm5.processed/transports/dash/text_loader.d.ts +0 -25
  2642. package/dist/_esm5.processed/transports/dash/text_loader.js +0 -82
  2643. package/dist/_esm5.processed/transports/dash/text_parser.d.ts +0 -25
  2644. package/dist/_esm5.processed/transports/dash/text_parser.js +0 -169
  2645. package/dist/_esm5.processed/transports/index.d.ts +0 -16
  2646. package/dist/_esm5.processed/transports/index.js +0 -16
  2647. package/dist/_esm5.processed/transports/local/index.d.ts +0 -17
  2648. package/dist/_esm5.processed/transports/local/index.js +0 -17
  2649. package/dist/_esm5.processed/transports/local/pipelines.d.ts +0 -22
  2650. package/dist/_esm5.processed/transports/local/pipelines.js +0 -73
  2651. package/dist/_esm5.processed/transports/local/segment_loader.d.ts +0 -28
  2652. package/dist/_esm5.processed/transports/local/segment_loader.js +0 -144
  2653. package/dist/_esm5.processed/transports/local/segment_parser.d.ts +0 -20
  2654. package/dist/_esm5.processed/transports/local/segment_parser.js +0 -69
  2655. package/dist/_esm5.processed/transports/local/text_parser.d.ts +0 -27
  2656. package/dist/_esm5.processed/transports/local/text_parser.js +0 -131
  2657. package/dist/_esm5.processed/transports/metaplaylist/index.d.ts +0 -21
  2658. package/dist/_esm5.processed/transports/metaplaylist/index.js +0 -21
  2659. package/dist/_esm5.processed/transports/metaplaylist/manifest_loader.d.ts +0 -26
  2660. package/dist/_esm5.processed/transports/metaplaylist/manifest_loader.js +0 -41
  2661. package/dist/_esm5.processed/transports/metaplaylist/pipelines.d.ts +0 -17
  2662. package/dist/_esm5.processed/transports/metaplaylist/pipelines.js +0 -254
  2663. package/dist/_esm5.processed/transports/smooth/extract_timings_infos.d.ts +0 -62
  2664. package/dist/_esm5.processed/transports/smooth/extract_timings_infos.js +0 -78
  2665. package/dist/_esm5.processed/transports/smooth/index.d.ts +0 -21
  2666. package/dist/_esm5.processed/transports/smooth/index.js +0 -21
  2667. package/dist/_esm5.processed/transports/smooth/isobmff/create_audio_init_segment.d.ts +0 -29
  2668. package/dist/_esm5.processed/transports/smooth/isobmff/create_audio_init_segment.js +0 -52
  2669. package/dist/_esm5.processed/transports/smooth/isobmff/create_boxes.d.ts +0 -171
  2670. package/dist/_esm5.processed/transports/smooth/isobmff/create_boxes.js +0 -328
  2671. package/dist/_esm5.processed/transports/smooth/isobmff/create_init_segment.d.ts +0 -33
  2672. package/dist/_esm5.processed/transports/smooth/isobmff/create_init_segment.js +0 -65
  2673. package/dist/_esm5.processed/transports/smooth/isobmff/create_traf_box.d.ts +0 -16
  2674. package/dist/_esm5.processed/transports/smooth/isobmff/create_traf_box.js +0 -24
  2675. package/dist/_esm5.processed/transports/smooth/isobmff/create_video_init_segment.d.ts +0 -29
  2676. package/dist/_esm5.processed/transports/smooth/isobmff/create_video_init_segment.js +0 -57
  2677. package/dist/_esm5.processed/transports/smooth/isobmff/get_aaces_header.d.ts +0 -27
  2678. package/dist/_esm5.processed/transports/smooth/isobmff/get_aaces_header.js +0 -55
  2679. package/dist/_esm5.processed/transports/smooth/isobmff/index.d.ts +0 -21
  2680. package/dist/_esm5.processed/transports/smooth/isobmff/index.js +0 -21
  2681. package/dist/_esm5.processed/transports/smooth/isobmff/parse_tfrf.d.ts +0 -24
  2682. package/dist/_esm5.processed/transports/smooth/isobmff/parse_tfrf.js +0 -47
  2683. package/dist/_esm5.processed/transports/smooth/isobmff/parse_tfxd.d.ts +0 -24
  2684. package/dist/_esm5.processed/transports/smooth/isobmff/parse_tfxd.js +0 -31
  2685. package/dist/_esm5.processed/transports/smooth/isobmff/patch_segment.d.ts +0 -23
  2686. package/dist/_esm5.processed/transports/smooth/isobmff/patch_segment.js +0 -127
  2687. package/dist/_esm5.processed/transports/smooth/pipelines.d.ts +0 -17
  2688. package/dist/_esm5.processed/transports/smooth/pipelines.js +0 -440
  2689. package/dist/_esm5.processed/transports/smooth/segment_loader.d.ts +0 -27
  2690. package/dist/_esm5.processed/transports/smooth/segment_loader.js +0 -198
  2691. package/dist/_esm5.processed/transports/smooth/utils.d.ts +0 -51
  2692. package/dist/_esm5.processed/transports/smooth/utils.js +0 -86
  2693. package/dist/_esm5.processed/transports/types.d.ts +0 -687
  2694. package/dist/_esm5.processed/transports/types.js +0 -16
  2695. package/dist/_esm5.processed/transports/utils/byte_range.d.ts +0 -21
  2696. package/dist/_esm5.processed/transports/utils/byte_range.js +0 -25
  2697. package/dist/_esm5.processed/transports/utils/call_custom_manifest_loader.d.ts +0 -19
  2698. package/dist/_esm5.processed/transports/utils/call_custom_manifest_loader.js +0 -91
  2699. package/dist/_esm5.processed/transports/utils/check_isobmff_integrity.d.ts +0 -23
  2700. package/dist/_esm5.processed/transports/utils/check_isobmff_integrity.js +0 -46
  2701. package/dist/_esm5.processed/transports/utils/find_complete_box.d.ts +0 -25
  2702. package/dist/_esm5.processed/transports/utils/find_complete_box.js +0 -53
  2703. package/dist/_esm5.processed/transports/utils/generate_manifest_loader.d.ts +0 -26
  2704. package/dist/_esm5.processed/transports/utils/generate_manifest_loader.js +0 -59
  2705. package/dist/_esm5.processed/transports/utils/get_isobmff_timing_infos.d.ts +0 -29
  2706. package/dist/_esm5.processed/transports/utils/get_isobmff_timing_infos.js +0 -66
  2707. package/dist/_esm5.processed/transports/utils/infer_segment_container.d.ts +0 -29
  2708. package/dist/_esm5.processed/transports/utils/infer_segment_container.js +0 -46
  2709. package/dist/_esm5.processed/transports/utils/parse_text_track.d.ts +0 -60
  2710. package/dist/_esm5.processed/transports/utils/parse_text_track.js +0 -136
  2711. package/dist/_esm5.processed/utils/are_arrays_of_numbers_equal.d.ts +0 -22
  2712. package/dist/_esm5.processed/utils/are_arrays_of_numbers_equal.js +0 -35
  2713. package/dist/_esm5.processed/utils/are_codecs_compatible.d.ts +0 -25
  2714. package/dist/_esm5.processed/utils/are_codecs_compatible.js +0 -44
  2715. package/dist/_esm5.processed/utils/array_find.d.ts +0 -23
  2716. package/dist/_esm5.processed/utils/array_find.js +0 -35
  2717. package/dist/_esm5.processed/utils/array_find_index.d.ts +0 -23
  2718. package/dist/_esm5.processed/utils/array_find_index.js +0 -34
  2719. package/dist/_esm5.processed/utils/array_includes.d.ts +0 -53
  2720. package/dist/_esm5.processed/utils/array_includes.js +0 -83
  2721. package/dist/_esm5.processed/utils/assert.d.ts +0 -34
  2722. package/dist/_esm5.processed/utils/assert.js +0 -52
  2723. package/dist/_esm5.processed/utils/assert_unreachable.d.ts +0 -40
  2724. package/dist/_esm5.processed/utils/assert_unreachable.js +0 -43
  2725. package/dist/_esm5.processed/utils/base64.d.ts +0 -14
  2726. package/dist/_esm5.processed/utils/base64.js +0 -147
  2727. package/dist/_esm5.processed/utils/byte_parsing.d.ts +0 -123
  2728. package/dist/_esm5.processed/utils/byte_parsing.js +0 -231
  2729. package/dist/_esm5.processed/utils/cancellable_sleep.d.ts +0 -30
  2730. package/dist/_esm5.processed/utils/cancellable_sleep.js +0 -35
  2731. package/dist/_esm5.processed/utils/create_cancellable_promise.d.ts +0 -26
  2732. package/dist/_esm5.processed/utils/create_cancellable_promise.js +0 -52
  2733. package/dist/_esm5.processed/utils/deep_merge.d.ts +0 -9
  2734. package/dist/_esm5.processed/utils/deep_merge.js +0 -54
  2735. package/dist/_esm5.processed/utils/event_emitter.d.ts +0 -62
  2736. package/dist/_esm5.processed/utils/event_emitter.js +0 -103
  2737. package/dist/_esm5.processed/utils/flat_map.d.ts +0 -22
  2738. package/dist/_esm5.processed/utils/flat_map.js +0 -37
  2739. package/dist/_esm5.processed/utils/get_fuzzed_delay.d.ts +0 -21
  2740. package/dist/_esm5.processed/utils/get_fuzzed_delay.js +0 -25
  2741. package/dist/_esm5.processed/utils/hash_buffer.d.ts +0 -32
  2742. package/dist/_esm5.processed/utils/hash_buffer.js +0 -41
  2743. package/dist/_esm5.processed/utils/id_generator.d.ts +0 -21
  2744. package/dist/_esm5.processed/utils/id_generator.js +0 -33
  2745. package/dist/_esm5.processed/utils/initialization_segment_cache.d.ts +0 -42
  2746. package/dist/_esm5.processed/utils/initialization_segment_cache.js +0 -51
  2747. package/dist/_esm5.processed/utils/is_non_empty_string.d.ts +0 -20
  2748. package/dist/_esm5.processed/utils/is_non_empty_string.js +0 -22
  2749. package/dist/_esm5.processed/utils/is_null_or_undefined.d.ts +0 -24
  2750. package/dist/_esm5.processed/utils/is_null_or_undefined.js +0 -26
  2751. package/dist/_esm5.processed/utils/languages/ISO_639-1_to_ISO_639-3.d.ts +0 -22
  2752. package/dist/_esm5.processed/utils/languages/ISO_639-1_to_ISO_639-3.js +0 -205
  2753. package/dist/_esm5.processed/utils/languages/ISO_639-2_to_ISO_639-3.d.ts +0 -22
  2754. package/dist/_esm5.processed/utils/languages/ISO_639-2_to_ISO_639-3.js +0 -41
  2755. package/dist/_esm5.processed/utils/languages/index.d.ts +0 -18
  2756. package/dist/_esm5.processed/utils/languages/index.js +0 -18
  2757. package/dist/_esm5.processed/utils/languages/normalize.d.ts +0 -68
  2758. package/dist/_esm5.processed/utils/languages/normalize.js +0 -117
  2759. package/dist/_esm5.processed/utils/list_to_map.d.ts +0 -22
  2760. package/dist/_esm5.processed/utils/list_to_map.js +0 -28
  2761. package/dist/_esm5.processed/utils/logger.d.ts +0 -46
  2762. package/dist/_esm5.processed/utils/logger.js +0 -79
  2763. package/dist/_esm5.processed/utils/noop.d.ts +0 -23
  2764. package/dist/_esm5.processed/utils/noop.js +0 -25
  2765. package/dist/_esm5.processed/utils/object_assign.d.ts +0 -22
  2766. package/dist/_esm5.processed/utils/object_assign.js +0 -44
  2767. package/dist/_esm5.processed/utils/object_values.d.ts +0 -30
  2768. package/dist/_esm5.processed/utils/object_values.js +0 -26
  2769. package/dist/_esm5.processed/utils/ranges.d.ts +0 -170
  2770. package/dist/_esm5.processed/utils/ranges.js +0 -427
  2771. package/dist/_esm5.processed/utils/reference.d.ts +0 -214
  2772. package/dist/_esm5.processed/utils/reference.js +0 -295
  2773. package/dist/_esm5.processed/utils/request/fetch.d.ts +0 -76
  2774. package/dist/_esm5.processed/utils/request/fetch.js +0 -181
  2775. package/dist/_esm5.processed/utils/request/index.d.ts +0 -19
  2776. package/dist/_esm5.processed/utils/request/index.js +0 -19
  2777. package/dist/_esm5.processed/utils/request/xhr.d.ts +0 -95
  2778. package/dist/_esm5.processed/utils/request/xhr.js +0 -152
  2779. package/dist/_esm5.processed/utils/resolve_url.d.ts +0 -35
  2780. package/dist/_esm5.processed/utils/resolve_url.js +0 -117
  2781. package/dist/_esm5.processed/utils/retry_promise_with_backoff.d.ts +0 -46
  2782. package/dist/_esm5.processed/utils/retry_promise_with_backoff.js +0 -119
  2783. package/dist/_esm5.processed/utils/simple_set.d.ts +0 -51
  2784. package/dist/_esm5.processed/utils/simple_set.js +0 -57
  2785. package/dist/_esm5.processed/utils/sleep.d.ts +0 -10
  2786. package/dist/_esm5.processed/utils/sleep.js +0 -14
  2787. package/dist/_esm5.processed/utils/slice_uint8array.d.ts +0 -27
  2788. package/dist/_esm5.processed/utils/slice_uint8array.js +0 -42
  2789. package/dist/_esm5.processed/utils/sorted_list.d.ts +0 -127
  2790. package/dist/_esm5.processed/utils/sorted_list.js +0 -183
  2791. package/dist/_esm5.processed/utils/starts_with.d.ts +0 -26
  2792. package/dist/_esm5.processed/utils/starts_with.js +0 -36
  2793. package/dist/_esm5.processed/utils/string_parsing.d.ts +0 -88
  2794. package/dist/_esm5.processed/utils/string_parsing.js +0 -372
  2795. package/dist/_esm5.processed/utils/task_canceller.d.ts +0 -263
  2796. package/dist/_esm5.processed/utils/task_canceller.js +0 -325
  2797. package/dist/_esm5.processed/utils/uniq.d.ts +0 -36
  2798. package/dist/_esm5.processed/utils/uniq.js +0 -43
  2799. package/dist/_esm5.processed/utils/warn_once.d.ts +0 -23
  2800. package/dist/_esm5.processed/utils/warn_once.js +0 -31
  2801. package/dist/_esm5.processed/utils/weak_map_memory.d.ts +0 -70
  2802. package/dist/_esm5.processed/utils/weak_map_memory.js +0 -86
  2803. package/dist/_esm5.processed/utils/wrapInPromise.d.ts +0 -7
  2804. package/dist/_esm5.processed/utils/wrapInPromise.js +0 -22
  2805. package/dist/commonjs/compat/global_scope.d.ts +0 -9
  2806. package/dist/commonjs/compat/global_scope.js +0 -15
  2807. package/dist/commonjs/compat/index.d.ts +0 -37
  2808. package/dist/commonjs/compat/index.js +0 -66
  2809. package/dist/commonjs/core/api/debug/buffer_graph.d.ts +0 -28
  2810. package/dist/commonjs/core/api/debug/buffer_graph.js +0 -173
  2811. package/dist/commonjs/core/api/debug/buffer_size_graph.js +0 -132
  2812. package/dist/commonjs/core/api/debug/modules/general_info.d.ts +0 -3
  2813. package/dist/commonjs/core/api/debug/modules/general_info.js +0 -220
  2814. package/dist/commonjs/core/api/debug/modules/segment_buffer_content.d.ts +0 -4
  2815. package/dist/commonjs/core/api/debug/modules/segment_buffer_content.js +0 -124
  2816. package/dist/commonjs/core/api/debug/modules/segment_buffer_size.d.ts +0 -3
  2817. package/dist/commonjs/core/api/debug/modules/segment_buffer_size.js +0 -38
  2818. package/dist/commonjs/core/api/debug/render.d.ts +0 -3
  2819. package/dist/commonjs/core/api/index.d.ts +0 -20
  2820. package/dist/commonjs/core/api/index.js +0 -22
  2821. package/dist/commonjs/core/api/option_utils.d.ts +0 -123
  2822. package/dist/commonjs/core/api/option_utils.js +0 -308
  2823. package/dist/commonjs/core/api/playback_observer.d.ts +0 -490
  2824. package/dist/commonjs/core/api/playback_observer.js +0 -738
  2825. package/dist/commonjs/core/api/public_api.d.ts +0 -728
  2826. package/dist/commonjs/core/api/public_api.js +0 -2261
  2827. package/dist/commonjs/core/api/track_management/index.d.ts +0 -18
  2828. package/dist/commonjs/core/api/track_management/media_element_tracks_store.d.ts +0 -197
  2829. package/dist/commonjs/core/api/track_management/media_element_tracks_store.js +0 -688
  2830. package/dist/commonjs/core/api/track_management/track_dispatcher.d.ts +0 -96
  2831. package/dist/commonjs/core/api/track_management/track_dispatcher.js +0 -178
  2832. package/dist/commonjs/core/api/track_management/tracks_store.d.ts +0 -429
  2833. package/dist/commonjs/core/api/track_management/tracks_store.js +0 -998
  2834. package/dist/commonjs/core/api/utils.d.ts +0 -66
  2835. package/dist/commonjs/core/api/utils.js +0 -175
  2836. package/dist/commonjs/core/decrypt/__tests__/__global__/utils.d.ts +0 -178
  2837. package/dist/commonjs/core/decrypt/__tests__/__global__/utils.js +0 -413
  2838. package/dist/commonjs/core/decrypt/attach_media_keys.d.ts +0 -52
  2839. package/dist/commonjs/core/decrypt/attach_media_keys.js +0 -120
  2840. package/dist/commonjs/core/decrypt/clear_on_stop.js +0 -43
  2841. package/dist/commonjs/core/decrypt/content_decryptor.d.ts +0 -184
  2842. package/dist/commonjs/core/decrypt/content_decryptor.js +0 -1146
  2843. package/dist/commonjs/core/decrypt/create_or_load_session.d.ts +0 -63
  2844. package/dist/commonjs/core/decrypt/create_or_load_session.js +0 -127
  2845. package/dist/commonjs/core/decrypt/create_session.d.ts +0 -53
  2846. package/dist/commonjs/core/decrypt/create_session.js +0 -215
  2847. package/dist/commonjs/core/decrypt/dispose_decryption_resources.js +0 -91
  2848. package/dist/commonjs/core/decrypt/find_key_system.d.ts +0 -48
  2849. package/dist/commonjs/core/decrypt/find_key_system.js +0 -369
  2850. package/dist/commonjs/core/decrypt/get_media_keys.d.ts +0 -44
  2851. package/dist/commonjs/core/decrypt/get_media_keys.js +0 -156
  2852. package/dist/commonjs/core/decrypt/index.d.ts +0 -26
  2853. package/dist/commonjs/core/decrypt/init_media_keys.d.ts +0 -26
  2854. package/dist/commonjs/core/decrypt/init_media_keys.js +0 -85
  2855. package/dist/commonjs/core/decrypt/session_events_listener.d.ts +0 -75
  2856. package/dist/commonjs/core/decrypt/session_events_listener.js +0 -330
  2857. package/dist/commonjs/core/decrypt/set_server_certificate.d.ts +0 -51
  2858. package/dist/commonjs/core/decrypt/set_server_certificate.js +0 -146
  2859. package/dist/commonjs/core/decrypt/types.d.ts +0 -368
  2860. package/dist/commonjs/core/decrypt/utils/are_init_values_compatible.js +0 -116
  2861. package/dist/commonjs/core/decrypt/utils/check_key_statuses.d.ts +0 -52
  2862. package/dist/commonjs/core/decrypt/utils/check_key_statuses.js +0 -211
  2863. package/dist/commonjs/core/decrypt/utils/clean_old_loaded_sessions.d.ts +0 -26
  2864. package/dist/commonjs/core/decrypt/utils/clean_old_stored_persistent_info.d.ts +0 -32
  2865. package/dist/commonjs/core/decrypt/utils/init_data_values_container.d.ts +0 -69
  2866. package/dist/commonjs/core/decrypt/utils/init_data_values_container.js +0 -126
  2867. package/dist/commonjs/core/decrypt/utils/is_session_usable.d.ts +0 -24
  2868. package/dist/commonjs/core/decrypt/utils/is_session_usable.js +0 -52
  2869. package/dist/commonjs/core/decrypt/utils/key_session_record.d.ts +0 -104
  2870. package/dist/commonjs/core/decrypt/utils/key_session_record.js +0 -190
  2871. package/dist/commonjs/core/decrypt/utils/loaded_sessions_store.d.ts +0 -215
  2872. package/dist/commonjs/core/decrypt/utils/loaded_sessions_store.js +0 -515
  2873. package/dist/commonjs/core/decrypt/utils/media_keys_infos_store.d.ts +0 -56
  2874. package/dist/commonjs/core/decrypt/utils/media_keys_infos_store.js +0 -46
  2875. package/dist/commonjs/core/decrypt/utils/persistent_sessions_store.d.ts +0 -94
  2876. package/dist/commonjs/core/decrypt/utils/persistent_sessions_store.js +0 -346
  2877. package/dist/commonjs/core/decrypt/utils/serializable_bytes.d.ts +0 -44
  2878. package/dist/commonjs/core/decrypt/utils/serializable_bytes.js +0 -50
  2879. package/dist/commonjs/core/decrypt/utils/server_certificate_store.d.ts +0 -64
  2880. package/dist/commonjs/core/decrypt/utils/server_certificate_store.js +0 -114
  2881. package/dist/commonjs/core/init/directfile_content_initializer.d.ts +0 -97
  2882. package/dist/commonjs/core/init/directfile_content_initializer.js +0 -262
  2883. package/dist/commonjs/core/init/media_source_content_initializer.d.ts +0 -180
  2884. package/dist/commonjs/core/init/media_source_content_initializer.js +0 -667
  2885. package/dist/commonjs/core/init/types.d.ts +0 -217
  2886. package/dist/commonjs/core/init/types.js +0 -54
  2887. package/dist/commonjs/core/init/utils/content_time_boundaries_observer.d.ts +0 -192
  2888. package/dist/commonjs/core/init/utils/content_time_boundaries_observer.js +0 -518
  2889. package/dist/commonjs/core/init/utils/create_media_source.d.ts +0 -37
  2890. package/dist/commonjs/core/init/utils/create_media_source.js +0 -117
  2891. package/dist/commonjs/core/init/utils/create_stream_playback_observer.d.ts +0 -41
  2892. package/dist/commonjs/core/init/utils/create_stream_playback_observer.js +0 -91
  2893. package/dist/commonjs/core/init/utils/end_of_stream.d.ts +0 -33
  2894. package/dist/commonjs/core/init/utils/end_of_stream.js +0 -115
  2895. package/dist/commonjs/core/init/utils/get_initial_time.d.ts +0 -76
  2896. package/dist/commonjs/core/init/utils/get_initial_time.js +0 -115
  2897. package/dist/commonjs/core/init/utils/get_loaded_reference.d.ts +0 -28
  2898. package/dist/commonjs/core/init/utils/get_loaded_reference.js +0 -59
  2899. package/dist/commonjs/core/init/utils/initial_seek_and_play.d.ts +0 -61
  2900. package/dist/commonjs/core/init/utils/initial_seek_and_play.js +0 -161
  2901. package/dist/commonjs/core/init/utils/initialize_content_decryption.d.ts +0 -80
  2902. package/dist/commonjs/core/init/utils/initialize_content_decryption.js +0 -107
  2903. package/dist/commonjs/core/init/utils/media_source_duration_updater.js +0 -270
  2904. package/dist/commonjs/core/init/utils/rebuffering_controller.d.ts +0 -147
  2905. package/dist/commonjs/core/init/utils/rebuffering_controller.js +0 -554
  2906. package/dist/commonjs/core/init/utils/stream_events_emitter/are_same_stream_events.js +0 -37
  2907. package/dist/commonjs/core/init/utils/stream_events_emitter/index.d.ts +0 -18
  2908. package/dist/commonjs/core/init/utils/stream_events_emitter/refresh_scheduled_events_list.d.ts +0 -25
  2909. package/dist/commonjs/core/init/utils/stream_events_emitter/refresh_scheduled_events_list.js +0 -68
  2910. package/dist/commonjs/core/init/utils/stream_events_emitter/stream_events_emitter.d.ts +0 -52
  2911. package/dist/commonjs/core/init/utils/stream_events_emitter/stream_events_emitter.js +0 -234
  2912. package/dist/commonjs/core/init/utils/stream_events_emitter/types.d.ts +0 -41
  2913. package/dist/commonjs/core/init/utils/throw_on_media_error.d.ts +0 -23
  2914. package/dist/commonjs/core/init/utils/throw_on_media_error.js +0 -61
  2915. package/dist/commonjs/core/segment_buffers/garbage_collector.d.ts +0 -41
  2916. package/dist/commonjs/core/segment_buffers/garbage_collector.js +0 -211
  2917. package/dist/commonjs/core/segment_buffers/implementations/audio_video/audio_video_segment_buffer.d.ts +0 -182
  2918. package/dist/commonjs/core/segment_buffers/implementations/audio_video/audio_video_segment_buffer.js +0 -464
  2919. package/dist/commonjs/core/segment_buffers/implementations/audio_video/index.d.ts +0 -17
  2920. package/dist/commonjs/core/segment_buffers/implementations/index.d.ts +0 -18
  2921. package/dist/commonjs/core/segment_buffers/implementations/index.js +0 -35
  2922. package/dist/commonjs/core/segment_buffers/implementations/text/html/html_text_segment_buffer.d.ts +0 -141
  2923. package/dist/commonjs/core/segment_buffers/implementations/text/html/html_text_segment_buffer.js +0 -407
  2924. package/dist/commonjs/core/segment_buffers/implementations/text/html/index.d.ts +0 -21
  2925. package/dist/commonjs/core/segment_buffers/implementations/text/html/index.js +0 -23
  2926. package/dist/commonjs/core/segment_buffers/implementations/text/html/parsers.d.ts +0 -30
  2927. package/dist/commonjs/core/segment_buffers/implementations/text/html/parsers.js +0 -40
  2928. package/dist/commonjs/core/segment_buffers/implementations/text/html/text_track_cues_store.d.ts +0 -79
  2929. package/dist/commonjs/core/segment_buffers/implementations/text/html/text_track_cues_store.js +0 -390
  2930. package/dist/commonjs/core/segment_buffers/implementations/text/html/types.d.ts +0 -25
  2931. package/dist/commonjs/core/segment_buffers/implementations/text/html/update_proportional_elements.d.ts +0 -30
  2932. package/dist/commonjs/core/segment_buffers/implementations/text/html/update_proportional_elements.js +0 -80
  2933. package/dist/commonjs/core/segment_buffers/implementations/text/html/utils.d.ts +0 -45
  2934. package/dist/commonjs/core/segment_buffers/implementations/text/html/utils.js +0 -131
  2935. package/dist/commonjs/core/segment_buffers/implementations/text/native/index.d.ts +0 -17
  2936. package/dist/commonjs/core/segment_buffers/implementations/text/native/index.js +0 -19
  2937. package/dist/commonjs/core/segment_buffers/implementations/text/native/native_text_segment_buffer.d.ts +0 -83
  2938. package/dist/commonjs/core/segment_buffers/implementations/text/native/native_text_segment_buffer.js +0 -273
  2939. package/dist/commonjs/core/segment_buffers/implementations/text/native/parsers.d.ts +0 -26
  2940. package/dist/commonjs/core/segment_buffers/implementations/text/native/parsers.js +0 -40
  2941. package/dist/commonjs/core/segment_buffers/implementations/types.d.ts +0 -320
  2942. package/dist/commonjs/core/segment_buffers/implementations/types.js +0 -124
  2943. package/dist/commonjs/core/segment_buffers/index.d.ts +0 -21
  2944. package/dist/commonjs/core/segment_buffers/index.js +0 -28
  2945. package/dist/commonjs/core/segment_buffers/inventory/buffered_history.d.ts +0 -89
  2946. package/dist/commonjs/core/segment_buffers/inventory/index.d.ts +0 -21
  2947. package/dist/commonjs/core/segment_buffers/inventory/segment_inventory.d.ts +0 -224
  2948. package/dist/commonjs/core/segment_buffers/inventory/segment_inventory.js +0 -875
  2949. package/dist/commonjs/core/segment_buffers/inventory/types.d.ts +0 -27
  2950. package/dist/commonjs/core/segment_buffers/inventory/utils.d.ts +0 -33
  2951. package/dist/commonjs/core/segment_buffers/inventory/utils.js +0 -54
  2952. package/dist/commonjs/core/segment_buffers/segment_buffers_store.d.ts +0 -180
  2953. package/dist/commonjs/core/segment_buffers/segment_buffers_store.js +0 -302
  2954. package/dist/commonjs/core/stream/representation/utils/force_garbage_collection.d.ts +0 -29
  2955. package/dist/commonjs/core/stream/representation/utils/force_garbage_collection.js +0 -179
  2956. package/dist/commonjs/errors/assertion_error.d.ts +0 -31
  2957. package/dist/commonjs/errors/assertion_error.js +0 -56
  2958. package/dist/commonjs/errors/request_error.d.ts +0 -38
  2959. package/dist/commonjs/errors/request_error.js +0 -76
  2960. package/dist/commonjs/experimental/features/dash_wasm.d.ts +0 -23
  2961. package/dist/commonjs/experimental/features/dash_wasm.js +0 -37
  2962. package/dist/commonjs/experimental/features/debug_element.d.ts +0 -8
  2963. package/dist/commonjs/experimental/features/debug_element.js +0 -13
  2964. package/dist/commonjs/experimental/tools/parseBIFThumbnails/index.js +0 -32
  2965. package/dist/commonjs/manifest/adaptation.d.ts +0 -113
  2966. package/dist/commonjs/manifest/adaptation.js +0 -223
  2967. package/dist/commonjs/manifest/manifest.d.ts +0 -265
  2968. package/dist/commonjs/manifest/manifest.js +0 -453
  2969. package/dist/commonjs/manifest/period.d.ts +0 -68
  2970. package/dist/commonjs/manifest/period.js +0 -140
  2971. package/dist/commonjs/manifest/representation.d.ts +0 -251
  2972. package/dist/commonjs/manifest/representation.js +0 -296
  2973. package/dist/commonjs/manifest/representation_index/index.d.ts +0 -18
  2974. package/dist/commonjs/manifest/representation_index/static.d.ts +0 -101
  2975. package/dist/commonjs/manifest/representation_index/static.js +0 -143
  2976. package/dist/commonjs/manifest/representation_index/types.d.ts +0 -420
  2977. package/dist/commonjs/manifest/representation_index/types.js +0 -17
  2978. package/dist/commonjs/manifest/update_period_in_place.d.ts +0 -49
  2979. package/dist/commonjs/manifest/update_period_in_place.js +0 -168
  2980. package/dist/commonjs/manifest/update_periods.d.ts +0 -47
  2981. package/dist/commonjs/manifest/update_periods.js +0 -189
  2982. package/dist/commonjs/parsers/manifest/dash/js-parser/node_parsers/AdaptationSet.d.ts +0 -23
  2983. package/dist/commonjs/parsers/manifest/dash/js-parser/node_parsers/AdaptationSet.js +0 -331
  2984. package/dist/commonjs/parsers/manifest/dash/js-parser/node_parsers/BaseURL.d.ts +0 -23
  2985. package/dist/commonjs/parsers/manifest/dash/js-parser/node_parsers/BaseURL.js +0 -33
  2986. package/dist/commonjs/parsers/manifest/dash/js-parser/node_parsers/ContentComponent.d.ts +0 -22
  2987. package/dist/commonjs/parsers/manifest/dash/js-parser/node_parsers/ContentProtection.d.ts +0 -21
  2988. package/dist/commonjs/parsers/manifest/dash/js-parser/node_parsers/EventStream.d.ts +0 -23
  2989. package/dist/commonjs/parsers/manifest/dash/js-parser/node_parsers/EventStream.js +0 -113
  2990. package/dist/commonjs/parsers/manifest/dash/js-parser/node_parsers/Initialization.d.ts +0 -21
  2991. package/dist/commonjs/parsers/manifest/dash/js-parser/node_parsers/Initialization.js +0 -42
  2992. package/dist/commonjs/parsers/manifest/dash/js-parser/node_parsers/MPD.d.ts +0 -21
  2993. package/dist/commonjs/parsers/manifest/dash/js-parser/node_parsers/MPD.js +0 -164
  2994. package/dist/commonjs/parsers/manifest/dash/js-parser/node_parsers/Period.d.ts +0 -21
  2995. package/dist/commonjs/parsers/manifest/dash/js-parser/node_parsers/Period.js +0 -132
  2996. package/dist/commonjs/parsers/manifest/dash/js-parser/node_parsers/Representation.d.ts +0 -21
  2997. package/dist/commonjs/parsers/manifest/dash/js-parser/node_parsers/Representation.js +0 -209
  2998. package/dist/commonjs/parsers/manifest/dash/js-parser/node_parsers/SegmentBase.d.ts +0 -22
  2999. package/dist/commonjs/parsers/manifest/dash/js-parser/node_parsers/SegmentBase.js +0 -108
  3000. package/dist/commonjs/parsers/manifest/dash/js-parser/node_parsers/SegmentList.d.ts +0 -21
  3001. package/dist/commonjs/parsers/manifest/dash/js-parser/node_parsers/SegmentTemplate.d.ts +0 -23
  3002. package/dist/commonjs/parsers/manifest/dash/js-parser/node_parsers/SegmentTemplate.js +0 -92
  3003. package/dist/commonjs/parsers/manifest/dash/js-parser/node_parsers/SegmentTimeline.d.ts +0 -21
  3004. package/dist/commonjs/parsers/manifest/dash/js-parser/node_parsers/SegmentURL.d.ts +0 -23
  3005. package/dist/commonjs/parsers/manifest/dash/js-parser/node_parsers/SegmentURL.js +0 -52
  3006. package/dist/commonjs/parsers/manifest/dash/js-parser/node_parsers/utils.d.ts +0 -187
  3007. package/dist/commonjs/parsers/manifest/dash/js-parser/node_parsers/utils.js +0 -354
  3008. package/dist/commonjs/parsers/manifest/dash/js-parser/parse_from_document.d.ts +0 -24
  3009. package/dist/commonjs/parsers/manifest/dash/js-parser/parse_from_document.js +0 -131
  3010. package/dist/commonjs/utils/assert_unreachable.d.ts +0 -40
  3011. package/dist/commonjs/utils/assert_unreachable.js +0 -46
  3012. package/dist/commonjs/utils/initialization_segment_cache.d.ts +0 -42
  3013. package/dist/es2017/compat/global_scope.d.ts +0 -9
  3014. package/dist/es2017/compat/global_scope.js +0 -13
  3015. package/dist/es2017/compat/index.d.ts +0 -37
  3016. package/dist/es2017/compat/index.js +0 -43
  3017. package/dist/es2017/core/api/debug/buffer_graph.d.ts +0 -28
  3018. package/dist/es2017/core/api/debug/buffer_graph.js +0 -169
  3019. package/dist/es2017/core/api/debug/buffer_size_graph.d.ts +0 -10
  3020. package/dist/es2017/core/api/debug/buffer_size_graph.js +0 -103
  3021. package/dist/es2017/core/api/debug/constants.d.ts +0 -2
  3022. package/dist/es2017/core/api/debug/index.d.ts +0 -2
  3023. package/dist/es2017/core/api/debug/index.js +0 -2
  3024. package/dist/es2017/core/api/debug/modules/general_info.d.ts +0 -3
  3025. package/dist/es2017/core/api/debug/modules/general_info.js +0 -176
  3026. package/dist/es2017/core/api/debug/modules/segment_buffer_content.d.ts +0 -4
  3027. package/dist/es2017/core/api/debug/modules/segment_buffer_content.js +0 -121
  3028. package/dist/es2017/core/api/debug/modules/segment_buffer_size.d.ts +0 -3
  3029. package/dist/es2017/core/api/debug/modules/segment_buffer_size.js +0 -35
  3030. package/dist/es2017/core/api/debug/render.d.ts +0 -3
  3031. package/dist/es2017/core/api/debug/render.js +0 -32
  3032. package/dist/es2017/core/api/debug/utils.d.ts +0 -39
  3033. package/dist/es2017/core/api/debug/utils.js +0 -54
  3034. package/dist/es2017/core/api/index.d.ts +0 -20
  3035. package/dist/es2017/core/api/index.js +0 -19
  3036. package/dist/es2017/core/api/option_utils.d.ts +0 -123
  3037. package/dist/es2017/core/api/option_utils.js +0 -304
  3038. package/dist/es2017/core/api/playback_observer.d.ts +0 -490
  3039. package/dist/es2017/core/api/playback_observer.js +0 -742
  3040. package/dist/es2017/core/api/public_api.d.ts +0 -728
  3041. package/dist/es2017/core/api/public_api.js +0 -2136
  3042. package/dist/es2017/core/api/track_management/index.d.ts +0 -18
  3043. package/dist/es2017/core/api/track_management/media_element_tracks_store.d.ts +0 -197
  3044. package/dist/es2017/core/api/track_management/media_element_tracks_store.js +0 -669
  3045. package/dist/es2017/core/api/track_management/track_dispatcher.d.ts +0 -96
  3046. package/dist/es2017/core/api/track_management/track_dispatcher.js +0 -159
  3047. package/dist/es2017/core/api/track_management/tracks_store.d.ts +0 -429
  3048. package/dist/es2017/core/api/track_management/tracks_store.js +0 -944
  3049. package/dist/es2017/core/api/utils.d.ts +0 -66
  3050. package/dist/es2017/core/api/utils.js +0 -167
  3051. package/dist/es2017/core/decrypt/__tests__/__global__/utils.d.ts +0 -178
  3052. package/dist/es2017/core/decrypt/__tests__/__global__/utils.js +0 -363
  3053. package/dist/es2017/core/decrypt/attach_media_keys.d.ts +0 -52
  3054. package/dist/es2017/core/decrypt/attach_media_keys.js +0 -71
  3055. package/dist/es2017/core/decrypt/clear_on_stop.d.ts +0 -22
  3056. package/dist/es2017/core/decrypt/clear_on_stop.js +0 -40
  3057. package/dist/es2017/core/decrypt/content_decryptor.d.ts +0 -184
  3058. package/dist/es2017/core/decrypt/content_decryptor.js +0 -846
  3059. package/dist/es2017/core/decrypt/create_or_load_session.d.ts +0 -63
  3060. package/dist/es2017/core/decrypt/create_or_load_session.js +0 -75
  3061. package/dist/es2017/core/decrypt/create_session.d.ts +0 -53
  3062. package/dist/es2017/core/decrypt/create_session.js +0 -150
  3063. package/dist/es2017/core/decrypt/dispose_decryption_resources.d.ts +0 -21
  3064. package/dist/es2017/core/decrypt/dispose_decryption_resources.js +0 -42
  3065. package/dist/es2017/core/decrypt/find_key_system.d.ts +0 -48
  3066. package/dist/es2017/core/decrypt/find_key_system.js +0 -281
  3067. package/dist/es2017/core/decrypt/get_media_keys.d.ts +0 -44
  3068. package/dist/es2017/core/decrypt/get_media_keys.js +0 -100
  3069. package/dist/es2017/core/decrypt/index.d.ts +0 -26
  3070. package/dist/es2017/core/decrypt/index.js +0 -26
  3071. package/dist/es2017/core/decrypt/init_media_keys.d.ts +0 -26
  3072. package/dist/es2017/core/decrypt/init_media_keys.js +0 -37
  3073. package/dist/es2017/core/decrypt/session_events_listener.d.ts +0 -75
  3074. package/dist/es2017/core/decrypt/session_events_listener.js +0 -249
  3075. package/dist/es2017/core/decrypt/set_server_certificate.d.ts +0 -51
  3076. package/dist/es2017/core/decrypt/set_server_certificate.js +0 -83
  3077. package/dist/es2017/core/decrypt/types.d.ts +0 -368
  3078. package/dist/es2017/core/decrypt/types.js +0 -55
  3079. package/dist/es2017/core/decrypt/utils/are_init_values_compatible.d.ts +0 -34
  3080. package/dist/es2017/core/decrypt/utils/are_init_values_compatible.js +0 -113
  3081. package/dist/es2017/core/decrypt/utils/check_key_statuses.d.ts +0 -52
  3082. package/dist/es2017/core/decrypt/utils/check_key_statuses.js +0 -165
  3083. package/dist/es2017/core/decrypt/utils/clean_old_loaded_sessions.d.ts +0 -26
  3084. package/dist/es2017/core/decrypt/utils/clean_old_stored_persistent_info.d.ts +0 -32
  3085. package/dist/es2017/core/decrypt/utils/get_drm_system_id.d.ts +0 -20
  3086. package/dist/es2017/core/decrypt/utils/get_drm_system_id.js +0 -37
  3087. package/dist/es2017/core/decrypt/utils/init_data_values_container.d.ts +0 -69
  3088. package/dist/es2017/core/decrypt/utils/init_data_values_container.js +0 -96
  3089. package/dist/es2017/core/decrypt/utils/is_session_usable.d.ts +0 -24
  3090. package/dist/es2017/core/decrypt/utils/is_session_usable.js +0 -49
  3091. package/dist/es2017/core/decrypt/utils/key_id_comparison.d.ts +0 -31
  3092. package/dist/es2017/core/decrypt/utils/key_id_comparison.js +0 -48
  3093. package/dist/es2017/core/decrypt/utils/key_session_record.d.ts +0 -104
  3094. package/dist/es2017/core/decrypt/utils/key_session_record.js +0 -153
  3095. package/dist/es2017/core/decrypt/utils/loaded_sessions_store.d.ts +0 -215
  3096. package/dist/es2017/core/decrypt/utils/loaded_sessions_store.js +0 -365
  3097. package/dist/es2017/core/decrypt/utils/media_keys_infos_store.d.ts +0 -56
  3098. package/dist/es2017/core/decrypt/utils/media_keys_infos_store.js +0 -44
  3099. package/dist/es2017/core/decrypt/utils/persistent_sessions_store.d.ts +0 -94
  3100. package/dist/es2017/core/decrypt/utils/persistent_sessions_store.js +0 -321
  3101. package/dist/es2017/core/decrypt/utils/serializable_bytes.d.ts +0 -44
  3102. package/dist/es2017/core/decrypt/utils/serializable_bytes.js +0 -46
  3103. package/dist/es2017/core/decrypt/utils/server_certificate_store.d.ts +0 -64
  3104. package/dist/es2017/core/decrypt/utils/server_certificate_store.js +0 -112
  3105. package/dist/es2017/core/init/directfile_content_initializer.d.ts +0 -97
  3106. package/dist/es2017/core/init/directfile_content_initializer.js +0 -233
  3107. package/dist/es2017/core/init/index.d.ts +0 -16
  3108. package/dist/es2017/core/init/index.js +0 -16
  3109. package/dist/es2017/core/init/media_source_content_initializer.d.ts +0 -180
  3110. package/dist/es2017/core/init/media_source_content_initializer.js +0 -577
  3111. package/dist/es2017/core/init/types.d.ts +0 -217
  3112. package/dist/es2017/core/init/types.js +0 -30
  3113. package/dist/es2017/core/init/utils/content_time_boundaries_observer.d.ts +0 -192
  3114. package/dist/es2017/core/init/utils/content_time_boundaries_observer.js +0 -468
  3115. package/dist/es2017/core/init/utils/create_media_source.d.ts +0 -37
  3116. package/dist/es2017/core/init/utils/create_media_source.js +0 -112
  3117. package/dist/es2017/core/init/utils/create_stream_playback_observer.d.ts +0 -41
  3118. package/dist/es2017/core/init/utils/create_stream_playback_observer.js +0 -87
  3119. package/dist/es2017/core/init/utils/end_of_stream.d.ts +0 -33
  3120. package/dist/es2017/core/init/utils/end_of_stream.js +0 -88
  3121. package/dist/es2017/core/init/utils/get_initial_time.d.ts +0 -76
  3122. package/dist/es2017/core/init/utils/get_initial_time.js +0 -112
  3123. package/dist/es2017/core/init/utils/get_loaded_reference.d.ts +0 -28
  3124. package/dist/es2017/core/init/utils/get_loaded_reference.js +0 -56
  3125. package/dist/es2017/core/init/utils/initial_seek_and_play.d.ts +0 -61
  3126. package/dist/es2017/core/init/utils/initial_seek_and_play.js +0 -157
  3127. package/dist/es2017/core/init/utils/initialize_content_decryption.d.ts +0 -80
  3128. package/dist/es2017/core/init/utils/initialize_content_decryption.js +0 -104
  3129. package/dist/es2017/core/init/utils/media_source_duration_updater.d.ts +0 -58
  3130. package/dist/es2017/core/init/utils/media_source_duration_updater.js +0 -263
  3131. package/dist/es2017/core/init/utils/rebuffering_controller.d.ts +0 -147
  3132. package/dist/es2017/core/init/utils/rebuffering_controller.js +0 -498
  3133. package/dist/es2017/core/init/utils/stream_events_emitter/are_same_stream_events.d.ts +0 -39
  3134. package/dist/es2017/core/init/utils/stream_events_emitter/are_same_stream_events.js +0 -35
  3135. package/dist/es2017/core/init/utils/stream_events_emitter/index.d.ts +0 -18
  3136. package/dist/es2017/core/init/utils/stream_events_emitter/index.js +0 -17
  3137. package/dist/es2017/core/init/utils/stream_events_emitter/refresh_scheduled_events_list.d.ts +0 -25
  3138. package/dist/es2017/core/init/utils/stream_events_emitter/refresh_scheduled_events_list.js +0 -62
  3139. package/dist/es2017/core/init/utils/stream_events_emitter/stream_events_emitter.d.ts +0 -52
  3140. package/dist/es2017/core/init/utils/stream_events_emitter/stream_events_emitter.js +0 -180
  3141. package/dist/es2017/core/init/utils/stream_events_emitter/types.d.ts +0 -41
  3142. package/dist/es2017/core/init/utils/stream_events_emitter/types.js +0 -16
  3143. package/dist/es2017/core/init/utils/throw_on_media_error.d.ts +0 -23
  3144. package/dist/es2017/core/init/utils/throw_on_media_error.js +0 -58
  3145. package/dist/es2017/core/segment_buffers/garbage_collector.d.ts +0 -41
  3146. package/dist/es2017/core/segment_buffers/garbage_collector.js +0 -128
  3147. package/dist/es2017/core/segment_buffers/implementations/audio_video/audio_video_segment_buffer.d.ts +0 -182
  3148. package/dist/es2017/core/segment_buffers/implementations/audio_video/audio_video_segment_buffer.js +0 -442
  3149. package/dist/es2017/core/segment_buffers/implementations/audio_video/index.d.ts +0 -17
  3150. package/dist/es2017/core/segment_buffers/implementations/audio_video/index.js +0 -17
  3151. package/dist/es2017/core/segment_buffers/implementations/index.d.ts +0 -18
  3152. package/dist/es2017/core/segment_buffers/implementations/index.js +0 -18
  3153. package/dist/es2017/core/segment_buffers/implementations/text/html/html_text_segment_buffer.d.ts +0 -141
  3154. package/dist/es2017/core/segment_buffers/implementations/text/html/html_text_segment_buffer.js +0 -383
  3155. package/dist/es2017/core/segment_buffers/implementations/text/html/index.d.ts +0 -21
  3156. package/dist/es2017/core/segment_buffers/implementations/text/html/index.js +0 -21
  3157. package/dist/es2017/core/segment_buffers/implementations/text/html/parsers.d.ts +0 -30
  3158. package/dist/es2017/core/segment_buffers/implementations/text/html/parsers.js +0 -37
  3159. package/dist/es2017/core/segment_buffers/implementations/text/html/text_track_cues_store.d.ts +0 -79
  3160. package/dist/es2017/core/segment_buffers/implementations/text/html/text_track_cues_store.js +0 -370
  3161. package/dist/es2017/core/segment_buffers/implementations/text/html/types.d.ts +0 -25
  3162. package/dist/es2017/core/segment_buffers/implementations/text/html/types.js +0 -16
  3163. package/dist/es2017/core/segment_buffers/implementations/text/html/update_proportional_elements.d.ts +0 -30
  3164. package/dist/es2017/core/segment_buffers/implementations/text/html/update_proportional_elements.js +0 -77
  3165. package/dist/es2017/core/segment_buffers/implementations/text/html/utils.d.ts +0 -45
  3166. package/dist/es2017/core/segment_buffers/implementations/text/html/utils.js +0 -123
  3167. package/dist/es2017/core/segment_buffers/implementations/text/native/index.d.ts +0 -17
  3168. package/dist/es2017/core/segment_buffers/implementations/text/native/index.js +0 -17
  3169. package/dist/es2017/core/segment_buffers/implementations/text/native/native_text_segment_buffer.d.ts +0 -83
  3170. package/dist/es2017/core/segment_buffers/implementations/text/native/native_text_segment_buffer.js +0 -251
  3171. package/dist/es2017/core/segment_buffers/implementations/text/native/parsers.d.ts +0 -26
  3172. package/dist/es2017/core/segment_buffers/implementations/text/native/parsers.js +0 -37
  3173. package/dist/es2017/core/segment_buffers/implementations/types.d.ts +0 -320
  3174. package/dist/es2017/core/segment_buffers/implementations/types.js +0 -119
  3175. package/dist/es2017/core/segment_buffers/implementations/utils/manual_time_ranges.d.ts +0 -29
  3176. package/dist/es2017/core/segment_buffers/implementations/utils/manual_time_ranges.js +0 -63
  3177. package/dist/es2017/core/segment_buffers/index.d.ts +0 -21
  3178. package/dist/es2017/core/segment_buffers/index.js +0 -21
  3179. package/dist/es2017/core/segment_buffers/inventory/buffered_history.d.ts +0 -89
  3180. package/dist/es2017/core/segment_buffers/inventory/buffered_history.js +0 -90
  3181. package/dist/es2017/core/segment_buffers/inventory/index.d.ts +0 -21
  3182. package/dist/es2017/core/segment_buffers/inventory/index.js +0 -18
  3183. package/dist/es2017/core/segment_buffers/inventory/segment_inventory.d.ts +0 -224
  3184. package/dist/es2017/core/segment_buffers/inventory/segment_inventory.js +0 -831
  3185. package/dist/es2017/core/segment_buffers/inventory/types.d.ts +0 -27
  3186. package/dist/es2017/core/segment_buffers/inventory/types.js +0 -16
  3187. package/dist/es2017/core/segment_buffers/inventory/utils.d.ts +0 -33
  3188. package/dist/es2017/core/segment_buffers/inventory/utils.js +0 -49
  3189. package/dist/es2017/core/segment_buffers/segment_buffers_store.d.ts +0 -180
  3190. package/dist/es2017/core/segment_buffers/segment_buffers_store.js +0 -290
  3191. package/dist/es2017/core/stream/representation/utils/force_garbage_collection.d.ts +0 -29
  3192. package/dist/es2017/core/stream/representation/utils/force_garbage_collection.js +0 -91
  3193. package/dist/es2017/errors/assertion_error.d.ts +0 -31
  3194. package/dist/es2017/errors/assertion_error.js +0 -35
  3195. package/dist/es2017/errors/request_error.d.ts +0 -38
  3196. package/dist/es2017/errors/request_error.js +0 -55
  3197. package/dist/es2017/experimental/features/dash_wasm.d.ts +0 -23
  3198. package/dist/es2017/experimental/features/dash_wasm.js +0 -34
  3199. package/dist/es2017/experimental/features/debug_element.d.ts +0 -8
  3200. package/dist/es2017/experimental/features/debug_element.js +0 -10
  3201. package/dist/es2017/experimental/tools/parseBIFThumbnails/index.js +0 -29
  3202. package/dist/es2017/manifest/adaptation.d.ts +0 -113
  3203. package/dist/es2017/manifest/adaptation.js +0 -213
  3204. package/dist/es2017/manifest/manifest.d.ts +0 -265
  3205. package/dist/es2017/manifest/manifest.js +0 -362
  3206. package/dist/es2017/manifest/period.d.ts +0 -68
  3207. package/dist/es2017/manifest/period.js +0 -131
  3208. package/dist/es2017/manifest/representation.d.ts +0 -251
  3209. package/dist/es2017/manifest/representation.js +0 -288
  3210. package/dist/es2017/manifest/representation_index/index.d.ts +0 -18
  3211. package/dist/es2017/manifest/representation_index/index.js +0 -17
  3212. package/dist/es2017/manifest/representation_index/static.d.ts +0 -101
  3213. package/dist/es2017/manifest/representation_index/static.js +0 -139
  3214. package/dist/es2017/manifest/representation_index/types.d.ts +0 -420
  3215. package/dist/es2017/manifest/representation_index/types.js +0 -16
  3216. package/dist/es2017/manifest/update_period_in_place.d.ts +0 -49
  3217. package/dist/es2017/manifest/update_period_in_place.js +0 -106
  3218. package/dist/es2017/manifest/update_periods.d.ts +0 -47
  3219. package/dist/es2017/manifest/update_periods.js +0 -153
  3220. package/dist/es2017/parsers/manifest/dash/js-parser/index.d.ts +0 -17
  3221. package/dist/es2017/parsers/manifest/dash/js-parser/index.js +0 -17
  3222. package/dist/es2017/parsers/manifest/dash/js-parser/node_parsers/AdaptationSet.d.ts +0 -23
  3223. package/dist/es2017/parsers/manifest/dash/js-parser/node_parsers/AdaptationSet.js +0 -311
  3224. package/dist/es2017/parsers/manifest/dash/js-parser/node_parsers/BaseURL.d.ts +0 -23
  3225. package/dist/es2017/parsers/manifest/dash/js-parser/node_parsers/BaseURL.js +0 -30
  3226. package/dist/es2017/parsers/manifest/dash/js-parser/node_parsers/ContentComponent.d.ts +0 -22
  3227. package/dist/es2017/parsers/manifest/dash/js-parser/node_parsers/ContentProtection.d.ts +0 -21
  3228. package/dist/es2017/parsers/manifest/dash/js-parser/node_parsers/EventStream.d.ts +0 -23
  3229. package/dist/es2017/parsers/manifest/dash/js-parser/node_parsers/EventStream.js +0 -94
  3230. package/dist/es2017/parsers/manifest/dash/js-parser/node_parsers/Initialization.d.ts +0 -21
  3231. package/dist/es2017/parsers/manifest/dash/js-parser/node_parsers/Initialization.js +0 -39
  3232. package/dist/es2017/parsers/manifest/dash/js-parser/node_parsers/MPD.d.ts +0 -21
  3233. package/dist/es2017/parsers/manifest/dash/js-parser/node_parsers/MPD.js +0 -144
  3234. package/dist/es2017/parsers/manifest/dash/js-parser/node_parsers/Period.d.ts +0 -21
  3235. package/dist/es2017/parsers/manifest/dash/js-parser/node_parsers/Period.js +0 -112
  3236. package/dist/es2017/parsers/manifest/dash/js-parser/node_parsers/Representation.d.ts +0 -21
  3237. package/dist/es2017/parsers/manifest/dash/js-parser/node_parsers/Representation.js +0 -189
  3238. package/dist/es2017/parsers/manifest/dash/js-parser/node_parsers/SegmentBase.d.ts +0 -22
  3239. package/dist/es2017/parsers/manifest/dash/js-parser/node_parsers/SegmentBase.js +0 -89
  3240. package/dist/es2017/parsers/manifest/dash/js-parser/node_parsers/SegmentList.d.ts +0 -21
  3241. package/dist/es2017/parsers/manifest/dash/js-parser/node_parsers/SegmentTemplate.d.ts +0 -23
  3242. package/dist/es2017/parsers/manifest/dash/js-parser/node_parsers/SegmentTemplate.js +0 -73
  3243. package/dist/es2017/parsers/manifest/dash/js-parser/node_parsers/SegmentTimeline.d.ts +0 -21
  3244. package/dist/es2017/parsers/manifest/dash/js-parser/node_parsers/SegmentURL.d.ts +0 -23
  3245. package/dist/es2017/parsers/manifest/dash/js-parser/node_parsers/SegmentURL.js +0 -49
  3246. package/dist/es2017/parsers/manifest/dash/js-parser/node_parsers/utils.d.ts +0 -187
  3247. package/dist/es2017/parsers/manifest/dash/js-parser/node_parsers/utils.js +0 -306
  3248. package/dist/es2017/parsers/manifest/dash/js-parser/parse_from_document.d.ts +0 -24
  3249. package/dist/es2017/parsers/manifest/dash/js-parser/parse_from_document.js +0 -106
  3250. package/dist/es2017/utils/assert_unreachable.d.ts +0 -40
  3251. package/dist/es2017/utils/assert_unreachable.js +0 -43
  3252. package/dist/es2017/utils/initialization_segment_cache.d.ts +0 -42
  3253. package/dist/es2017/utils/initialization_segment_cache.js +0 -48
  3254. package/dist/rx-player.d.ts +0 -3
  3255. package/dist/rx-player.min.d.ts +0 -3
  3256. package/experimental/features/index.d.ts +0 -16
  3257. package/experimental/features/index.js +0 -16
  3258. package/experimental/index.d.ts +0 -16
  3259. package/experimental/index.js +0 -16
  3260. package/experimental/tools/VideoThumbnailLoader.d.ts +0 -18
  3261. package/experimental/tools/VideoThumbnailLoader.js +0 -18
  3262. package/experimental/tools/createMetaplaylist.d.ts +0 -18
  3263. package/experimental/tools/createMetaplaylist.js +0 -18
  3264. package/experimental/tools/index.d.ts +0 -16
  3265. package/experimental/tools/index.js +0 -16
  3266. package/experimental/tools/mediaCapabilitiesProber.d.ts +0 -18
  3267. package/experimental/tools/mediaCapabilitiesProber.js +0 -18
  3268. package/experimental/tools/parseBIFThumbnails.d.ts +0 -18
  3269. package/experimental/tools/parseBIFThumbnails.js +0 -18
  3270. package/features/index.d.ts +0 -16
  3271. package/features/index.js +0 -16
  3272. package/jest.config.js +0 -33
  3273. package/logger/index.d.ts +0 -17
  3274. package/logger/index.js +0 -17
  3275. package/manifest.mpd +0 -149
  3276. package/minimal/index.d.ts +0 -17
  3277. package/minimal/index.js +0 -17
  3278. package/scripts/README.md +0 -11
  3279. package/scripts/build/generate_build.mjs +0 -194
  3280. package/scripts/build/templates/experimental/features/index.d.ts +0 -16
  3281. package/scripts/build/templates/experimental/features/index.js +0 -16
  3282. package/scripts/build/templates/experimental/index.d.ts +0 -16
  3283. package/scripts/build/templates/experimental/index.js +0 -16
  3284. package/scripts/build/templates/experimental/tools/VideoThumbnailLoader.d.ts +0 -18
  3285. package/scripts/build/templates/experimental/tools/VideoThumbnailLoader.js +0 -18
  3286. package/scripts/build/templates/experimental/tools/createMetaplaylist.d.ts +0 -18
  3287. package/scripts/build/templates/experimental/tools/createMetaplaylist.js +0 -18
  3288. package/scripts/build/templates/experimental/tools/index.d.ts +0 -16
  3289. package/scripts/build/templates/experimental/tools/index.js +0 -16
  3290. package/scripts/build/templates/experimental/tools/mediaCapabilitiesProber.d.ts +0 -18
  3291. package/scripts/build/templates/experimental/tools/mediaCapabilitiesProber.js +0 -18
  3292. package/scripts/build/templates/experimental/tools/parseBIFThumbnails.d.ts +0 -18
  3293. package/scripts/build/templates/experimental/tools/parseBIFThumbnails.js +0 -18
  3294. package/scripts/build/templates/features/index.d.ts +0 -16
  3295. package/scripts/build/templates/features/index.js +0 -16
  3296. package/scripts/build/templates/logger/index.d.ts +0 -17
  3297. package/scripts/build/templates/logger/index.js +0 -17
  3298. package/scripts/build/templates/minimal/index.d.ts +0 -17
  3299. package/scripts/build/templates/minimal/index.js +0 -17
  3300. package/scripts/build/templates/tools/TextTrackRenderer.d.ts +0 -18
  3301. package/scripts/build/templates/tools/TextTrackRenderer.js +0 -18
  3302. package/scripts/build/templates/tools/index.d.ts +0 -16
  3303. package/scripts/build/templates/tools/index.js +0 -16
  3304. package/scripts/build/templates/tools/string-utils.d.ts +0 -18
  3305. package/scripts/build/templates/tools/string-utils.js +0 -18
  3306. package/scripts/build/templates/types/index.d.ts +0 -16
  3307. package/scripts/build/templates/types/index.js +0 -15
  3308. package/scripts/build_demo.mjs +0 -130
  3309. package/scripts/canal-release.patch +0 -78
  3310. package/scripts/check_nodejs_import_compatibility.js +0 -60
  3311. package/scripts/deploy_new_demo +0 -123
  3312. package/scripts/generate_certificate +0 -19
  3313. package/scripts/generate_demo_list.mjs +0 -110
  3314. package/scripts/generate_documentation_list.mjs +0 -114
  3315. package/scripts/generate_standalone_demo.mjs +0 -109
  3316. package/scripts/launch_static_server.mjs +0 -163
  3317. package/scripts/list-npm-scripts.mjs +0 -207
  3318. package/scripts/make-dev-releases +0 -65
  3319. package/scripts/run_standalone_demo.mjs +0 -32
  3320. package/scripts/start_demo_web_server.mjs +0 -59
  3321. package/scripts/update-version +0 -45
  3322. package/scripts/update_gh-pages_demo +0 -132
  3323. package/scripts/update_gh-pages_doc +0 -106
  3324. package/scripts/utils/display_webpack_errors.mjs +0 -33
  3325. package/scripts/utils/get_human_readable_hours.mjs +0 -12
  3326. package/scripts/utils/project_root_directory.mjs +0 -4
  3327. package/scripts/wasm-strip.mjs +0 -364
  3328. package/sonar-project.properties +0 -7
  3329. package/src/README.md +0 -137
  3330. package/src/compat/README.md +0 -29
  3331. package/src/compat/__tests__/add_text_track.test.ts +0 -131
  3332. package/src/compat/__tests__/browser_compatibility_types.test.ts +0 -131
  3333. package/src/compat/__tests__/browser_version.test.ts +0 -84
  3334. package/src/compat/__tests__/can_patch_isobmff.test.ts +0 -50
  3335. package/src/compat/__tests__/can_rely_on_video_visibility_and_size.test.ts +0 -78
  3336. package/src/compat/__tests__/can_reuse_media_keys.test.ts +0 -31
  3337. package/src/compat/__tests__/change_source_buffer_type.test.ts +0 -60
  3338. package/src/compat/__tests__/clear_element_src.test.ts +0 -252
  3339. package/src/compat/__tests__/enable_audio_track.test.ts +0 -341
  3340. package/src/compat/__tests__/is_codec_supported.test.ts +0 -78
  3341. package/src/compat/__tests__/is_seeking_approximate.test.ts +0 -48
  3342. package/src/compat/__tests__/is_vtt_cue.test.ts +0 -75
  3343. package/src/compat/__tests__/make_vtt_cue.test.ts +0 -99
  3344. package/src/compat/__tests__/patch_webkit_source_buffer.test.ts +0 -145
  3345. package/src/compat/__tests__/remove_cue.test.ts +0 -229
  3346. package/src/compat/__tests__/should_favour_custom_safari_EME.test.ts +0 -130
  3347. package/src/compat/__tests__/should_reload_media_source_on_decipherability_update.test.ts +0 -50
  3348. package/src/compat/__tests__/should_renew_media_key_system_access.test.ts +0 -55
  3349. package/src/compat/__tests__/should_unset_media_keys.test.ts +0 -53
  3350. package/src/compat/__tests__/should_validate_metadata.test.ts +0 -53
  3351. package/src/compat/__tests__/should_wait_for_data_before_loaded.test.ts +0 -121
  3352. package/src/compat/__tests__/should_wait_for_have_enough_data.test.ts +0 -36
  3353. package/src/compat/add_class_name.ts +0 -41
  3354. package/src/compat/add_text_track.ts +0 -54
  3355. package/src/compat/browser_compatibility_types.ts +0 -208
  3356. package/src/compat/browser_detection.ts +0 -155
  3357. package/src/compat/browser_version.ts +0 -44
  3358. package/src/compat/can_patch_isobmff.ts +0 -30
  3359. package/src/compat/can_rely_on_video_visibility_and_size.ts +0 -52
  3360. package/src/compat/can_reuse_media_keys.ts +0 -20
  3361. package/src/compat/change_source_buffer_type.ts +0 -66
  3362. package/src/compat/clear_element_src.ts +0 -55
  3363. package/src/compat/eme/close_session.ts +0 -111
  3364. package/src/compat/eme/constants.ts +0 -21
  3365. package/src/compat/eme/custom_key_system_access.ts +0 -67
  3366. package/src/compat/eme/custom_media_keys/ie11_media_keys.ts +0 -186
  3367. package/src/compat/eme/custom_media_keys/index.ts +0 -28
  3368. package/src/compat/eme/custom_media_keys/moz_media_keys_constructor.ts +0 -86
  3369. package/src/compat/eme/custom_media_keys/ms_media_keys_constructor.ts +0 -67
  3370. package/src/compat/eme/custom_media_keys/old_webkit_media_keys.ts +0 -235
  3371. package/src/compat/eme/custom_media_keys/types.ts +0 -67
  3372. package/src/compat/eme/custom_media_keys/webkit_media_keys.ts +0 -308
  3373. package/src/compat/eme/custom_media_keys/webkit_media_keys_constructor.ts +0 -48
  3374. package/src/compat/eme/eme-api-implementation.ts +0 -319
  3375. package/src/compat/eme/generate_key_request.ts +0 -162
  3376. package/src/compat/eme/get_init_data.ts +0 -159
  3377. package/src/compat/eme/get_uuid_kid_from_keystatus_kid.ts +0 -37
  3378. package/src/compat/eme/get_webkit_fairplay_initdata.ts +0 -75
  3379. package/src/compat/eme/index.ts +0 -47
  3380. package/src/compat/eme/load_session.ts +0 -67
  3381. package/src/compat/enable_audio_track.ts +0 -33
  3382. package/src/compat/event_listeners.ts +0 -589
  3383. package/src/compat/get_start_date.ts +0 -48
  3384. package/src/compat/global_scope.ts +0 -18
  3385. package/src/compat/has_issues_with_high_media_source_duration.ts +0 -27
  3386. package/src/compat/index.ts +0 -77
  3387. package/src/compat/is_codec_supported.ts +0 -62
  3388. package/src/compat/is_debug_mode_enabled.ts +0 -12
  3389. package/src/compat/is_node.ts +0 -21
  3390. package/src/compat/is_seeking_approximate.ts +0 -32
  3391. package/src/compat/is_vtt_cue.ts +0 -31
  3392. package/src/compat/is_worker.ts +0 -9
  3393. package/src/compat/make_vtt_cue.ts +0 -52
  3394. package/src/compat/on_height_width_change.ts +0 -114
  3395. package/src/compat/patch_webkit_source_buffer.ts +0 -90
  3396. package/src/compat/remove_cue.ts +0 -64
  3397. package/src/compat/should_favour_custom_safari_EME.ts +0 -34
  3398. package/src/compat/should_reload_media_source_on_decipherability_update.ts +0 -32
  3399. package/src/compat/should_renew_media_key_system_access.ts +0 -26
  3400. package/src/compat/should_unset_media_keys.ts +0 -27
  3401. package/src/compat/should_validate_metadata.ts +0 -27
  3402. package/src/compat/should_wait_for_data_before_loaded.ts +0 -35
  3403. package/src/compat/should_wait_for_have_enough_data.ts +0 -17
  3404. package/src/config.ts +0 -33
  3405. package/src/core/README.md +0 -56
  3406. package/src/core/adaptive/README.md +0 -147
  3407. package/src/core/adaptive/__tests__/buffer_based_chooser.test.ts +0 -548
  3408. package/src/core/adaptive/adaptive_representation_selector.ts +0 -800
  3409. package/src/core/adaptive/buffer_based_chooser.ts +0 -265
  3410. package/src/core/adaptive/guess_based_chooser.ts +0 -310
  3411. package/src/core/adaptive/index.ts +0 -45
  3412. package/src/core/adaptive/network_analyzer.ts +0 -421
  3413. package/src/core/adaptive/utils/__tests__/bandwith_estimator.test.ts +0 -134
  3414. package/src/core/adaptive/utils/__tests__/ewma.test.ts +0 -79
  3415. package/src/core/adaptive/utils/__tests__/filter_by_bitrate.test.ts +0 -56
  3416. package/src/core/adaptive/utils/__tests__/filter_by_resolution.test.ts +0 -82
  3417. package/src/core/adaptive/utils/__tests__/get_buffer_levels.test.ts +0 -48
  3418. package/src/core/adaptive/utils/__tests__/select_optimal_representation.test.ts +0 -67
  3419. package/src/core/adaptive/utils/bandwidth_estimator.ts +0 -88
  3420. package/src/core/adaptive/utils/ewma.ts +0 -59
  3421. package/src/core/adaptive/utils/filter_by_bitrate.ts +0 -46
  3422. package/src/core/adaptive/utils/filter_by_resolution.ts +0 -63
  3423. package/src/core/adaptive/utils/get_buffer_levels.ts +0 -50
  3424. package/src/core/adaptive/utils/last_estimate_storage.ts +0 -79
  3425. package/src/core/adaptive/utils/pending_requests_store.ts +0 -157
  3426. package/src/core/adaptive/utils/representation_score_calculator.ts +0 -168
  3427. package/src/core/adaptive/utils/select_optimal_representation.ts +0 -43
  3428. package/src/core/api/README.md +0 -36
  3429. package/src/core/api/__tests__/option_utils.test.ts +0 -996
  3430. package/src/core/api/__tests__/public_api.test.ts +0 -470
  3431. package/src/core/api/__tests__/utils.test.ts +0 -195
  3432. package/src/core/api/debug/buffer_graph.ts +0 -244
  3433. package/src/core/api/debug/buffer_size_graph.ts +0 -132
  3434. package/src/core/api/debug/constants.ts +0 -2
  3435. package/src/core/api/debug/index.ts +0 -3
  3436. package/src/core/api/debug/modules/general_info.ts +0 -189
  3437. package/src/core/api/debug/modules/segment_buffer_content.ts +0 -155
  3438. package/src/core/api/debug/modules/segment_buffer_size.ts +0 -48
  3439. package/src/core/api/debug/render.ts +0 -40
  3440. package/src/core/api/debug/utils.ts +0 -103
  3441. package/src/core/api/index.ts +0 -28
  3442. package/src/core/api/option_utils.ts +0 -438
  3443. package/src/core/api/playback_observer.ts +0 -1221
  3444. package/src/core/api/public_api.ts +0 -2908
  3445. package/src/core/api/track_management/README.md +0 -15
  3446. package/src/core/api/track_management/__tests__/media_element_tracks_store.test.ts +0 -184
  3447. package/src/core/api/track_management/index.ts +0 -20
  3448. package/src/core/api/track_management/media_element_tracks_store.ts +0 -806
  3449. package/src/core/api/track_management/track_dispatcher.ts +0 -267
  3450. package/src/core/api/track_management/tracks_store.ts +0 -1380
  3451. package/src/core/api/utils.ts +0 -228
  3452. package/src/core/decrypt/README.md +0 -22
  3453. package/src/core/decrypt/__tests__/__global__/get_license.test.ts +0 -422
  3454. package/src/core/decrypt/__tests__/__global__/init_data.test.ts +0 -677
  3455. package/src/core/decrypt/__tests__/__global__/media_key_system_access.test.ts +0 -644
  3456. package/src/core/decrypt/__tests__/__global__/media_keys.test.ts +0 -343
  3457. package/src/core/decrypt/__tests__/__global__/server_certificate.test.ts +0 -264
  3458. package/src/core/decrypt/__tests__/__global__/utils.ts +0 -491
  3459. package/src/core/decrypt/attach_media_keys.ts +0 -118
  3460. package/src/core/decrypt/clear_on_stop.ts +0 -47
  3461. package/src/core/decrypt/content_decryptor.ts +0 -1246
  3462. package/src/core/decrypt/create_or_load_session.ts +0 -133
  3463. package/src/core/decrypt/create_session.ts +0 -214
  3464. package/src/core/decrypt/dispose_decryption_resources.ts +0 -54
  3465. package/src/core/decrypt/find_key_system.ts +0 -386
  3466. package/src/core/decrypt/get_key_system_configuration.ts +0 -36
  3467. package/src/core/decrypt/get_media_keys.ts +0 -142
  3468. package/src/core/decrypt/index.ts +0 -33
  3469. package/src/core/decrypt/init_media_keys.ts +0 -51
  3470. package/src/core/decrypt/session_events_listener.ts +0 -343
  3471. package/src/core/decrypt/set_server_certificate.ts +0 -105
  3472. package/src/core/decrypt/types.ts +0 -404
  3473. package/src/core/decrypt/utils/__tests__/are_init_values_compatible.test.ts +0 -261
  3474. package/src/core/decrypt/utils/__tests__/clean_old_loaded_sessions.test.ts +0 -158
  3475. package/src/core/decrypt/utils/__tests__/clean_old_stored_persistent_info.test.ts +0 -133
  3476. package/src/core/decrypt/utils/are_init_values_compatible.ts +0 -140
  3477. package/src/core/decrypt/utils/check_key_statuses.ts +0 -229
  3478. package/src/core/decrypt/utils/clean_old_loaded_sessions.ts +0 -45
  3479. package/src/core/decrypt/utils/clean_old_stored_persistent_info.ts +0 -48
  3480. package/src/core/decrypt/utils/get_drm_system_id.ts +0 -42
  3481. package/src/core/decrypt/utils/init_data_values_container.ts +0 -119
  3482. package/src/core/decrypt/utils/is_session_usable.ts +0 -62
  3483. package/src/core/decrypt/utils/key_id_comparison.ts +0 -57
  3484. package/src/core/decrypt/utils/key_session_record.ts +0 -174
  3485. package/src/core/decrypt/utils/loaded_sessions_store.ts +0 -505
  3486. package/src/core/decrypt/utils/media_keys_infos_store.ts +0 -85
  3487. package/src/core/decrypt/utils/persistent_sessions_store.ts +0 -360
  3488. package/src/core/decrypt/utils/serializable_bytes.ts +0 -59
  3489. package/src/core/decrypt/utils/server_certificate_store.ts +0 -133
  3490. package/src/core/fetchers/README.md +0 -84
  3491. package/src/core/fetchers/cdn_prioritizer.ts +0 -207
  3492. package/src/core/fetchers/index.ts +0 -38
  3493. package/src/core/fetchers/manifest/index.ts +0 -28
  3494. package/src/core/fetchers/manifest/manifest_fetcher.ts +0 -792
  3495. package/src/core/fetchers/segment/__tests__/task_prioritizer.test.ts +0 -763
  3496. package/src/core/fetchers/segment/index.ts +0 -28
  3497. package/src/core/fetchers/segment/prioritized_segment_fetcher.ts +0 -113
  3498. package/src/core/fetchers/segment/segment_fetcher.ts +0 -499
  3499. package/src/core/fetchers/segment/segment_fetcher_creator.ts +0 -128
  3500. package/src/core/fetchers/segment/task_prioritizer.ts +0 -455
  3501. package/src/core/fetchers/utils/error_selector.ts +0 -38
  3502. package/src/core/fetchers/utils/schedule_request.ts +0 -442
  3503. package/src/core/init/README.md +0 -81
  3504. package/src/core/init/directfile_content_initializer.ts +0 -310
  3505. package/src/core/init/index.ts +0 -22
  3506. package/src/core/init/media_source_content_initializer.ts +0 -891
  3507. package/src/core/init/types.ts +0 -247
  3508. package/src/core/init/utils/__tests__/are_same_stream_events.test.ts +0 -84
  3509. package/src/core/init/utils/__tests__/refresh_scheduled_events_list.test.ts +0 -94
  3510. package/src/core/init/utils/content_time_boundaries_observer.ts +0 -646
  3511. package/src/core/init/utils/create_media_source.ts +0 -139
  3512. package/src/core/init/utils/create_stream_playback_observer.ts +0 -131
  3513. package/src/core/init/utils/end_of_stream.ts +0 -108
  3514. package/src/core/init/utils/get_initial_time.ts +0 -167
  3515. package/src/core/init/utils/get_loaded_reference.ts +0 -80
  3516. package/src/core/init/utils/initial_seek_and_play.ts +0 -215
  3517. package/src/core/init/utils/initialize_content_decryption.ts +0 -172
  3518. package/src/core/init/utils/media_source_duration_updater.ts +0 -349
  3519. package/src/core/init/utils/rebuffering_controller.ts +0 -711
  3520. package/src/core/init/utils/stream_events_emitter/are_same_stream_events.ts +0 -42
  3521. package/src/core/init/utils/stream_events_emitter/index.ts +0 -22
  3522. package/src/core/init/utils/stream_events_emitter/refresh_scheduled_events_list.ts +0 -74
  3523. package/src/core/init/utils/stream_events_emitter/stream_events_emitter.ts +0 -255
  3524. package/src/core/init/utils/stream_events_emitter/types.ts +0 -46
  3525. package/src/core/init/utils/throw_on_media_error.ts +0 -74
  3526. package/src/core/segment_buffers/README.md +0 -219
  3527. package/src/core/segment_buffers/garbage_collector.ts +0 -177
  3528. package/src/core/segment_buffers/implementations/audio_video/audio_video_segment_buffer.ts +0 -650
  3529. package/src/core/segment_buffers/implementations/audio_video/index.ts +0 -18
  3530. package/src/core/segment_buffers/implementations/index.ts +0 -20
  3531. package/src/core/segment_buffers/implementations/text/html/__tests__/utils.test.ts +0 -343
  3532. package/src/core/segment_buffers/implementations/text/html/html_text_segment_buffer.ts +0 -527
  3533. package/src/core/segment_buffers/implementations/text/html/index.ts +0 -24
  3534. package/src/core/segment_buffers/implementations/text/html/parsers.ts +0 -49
  3535. package/src/core/segment_buffers/implementations/text/html/text_track_cues_store.ts +0 -391
  3536. package/src/core/segment_buffers/implementations/text/html/types.ts +0 -23
  3537. package/src/core/segment_buffers/implementations/text/html/update_proportional_elements.ts +0 -93
  3538. package/src/core/segment_buffers/implementations/text/html/utils.ts +0 -139
  3539. package/src/core/segment_buffers/implementations/text/native/index.ts +0 -19
  3540. package/src/core/segment_buffers/implementations/text/native/native_text_segment_buffer.ts +0 -335
  3541. package/src/core/segment_buffers/implementations/text/native/parsers.ts +0 -47
  3542. package/src/core/segment_buffers/implementations/types.ts +0 -380
  3543. package/src/core/segment_buffers/implementations/utils/manual_time_ranges.ts +0 -80
  3544. package/src/core/segment_buffers/index.ts +0 -72
  3545. package/src/core/segment_buffers/inventory/buffered_history.ts +0 -132
  3546. package/src/core/segment_buffers/inventory/index.ts +0 -34
  3547. package/src/core/segment_buffers/inventory/segment_inventory.ts +0 -1106
  3548. package/src/core/segment_buffers/inventory/types.ts +0 -35
  3549. package/src/core/segment_buffers/inventory/utils.ts +0 -61
  3550. package/src/core/segment_buffers/segment_buffers_store.ts +0 -369
  3551. package/src/core/stream/README.md +0 -59
  3552. package/src/core/stream/adaptation/adaptation_stream.ts +0 -438
  3553. package/src/core/stream/adaptation/get_representations_switch_strategy.ts +0 -203
  3554. package/src/core/stream/adaptation/index.ts +0 -20
  3555. package/src/core/stream/adaptation/types.ts +0 -229
  3556. package/src/core/stream/index.ts +0 -40
  3557. package/src/core/stream/orchestrator/README.md +0 -346
  3558. package/src/core/stream/orchestrator/get_time_ranges_for_content.ts +0 -70
  3559. package/src/core/stream/orchestrator/index.ts +0 -30
  3560. package/src/core/stream/orchestrator/stream_orchestrator.ts +0 -726
  3561. package/src/core/stream/period/index.ts +0 -20
  3562. package/src/core/stream/period/period_stream.ts +0 -501
  3563. package/src/core/stream/period/types.ts +0 -125
  3564. package/src/core/stream/period/utils/get_adaptation_switch_strategy.ts +0 -248
  3565. package/src/core/stream/representation/README.md +0 -16
  3566. package/src/core/stream/representation/index.ts +0 -20
  3567. package/src/core/stream/representation/representation_stream.ts +0 -480
  3568. package/src/core/stream/representation/types.ts +0 -308
  3569. package/src/core/stream/representation/utils/append_segment_to_buffer.ts +0 -77
  3570. package/src/core/stream/representation/utils/check_for_discontinuity.ts +0 -305
  3571. package/src/core/stream/representation/utils/downloading_queue.ts +0 -603
  3572. package/src/core/stream/representation/utils/force_garbage_collection.ts +0 -113
  3573. package/src/core/stream/representation/utils/get_buffer_status.ts +0 -321
  3574. package/src/core/stream/representation/utils/get_needed_segments.ts +0 -617
  3575. package/src/core/stream/representation/utils/get_segment_priority.ts +0 -43
  3576. package/src/core/stream/representation/utils/push_init_segment.ts +0 -84
  3577. package/src/core/stream/representation/utils/push_media_segment.ts +0 -113
  3578. package/src/default_config.ts +0 -1200
  3579. package/src/errors/README.md +0 -6
  3580. package/src/errors/__tests__/assertion_error.test.ts +0 -26
  3581. package/src/errors/__tests__/encrypted_media_error.test.ts +0 -45
  3582. package/src/errors/__tests__/error_message.test.ts +0 -23
  3583. package/src/errors/__tests__/format_error.test.ts +0 -62
  3584. package/src/errors/__tests__/is_known_error.test.ts +0 -61
  3585. package/src/errors/__tests__/media_error.test.ts +0 -55
  3586. package/src/errors/__tests__/network_error.test.ts +0 -72
  3587. package/src/errors/__tests__/other_error.test.ts +0 -53
  3588. package/src/errors/__tests__/request_error.test.ts +0 -29
  3589. package/src/errors/assertion_error.ts +0 -40
  3590. package/src/errors/custom_loader_error.ts +0 -52
  3591. package/src/errors/encrypted_media_error.ts +0 -73
  3592. package/src/errors/error_codes.ts +0 -149
  3593. package/src/errors/error_message.ts +0 -25
  3594. package/src/errors/format_error.ts +0 -39
  3595. package/src/errors/index.ts +0 -52
  3596. package/src/errors/is_known_error.ts +0 -35
  3597. package/src/errors/media_error.ts +0 -124
  3598. package/src/errors/network_error.ts +0 -72
  3599. package/src/errors/other_error.ts +0 -50
  3600. package/src/errors/request_error.ts +0 -70
  3601. package/src/experimental/README.md +0 -20
  3602. package/src/experimental/features/__tests__/dash_wasm.test.ts +0 -44
  3603. package/src/experimental/features/__tests__/debug_element.test.ts +0 -12
  3604. package/src/experimental/features/__tests__/index.test.ts +0 -19
  3605. package/src/experimental/features/__tests__/local.test.ts +0 -35
  3606. package/src/experimental/features/__tests__/metaplaylist.test.ts +0 -35
  3607. package/src/experimental/features/dash_wasm.ts +0 -41
  3608. package/src/experimental/features/debug_element.ts +0 -13
  3609. package/src/experimental/features/index.ts +0 -20
  3610. package/src/experimental/features/local.ts +0 -28
  3611. package/src/experimental/features/metaplaylist.ts +0 -28
  3612. package/src/experimental/index.ts +0 -5
  3613. package/src/experimental/tools/VideoThumbnailLoader/features/dash.ts +0 -23
  3614. package/src/experimental/tools/VideoThumbnailLoader/features/metaplaylist.ts +0 -23
  3615. package/src/experimental/tools/VideoThumbnailLoader/index.ts +0 -25
  3616. package/src/experimental/tools/VideoThumbnailLoader/load_and_push_segment.ts +0 -77
  3617. package/src/experimental/tools/VideoThumbnailLoader/prepare_source_buffer.ts +0 -75
  3618. package/src/experimental/tools/VideoThumbnailLoader/remove_buffer_around_time.ts +0 -54
  3619. package/src/experimental/tools/VideoThumbnailLoader/types.ts +0 -39
  3620. package/src/experimental/tools/VideoThumbnailLoader/video_thumbnail_loader.ts +0 -425
  3621. package/src/experimental/tools/VideoThumbnailLoader/video_thumbnail_loader_error.ts +0 -34
  3622. package/src/experimental/tools/createMetaplaylist/get_duration_from_manifest.ts +0 -143
  3623. package/src/experimental/tools/createMetaplaylist/index.ts +0 -72
  3624. package/src/experimental/tools/index.ts +0 -27
  3625. package/src/experimental/tools/mediaCapabilitiesProber/__tests__/capabilities.test.ts +0 -37
  3626. package/src/experimental/tools/mediaCapabilitiesProber/__tests__/probers/DRMInfos.test.ts +0 -140
  3627. package/src/experimental/tools/mediaCapabilitiesProber/__tests__/probers/HDCPPolicy.test.ts +0 -153
  3628. package/src/experimental/tools/mediaCapabilitiesProber/__tests__/probers/decodingInfos.test.ts +0 -405
  3629. package/src/experimental/tools/mediaCapabilitiesProber/__tests__/probers/defaultCodecFinder.test.ts +0 -136
  3630. package/src/experimental/tools/mediaCapabilitiesProber/__tests__/probers/mediaContentType.test.ts +0 -294
  3631. package/src/experimental/tools/mediaCapabilitiesProber/__tests__/probers/mediaDisplayInfos.test.ts +0 -190
  3632. package/src/experimental/tools/mediaCapabilitiesProber/__tests__/utils.test.ts +0 -361
  3633. package/src/experimental/tools/mediaCapabilitiesProber/api/index.ts +0 -184
  3634. package/src/experimental/tools/mediaCapabilitiesProber/api/probeMediaConfiguration.ts +0 -136
  3635. package/src/experimental/tools/mediaCapabilitiesProber/capabilities.ts +0 -169
  3636. package/src/experimental/tools/mediaCapabilitiesProber/index.ts +0 -18
  3637. package/src/experimental/tools/mediaCapabilitiesProber/log.ts +0 -21
  3638. package/src/experimental/tools/mediaCapabilitiesProber/probers/DRMInfos.ts +0 -67
  3639. package/src/experimental/tools/mediaCapabilitiesProber/probers/HDCPPolicy.ts +0 -89
  3640. package/src/experimental/tools/mediaCapabilitiesProber/probers/decodingInfo.ts +0 -100
  3641. package/src/experimental/tools/mediaCapabilitiesProber/probers/defaultCodecsFinder.ts +0 -66
  3642. package/src/experimental/tools/mediaCapabilitiesProber/probers/index.ts +0 -44
  3643. package/src/experimental/tools/mediaCapabilitiesProber/probers/mediaContentType.ts +0 -66
  3644. package/src/experimental/tools/mediaCapabilitiesProber/probers/mediaContentTypeWithFeatures/format.ts +0 -100
  3645. package/src/experimental/tools/mediaCapabilitiesProber/probers/mediaContentTypeWithFeatures/index.ts +0 -106
  3646. package/src/experimental/tools/mediaCapabilitiesProber/probers/mediaDisplayInfos.ts +0 -55
  3647. package/src/experimental/tools/mediaCapabilitiesProber/types.ts +0 -75
  3648. package/src/experimental/tools/mediaCapabilitiesProber/utils.ts +0 -107
  3649. package/src/experimental/tools/parseBIFThumbnails/index.ts +0 -39
  3650. package/src/features/README.md +0 -11
  3651. package/src/features/__tests__/add_features.test.ts +0 -69
  3652. package/src/features/add_features.ts +0 -37
  3653. package/src/features/features_object.ts +0 -35
  3654. package/src/features/index.ts +0 -40
  3655. package/src/features/list/__tests__/dash.test.ts +0 -41
  3656. package/src/features/list/__tests__/directfile.test.ts +0 -35
  3657. package/src/features/list/__tests__/eme.test.ts +0 -28
  3658. package/src/features/list/__tests__/html_sami_parser.test.ts +0 -33
  3659. package/src/features/list/__tests__/html_srt_parser.test.ts +0 -33
  3660. package/src/features/list/__tests__/html_text_buffer.test.ts +0 -29
  3661. package/src/features/list/__tests__/html_ttml_parser.test.ts +0 -33
  3662. package/src/features/list/__tests__/html_vtt_parser.test.ts +0 -33
  3663. package/src/features/list/__tests__/index.test.ts +0 -49
  3664. package/src/features/list/__tests__/native_sami_parser.test.ts +0 -33
  3665. package/src/features/list/__tests__/native_srt_parser.test.ts +0 -33
  3666. package/src/features/list/__tests__/native_text_buffer.test.ts +0 -29
  3667. package/src/features/list/__tests__/native_ttml_parser.test.ts +0 -33
  3668. package/src/features/list/__tests__/native_vtt_parser.test.ts +0 -33
  3669. package/src/features/list/__tests__/smooth.test.ts +0 -36
  3670. package/src/features/list/dash.ts +0 -36
  3671. package/src/features/list/directfile.ts +0 -33
  3672. package/src/features/list/eme.ts +0 -29
  3673. package/src/features/list/html_sami_parser.ts +0 -31
  3674. package/src/features/list/html_srt_parser.ts +0 -31
  3675. package/src/features/list/html_text_buffer.ts +0 -29
  3676. package/src/features/list/html_ttml_parser.ts +0 -31
  3677. package/src/features/list/html_vtt_parser.ts +0 -31
  3678. package/src/features/list/index.ts +0 -30
  3679. package/src/features/list/native_sami_parser.ts +0 -32
  3680. package/src/features/list/native_srt_parser.ts +0 -32
  3681. package/src/features/list/native_text_buffer.ts +0 -30
  3682. package/src/features/list/native_ttml_parser.ts +0 -32
  3683. package/src/features/list/native_vtt_parser.ts +0 -32
  3684. package/src/features/list/smooth.ts +0 -32
  3685. package/src/features/types.ts +0 -156
  3686. package/src/globals.dev.d.ts +0 -15
  3687. package/src/globals.prod.d.ts +0 -15
  3688. package/src/index.ts +0 -60
  3689. package/src/log.ts +0 -22
  3690. package/src/manifest/README.md +0 -55
  3691. package/src/manifest/__tests__/adaptation.test.ts +0 -448
  3692. package/src/manifest/__tests__/manifest.test.ts +0 -487
  3693. package/src/manifest/__tests__/period.test.ts +0 -799
  3694. package/src/manifest/__tests__/representation.test.ts +0 -297
  3695. package/src/manifest/__tests__/update_period_in_place.test.ts +0 -1074
  3696. package/src/manifest/__tests__/update_periods.test.ts +0 -845
  3697. package/src/manifest/adaptation.ts +0 -308
  3698. package/src/manifest/index.ts +0 -59
  3699. package/src/manifest/manifest.ts +0 -650
  3700. package/src/manifest/period.ts +0 -188
  3701. package/src/manifest/representation.ts +0 -479
  3702. package/src/manifest/representation_index/__tests__/static.test.ts +0 -74
  3703. package/src/manifest/representation_index/index.ts +0 -29
  3704. package/src/manifest/representation_index/static.ts +0 -166
  3705. package/src/manifest/representation_index/types.ts +0 -458
  3706. package/src/manifest/types.ts +0 -30
  3707. package/src/manifest/update_period_in_place.ts +0 -142
  3708. package/src/manifest/update_periods.ts +0 -201
  3709. package/src/manifest/utils.ts +0 -60
  3710. package/src/minimal.ts +0 -34
  3711. package/src/parsers/README.md +0 -12
  3712. package/src/parsers/containers/isobmff/constants.ts +0 -24
  3713. package/src/parsers/containers/isobmff/create_box.ts +0 -81
  3714. package/src/parsers/containers/isobmff/drm/index.ts +0 -17
  3715. package/src/parsers/containers/isobmff/drm/playready.ts +0 -45
  3716. package/src/parsers/containers/isobmff/get_box.ts +0 -278
  3717. package/src/parsers/containers/isobmff/index.ts +0 -51
  3718. package/src/parsers/containers/isobmff/read.ts +0 -105
  3719. package/src/parsers/containers/isobmff/take_pssh_out.ts +0 -101
  3720. package/src/parsers/containers/isobmff/utils.ts +0 -555
  3721. package/src/parsers/containers/matroska/index.ts +0 -21
  3722. package/src/parsers/containers/matroska/utils.ts +0 -313
  3723. package/src/parsers/images/bif.ts +0 -128
  3724. package/src/parsers/manifest/dash/common/__tests__/attach_trickmode_track.test.ts +0 -65
  3725. package/src/parsers/manifest/dash/common/__tests__/convert_supplemental_codecs.test.ts +0 -37
  3726. package/src/parsers/manifest/dash/common/__tests__/flatten_overlapping_period.test.ts +0 -162
  3727. package/src/parsers/manifest/dash/common/__tests__/get_clock_offset.test.ts +0 -66
  3728. package/src/parsers/manifest/dash/common/__tests__/get_http_utc-timing_url.test.ts +0 -165
  3729. package/src/parsers/manifest/dash/common/__tests__/get_periods_time_infos.test.ts +0 -118
  3730. package/src/parsers/manifest/dash/common/__tests__/manifest_bounds_calculator.test.ts +0 -290
  3731. package/src/parsers/manifest/dash/common/__tests__/parse_availability_start_time.test.ts +0 -63
  3732. package/src/parsers/manifest/dash/common/attach_trickmode_track.ts +0 -55
  3733. package/src/parsers/manifest/dash/common/convert_supplemental_codecs.ts +0 -32
  3734. package/src/parsers/manifest/dash/common/flatten_overlapping_periods.ts +0 -87
  3735. package/src/parsers/manifest/dash/common/get_clock_offset.ts +0 -42
  3736. package/src/parsers/manifest/dash/common/get_hdr_information.ts +0 -94
  3737. package/src/parsers/manifest/dash/common/get_http_utc-timing_url.ts +0 -46
  3738. package/src/parsers/manifest/dash/common/get_minimum_and_maximum_positions.ts +0 -39
  3739. package/src/parsers/manifest/dash/common/get_periods_time_infos.ts +0 -91
  3740. package/src/parsers/manifest/dash/common/index.ts +0 -40
  3741. package/src/parsers/manifest/dash/common/indexes/__tests__/tokens.test.ts +0 -60
  3742. package/src/parsers/manifest/dash/common/indexes/base.ts +0 -435
  3743. package/src/parsers/manifest/dash/common/indexes/get_init_segment.ts +0 -55
  3744. package/src/parsers/manifest/dash/common/indexes/get_segments_from_timeline.ts +0 -148
  3745. package/src/parsers/manifest/dash/common/indexes/index.ts +0 -39
  3746. package/src/parsers/manifest/dash/common/indexes/list.ts +0 -346
  3747. package/src/parsers/manifest/dash/common/indexes/template.ts +0 -661
  3748. package/src/parsers/manifest/dash/common/indexes/timeline/__tests__/parse_s_element.test.ts +0 -115
  3749. package/src/parsers/manifest/dash/common/indexes/timeline/construct_timeline_from_elements.ts +0 -54
  3750. package/src/parsers/manifest/dash/common/indexes/timeline/construct_timeline_from_previous_timeline.ts +0 -102
  3751. package/src/parsers/manifest/dash/common/indexes/timeline/convert_element_to_index_segment.ts +0 -66
  3752. package/src/parsers/manifest/dash/common/indexes/timeline/find_first_common_start_time.ts +0 -153
  3753. package/src/parsers/manifest/dash/common/indexes/timeline/index.ts +0 -21
  3754. package/src/parsers/manifest/dash/common/indexes/timeline/parse_s_element.ts +0 -72
  3755. package/src/parsers/manifest/dash/common/indexes/timeline/timeline_representation_index.ts +0 -1060
  3756. package/src/parsers/manifest/dash/common/indexes/tokens.ts +0 -127
  3757. package/src/parsers/manifest/dash/common/indexes/utils.ts +0 -32
  3758. package/src/parsers/manifest/dash/common/infer_adaptation_type.ts +0 -136
  3759. package/src/parsers/manifest/dash/common/manifest_bounds_calculator.ts +0 -171
  3760. package/src/parsers/manifest/dash/common/parse_adaptation_sets.ts +0 -568
  3761. package/src/parsers/manifest/dash/common/parse_availability_start_time.ts +0 -35
  3762. package/src/parsers/manifest/dash/common/parse_mpd.ts +0 -400
  3763. package/src/parsers/manifest/dash/common/parse_periods.ts +0 -369
  3764. package/src/parsers/manifest/dash/common/parse_representation_index.ts +0 -199
  3765. package/src/parsers/manifest/dash/common/parse_representations.ts +0 -352
  3766. package/src/parsers/manifest/dash/common/resolve_base_urls.ts +0 -58
  3767. package/src/parsers/manifest/dash/index.ts +0 -22
  3768. package/src/parsers/manifest/dash/js-parser/__tests__/parse_from_document.test.ts +0 -43
  3769. package/src/parsers/manifest/dash/js-parser/index.ts +0 -18
  3770. package/src/parsers/manifest/dash/js-parser/node_parsers/AdaptationSet.ts +0 -387
  3771. package/src/parsers/manifest/dash/js-parser/node_parsers/BaseURL.ts +0 -35
  3772. package/src/parsers/manifest/dash/js-parser/node_parsers/ContentComponent.ts +0 -49
  3773. package/src/parsers/manifest/dash/js-parser/node_parsers/ContentProtection.ts +0 -94
  3774. package/src/parsers/manifest/dash/js-parser/node_parsers/EventStream.ts +0 -117
  3775. package/src/parsers/manifest/dash/js-parser/node_parsers/Initialization.ts +0 -48
  3776. package/src/parsers/manifest/dash/js-parser/node_parsers/MPD.ts +0 -180
  3777. package/src/parsers/manifest/dash/js-parser/node_parsers/Period.ts +0 -152
  3778. package/src/parsers/manifest/dash/js-parser/node_parsers/Representation.ts +0 -237
  3779. package/src/parsers/manifest/dash/js-parser/node_parsers/SegmentBase.ts +0 -112
  3780. package/src/parsers/manifest/dash/js-parser/node_parsers/SegmentList.ts +0 -50
  3781. package/src/parsers/manifest/dash/js-parser/node_parsers/SegmentTemplate.ts +0 -98
  3782. package/src/parsers/manifest/dash/js-parser/node_parsers/SegmentTimeline.ts +0 -35
  3783. package/src/parsers/manifest/dash/js-parser/node_parsers/SegmentURL.ts +0 -63
  3784. package/src/parsers/manifest/dash/js-parser/node_parsers/__tests__/AdaptationSet.test.ts +0 -573
  3785. package/src/parsers/manifest/dash/js-parser/node_parsers/__tests__/ContentComponent.test.ts +0 -67
  3786. package/src/parsers/manifest/dash/js-parser/node_parsers/__tests__/ContentProtection.test.ts +0 -223
  3787. package/src/parsers/manifest/dash/js-parser/node_parsers/__tests__/Initialization.test.ts +0 -139
  3788. package/src/parsers/manifest/dash/js-parser/node_parsers/__tests__/SegmentTimeline.test.ts +0 -119
  3789. package/src/parsers/manifest/dash/js-parser/node_parsers/__tests__/SegmentURL.test.ts +0 -205
  3790. package/src/parsers/manifest/dash/js-parser/node_parsers/__tests__/utils.test.ts +0 -218
  3791. package/src/parsers/manifest/dash/js-parser/node_parsers/utils.ts +0 -404
  3792. package/src/parsers/manifest/dash/js-parser/parse_from_document.ts +0 -129
  3793. package/src/parsers/manifest/dash/node_parser_types.ts +0 -431
  3794. package/src/parsers/manifest/dash/parsers_types.ts +0 -91
  3795. package/src/parsers/manifest/dash/wasm-parser/Cargo.lock +0 -25
  3796. package/src/parsers/manifest/dash/wasm-parser/Cargo.toml +0 -16
  3797. package/src/parsers/manifest/dash/wasm-parser/README.md +0 -267
  3798. package/src/parsers/manifest/dash/wasm-parser/index.ts +0 -21
  3799. package/src/parsers/manifest/dash/wasm-parser/rs/errors.rs +0 -28
  3800. package/src/parsers/manifest/dash/wasm-parser/rs/events.rs +0 -383
  3801. package/src/parsers/manifest/dash/wasm-parser/rs/lib.rs +0 -85
  3802. package/src/parsers/manifest/dash/wasm-parser/rs/processor/attributes.rs +0 -414
  3803. package/src/parsers/manifest/dash/wasm-parser/rs/processor/mod.rs +0 -472
  3804. package/src/parsers/manifest/dash/wasm-parser/rs/processor/s_element.rs +0 -72
  3805. package/src/parsers/manifest/dash/wasm-parser/rs/reader.rs +0 -17
  3806. package/src/parsers/manifest/dash/wasm-parser/rs/reportable.rs +0 -147
  3807. package/src/parsers/manifest/dash/wasm-parser/rs/utils.rs +0 -266
  3808. package/src/parsers/manifest/dash/wasm-parser/ts/dash-wasm-parser.ts +0 -478
  3809. package/src/parsers/manifest/dash/wasm-parser/ts/generators/AdaptationSet.ts +0 -340
  3810. package/src/parsers/manifest/dash/wasm-parser/ts/generators/BaseURL.ts +0 -38
  3811. package/src/parsers/manifest/dash/wasm-parser/ts/generators/ContentComponent.ts +0 -53
  3812. package/src/parsers/manifest/dash/wasm-parser/ts/generators/ContentProtection.ts +0 -62
  3813. package/src/parsers/manifest/dash/wasm-parser/ts/generators/EventStream.ts +0 -144
  3814. package/src/parsers/manifest/dash/wasm-parser/ts/generators/MPD.ts +0 -183
  3815. package/src/parsers/manifest/dash/wasm-parser/ts/generators/Period.ts +0 -180
  3816. package/src/parsers/manifest/dash/wasm-parser/ts/generators/Representation.ts +0 -214
  3817. package/src/parsers/manifest/dash/wasm-parser/ts/generators/Scheme.ts +0 -44
  3818. package/src/parsers/manifest/dash/wasm-parser/ts/generators/SegmentBase.ts +0 -115
  3819. package/src/parsers/manifest/dash/wasm-parser/ts/generators/SegmentList.ts +0 -61
  3820. package/src/parsers/manifest/dash/wasm-parser/ts/generators/SegmentTemplate.ts +0 -133
  3821. package/src/parsers/manifest/dash/wasm-parser/ts/generators/SegmentUrl.ts +0 -70
  3822. package/src/parsers/manifest/dash/wasm-parser/ts/generators/XLink.ts +0 -66
  3823. package/src/parsers/manifest/dash/wasm-parser/ts/generators/index.ts +0 -17
  3824. package/src/parsers/manifest/dash/wasm-parser/ts/generators/root.ts +0 -66
  3825. package/src/parsers/manifest/dash/wasm-parser/ts/parsers_stack.ts +0 -80
  3826. package/src/parsers/manifest/dash/wasm-parser/ts/types.ts +0 -298
  3827. package/src/parsers/manifest/dash/wasm-parser/ts/utils.ts +0 -47
  3828. package/src/parsers/manifest/index.ts +0 -17
  3829. package/src/parsers/manifest/local/index.ts +0 -25
  3830. package/src/parsers/manifest/local/parse_local_manifest.ts +0 -165
  3831. package/src/parsers/manifest/local/representation_index.ts +0 -254
  3832. package/src/parsers/manifest/local/types.ts +0 -291
  3833. package/src/parsers/manifest/metaplaylist/index.ts +0 -28
  3834. package/src/parsers/manifest/metaplaylist/metaplaylist_parser.ts +0 -336
  3835. package/src/parsers/manifest/metaplaylist/representation_index.ts +0 -272
  3836. package/src/parsers/manifest/smooth/create_parser.ts +0 -690
  3837. package/src/parsers/manifest/smooth/get_codecs.ts +0 -55
  3838. package/src/parsers/manifest/smooth/index.ts +0 -26
  3839. package/src/parsers/manifest/smooth/parse_C_nodes.ts +0 -69
  3840. package/src/parsers/manifest/smooth/parse_protection_node.ts +0 -72
  3841. package/src/parsers/manifest/smooth/representation_index.ts +0 -563
  3842. package/src/parsers/manifest/smooth/shared_smooth_segment_timeline.ts +0 -242
  3843. package/src/parsers/manifest/smooth/utils/add_segment_infos.ts +0 -75
  3844. package/src/parsers/manifest/smooth/utils/parseBoolean.ts +0 -31
  3845. package/src/parsers/manifest/smooth/utils/reduceChildren.ts +0 -36
  3846. package/src/parsers/manifest/smooth/utils/tokens.ts +0 -46
  3847. package/src/parsers/manifest/types.ts +0 -394
  3848. package/src/parsers/manifest/utils/__tests__/get_first_time_from_adaptations.test.ts +0 -163
  3849. package/src/parsers/manifest/utils/__tests__/get_last_time_from_adaptation.test.ts +0 -163
  3850. package/src/parsers/manifest/utils/__tests__/index_helpers.test.ts +0 -55
  3851. package/src/parsers/manifest/utils/__tests__/update_segment_timeline.test.ts +0 -545
  3852. package/src/parsers/manifest/utils/check_manifest_ids.ts +0 -83
  3853. package/src/parsers/manifest/utils/clear_timeline_from_position.ts +0 -74
  3854. package/src/parsers/manifest/utils/get_first_time_from_adaptation.ts +0 -48
  3855. package/src/parsers/manifest/utils/get_last_time_from_adaptation.ts +0 -50
  3856. package/src/parsers/manifest/utils/get_maximum_positions.ts +0 -87
  3857. package/src/parsers/manifest/utils/get_minimum_position.ts +0 -80
  3858. package/src/parsers/manifest/utils/index_helpers.ts +0 -204
  3859. package/src/parsers/manifest/utils/update_segment_timeline.ts +0 -141
  3860. package/src/parsers/texttracks/index.ts +0 -21
  3861. package/src/parsers/texttracks/sami/html.ts +0 -219
  3862. package/src/parsers/texttracks/sami/native.ts +0 -192
  3863. package/src/parsers/texttracks/srt/__tests__/find_end_of_cue_block.test.ts +0 -99
  3864. package/src/parsers/texttracks/srt/__tests__/get_cue_blocks.test.ts +0 -119
  3865. package/src/parsers/texttracks/srt/__tests__/parse_cue.test.ts +0 -123
  3866. package/src/parsers/texttracks/srt/__tests__/parse_timestamp.test.ts +0 -36
  3867. package/src/parsers/texttracks/srt/find_end_of_cue_block.ts +0 -46
  3868. package/src/parsers/texttracks/srt/get_cue_blocks.ts +0 -49
  3869. package/src/parsers/texttracks/srt/html.ts +0 -182
  3870. package/src/parsers/texttracks/srt/native.ts +0 -74
  3871. package/src/parsers/texttracks/srt/parse_cue.ts +0 -76
  3872. package/src/parsers/texttracks/srt/parse_timestamp.ts +0 -37
  3873. package/src/parsers/texttracks/ttml/__tests__/resolve_styles_inheritance.test.ts +0 -248
  3874. package/src/parsers/texttracks/ttml/get_parameters.ts +0 -106
  3875. package/src/parsers/texttracks/ttml/get_styling.ts +0 -146
  3876. package/src/parsers/texttracks/ttml/get_time_delimiters.ts +0 -49
  3877. package/src/parsers/texttracks/ttml/html/__tests__/__global__/html_ttml_parser.test.test.ts +0 -191
  3878. package/src/parsers/texttracks/ttml/html/__tests__/generate_css_test_outline.test.ts +0 -32
  3879. package/src/parsers/texttracks/ttml/html/__tests__/ttml_color_to_css_color.test.ts +0 -62
  3880. package/src/parsers/texttracks/ttml/html/apply_default_ttml_paragraph_style.ts +0 -67
  3881. package/src/parsers/texttracks/ttml/html/apply_extent.ts +0 -65
  3882. package/src/parsers/texttracks/ttml/html/apply_font_size.ts +0 -62
  3883. package/src/parsers/texttracks/ttml/html/apply_line_height.ts +0 -50
  3884. package/src/parsers/texttracks/ttml/html/apply_origin.ts +0 -64
  3885. package/src/parsers/texttracks/ttml/html/apply_padding.ts +0 -141
  3886. package/src/parsers/texttracks/ttml/html/create_element.ts +0 -549
  3887. package/src/parsers/texttracks/ttml/html/generate_css_test_outline.ts +0 -46
  3888. package/src/parsers/texttracks/ttml/html/index.ts +0 -23
  3889. package/src/parsers/texttracks/ttml/html/parse_cue.ts +0 -65
  3890. package/src/parsers/texttracks/ttml/html/parse_ttml_to_div.ts +0 -58
  3891. package/src/parsers/texttracks/ttml/html/ttml_color_to_css_color.ts +0 -68
  3892. package/src/parsers/texttracks/ttml/native/index.ts +0 -23
  3893. package/src/parsers/texttracks/ttml/native/parse_cue.ts +0 -245
  3894. package/src/parsers/texttracks/ttml/native/parse_ttml_to_vtt.ts +0 -39
  3895. package/src/parsers/texttracks/ttml/parse_ttml.ts +0 -206
  3896. package/src/parsers/texttracks/ttml/regexps.ts +0 -65
  3897. package/src/parsers/texttracks/ttml/resolve_styles_inheritance.ts +0 -84
  3898. package/src/parsers/texttracks/ttml/time_parsing.ts +0 -156
  3899. package/src/parsers/texttracks/ttml/xml_utils.ts +0 -166
  3900. package/src/parsers/texttracks/types.ts +0 -34
  3901. package/src/parsers/texttracks/webvtt/__tests__/get_cue_blocks.test.ts +0 -218
  3902. package/src/parsers/texttracks/webvtt/__tests__/get_style_blocks.test.ts +0 -65
  3903. package/src/parsers/texttracks/webvtt/__tests__/parse_cue_block.test.ts +0 -249
  3904. package/src/parsers/texttracks/webvtt/__tests__/parse_timestamp.test.ts +0 -39
  3905. package/src/parsers/texttracks/webvtt/__tests__/utils.test.ts +0 -401
  3906. package/src/parsers/texttracks/webvtt/get_cue_blocks.ts +0 -51
  3907. package/src/parsers/texttracks/webvtt/get_style_blocks.ts +0 -56
  3908. package/src/parsers/texttracks/webvtt/html/__tests__/convert_payload_to_html.test.ts +0 -108
  3909. package/src/parsers/texttracks/webvtt/html/__tests__/create_default_style_elements.test.ts +0 -44
  3910. package/src/parsers/texttracks/webvtt/html/__tests__/create_style_attribute.test.ts +0 -139
  3911. package/src/parsers/texttracks/webvtt/html/__tests__/create_styled_element.test.ts +0 -140
  3912. package/src/parsers/texttracks/webvtt/html/__tests__/parse_style_block.test.ts +0 -345
  3913. package/src/parsers/texttracks/webvtt/html/__tests__/parse_webvtt_to_div.test.ts +0 -181
  3914. package/src/parsers/texttracks/webvtt/html/__tests__/to_html.test.ts +0 -234
  3915. package/src/parsers/texttracks/webvtt/html/convert_payload_to_html.ts +0 -46
  3916. package/src/parsers/texttracks/webvtt/html/create_default_style_elements.ts +0 -26
  3917. package/src/parsers/texttracks/webvtt/html/create_style_attribute.ts +0 -222
  3918. package/src/parsers/texttracks/webvtt/html/create_styled_element.ts +0 -95
  3919. package/src/parsers/texttracks/webvtt/html/index.ts +0 -25
  3920. package/src/parsers/texttracks/webvtt/html/parse_style_block.ts +0 -76
  3921. package/src/parsers/texttracks/webvtt/html/parse_webvtt_to_div.ts +0 -67
  3922. package/src/parsers/texttracks/webvtt/html/to_html.ts +0 -96
  3923. package/src/parsers/texttracks/webvtt/native/index.ts +0 -23
  3924. package/src/parsers/texttracks/webvtt/native/parse_vtt_to_cues.ts +0 -70
  3925. package/src/parsers/texttracks/webvtt/native/set_settings_on_cue.ts +0 -95
  3926. package/src/parsers/texttracks/webvtt/native/to_native_cue.ts +0 -34
  3927. package/src/parsers/texttracks/webvtt/parse_cue_block.ts +0 -128
  3928. package/src/parsers/texttracks/webvtt/parse_timestamp.ts +0 -40
  3929. package/src/parsers/texttracks/webvtt/utils.ts +0 -135
  3930. package/src/public_types.ts +0 -1040
  3931. package/src/tools/README.md +0 -8
  3932. package/src/tools/TextTrackRenderer/index.ts +0 -28
  3933. package/src/tools/TextTrackRenderer/text_track_renderer.ts +0 -108
  3934. package/src/tools/index.ts +0 -20
  3935. package/src/tools/string_utils/index.ts +0 -24
  3936. package/src/transports/README.md +0 -276
  3937. package/src/transports/dash/add_segment_integrity_checks_to_loader.ts +0 -97
  3938. package/src/transports/dash/construct_segment_url.ts +0 -28
  3939. package/src/transports/dash/extract_complete_chunks.ts +0 -66
  3940. package/src/transports/dash/get_events_out_of_emsgs.ts +0 -105
  3941. package/src/transports/dash/index.ts +0 -23
  3942. package/src/transports/dash/init_segment_loader.ts +0 -119
  3943. package/src/transports/dash/low_latency_segment_loader.ts +0 -87
  3944. package/src/transports/dash/manifest_parser.ts +0 -330
  3945. package/src/transports/dash/pipelines.ts +0 -66
  3946. package/src/transports/dash/segment_loader.ts +0 -255
  3947. package/src/transports/dash/segment_parser.ts +0 -188
  3948. package/src/transports/dash/text_loader.ts +0 -122
  3949. package/src/transports/dash/text_parser.ts +0 -228
  3950. package/src/transports/index.ts +0 -17
  3951. package/src/transports/local/index.ts +0 -18
  3952. package/src/transports/local/pipelines.ts +0 -91
  3953. package/src/transports/local/segment_loader.ts +0 -196
  3954. package/src/transports/local/segment_parser.ts +0 -102
  3955. package/src/transports/local/text_parser.ts +0 -185
  3956. package/src/transports/metaplaylist/README.md +0 -94
  3957. package/src/transports/metaplaylist/index.ts +0 -23
  3958. package/src/transports/metaplaylist/manifest_loader.ts +0 -63
  3959. package/src/transports/metaplaylist/pipelines.ts +0 -381
  3960. package/src/transports/smooth/extract_timings_infos.ts +0 -142
  3961. package/src/transports/smooth/index.ts +0 -23
  3962. package/src/transports/smooth/is_mp4_embedded_track.ts +0 -25
  3963. package/src/transports/smooth/isobmff/__tests__/create_boxes.test.ts +0 -231
  3964. package/src/transports/smooth/isobmff/create_audio_init_segment.ts +0 -84
  3965. package/src/transports/smooth/isobmff/create_boxes.ts +0 -481
  3966. package/src/transports/smooth/isobmff/create_init_segment.ts +0 -100
  3967. package/src/transports/smooth/isobmff/create_traf_box.ts +0 -40
  3968. package/src/transports/smooth/isobmff/create_video_init_segment.ts +0 -78
  3969. package/src/transports/smooth/isobmff/get_aaces_header.ts +0 -62
  3970. package/src/transports/smooth/isobmff/index.ts +0 -32
  3971. package/src/transports/smooth/isobmff/parse_tfrf.ts +0 -57
  3972. package/src/transports/smooth/isobmff/parse_tfxd.ts +0 -38
  3973. package/src/transports/smooth/isobmff/patch_segment.ts +0 -171
  3974. package/src/transports/smooth/pipelines.ts +0 -378
  3975. package/src/transports/smooth/segment_loader.ts +0 -292
  3976. package/src/transports/smooth/utils.ts +0 -45
  3977. package/src/transports/types.ts +0 -820
  3978. package/src/transports/utils/__tests__/byte_range.test.ts +0 -35
  3979. package/src/transports/utils/__tests__/check_isobmff_integrity.test.ts +0 -148
  3980. package/src/transports/utils/__tests__/find_complete_box.test.ts +0 -138
  3981. package/src/transports/utils/__tests__/infer_segment_container.test.ts +0 -80
  3982. package/src/transports/utils/byte_range.ts +0 -25
  3983. package/src/transports/utils/call_custom_manifest_loader.ts +0 -146
  3984. package/src/transports/utils/check_isobmff_integrity.ts +0 -50
  3985. package/src/transports/utils/find_complete_box.ts +0 -63
  3986. package/src/transports/utils/generate_manifest_loader.ts +0 -100
  3987. package/src/transports/utils/get_isobmff_timing_infos.ts +0 -86
  3988. package/src/transports/utils/infer_segment_container.ts +0 -50
  3989. package/src/transports/utils/parse_text_track.ts +0 -170
  3990. package/src/typings/README.md +0 -7
  3991. package/src/utils/README.md +0 -5
  3992. package/src/utils/__tests__/are_arrays_of_numbers_equal.test.ts +0 -86
  3993. package/src/utils/__tests__/are_codecs_compatible.test.ts +0 -88
  3994. package/src/utils/__tests__/array_find.test.ts +0 -113
  3995. package/src/utils/__tests__/array_find_index.test.ts +0 -113
  3996. package/src/utils/__tests__/array_includes.test.ts +0 -151
  3997. package/src/utils/__tests__/assert.test.ts +0 -237
  3998. package/src/utils/__tests__/assert_unreachable.test.ts +0 -40
  3999. package/src/utils/__tests__/base64.test.ts +0 -149
  4000. package/src/utils/__tests__/byte_parsing.test.ts +0 -267
  4001. package/src/utils/__tests__/deep_merge.test.ts +0 -48
  4002. package/src/utils/__tests__/event_emitter.test.ts +0 -579
  4003. package/src/utils/__tests__/flat_map.test.ts +0 -71
  4004. package/src/utils/__tests__/get_fuzzed_delay.test.ts +0 -32
  4005. package/src/utils/__tests__/hash_buffer.test.ts +0 -105
  4006. package/src/utils/__tests__/id_generator.test.ts +0 -83
  4007. package/src/utils/__tests__/initialization_segment_cache.test.ts +0 -245
  4008. package/src/utils/__tests__/is_non_empty_string.test.ts +0 -41
  4009. package/src/utils/__tests__/is_null_or_undefined.test.ts +0 -33
  4010. package/src/utils/__tests__/logger.test.ts +0 -214
  4011. package/src/utils/__tests__/noop.test.ts +0 -23
  4012. package/src/utils/__tests__/object_assign.test.ts +0 -56
  4013. package/src/utils/__tests__/object_values.test.ts +0 -26
  4014. package/src/utils/__tests__/ranges.test.ts +0 -1214
  4015. package/src/utils/__tests__/resolve_url.test.ts +0 -100
  4016. package/src/utils/__tests__/sorted_list.test.ts +0 -335
  4017. package/src/utils/__tests__/starts_with.test.ts +0 -65
  4018. package/src/utils/__tests__/string_parsing.test.ts +0 -267
  4019. package/src/utils/__tests__/warn_once.test.ts +0 -38
  4020. package/src/utils/__tests__/weak_map_memory.test.ts +0 -188
  4021. package/src/utils/are_arrays_of_numbers_equal.ts +0 -39
  4022. package/src/utils/are_codecs_compatible.ts +0 -51
  4023. package/src/utils/array_find.ts +0 -55
  4024. package/src/utils/array_find_index.ts +0 -54
  4025. package/src/utils/array_includes.ts +0 -93
  4026. package/src/utils/assert.ts +0 -65
  4027. package/src/utils/assert_unreachable.ts +0 -45
  4028. package/src/utils/base64.ts +0 -153
  4029. package/src/utils/byte_parsing.ts +0 -256
  4030. package/src/utils/cancellable_sleep.ts +0 -41
  4031. package/src/utils/create_cancellable_promise.ts +0 -69
  4032. package/src/utils/deep_merge.ts +0 -49
  4033. package/src/utils/event_emitter.ts +0 -147
  4034. package/src/utils/flat_map.ts +0 -50
  4035. package/src/utils/get_fuzzed_delay.ts +0 -27
  4036. package/src/utils/hash_buffer.ts +0 -42
  4037. package/src/utils/id_generator.ts +0 -35
  4038. package/src/utils/initialization_segment_cache.ts +0 -68
  4039. package/src/utils/is_non_empty_string.ts +0 -23
  4040. package/src/utils/is_null_or_undefined.ts +0 -27
  4041. package/src/utils/languages/ISO_639-1_to_ISO_639-3.ts +0 -207
  4042. package/src/utils/languages/ISO_639-2_to_ISO_639-3.ts +0 -43
  4043. package/src/utils/languages/__tests__/normalize.test.ts +0 -290
  4044. package/src/utils/languages/index.ts +0 -29
  4045. package/src/utils/languages/normalize.ts +0 -152
  4046. package/src/utils/logger.ts +0 -100
  4047. package/src/utils/monotonic_timestamp.ts +0 -12
  4048. package/src/utils/noop.ts +0 -26
  4049. package/src/utils/object_assign.ts +0 -60
  4050. package/src/utils/object_values.ts +0 -31
  4051. package/src/utils/queue_microtask.ts +0 -7
  4052. package/src/utils/ranges.ts +0 -595
  4053. package/src/utils/reference.ts +0 -390
  4054. package/src/utils/request/fetch.ts +0 -279
  4055. package/src/utils/request/index.ts +0 -38
  4056. package/src/utils/request/xhr.ts +0 -319
  4057. package/src/utils/resolve_url.ts +0 -126
  4058. package/src/utils/retry_promise_with_backoff.ts +0 -95
  4059. package/src/utils/sleep.ts +0 -14
  4060. package/src/utils/slice_uint8array.ts +0 -53
  4061. package/src/utils/sorted_list.ts +0 -240
  4062. package/src/utils/starts_with.ts +0 -42
  4063. package/src/utils/string_parsing.ts +0 -415
  4064. package/src/utils/task_canceller.ts +0 -367
  4065. package/src/utils/warn_once.ts +0 -34
  4066. package/src/utils/weak_map_memory.ts +0 -89
  4067. package/src/utils/wrapInPromise.ts +0 -24
  4068. package/tools/TextTrackRenderer.d.ts +0 -18
  4069. package/tools/TextTrackRenderer.js +0 -18
  4070. package/tools/index.d.ts +0 -16
  4071. package/tools/index.js +0 -16
  4072. package/tools/string-utils.d.ts +0 -18
  4073. package/tools/string-utils.js +0 -18
  4074. package/tsconfig.commonjs.json +0 -9
  4075. package/tsconfig.eslint.json +0 -7
  4076. package/tsconfig.jest.json +0 -15
  4077. package/tsconfig.json +0 -32
  4078. package/types/index.d.ts +0 -16
  4079. package/types/index.js +0 -15
  4080. package/webpack.config.mjs +0 -97
  4081. /package/dist/commonjs/{utils → core/fetchers/segment}/initialization_segment_cache.js +0 -0
  4082. /package/dist/commonjs/core/{segment_buffers → segment_sinks}/implementations/audio_video/index.js +0 -0
  4083. /package/dist/{_esm5.processed/core/segment_buffers → commonjs/core/segment_sinks}/implementations/utils/manual_time_ranges.d.ts +0 -0
  4084. /package/dist/commonjs/core/{segment_buffers → segment_sinks}/implementations/utils/manual_time_ranges.js +0 -0
  4085. /package/dist/commonjs/core/{segment_buffers → segment_sinks}/inventory/buffered_history.js +0 -0
  4086. /package/dist/commonjs/core/{segment_buffers → segment_sinks}/inventory/index.js +0 -0
  4087. /package/dist/commonjs/core/{init/utils/stream_events_emitter → segment_sinks/inventory}/types.js +0 -0
  4088. /package/dist/{_esm5.processed/core → commonjs/main_thread}/api/debug/buffer_size_graph.d.ts +0 -0
  4089. /package/dist/{_esm5.processed/core → commonjs/main_thread}/api/debug/constants.d.ts +0 -0
  4090. /package/dist/commonjs/{core → main_thread}/api/debug/constants.js +0 -0
  4091. /package/dist/{_esm5.processed/core → commonjs/main_thread}/api/debug/index.d.ts +0 -0
  4092. /package/dist/commonjs/{core → main_thread}/api/debug/index.js +0 -0
  4093. /package/dist/commonjs/{core → main_thread}/api/debug/render.js +0 -0
  4094. /package/dist/{_esm5.processed/core → commonjs/main_thread}/api/debug/utils.d.ts +0 -0
  4095. /package/dist/commonjs/{core → main_thread}/api/debug/utils.js +0 -0
  4096. /package/dist/{_esm5.processed/core → commonjs/main_thread}/decrypt/clear_on_stop.d.ts +0 -0
  4097. /package/dist/{_esm5.processed/core → commonjs/main_thread}/decrypt/dispose_decryption_resources.d.ts +0 -0
  4098. /package/dist/commonjs/{core → main_thread}/decrypt/get_key_system_configuration.d.ts +0 -0
  4099. /package/dist/commonjs/{core → main_thread}/decrypt/get_key_system_configuration.js +0 -0
  4100. /package/dist/commonjs/{core → main_thread}/decrypt/index.js +0 -0
  4101. /package/dist/commonjs/{core → main_thread}/decrypt/types.js +0 -0
  4102. /package/dist/{_esm5.processed/core → commonjs/main_thread}/decrypt/utils/are_init_values_compatible.d.ts +0 -0
  4103. /package/dist/commonjs/{core → main_thread}/decrypt/utils/clean_old_loaded_sessions.js +0 -0
  4104. /package/dist/commonjs/{core → main_thread}/decrypt/utils/clean_old_stored_persistent_info.js +0 -0
  4105. /package/dist/{_esm5.processed/core → commonjs/main_thread}/decrypt/utils/get_drm_system_id.d.ts +0 -0
  4106. /package/dist/commonjs/{core → main_thread}/decrypt/utils/get_drm_system_id.js +0 -0
  4107. /package/dist/{_esm5.processed/core → commonjs/main_thread}/decrypt/utils/key_id_comparison.d.ts +0 -0
  4108. /package/dist/commonjs/{core → main_thread}/decrypt/utils/key_id_comparison.js +0 -0
  4109. /package/dist/{_esm5.processed/core → commonjs/main_thread}/init/index.d.ts +0 -0
  4110. /package/dist/commonjs/{core → main_thread}/init/index.js +0 -0
  4111. /package/dist/{_esm5.processed/core → commonjs/main_thread}/init/utils/stream_events_emitter/are_same_stream_events.d.ts +0 -0
  4112. /package/dist/commonjs/{core → main_thread}/init/utils/stream_events_emitter/index.js +0 -0
  4113. /package/dist/commonjs/{core/segment_buffers/implementations/text/html → main_thread/init/utils/stream_events_emitter}/types.js +0 -0
  4114. /package/dist/commonjs/{core/api/track_management → main_thread/tracks_store}/index.js +0 -0
  4115. /package/dist/commonjs/manifest/{representation_index → classes/representation_index}/index.js +0 -0
  4116. /package/dist/commonjs/{core/segment_buffers/inventory → manifest/classes/representation_index}/types.js +0 -0
  4117. /package/dist/{_esm5.processed/core/init → commonjs/mse}/utils/media_source_duration_updater.d.ts +0 -0
  4118. /package/dist/{_esm5.processed/parsers/manifest/dash/js-parser → commonjs/parsers/manifest/dash/native-parser}/index.d.ts +0 -0
  4119. /package/dist/commonjs/parsers/manifest/dash/{js-parser → native-parser}/index.js +0 -0
  4120. /package/dist/commonjs/parsers/manifest/dash/{js-parser → native-parser}/node_parsers/ContentComponent.js +0 -0
  4121. /package/dist/commonjs/parsers/manifest/dash/{js-parser → native-parser}/node_parsers/ContentProtection.js +0 -0
  4122. /package/dist/commonjs/parsers/manifest/dash/{js-parser → native-parser}/node_parsers/SegmentList.js +0 -0
  4123. /package/dist/commonjs/parsers/manifest/dash/{js-parser → native-parser}/node_parsers/SegmentTimeline.js +0 -0
  4124. /package/dist/commonjs/{experimental/tools → tools}/parseBIFThumbnails/index.d.ts +0 -0
  4125. /package/dist/commonjs/{compat → utils}/is_node.d.ts +0 -0
  4126. /package/dist/commonjs/{compat → utils}/is_node.js +0 -0
  4127. /package/dist/commonjs/{compat → utils}/is_worker.d.ts +0 -0
  4128. /package/dist/commonjs/{compat → utils}/is_worker.js +0 -0
  4129. /package/dist/{commonjs/core/segment_buffers → es2017/core/segment_sinks}/implementations/utils/manual_time_ranges.d.ts +0 -0
  4130. /package/dist/{_esm5.processed/compat/eme/custom_media_keys → es2017/core/segment_sinks/inventory}/types.js +0 -0
  4131. /package/dist/{_esm5.processed/core/stream/adaptation → es2017/core}/types.js +0 -0
  4132. /package/dist/{commonjs/core → es2017/main_thread}/api/debug/buffer_size_graph.d.ts +0 -0
  4133. /package/dist/{commonjs/core → es2017/main_thread}/api/debug/constants.d.ts +0 -0
  4134. /package/dist/es2017/{core → main_thread}/api/debug/constants.js +0 -0
  4135. /package/dist/{commonjs/core → es2017/main_thread}/api/debug/index.d.ts +0 -0
  4136. /package/dist/{_esm5.processed/core → es2017/main_thread}/api/debug/index.js +0 -0
  4137. /package/dist/{commonjs/core → es2017/main_thread}/api/debug/utils.d.ts +0 -0
  4138. /package/dist/{commonjs/core → es2017/main_thread}/decrypt/clear_on_stop.d.ts +0 -0
  4139. /package/dist/{commonjs/core → es2017/main_thread}/decrypt/dispose_decryption_resources.d.ts +0 -0
  4140. /package/dist/es2017/{core → main_thread}/decrypt/get_key_system_configuration.d.ts +0 -0
  4141. /package/dist/es2017/{core → main_thread}/decrypt/get_key_system_configuration.js +0 -0
  4142. /package/dist/{_esm5.processed/core → es2017/main_thread}/decrypt/types.js +0 -0
  4143. /package/dist/{commonjs/core → es2017/main_thread}/decrypt/utils/are_init_values_compatible.d.ts +0 -0
  4144. /package/dist/es2017/{core → main_thread}/decrypt/utils/clean_old_loaded_sessions.js +0 -0
  4145. /package/dist/es2017/{core → main_thread}/decrypt/utils/clean_old_stored_persistent_info.js +0 -0
  4146. /package/dist/{commonjs/core → es2017/main_thread}/decrypt/utils/get_drm_system_id.d.ts +0 -0
  4147. /package/dist/{_esm5.processed/core → es2017/main_thread}/decrypt/utils/get_drm_system_id.js +0 -0
  4148. /package/dist/{commonjs/core → es2017/main_thread}/decrypt/utils/key_id_comparison.d.ts +0 -0
  4149. /package/dist/{commonjs/core → es2017/main_thread}/init/index.d.ts +0 -0
  4150. /package/dist/{_esm5.processed/core → es2017/main_thread}/init/index.js +0 -0
  4151. /package/dist/{commonjs/core → es2017/main_thread}/init/utils/stream_events_emitter/are_same_stream_events.d.ts +0 -0
  4152. /package/dist/{_esm5.processed/core → es2017/main_thread}/init/utils/stream_events_emitter/index.js +0 -0
  4153. /package/dist/{_esm5.processed/core → es2017/main_thread}/init/utils/stream_events_emitter/types.js +0 -0
  4154. /package/dist/{_esm5.processed/core/stream/period/types.js → es2017/main_thread/text_displayer/index.js} +0 -0
  4155. /package/dist/{_esm5.processed/core/stream/representation → es2017/main_thread/text_displayer}/types.js +0 -0
  4156. /package/dist/es2017/{core/api/track_management → main_thread/tracks_store}/index.js +0 -0
  4157. /package/dist/{_esm5.processed/manifest → es2017/manifest/classes}/representation_index/index.js +0 -0
  4158. /package/dist/{_esm5.processed/core/segment_buffers/implementations/text/html → es2017/manifest/classes/representation_index}/types.js +0 -0
  4159. /package/dist/{_esm5.processed/manifest → es2017/manifest/classes}/types.js +0 -0
  4160. /package/dist/{commonjs/core/init → es2017/mse}/utils/media_source_duration_updater.d.ts +0 -0
  4161. /package/dist/{commonjs/parsers/manifest/dash/js-parser → es2017/parsers/manifest/dash/native-parser}/index.d.ts +0 -0
  4162. /package/dist/{_esm5.processed/parsers/manifest/dash/js-parser → es2017/parsers/manifest/dash/native-parser}/index.js +0 -0
  4163. /package/dist/es2017/parsers/manifest/dash/{js-parser → native-parser}/node_parsers/ContentComponent.js +0 -0
  4164. /package/dist/es2017/parsers/manifest/dash/{js-parser → native-parser}/node_parsers/ContentProtection.js +0 -0
  4165. /package/dist/es2017/parsers/manifest/dash/{js-parser → native-parser}/node_parsers/SegmentList.js +0 -0
  4166. /package/dist/es2017/parsers/manifest/dash/{js-parser → native-parser}/node_parsers/SegmentTimeline.js +0 -0
  4167. /package/dist/es2017/{experimental/tools → tools}/parseBIFThumbnails/index.d.ts +0 -0
  4168. /package/dist/es2017/{compat → utils}/is_node.d.ts +0 -0
  4169. /package/dist/es2017/{compat → utils}/is_node.js +0 -0
  4170. /package/dist/es2017/{compat → utils}/is_worker.d.ts +0 -0
  4171. /package/dist/es2017/{compat → utils}/is_worker.js +0 -0
@@ -0,0 +1,2347 @@
1
+ /**
2
+ * Copyright 2015 CANAL+ Group
3
+ *
4
+ * Licensed under the Apache License, Version 2.0 (the "License");publicapi
5
+ * you may not use this file except in compliance with the License.
6
+ * You may obtain a copy of the License at
7
+ *
8
+ * http://www.apache.org/licenses/LICENSE-2.0
9
+ *
10
+ * Unless required by applicable law or agreed to in writing, software
11
+ * distributed under the License is distributed on an "AS IS" BASIS,
12
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13
+ * See the License for the specific language governing permissions and
14
+ * limitations under the License.
15
+ */
16
+ /**
17
+ * This file defines the public API for the RxPlayer.
18
+ * It also starts the different sub-parts of the player on various API calls.
19
+ */
20
+ import canRelyOnVideoVisibilityAndSize from "../../compat/can_rely_on_video_visibility_and_size";
21
+ import { getPictureOnPictureStateRef, getVideoVisibilityRef, getElementResolutionRef, getScreenResolutionRef, } from "../../compat/event_listeners";
22
+ import getStartDate from "../../compat/get_start_date";
23
+ import hasMseInWorker from "../../compat/has_mse_in_worker";
24
+ import isDebugModeEnabled from "../../compat/is_debug_mode_enabled";
25
+ import { ErrorCodes, ErrorTypes, formatError, MediaError } from "../../errors";
26
+ import WorkerInitializationError from "../../errors/worker_initialization_error";
27
+ import features, { addFeatures } from "../../features";
28
+ import log from "../../log";
29
+ import { getLivePosition, getMaximumSafePosition, getMinimumSafePosition, createRepresentationFilterFromFnString, } from "../../manifest";
30
+ import MediaElementPlaybackObserver from "../../playback_observer/media_element_playback_observer";
31
+ import arrayFind from "../../utils/array_find";
32
+ import arrayIncludes from "../../utils/array_includes";
33
+ import assert, { assertUnreachable } from "../../utils/assert";
34
+ import EventEmitter from "../../utils/event_emitter";
35
+ import idGenerator from "../../utils/id_generator";
36
+ import isNullOrUndefined from "../../utils/is_null_or_undefined";
37
+ import getMonotonicTimeStamp from "../../utils/monotonic_timestamp";
38
+ import objectAssign from "../../utils/object_assign";
39
+ import { getLeftSizeOfBufferedTimeRange } from "../../utils/ranges";
40
+ import SharedReference, { createMappedReference } from "../../utils/reference";
41
+ import TaskCanceller from "../../utils/task_canceller";
42
+ import { clearOnStop, disposeDecryptionResources, getKeySystemConfiguration, } from "../decrypt";
43
+ import TracksStore from "../tracks_store";
44
+ import { checkReloadOptions, parseConstructorOptions, parseLoadVideoOptions, } from "./option_utils";
45
+ import { constructPlayerStateReference, emitPlayPauseEvents, emitSeekEvents, isLoadedState, } from "./utils";
46
+ /* eslint-disable @typescript-eslint/naming-convention */
47
+ const generateContentId = idGenerator();
48
+ /**
49
+ * Options of a `loadVideo` call which are for now not supported when running
50
+ * in a "multithread" mode.
51
+ *
52
+ * TODO support those?
53
+ */
54
+ const MULTI_THREAD_UNSUPPORTED_LOAD_VIDEO_OPTIONS = [
55
+ "manifestLoader",
56
+ "segmentLoader",
57
+ ];
58
+ /**
59
+ * @class Player
60
+ * @extends EventEmitter
61
+ */
62
+ class Player extends EventEmitter {
63
+ /** All possible Error types emitted by the RxPlayer. */
64
+ static get ErrorTypes() {
65
+ return ErrorTypes;
66
+ }
67
+ /** All possible Error codes emitted by the RxPlayer. */
68
+ static get ErrorCodes() {
69
+ return ErrorCodes;
70
+ }
71
+ /**
72
+ * Current log level.
73
+ * Update current log level.
74
+ * Should be either (by verbosity ascending):
75
+ * - "NONE"
76
+ * - "ERROR"
77
+ * - "WARNING"
78
+ * - "INFO"
79
+ * - "DEBUG"
80
+ * Any other value will be translated to "NONE".
81
+ */
82
+ static get LogLevel() {
83
+ return log.getLevel();
84
+ }
85
+ static set LogLevel(logLevel) {
86
+ log.setLevel(logLevel);
87
+ }
88
+ /**
89
+ * Add feature(s) to the RxPlayer.
90
+ * @param {Array.<Object>} featureList - Features wanted.
91
+ */
92
+ static addFeatures(featureList) {
93
+ addFeatures(featureList);
94
+ }
95
+ /**
96
+ * @constructor
97
+ * @param {Object} options
98
+ */
99
+ constructor(options = {}) {
100
+ super();
101
+ const { baseBandwidth, videoResolutionLimit, maxBufferAhead, maxBufferBehind, throttleVideoBitrateWhenHidden, videoElement, wantedBufferAhead, maxVideoBufferSize, } = parseConstructorOptions(options);
102
+ // Workaround to support Firefox autoplay on FF 42.
103
+ // See: https://bugzilla.mozilla.org/show_bug.cgi?id=1194624
104
+ videoElement.preload = "auto";
105
+ this.version = /* PLAYER_VERSION */ "4.0.0-rc.2";
106
+ this.log = log;
107
+ this.state = "STOPPED";
108
+ this.videoElement = videoElement;
109
+ const destroyCanceller = new TaskCanceller();
110
+ this._destroyCanceller = destroyCanceller;
111
+ this._priv_pictureInPictureRef = getPictureOnPictureStateRef(videoElement, destroyCanceller.signal);
112
+ this._priv_speed = new SharedReference(videoElement.playbackRate, this._destroyCanceller.signal);
113
+ this._priv_preferTrickModeTracks = false;
114
+ this._priv_contentLock = new SharedReference(false, this._destroyCanceller.signal);
115
+ this._priv_bufferOptions = {
116
+ wantedBufferAhead: new SharedReference(wantedBufferAhead, this._destroyCanceller.signal),
117
+ maxBufferAhead: new SharedReference(maxBufferAhead, this._destroyCanceller.signal),
118
+ maxBufferBehind: new SharedReference(maxBufferBehind, this._destroyCanceller.signal),
119
+ maxVideoBufferSize: new SharedReference(maxVideoBufferSize, this._destroyCanceller.signal),
120
+ };
121
+ this._priv_bitrateInfos = {
122
+ lastBitrates: { audio: baseBandwidth, video: baseBandwidth },
123
+ };
124
+ this._priv_throttleVideoBitrateWhenHidden = throttleVideoBitrateWhenHidden;
125
+ this._priv_videoResolutionLimit = videoResolutionLimit;
126
+ this._priv_currentError = null;
127
+ this._priv_contentInfos = null;
128
+ this._priv_contentEventsMemory = {};
129
+ this._priv_reloadingMetadata = {};
130
+ this._priv_lastAutoPlay = false;
131
+ this._priv_worker = null;
132
+ const onVolumeChange = () => {
133
+ this.trigger("volumeChange", {
134
+ volume: videoElement.volume,
135
+ muted: videoElement.muted,
136
+ });
137
+ };
138
+ videoElement.addEventListener("volumechange", onVolumeChange);
139
+ destroyCanceller.signal.register(() => {
140
+ videoElement.removeEventListener("volumechange", onVolumeChange);
141
+ });
142
+ }
143
+ /**
144
+ * TODO returns promise?
145
+ * @param {Object} workerSettings
146
+ */
147
+ attachWorker(workerSettings) {
148
+ return new Promise((res, rej) => {
149
+ var _a;
150
+ if (typeof Worker !== "function") {
151
+ log.warn("API: Cannot rely on a WebWorker: Worker API unavailable");
152
+ return rej(new WorkerInitializationError("INCOMPATIBLE_ERROR", "Worker unavailable"));
153
+ }
154
+ if (typeof workerSettings.workerUrl === "string") {
155
+ this._priv_worker = new Worker(workerSettings.workerUrl);
156
+ }
157
+ else {
158
+ const blobUrl = URL.createObjectURL(workerSettings.workerUrl);
159
+ this._priv_worker = new Worker(blobUrl);
160
+ URL.revokeObjectURL(blobUrl);
161
+ }
162
+ this._priv_worker.onerror = (evt) => {
163
+ if (this._priv_worker !== null) {
164
+ this._priv_worker.terminate();
165
+ this._priv_worker = null;
166
+ }
167
+ log.error("API: Unexpected worker error", evt.error instanceof Error ? evt.error : undefined);
168
+ rej(new WorkerInitializationError("UNKNOWN_ERROR", 'Unexpected Worker "error" event'));
169
+ };
170
+ const handleInitMessages = (msg) => {
171
+ const msgData = msg.data;
172
+ if (msgData.type === "init-error" /* WorkerMessageType.InitError */) {
173
+ log.warn("API: Processing InitError worker message: detaching worker");
174
+ if (this._priv_worker !== null) {
175
+ this._priv_worker.removeEventListener("message", handleInitMessages);
176
+ this._priv_worker.terminate();
177
+ this._priv_worker = null;
178
+ }
179
+ rej(new WorkerInitializationError("SETUP_ERROR", "Worker parser initialization failed: " + msgData.value.errorMessage));
180
+ }
181
+ else if (msgData.type === "init-success" /* WorkerMessageType.InitSuccess */) {
182
+ log.info("API: InitSuccess received from worker.");
183
+ if (this._priv_worker !== null) {
184
+ this._priv_worker.removeEventListener("message", handleInitMessages);
185
+ }
186
+ res();
187
+ }
188
+ };
189
+ this._priv_worker.addEventListener("message", handleInitMessages);
190
+ log.debug("---> Sending To Worker:", "init" /* MainThreadMessageType.Init */);
191
+ this._priv_worker.postMessage({
192
+ type: "init" /* MainThreadMessageType.Init */,
193
+ value: {
194
+ dashWasmUrl: workerSettings.dashWasmUrl,
195
+ logLevel: log.getLevel(),
196
+ sendBackLogs: isDebugModeEnabled(),
197
+ date: Date.now(),
198
+ timestamp: getMonotonicTimeStamp(),
199
+ hasVideo: ((_a = this.videoElement) === null || _a === void 0 ? void 0 : _a.nodeName.toLowerCase()) === "video",
200
+ hasMseInWorker,
201
+ },
202
+ });
203
+ log.addEventListener("onLogLevelChange", (logLevel) => {
204
+ if (this._priv_worker === null) {
205
+ return;
206
+ }
207
+ log.debug("---> Sending To Worker:", "log-level-update" /* MainThreadMessageType.LogLevelUpdate */);
208
+ this._priv_worker.postMessage({
209
+ type: "log-level-update" /* MainThreadMessageType.LogLevelUpdate */,
210
+ value: {
211
+ logLevel,
212
+ sendBackLogs: isDebugModeEnabled(),
213
+ },
214
+ });
215
+ }, this._destroyCanceller.signal);
216
+ });
217
+ }
218
+ /**
219
+ * Returns information on which "mode" the RxPlayer is running for the current
220
+ * content (e.g. main logic running in a WebWorker or not, are we in
221
+ * directfile mode...).
222
+ *
223
+ * Returns `null` if no content is loaded.
224
+ * @returns {Object|null}
225
+ */
226
+ getCurrentModeInformation() {
227
+ if (this._priv_contentInfos === null) {
228
+ return null;
229
+ }
230
+ return {
231
+ isDirectFile: this._priv_contentInfos.isDirectFile,
232
+ useWorker: this._priv_contentInfos.useWorker,
233
+ };
234
+ }
235
+ /**
236
+ * Register a new callback for a player event event.
237
+ *
238
+ * @param {string} evt - The event to register a callback to
239
+ * @param {Function} fn - The callback to call as that event is triggered.
240
+ * The callback will take as argument the eventual payload of the event
241
+ * (single argument).
242
+ */
243
+ addEventListener(evt, fn) {
244
+ // The EventEmitter's `addEventListener` method takes an optional third
245
+ // argument that we do not want to expose in the public API.
246
+ // We thus overwrite that function to remove any possible usage of that
247
+ // third argument.
248
+ return super.addEventListener(evt, fn);
249
+ }
250
+ /**
251
+ * Stop the playback for the current content.
252
+ */
253
+ stop() {
254
+ if (this._priv_contentInfos !== null) {
255
+ this._priv_contentInfos.currentContentCanceller.cancel();
256
+ }
257
+ this._priv_cleanUpCurrentContentState();
258
+ if (this.state !== "STOPPED" /* PLAYER_STATES.STOPPED */) {
259
+ this._priv_setPlayerState("STOPPED" /* PLAYER_STATES.STOPPED */);
260
+ }
261
+ }
262
+ /**
263
+ * Free the resources used by the player.
264
+ * /!\ The player cannot be "used" anymore after this method has been called.
265
+ */
266
+ dispose() {
267
+ // free resources linked to the loaded content
268
+ this.stop();
269
+ if (this.videoElement !== null) {
270
+ // free resources used for decryption management
271
+ disposeDecryptionResources(this.videoElement).catch((err) => {
272
+ const message = err instanceof Error ? err.message : "Unknown error";
273
+ log.error("API: Could not dispose decryption resources: " + message);
274
+ });
275
+ }
276
+ // free resources linked to the Player instance
277
+ this._destroyCanceller.cancel();
278
+ this._priv_reloadingMetadata = {};
279
+ // un-attach video element
280
+ this.videoElement = null;
281
+ if (this._priv_worker !== null) {
282
+ this._priv_worker.terminate();
283
+ this._priv_worker = null;
284
+ }
285
+ }
286
+ /**
287
+ * Load a new video.
288
+ * @param {Object} opts
289
+ */
290
+ loadVideo(opts) {
291
+ const options = parseLoadVideoOptions(opts);
292
+ log.info("API: Calling loadvideo", options.url, options.transport);
293
+ this._priv_reloadingMetadata = { options };
294
+ this._priv_initializeContentPlayback(options);
295
+ this._priv_lastAutoPlay = options.autoPlay;
296
+ }
297
+ /**
298
+ * Reload the last loaded content.
299
+ * @param {Object} reloadOpts
300
+ */
301
+ reload(reloadOpts) {
302
+ var _a, _b, _c;
303
+ const { options, manifest, reloadPosition, reloadInPause } = this._priv_reloadingMetadata;
304
+ if (options === undefined) {
305
+ throw new Error("API: Can't reload without having previously loaded a content.");
306
+ }
307
+ checkReloadOptions(reloadOpts);
308
+ let startAt;
309
+ if (((_a = reloadOpts === null || reloadOpts === void 0 ? void 0 : reloadOpts.reloadAt) === null || _a === void 0 ? void 0 : _a.position) !== undefined) {
310
+ startAt = { position: reloadOpts.reloadAt.position };
311
+ }
312
+ else if (((_b = reloadOpts === null || reloadOpts === void 0 ? void 0 : reloadOpts.reloadAt) === null || _b === void 0 ? void 0 : _b.relative) !== undefined) {
313
+ if (reloadPosition === undefined) {
314
+ throw new Error("Can't reload to a relative position when previous content was not loaded.");
315
+ }
316
+ else {
317
+ startAt = { position: reloadOpts.reloadAt.relative + reloadPosition };
318
+ }
319
+ }
320
+ else if (reloadPosition !== undefined) {
321
+ startAt = { position: reloadPosition };
322
+ }
323
+ let autoPlay;
324
+ if ((reloadOpts === null || reloadOpts === void 0 ? void 0 : reloadOpts.autoPlay) !== undefined) {
325
+ autoPlay = reloadOpts.autoPlay;
326
+ }
327
+ else if (reloadInPause !== undefined) {
328
+ autoPlay = !reloadInPause;
329
+ }
330
+ let keySystems;
331
+ if ((reloadOpts === null || reloadOpts === void 0 ? void 0 : reloadOpts.keySystems) !== undefined) {
332
+ keySystems = reloadOpts.keySystems;
333
+ }
334
+ else if (((_c = this._priv_reloadingMetadata.options) === null || _c === void 0 ? void 0 : _c.keySystems) !== undefined) {
335
+ keySystems = this._priv_reloadingMetadata.options.keySystems;
336
+ }
337
+ const newOptions = Object.assign(Object.assign({}, options), { initialManifest: manifest });
338
+ if (startAt !== undefined) {
339
+ newOptions.startAt = startAt;
340
+ }
341
+ if (autoPlay !== undefined) {
342
+ newOptions.autoPlay = autoPlay;
343
+ }
344
+ if (keySystems !== undefined) {
345
+ newOptions.keySystems = keySystems;
346
+ }
347
+ this._priv_initializeContentPlayback(newOptions);
348
+ }
349
+ createDebugElement(element) {
350
+ if (features.createDebugElement === null) {
351
+ throw new Error("Feature `DEBUG_ELEMENT` not added to the RxPlayer");
352
+ }
353
+ const canceller = new TaskCanceller();
354
+ features.createDebugElement(element, this, canceller.signal);
355
+ return {
356
+ dispose() {
357
+ canceller.cancel();
358
+ },
359
+ };
360
+ }
361
+ /**
362
+ * From given options, initialize content playback.
363
+ * @param {Object} options
364
+ */
365
+ _priv_initializeContentPlayback(options) {
366
+ var _a, _b, _c, _d, _e, _f;
367
+ const { autoPlay, defaultAudioTrackSwitchingMode, enableFastSwitching, initialManifest, keySystems, lowLatencyMode, minimumManifestUpdateInterval, requestConfig, onCodecSwitch, startAt, transport, checkMediaSegmentIntegrity, manifestLoader, referenceDateTime, segmentLoader, serverSyncInfos, mode, __priv_manifestUpdateUrl, __priv_patchLastSegmentInSidx, url, } = options;
368
+ // Perform multiple checks on the given options
369
+ if (this.videoElement === null) {
370
+ throw new Error("the attached video element is disposed");
371
+ }
372
+ const isDirectFile = transport === "directfile";
373
+ /** Emit to stop the current content. */
374
+ const currentContentCanceller = new TaskCanceller();
375
+ const videoElement = this.videoElement;
376
+ let initializer;
377
+ let useWorker = false;
378
+ let mediaElementTracksStore = null;
379
+ if (!isDirectFile) {
380
+ /** Interface used to load and refresh the Manifest. */
381
+ const manifestRequestSettings = {
382
+ lowLatencyMode,
383
+ maxRetry: (_a = requestConfig.manifest) === null || _a === void 0 ? void 0 : _a.maxRetry,
384
+ requestTimeout: (_b = requestConfig.manifest) === null || _b === void 0 ? void 0 : _b.timeout,
385
+ connectionTimeout: (_c = requestConfig.manifest) === null || _c === void 0 ? void 0 : _c.connectionTimeout,
386
+ minimumManifestUpdateInterval,
387
+ initialManifest,
388
+ };
389
+ const relyOnVideoVisibilityAndSize = canRelyOnVideoVisibilityAndSize();
390
+ const throttlers = {
391
+ throttleBitrate: {},
392
+ limitResolution: {},
393
+ };
394
+ if (this._priv_throttleVideoBitrateWhenHidden) {
395
+ if (!relyOnVideoVisibilityAndSize) {
396
+ log.warn("API: Can't apply throttleVideoBitrateWhenHidden because " +
397
+ "browser can't be trusted for visibility.");
398
+ }
399
+ else {
400
+ throttlers.throttleBitrate = {
401
+ video: createMappedReference(getVideoVisibilityRef(this._priv_pictureInPictureRef, currentContentCanceller.signal), (isActive) => (isActive ? Infinity : 0), currentContentCanceller.signal),
402
+ };
403
+ }
404
+ }
405
+ if (this._priv_videoResolutionLimit === "videoElement") {
406
+ if (!relyOnVideoVisibilityAndSize) {
407
+ log.warn("API: Can't apply videoResolutionLimit because browser can't be " +
408
+ "trusted for video size.");
409
+ }
410
+ else {
411
+ throttlers.limitResolution = {
412
+ video: getElementResolutionRef(videoElement, this._priv_pictureInPictureRef, currentContentCanceller.signal),
413
+ };
414
+ }
415
+ }
416
+ else if (this._priv_videoResolutionLimit === "screen") {
417
+ throttlers.limitResolution = {
418
+ video: getScreenResolutionRef(currentContentCanceller.signal),
419
+ };
420
+ }
421
+ /** Options used by the adaptive logic. */
422
+ const adaptiveOptions = {
423
+ initialBitrates: this._priv_bitrateInfos.lastBitrates,
424
+ lowLatencyMode,
425
+ throttlers,
426
+ };
427
+ /** Options used by the TextTrack SegmentSink. */
428
+ const textTrackOptions = options.textTrackMode === "native"
429
+ ? { textTrackMode: "native" }
430
+ : {
431
+ textTrackMode: "html",
432
+ textTrackElement: options.textTrackElement,
433
+ };
434
+ const bufferOptions = objectAssign({ enableFastSwitching, onCodecSwitch }, this._priv_bufferOptions);
435
+ const segmentRequestOptions = {
436
+ lowLatencyMode,
437
+ maxRetry: (_d = requestConfig.segment) === null || _d === void 0 ? void 0 : _d.maxRetry,
438
+ requestTimeout: (_e = requestConfig.segment) === null || _e === void 0 ? void 0 : _e.timeout,
439
+ connectionTimeout: (_f = requestConfig.segment) === null || _f === void 0 ? void 0 : _f.connectionTimeout,
440
+ };
441
+ const canRunInMultiThread = features.multithread !== null &&
442
+ this._priv_worker !== null &&
443
+ transport === "dash" &&
444
+ MULTI_THREAD_UNSUPPORTED_LOAD_VIDEO_OPTIONS.every((option) => isNullOrUndefined(options[option])) &&
445
+ typeof options.representationFilter !== "function";
446
+ if (mode === "main" || (mode === "auto" && !canRunInMultiThread)) {
447
+ if (features.mainThreadMediaSourceInit === null) {
448
+ throw new Error("Cannot load video, neither in a WebWorker nor with the " +
449
+ "`MEDIA_SOURCE_MAIN` feature");
450
+ }
451
+ const transportFn = features.transports[transport];
452
+ if (typeof transportFn !== "function") {
453
+ // Stop previous content and reset its state
454
+ this.stop();
455
+ this._priv_currentError = null;
456
+ throw new Error(`transport "${transport}" not supported`);
457
+ }
458
+ const representationFilter = typeof options.representationFilter === "string"
459
+ ? createRepresentationFilterFromFnString(options.representationFilter)
460
+ : options.representationFilter;
461
+ log.info("API: Initializing MediaSource mode in the main thread");
462
+ const transportPipelines = transportFn({
463
+ lowLatencyMode,
464
+ checkMediaSegmentIntegrity,
465
+ manifestLoader,
466
+ referenceDateTime,
467
+ representationFilter,
468
+ segmentLoader,
469
+ serverSyncInfos,
470
+ __priv_manifestUpdateUrl,
471
+ __priv_patchLastSegmentInSidx,
472
+ });
473
+ initializer = new features.mainThreadMediaSourceInit({
474
+ adaptiveOptions,
475
+ autoPlay,
476
+ bufferOptions,
477
+ keySystems,
478
+ lowLatencyMode,
479
+ transport: transportPipelines,
480
+ manifestRequestSettings,
481
+ segmentRequestOptions,
482
+ speed: this._priv_speed,
483
+ startAt,
484
+ textTrackOptions,
485
+ url,
486
+ });
487
+ }
488
+ else {
489
+ if (features.multithread === null) {
490
+ throw new Error("Cannot load video in multithread mode: `MULTI_THREAD` " +
491
+ "feature not imported.");
492
+ }
493
+ else if (this._priv_worker === null) {
494
+ throw new Error("Cannot load video in multithread mode: `attachWorker` " +
495
+ "method not called.");
496
+ }
497
+ assert(typeof options.representationFilter !== "function");
498
+ useWorker = true;
499
+ log.info("API: Initializing MediaSource mode in a WebWorker");
500
+ const transportOptions = {
501
+ lowLatencyMode,
502
+ checkMediaSegmentIntegrity,
503
+ referenceDateTime,
504
+ serverSyncInfos,
505
+ manifestLoader: undefined,
506
+ segmentLoader: undefined,
507
+ representationFilter: options.representationFilter,
508
+ __priv_manifestUpdateUrl,
509
+ __priv_patchLastSegmentInSidx,
510
+ };
511
+ initializer = new features.multithread.init({
512
+ adaptiveOptions,
513
+ autoPlay,
514
+ bufferOptions,
515
+ keySystems,
516
+ lowLatencyMode,
517
+ transportOptions,
518
+ manifestRequestSettings,
519
+ segmentRequestOptions,
520
+ speed: this._priv_speed,
521
+ startAt,
522
+ textTrackOptions,
523
+ worker: this._priv_worker,
524
+ url,
525
+ });
526
+ }
527
+ }
528
+ else {
529
+ if (features.directfile === null) {
530
+ this.stop();
531
+ this._priv_currentError = null;
532
+ throw new Error("DirectFile feature not activated in your build.");
533
+ }
534
+ else if (isNullOrUndefined(url)) {
535
+ throw new Error("No URL for a DirectFile content");
536
+ }
537
+ log.info("API: Initializing DirectFile mode in the main thread");
538
+ mediaElementTracksStore = this._priv_initializeMediaElementTracksStore(currentContentCanceller.signal);
539
+ if (currentContentCanceller.isUsed()) {
540
+ return;
541
+ }
542
+ initializer = new features.directfile.initDirectFile({
543
+ autoPlay,
544
+ keySystems,
545
+ speed: this._priv_speed,
546
+ startAt,
547
+ url,
548
+ });
549
+ }
550
+ /** Future `this._priv_contentInfos` related to this content. */
551
+ const contentInfos = {
552
+ contentId: generateContentId(),
553
+ originalUrl: url,
554
+ currentContentCanceller,
555
+ defaultAudioTrackSwitchingMode,
556
+ initializer,
557
+ isDirectFile,
558
+ segmentSinksStore: null,
559
+ manifest: null,
560
+ currentPeriod: null,
561
+ activeAdaptations: null,
562
+ activeRepresentations: null,
563
+ tracksStore: null,
564
+ mediaElementTracksStore,
565
+ useWorker,
566
+ };
567
+ // Bind events
568
+ initializer.addEventListener("error", (error) => {
569
+ this._priv_onFatalError(error, contentInfos);
570
+ });
571
+ initializer.addEventListener("warning", (error) => {
572
+ const formattedError = formatError(error, {
573
+ defaultCode: "NONE",
574
+ defaultReason: "An unknown error happened.",
575
+ });
576
+ log.warn("API: Sending warning:", formattedError);
577
+ this.trigger("warning", formattedError);
578
+ });
579
+ initializer.addEventListener("reloadingMediaSource", (payload) => {
580
+ contentInfos.segmentSinksStore = null;
581
+ if (contentInfos.tracksStore !== null) {
582
+ contentInfos.tracksStore.resetPeriodObjects();
583
+ }
584
+ this._priv_lastAutoPlay = payload.autoPlay;
585
+ });
586
+ initializer.addEventListener("inbandEvents", (inbandEvents) => this.trigger("inbandEvents", inbandEvents));
587
+ initializer.addEventListener("streamEvent", (streamEvent) => this.trigger("streamEvent", streamEvent));
588
+ initializer.addEventListener("streamEventSkip", (streamEventSkip) => this.trigger("streamEventSkip", streamEventSkip));
589
+ initializer.addEventListener("activePeriodChanged", (periodInfo) => this._priv_onActivePeriodChanged(contentInfos, periodInfo));
590
+ initializer.addEventListener("periodStreamReady", (periodReadyInfo) => this._priv_onPeriodStreamReady(contentInfos, periodReadyInfo));
591
+ initializer.addEventListener("periodStreamCleared", (periodClearedInfo) => this._priv_onPeriodStreamCleared(contentInfos, periodClearedInfo));
592
+ initializer.addEventListener("representationChange", (representationInfo) => this._priv_onRepresentationChange(contentInfos, representationInfo));
593
+ initializer.addEventListener("adaptationChange", (adaptationInfo) => this._priv_onAdaptationChange(contentInfos, adaptationInfo));
594
+ initializer.addEventListener("bitrateEstimateChange", (bitrateEstimateInfo) => this._priv_onBitrateEstimateChange(bitrateEstimateInfo));
595
+ initializer.addEventListener("manifestReady", (manifest) => this._priv_onManifestReady(contentInfos, manifest));
596
+ initializer.addEventListener("manifestUpdate", (updates) => this._priv_onManifestUpdate(contentInfos, updates));
597
+ initializer.addEventListener("decipherabilityUpdate", (updates) => this._priv_onDecipherabilityUpdate(contentInfos, updates));
598
+ initializer.addEventListener("loaded", (evt) => {
599
+ contentInfos.segmentSinksStore = evt.segmentSinksStore;
600
+ });
601
+ // Now, that most events are linked, prepare the next content.
602
+ initializer.prepare();
603
+ // Now that the content is prepared, stop previous content and reset state
604
+ // This is done after content preparation as `stop` could technically have
605
+ // a long and synchronous blocking time.
606
+ // Note that this call is done **synchronously** after all events linking.
607
+ // This is **VERY** important so:
608
+ // - the `STOPPED` state is switched to synchronously after loading a new
609
+ // content.
610
+ // - we can avoid involontarily catching events linked to the previous
611
+ // content.
612
+ this.stop();
613
+ /** Global "playback observer" which will emit playback conditions */
614
+ const playbackObserver = new MediaElementPlaybackObserver(videoElement, {
615
+ withMediaSource: !isDirectFile,
616
+ lowLatencyMode,
617
+ });
618
+ currentContentCanceller.signal.register(() => {
619
+ playbackObserver.stop();
620
+ });
621
+ // Update the RxPlayer's state at the right events
622
+ const playerStateRef = constructPlayerStateReference(initializer, videoElement, playbackObserver, currentContentCanceller.signal);
623
+ currentContentCanceller.signal.register(() => {
624
+ initializer.dispose();
625
+ });
626
+ /**
627
+ * Function updating `this._priv_reloadingMetadata` in function of the
628
+ * current state and playback conditions.
629
+ * To call when either might change.
630
+ * @param {string} state - The player state we're about to switch to.
631
+ */
632
+ const updateReloadingMetadata = (state) => {
633
+ switch (state) {
634
+ case "STOPPED":
635
+ case "RELOADING":
636
+ case "LOADING":
637
+ break; // keep previous metadata
638
+ case "ENDED":
639
+ this._priv_reloadingMetadata.reloadInPause = true;
640
+ this._priv_reloadingMetadata.reloadPosition = playbackObserver
641
+ .getReference()
642
+ .getValue()
643
+ .position.getPolled();
644
+ break;
645
+ default:
646
+ const o = playbackObserver.getReference().getValue();
647
+ this._priv_reloadingMetadata.reloadInPause = o.paused;
648
+ this._priv_reloadingMetadata.reloadPosition = o.position.getWanted();
649
+ break;
650
+ }
651
+ };
652
+ /**
653
+ * `TaskCanceller` allowing to stop emitting `"play"` and `"pause"`
654
+ * events.
655
+ * `null` when such events are not emitted currently.
656
+ */
657
+ let playPauseEventsCanceller = null;
658
+ /**
659
+ * Callback emitting `"play"` and `"pause`" events once the content is
660
+ * loaded, starting from the state indicated in argument.
661
+ * @param {boolean} willAutoPlay - If `false`, we're currently paused.
662
+ */
663
+ const triggerPlayPauseEventsWhenReady = (willAutoPlay) => {
664
+ if (playPauseEventsCanceller !== null) {
665
+ playPauseEventsCanceller.cancel(); // cancel previous logic
666
+ playPauseEventsCanceller = null;
667
+ }
668
+ playerStateRef.onUpdate((val, stopListeningToStateUpdates) => {
669
+ if (!isLoadedState(val)) {
670
+ return; // content not loaded yet: no event
671
+ }
672
+ stopListeningToStateUpdates();
673
+ if (playPauseEventsCanceller !== null) {
674
+ playPauseEventsCanceller.cancel();
675
+ }
676
+ playPauseEventsCanceller = new TaskCanceller();
677
+ playPauseEventsCanceller.linkToSignal(currentContentCanceller.signal);
678
+ if (willAutoPlay !== !videoElement.paused) {
679
+ // paused status is not at the expected value on load: emit event
680
+ if (videoElement.paused) {
681
+ this.trigger("pause", null);
682
+ }
683
+ else {
684
+ this.trigger("play", null);
685
+ }
686
+ }
687
+ emitPlayPauseEvents(videoElement, () => this.trigger("play", null), () => this.trigger("pause", null), currentContentCanceller.signal);
688
+ }, {
689
+ emitCurrentValue: false,
690
+ clearSignal: currentContentCanceller.signal,
691
+ });
692
+ };
693
+ triggerPlayPauseEventsWhenReady(autoPlay);
694
+ initializer.addEventListener("reloadingMediaSource", (payload) => {
695
+ triggerPlayPauseEventsWhenReady(payload.autoPlay);
696
+ });
697
+ this._priv_currentError = null;
698
+ this._priv_contentInfos = contentInfos;
699
+ /**
700
+ * `TaskCanceller` allowing to stop emitting `"seeking"` and `"seeked"`
701
+ * events.
702
+ * `null` when such events are not emitted currently.
703
+ */
704
+ let seekEventsCanceller = null;
705
+ // React to player state change
706
+ playerStateRef.onUpdate((newState) => {
707
+ updateReloadingMetadata(newState);
708
+ this._priv_setPlayerState(newState);
709
+ if (currentContentCanceller.isUsed()) {
710
+ return;
711
+ }
712
+ if (seekEventsCanceller !== null) {
713
+ if (!isLoadedState(this.state)) {
714
+ seekEventsCanceller.cancel();
715
+ seekEventsCanceller = null;
716
+ }
717
+ }
718
+ else if (isLoadedState(this.state)) {
719
+ seekEventsCanceller = new TaskCanceller();
720
+ seekEventsCanceller.linkToSignal(currentContentCanceller.signal);
721
+ emitSeekEvents(videoElement, playbackObserver, () => this.trigger("seeking", null), () => this.trigger("seeked", null), seekEventsCanceller.signal);
722
+ }
723
+ }, { emitCurrentValue: true, clearSignal: currentContentCanceller.signal });
724
+ // React to playback conditions change
725
+ playbackObserver.listen((observation) => {
726
+ updateReloadingMetadata(this.state);
727
+ this._priv_triggerPositionUpdate(contentInfos, observation);
728
+ }, { clearSignal: currentContentCanceller.signal });
729
+ currentContentCanceller.signal.register(() => {
730
+ initializer.removeEventListener();
731
+ });
732
+ // initialize the content only when the lock is inactive
733
+ this._priv_contentLock.onUpdate((isLocked, stopListeningToLock) => {
734
+ if (!isLocked) {
735
+ stopListeningToLock();
736
+ // start playback!
737
+ initializer.start(videoElement, playbackObserver);
738
+ }
739
+ }, { emitCurrentValue: true, clearSignal: currentContentCanceller.signal });
740
+ }
741
+ /**
742
+ * Returns fatal error if one for the current content.
743
+ * null otherwise.
744
+ * @returns {Object|null} - The current Error (`null` when no error).
745
+ */
746
+ getError() {
747
+ return this._priv_currentError;
748
+ }
749
+ /**
750
+ * Returns the media DOM element used by the player.
751
+ * You should not its HTML5 API directly and use the player's method instead,
752
+ * to ensure a well-behaved player.
753
+ * @returns {HTMLMediaElement|null} - The HTMLMediaElement used (`null` when
754
+ * disposed)
755
+ */
756
+ getVideoElement() {
757
+ return this.videoElement;
758
+ }
759
+ /**
760
+ * Returns the player's current state.
761
+ * @returns {string} - The current Player's state
762
+ */
763
+ getPlayerState() {
764
+ return this.state;
765
+ }
766
+ /**
767
+ * Returns true if a content is loaded.
768
+ * @returns {Boolean} - `true` if a content is loaded, `false` otherwise.
769
+ */
770
+ isContentLoaded() {
771
+ return !arrayIncludes(["LOADING", "RELOADING", "STOPPED"], this.state);
772
+ }
773
+ /**
774
+ * Returns true if the player is buffering.
775
+ * @returns {Boolean} - `true` if the player is buffering, `false` otherwise.
776
+ */
777
+ isBuffering() {
778
+ return arrayIncludes(["BUFFERING", "SEEKING", "LOADING", "RELOADING"], this.state);
779
+ }
780
+ /**
781
+ * Returns the play/pause status of the player :
782
+ * - when `LOADING` or `RELOADING`, returns the scheduled play/pause condition
783
+ * for when loading is over,
784
+ * - in other states, returns the `<video>` element .paused value,
785
+ * - if the player is disposed, returns `true`.
786
+ * @returns {Boolean} - `true` if the player is paused or will be after loading,
787
+ * `false` otherwise.
788
+ */
789
+ isPaused() {
790
+ if (this.videoElement) {
791
+ if (arrayIncludes(["LOADING", "RELOADING"], this.state)) {
792
+ return !this._priv_lastAutoPlay;
793
+ }
794
+ else {
795
+ return this.videoElement.paused;
796
+ }
797
+ }
798
+ return true;
799
+ }
800
+ /**
801
+ * Returns true if both:
802
+ * - a content is loaded
803
+ * - the content loaded is a live content
804
+ * @returns {Boolean} - `true` if we're playing a live content, `false` otherwise.
805
+ */
806
+ isLive() {
807
+ if (this._priv_contentInfos === null) {
808
+ return false;
809
+ }
810
+ const { isDirectFile, manifest } = this._priv_contentInfos;
811
+ if (isDirectFile || manifest === null) {
812
+ return false;
813
+ }
814
+ return manifest.isLive;
815
+ }
816
+ /**
817
+ * Returns `true` if trickmode playback is active (usually through the usage
818
+ * of the `setPlaybackRate` method), which means that the RxPlayer selects
819
+ * "trickmode" video tracks in priority.
820
+ * @returns {Boolean}
821
+ */
822
+ areTrickModeTracksEnabled() {
823
+ return this._priv_preferTrickModeTracks;
824
+ }
825
+ /**
826
+ * Returns the URL(s) of the currently considered Manifest, or of the content for
827
+ * directfile content.
828
+ * @returns {Array.<string>|undefined} - Current URL. `undefined` if not known
829
+ * or no URL yet.
830
+ */
831
+ getContentUrls() {
832
+ if (this._priv_contentInfos === null) {
833
+ return undefined;
834
+ }
835
+ const { isDirectFile, manifest, originalUrl } = this._priv_contentInfos;
836
+ if (isDirectFile) {
837
+ return originalUrl === undefined ? undefined : [originalUrl];
838
+ }
839
+ if (manifest !== null) {
840
+ return manifest.uris;
841
+ }
842
+ return undefined;
843
+ }
844
+ /**
845
+ * Update URL of the content currently being played (e.g. DASH's MPD).
846
+ * @param {Array.<string>|undefined} urls - URLs to reach that content /
847
+ * Manifest from the most prioritized URL to the least prioritized URL.
848
+ * @param {Object|undefined} [params]
849
+ * @param {boolean} params.refresh - If `true` the resource in question
850
+ * (e.g. DASH's MPD) will be refreshed immediately.
851
+ */
852
+ updateContentUrls(urls, params) {
853
+ if (this._priv_contentInfos === null) {
854
+ throw new Error("No content loaded");
855
+ }
856
+ const refreshNow = (params === null || params === void 0 ? void 0 : params.refresh) === true;
857
+ this._priv_contentInfos.initializer.updateContentUrls(urls, refreshNow);
858
+ }
859
+ /**
860
+ * Returns the video duration, in seconds.
861
+ * NaN if no video is playing.
862
+ * @returns {Number}
863
+ */
864
+ getMediaDuration() {
865
+ if (this.videoElement === null) {
866
+ throw new Error("Disposed player");
867
+ }
868
+ return this.videoElement.duration;
869
+ }
870
+ /**
871
+ * Returns in seconds the difference between:
872
+ * - the end of the current contiguous loaded range.
873
+ * - the current time
874
+ * @returns {Number}
875
+ */
876
+ getCurrentBufferGap() {
877
+ if (this.videoElement === null) {
878
+ throw new Error("Disposed player");
879
+ }
880
+ const videoElement = this.videoElement;
881
+ const bufferGap = getLeftSizeOfBufferedTimeRange(videoElement.buffered, videoElement.currentTime);
882
+ if (bufferGap === Infinity) {
883
+ return 0;
884
+ }
885
+ return bufferGap;
886
+ }
887
+ /**
888
+ * Get the current position, in s, in wall-clock time.
889
+ * That is:
890
+ * - for live content, get a timestamp, in s, of the current played content.
891
+ * - for static content, returns the position from beginning in s.
892
+ *
893
+ * If you do not know if you want to use this method or getPosition:
894
+ * - If what you want is to display the current time to the user, use this
895
+ * one.
896
+ * - If what you want is to interact with the player's API or perform other
897
+ * actions (like statistics) with the real player data, use getPosition.
898
+ *
899
+ * @returns {Number}
900
+ */
901
+ getWallClockTime() {
902
+ if (this.videoElement === null) {
903
+ throw new Error("Disposed player");
904
+ }
905
+ if (this._priv_contentInfos === null) {
906
+ return this.videoElement.currentTime;
907
+ }
908
+ const { isDirectFile, manifest } = this._priv_contentInfos;
909
+ if (isDirectFile) {
910
+ const startDate = getStartDate(this.videoElement);
911
+ return (startDate !== null && startDate !== void 0 ? startDate : 0) + this.videoElement.currentTime;
912
+ }
913
+ if (manifest !== null) {
914
+ const currentTime = this.videoElement.currentTime;
915
+ const ast = manifest.availabilityStartTime !== undefined ? manifest.availabilityStartTime : 0;
916
+ return currentTime + ast;
917
+ }
918
+ return 0;
919
+ }
920
+ /**
921
+ * Get the current position, in seconds, of the video element.
922
+ *
923
+ * If you do not know if you want to use this method or getWallClockTime:
924
+ * - If what you want is to display the current time to the user, use
925
+ * getWallClockTime.
926
+ * - If what you want is to interact with the player's API or perform other
927
+ * actions (like statistics) with the real player data, use this one.
928
+ *
929
+ * @returns {Number}
930
+ */
931
+ getPosition() {
932
+ if (this.videoElement === null) {
933
+ throw new Error("Disposed player");
934
+ }
935
+ return this.videoElement.currentTime;
936
+ }
937
+ /**
938
+ * Returns the last stored content position, in seconds.
939
+ *
940
+ * @returns {number|undefined}
941
+ */
942
+ getLastStoredContentPosition() {
943
+ return this._priv_reloadingMetadata.reloadPosition;
944
+ }
945
+ /**
946
+ * Returns the current playback rate at which the video plays.
947
+ * @returns {Number}
948
+ */
949
+ getPlaybackRate() {
950
+ return this._priv_speed.getValue();
951
+ }
952
+ /**
953
+ * Update the playback rate of the video.
954
+ *
955
+ * This method's effect is persisted from content to content, and can be
956
+ * called even when no content is playing (it will still have an effect for
957
+ * the next contents).
958
+ *
959
+ * If you want to reverse effects provoked by `setPlaybackRate` before playing
960
+ * another content, you will have to call `setPlaybackRate` first with the
961
+ * default settings you want to set.
962
+ *
963
+ * As an example, to reset the speed to "normal" (x1) speed and to disable
964
+ * trickMode video tracks (which may have been enabled by a previous
965
+ * `setPlaybackRate` call), you can call:
966
+ * ```js
967
+ * player.setPlaybackRate(1, { preferTrickModeTracks: false });
968
+ * ```
969
+ *
970
+ * --
971
+ *
972
+ * This method can be used to switch to or exit from "trickMode" video tracks,
973
+ * which are tracks specifically defined to mimic the visual aspect of a VCR's
974
+ * fast forward/rewind feature, by only displaying a few video frames during
975
+ * playback.
976
+ *
977
+ * This behavior is configurable through the second argument, by adding a
978
+ * property named `preferTrickModeTracks` to that object.
979
+ *
980
+ * You can set that value to `true` to switch to trickMode video tracks when
981
+ * available, and set it to `false` when you want to disable that logic.
982
+ * Note that like any configuration given to `setPlaybackRate`, this setting
983
+ * is persisted through all future contents played by the player.
984
+ *
985
+ * If you want to stop enabling trickMode tracks, you will have to call
986
+ * `setPlaybackRate` again with `preferTrickModeTracks` set to `false`.
987
+ *
988
+ * You can know at any moment whether this behavior is enabled by calling
989
+ * the `areTrickModeTracksEnabled` method. This will only means that the
990
+ * RxPlayer will select in priority trickmode video tracks, not that the
991
+ * currently chosen video tracks is a trickmode track (for example, some
992
+ * contents may have no trickmode tracks available).
993
+ *
994
+ * If you want to know about the latter instead, you can call `getVideoTrack`
995
+ * and/or listen to `videoTrackChange` events. The track returned may have an
996
+ * `isTrickModeTrack` property set to `true`, indicating that it is a
997
+ * trickmode track.
998
+ *
999
+ * Note that switching to or getting out of a trickmode video track may
1000
+ * lead to the player being a brief instant in a `"RELOADING"` state (notified
1001
+ * through `playerStateChange` events and the `getLoadedContentState` method).
1002
+ * When in that state, a black screen may be displayed and multiple RxPlayer
1003
+ * APIs will not be usable.
1004
+ *
1005
+ * @param {Number} rate
1006
+ * @param {Object} opts
1007
+ */
1008
+ setPlaybackRate(rate, opts) {
1009
+ var _a;
1010
+ if (rate !== this._priv_speed.getValue()) {
1011
+ this._priv_speed.setValue(rate);
1012
+ }
1013
+ const preferTrickModeTracks = opts === null || opts === void 0 ? void 0 : opts.preferTrickModeTracks;
1014
+ if (typeof preferTrickModeTracks !== "boolean") {
1015
+ return;
1016
+ }
1017
+ this._priv_preferTrickModeTracks = preferTrickModeTracks;
1018
+ const tracksStore = (_a = this._priv_contentInfos) === null || _a === void 0 ? void 0 : _a.tracksStore;
1019
+ if (!isNullOrUndefined(tracksStore)) {
1020
+ if (preferTrickModeTracks && !tracksStore.isTrickModeEnabled()) {
1021
+ tracksStore.enableVideoTrickModeTracks();
1022
+ }
1023
+ else if (!preferTrickModeTracks && tracksStore.isTrickModeEnabled()) {
1024
+ tracksStore.disableVideoTrickModeTracks();
1025
+ }
1026
+ }
1027
+ }
1028
+ /**
1029
+ * Returns video Representation currently considered for the current Period.
1030
+ *
1031
+ * Returns `null` if no video track is playing for the current Period.
1032
+ *
1033
+ * Returns `undefined` either when are not currently playing any Period or
1034
+ * when we don't know which Representation is playing.
1035
+ * @returns {Object|null|undefined}
1036
+ */
1037
+ getVideoRepresentation() {
1038
+ const representations = this.__priv_getCurrentRepresentations();
1039
+ if (representations === null) {
1040
+ return undefined;
1041
+ }
1042
+ return representations.video;
1043
+ }
1044
+ /**
1045
+ * Returns audio Representation currently considered for the current Period.
1046
+ *
1047
+ * Returns `null` if no audio track is playing for the current Period.
1048
+ *
1049
+ * Returns `undefined` either when are not currently playing any Period or
1050
+ * when we don't know which Representation is playing.
1051
+ * @returns {Object|null|undefined}
1052
+ */
1053
+ getAudioRepresentation() {
1054
+ const representations = this.__priv_getCurrentRepresentations();
1055
+ if (representations === null) {
1056
+ return undefined;
1057
+ }
1058
+ return representations.audio;
1059
+ }
1060
+ /**
1061
+ * Play/Resume the current video.
1062
+ * @returns {Promise}
1063
+ */
1064
+ play() {
1065
+ if (this.videoElement === null) {
1066
+ throw new Error("Disposed player");
1067
+ }
1068
+ const playPromise = this.videoElement.play();
1069
+ /* eslint-disable @typescript-eslint/unbound-method */
1070
+ if (isNullOrUndefined(playPromise) || typeof playPromise.catch !== "function") {
1071
+ /* eslint-enable @typescript-eslint/unbound-method */
1072
+ return Promise.resolve();
1073
+ }
1074
+ return playPromise.catch((error) => {
1075
+ if (error.name === "NotAllowedError") {
1076
+ const warning = new MediaError("MEDIA_ERR_PLAY_NOT_ALLOWED", error.toString());
1077
+ this.trigger("warning", warning);
1078
+ }
1079
+ throw error;
1080
+ });
1081
+ }
1082
+ /**
1083
+ * Pause the current video.
1084
+ */
1085
+ pause() {
1086
+ if (this.videoElement === null) {
1087
+ throw new Error("Disposed player");
1088
+ }
1089
+ this.videoElement.pause();
1090
+ }
1091
+ /**
1092
+ * Seek to a given absolute position.
1093
+ * @param {Number|Object} time
1094
+ * @returns {Number} - The time the player has seek to
1095
+ */
1096
+ seekTo(time) {
1097
+ var _a;
1098
+ if (this.videoElement === null) {
1099
+ throw new Error("Disposed player");
1100
+ }
1101
+ if (this._priv_contentInfos === null) {
1102
+ throw new Error("player: no content loaded");
1103
+ }
1104
+ const { isDirectFile, manifest } = this._priv_contentInfos;
1105
+ if (!isDirectFile && manifest === null) {
1106
+ throw new Error("player: the content did not load yet");
1107
+ }
1108
+ let positionWanted;
1109
+ if (typeof time === "number") {
1110
+ positionWanted = time;
1111
+ }
1112
+ else if (typeof time === "object") {
1113
+ const timeObj = time;
1114
+ const currentTs = this.videoElement.currentTime;
1115
+ if (!isNullOrUndefined(timeObj.relative)) {
1116
+ positionWanted = currentTs + timeObj.relative;
1117
+ }
1118
+ else if (!isNullOrUndefined(timeObj.position)) {
1119
+ positionWanted = timeObj.position;
1120
+ }
1121
+ else if (!isNullOrUndefined(timeObj.wallClockTime)) {
1122
+ if (manifest !== null) {
1123
+ positionWanted = timeObj.wallClockTime - ((_a = manifest.availabilityStartTime) !== null && _a !== void 0 ? _a : 0);
1124
+ }
1125
+ else if (isDirectFile && this.videoElement !== null) {
1126
+ const startDate = getStartDate(this.videoElement);
1127
+ if (startDate !== undefined) {
1128
+ positionWanted = timeObj.wallClockTime - startDate;
1129
+ }
1130
+ }
1131
+ if (positionWanted === undefined) {
1132
+ positionWanted = timeObj.wallClockTime;
1133
+ }
1134
+ }
1135
+ else {
1136
+ throw new Error("invalid time object. You must set one of the " +
1137
+ 'following properties: "relative", "position" or ' +
1138
+ '"wallClockTime"');
1139
+ }
1140
+ }
1141
+ if (positionWanted === undefined) {
1142
+ throw new Error("invalid time given");
1143
+ }
1144
+ log.info("API: API Seek to", positionWanted);
1145
+ this.videoElement.currentTime = positionWanted;
1146
+ return positionWanted;
1147
+ }
1148
+ /**
1149
+ * Returns the current player's audio volume on the media element.
1150
+ * From 0 (no audio) to 1 (maximum volume).
1151
+ * @returns {Number}
1152
+ */
1153
+ getVolume() {
1154
+ if (this.videoElement === null) {
1155
+ throw new Error("Disposed player");
1156
+ }
1157
+ return this.videoElement.volume;
1158
+ }
1159
+ /**
1160
+ * Set the player's audio volume. From 0 (no volume) to 1 (maximum volume).
1161
+ * @param {Number} volume
1162
+ */
1163
+ setVolume(volume) {
1164
+ if (this.videoElement === null) {
1165
+ throw new Error("Disposed player");
1166
+ }
1167
+ const videoElement = this.videoElement;
1168
+ if (volume !== videoElement.volume) {
1169
+ videoElement.volume = volume;
1170
+ }
1171
+ }
1172
+ /**
1173
+ * Returns `true` if audio is currently muted.
1174
+ * @returns {Boolean}
1175
+ */
1176
+ isMute() {
1177
+ var _a;
1178
+ return ((_a = this.videoElement) === null || _a === void 0 ? void 0 : _a.muted) === true;
1179
+ }
1180
+ /**
1181
+ * Mute audio.
1182
+ */
1183
+ mute() {
1184
+ if (this.videoElement === null) {
1185
+ throw new Error("Disposed player");
1186
+ }
1187
+ if (!this.videoElement.muted) {
1188
+ this.videoElement.muted = true;
1189
+ }
1190
+ }
1191
+ /**
1192
+ * Unmute audio.
1193
+ */
1194
+ unMute() {
1195
+ if (this.videoElement === null) {
1196
+ throw new Error("Disposed player");
1197
+ }
1198
+ if (this.videoElement.muted) {
1199
+ this.videoElement.muted = false;
1200
+ }
1201
+ }
1202
+ /**
1203
+ * Set the max buffer size for the buffer behind the current position.
1204
+ * Every buffer data before will be removed.
1205
+ * @param {Number} depthInSeconds
1206
+ */
1207
+ setMaxBufferBehind(depthInSeconds) {
1208
+ this._priv_bufferOptions.maxBufferBehind.setValue(depthInSeconds);
1209
+ }
1210
+ /**
1211
+ * Set the max buffer size for the buffer behind the current position.
1212
+ * Every buffer data before will be removed.
1213
+ * @param {Number} depthInSeconds
1214
+ */
1215
+ setMaxBufferAhead(depthInSeconds) {
1216
+ this._priv_bufferOptions.maxBufferAhead.setValue(depthInSeconds);
1217
+ }
1218
+ /**
1219
+ * Set the max buffer size for the buffer ahead of the current position.
1220
+ * The player will stop downloading chunks when this size is reached.
1221
+ * @param {Number} sizeInSeconds
1222
+ */
1223
+ setWantedBufferAhead(sizeInSeconds) {
1224
+ this._priv_bufferOptions.wantedBufferAhead.setValue(sizeInSeconds);
1225
+ }
1226
+ /**
1227
+ * Set the max buffer size the buffer should take in memory
1228
+ * The player . will stop downloading chunks when this size is reached.
1229
+ * @param {Number} sizeInKBytes
1230
+ */
1231
+ setMaxVideoBufferSize(sizeInKBytes) {
1232
+ this._priv_bufferOptions.maxVideoBufferSize.setValue(sizeInKBytes);
1233
+ }
1234
+ /**
1235
+ * Returns the max buffer size for the buffer behind the current position.
1236
+ * @returns {Number}
1237
+ */
1238
+ getMaxBufferBehind() {
1239
+ return this._priv_bufferOptions.maxBufferBehind.getValue();
1240
+ }
1241
+ /**
1242
+ * Returns the max buffer size for the buffer behind the current position.
1243
+ * @returns {Number}
1244
+ */
1245
+ getMaxBufferAhead() {
1246
+ return this._priv_bufferOptions.maxBufferAhead.getValue();
1247
+ }
1248
+ /**
1249
+ * Returns the max buffer size for the buffer ahead of the current position.
1250
+ * @returns {Number}
1251
+ */
1252
+ getWantedBufferAhead() {
1253
+ return this._priv_bufferOptions.wantedBufferAhead.getValue();
1254
+ }
1255
+ /**
1256
+ * Returns the max buffer memory size for the buffer in kilobytes
1257
+ * @returns {Number}
1258
+ */
1259
+ getMaxVideoBufferSize() {
1260
+ return this._priv_bufferOptions.maxVideoBufferSize.getValue();
1261
+ }
1262
+ getCurrentPeriod() {
1263
+ var _a;
1264
+ const currentPeriod = (_a = this._priv_contentInfos) === null || _a === void 0 ? void 0 : _a.currentPeriod;
1265
+ if (isNullOrUndefined(currentPeriod)) {
1266
+ return null;
1267
+ }
1268
+ return {
1269
+ id: currentPeriod.id,
1270
+ start: currentPeriod.start,
1271
+ end: currentPeriod.end,
1272
+ };
1273
+ }
1274
+ /**
1275
+ * Returns both the name of the key system (e.g. `"com.widevine.alpha"`) and
1276
+ * the `MediaKeySystemConfiguration` currently associated to the
1277
+ * HTMLMediaElement linked to the RxPlayer.
1278
+ *
1279
+ * Returns `null` if no such capabilities is associated or if unknown.
1280
+ * @returns {Object|null}
1281
+ */
1282
+ getKeySystemConfiguration() {
1283
+ if (this.videoElement === null) {
1284
+ throw new Error("Disposed player");
1285
+ }
1286
+ const values = getKeySystemConfiguration(this.videoElement);
1287
+ if (values === null) {
1288
+ return null;
1289
+ }
1290
+ return { keySystem: values[0], configuration: values[1] };
1291
+ }
1292
+ /**
1293
+ * Returns the list of available Periods for which the current audio, video or
1294
+ * text track can now be changed.
1295
+ * @returns {Array.<Object>}
1296
+ */
1297
+ getAvailablePeriods() {
1298
+ if (this._priv_contentInfos === null) {
1299
+ return [];
1300
+ }
1301
+ const { isDirectFile, tracksStore } = this._priv_contentInfos;
1302
+ if (isDirectFile) {
1303
+ return [];
1304
+ }
1305
+ if (tracksStore === null) {
1306
+ return [];
1307
+ }
1308
+ return tracksStore.getAvailablePeriods().slice();
1309
+ }
1310
+ /**
1311
+ * Returns every available audio tracks for a given Period - or the current
1312
+ * one if no `periodId` is given.
1313
+ * @param {string|undefined} [periodId]
1314
+ * @returns {Array.<Object>}
1315
+ */
1316
+ getAvailableAudioTracks(periodId) {
1317
+ var _a;
1318
+ if (this._priv_contentInfos === null) {
1319
+ return [];
1320
+ }
1321
+ const { isDirectFile, mediaElementTracksStore } = this._priv_contentInfos;
1322
+ if (isDirectFile) {
1323
+ return (_a = mediaElementTracksStore === null || mediaElementTracksStore === void 0 ? void 0 : mediaElementTracksStore.getAvailableAudioTracks()) !== null && _a !== void 0 ? _a : [];
1324
+ }
1325
+ return this._priv_callTracksStoreGetterSetter(periodId, [], (tcm, periodRef) => { var _a; return (_a = tcm.getAvailableAudioTracks(periodRef)) !== null && _a !== void 0 ? _a : []; });
1326
+ }
1327
+ /**
1328
+ * Returns every available text tracks for a given Period - or the current
1329
+ * one if no `periodId` is given.
1330
+ * @param {string|undefined} [periodId]
1331
+ * @returns {Array.<Object>}
1332
+ */
1333
+ getAvailableTextTracks(periodId) {
1334
+ var _a;
1335
+ if (this._priv_contentInfos === null) {
1336
+ return [];
1337
+ }
1338
+ const { isDirectFile, mediaElementTracksStore } = this._priv_contentInfos;
1339
+ if (isDirectFile) {
1340
+ return (_a = mediaElementTracksStore === null || mediaElementTracksStore === void 0 ? void 0 : mediaElementTracksStore.getAvailableTextTracks()) !== null && _a !== void 0 ? _a : [];
1341
+ }
1342
+ return this._priv_callTracksStoreGetterSetter(periodId, [], (tcm, periodRef) => { var _a; return (_a = tcm.getAvailableTextTracks(periodRef)) !== null && _a !== void 0 ? _a : []; });
1343
+ }
1344
+ /**
1345
+ * Returns every available video tracks for the current Period.
1346
+ * @param {string|undefined} [periodId]
1347
+ * @returns {Array.<Object>}
1348
+ */
1349
+ getAvailableVideoTracks(periodId) {
1350
+ var _a;
1351
+ if (this._priv_contentInfos === null) {
1352
+ return [];
1353
+ }
1354
+ const { isDirectFile, mediaElementTracksStore } = this._priv_contentInfos;
1355
+ if (isDirectFile) {
1356
+ return (_a = mediaElementTracksStore === null || mediaElementTracksStore === void 0 ? void 0 : mediaElementTracksStore.getAvailableVideoTracks()) !== null && _a !== void 0 ? _a : [];
1357
+ }
1358
+ return this._priv_callTracksStoreGetterSetter(periodId, [], (tcm, periodRef) => { var _a; return (_a = tcm.getAvailableVideoTracks(periodRef)) !== null && _a !== void 0 ? _a : []; });
1359
+ }
1360
+ /**
1361
+ * Returns currently chosen audio language for the current Period.
1362
+ * @param {string|undefined} [periodId]
1363
+ * @returns {Object|null|undefined}
1364
+ */
1365
+ getAudioTrack(periodId) {
1366
+ if (this._priv_contentInfos === null) {
1367
+ return undefined;
1368
+ }
1369
+ const { isDirectFile, mediaElementTracksStore } = this._priv_contentInfos;
1370
+ if (isDirectFile) {
1371
+ if (mediaElementTracksStore === null) {
1372
+ return undefined;
1373
+ }
1374
+ return mediaElementTracksStore.getChosenAudioTrack();
1375
+ }
1376
+ return this._priv_callTracksStoreGetterSetter(periodId, undefined, (tcm, periodRef) => tcm.getChosenAudioTrack(periodRef));
1377
+ }
1378
+ /**
1379
+ * Returns currently chosen subtitle for the current Period.
1380
+ * @param {string|undefined} [periodId]
1381
+ * @returns {Object|null|undefined}
1382
+ */
1383
+ getTextTrack(periodId) {
1384
+ if (this._priv_contentInfos === null) {
1385
+ return undefined;
1386
+ }
1387
+ const { isDirectFile, mediaElementTracksStore } = this._priv_contentInfos;
1388
+ if (isDirectFile) {
1389
+ if (mediaElementTracksStore === null) {
1390
+ return undefined;
1391
+ }
1392
+ return mediaElementTracksStore.getChosenTextTrack();
1393
+ }
1394
+ return this._priv_callTracksStoreGetterSetter(periodId, undefined, (tcm, periodRef) => tcm.getChosenTextTrack(periodRef));
1395
+ }
1396
+ /**
1397
+ * Returns currently chosen video track for the current Period.
1398
+ * @param {string|undefined} [periodId]
1399
+ * @returns {Object|null|undefined}
1400
+ */
1401
+ getVideoTrack(periodId) {
1402
+ if (this._priv_contentInfos === null) {
1403
+ return undefined;
1404
+ }
1405
+ const { isDirectFile, mediaElementTracksStore } = this._priv_contentInfos;
1406
+ if (isDirectFile) {
1407
+ if (mediaElementTracksStore === null) {
1408
+ return undefined;
1409
+ }
1410
+ return mediaElementTracksStore.getChosenVideoTrack();
1411
+ }
1412
+ return this._priv_callTracksStoreGetterSetter(periodId, undefined, (tcm, periodRef) => tcm.getChosenVideoTrack(periodRef));
1413
+ }
1414
+ /**
1415
+ * Update the audio language for the current Period.
1416
+ * @param {string | object} arg
1417
+ * @throws Error - the current content has no TracksStore.
1418
+ * @throws Error - the given id is linked to no audio track.
1419
+ */
1420
+ setAudioTrack(arg) {
1421
+ var _a;
1422
+ if (this._priv_contentInfos === null) {
1423
+ throw new Error("No content loaded");
1424
+ }
1425
+ const { isDirectFile, mediaElementTracksStore } = this._priv_contentInfos;
1426
+ if (isDirectFile) {
1427
+ try {
1428
+ const audioId = typeof arg === "string" ? arg : arg.trackId;
1429
+ mediaElementTracksStore === null || mediaElementTracksStore === void 0 ? void 0 : mediaElementTracksStore.setAudioTrackById(audioId);
1430
+ return;
1431
+ }
1432
+ catch (e) {
1433
+ throw new Error("player: unknown audio track");
1434
+ }
1435
+ }
1436
+ let periodId;
1437
+ let trackId;
1438
+ let switchingMode;
1439
+ let lockedRepresentations = null;
1440
+ let relativeResumingPosition;
1441
+ if (typeof arg === "string") {
1442
+ trackId = arg;
1443
+ }
1444
+ else {
1445
+ trackId = arg.trackId;
1446
+ periodId = arg.periodId;
1447
+ switchingMode = arg.switchingMode;
1448
+ lockedRepresentations = (_a = arg.lockedRepresentations) !== null && _a !== void 0 ? _a : null;
1449
+ relativeResumingPosition = arg.relativeResumingPosition;
1450
+ }
1451
+ return this._priv_callTracksStoreGetterSetter(periodId, undefined, (tcm, periodRef) => tcm.setAudioTrack({
1452
+ periodRef,
1453
+ trackId,
1454
+ switchingMode,
1455
+ lockedRepresentations,
1456
+ relativeResumingPosition,
1457
+ }));
1458
+ }
1459
+ /**
1460
+ * Update the text language for the current Period.
1461
+ * @param {string | Object} arg
1462
+ * @throws Error - the current content has no TracksStore.
1463
+ * @throws Error - the given id is linked to no text track.
1464
+ */
1465
+ setTextTrack(arg) {
1466
+ if (this._priv_contentInfos === null) {
1467
+ throw new Error("No content loaded");
1468
+ }
1469
+ const { isDirectFile, mediaElementTracksStore } = this._priv_contentInfos;
1470
+ if (isDirectFile) {
1471
+ try {
1472
+ const textId = typeof arg === "string" ? arg : arg.trackId;
1473
+ mediaElementTracksStore === null || mediaElementTracksStore === void 0 ? void 0 : mediaElementTracksStore.setTextTrackById(textId);
1474
+ return;
1475
+ }
1476
+ catch (e) {
1477
+ throw new Error("player: unknown text track");
1478
+ }
1479
+ }
1480
+ let periodId;
1481
+ let trackId;
1482
+ if (typeof arg === "string") {
1483
+ trackId = arg;
1484
+ }
1485
+ else {
1486
+ trackId = arg.trackId;
1487
+ periodId = arg.periodId;
1488
+ }
1489
+ return this._priv_callTracksStoreGetterSetter(periodId, undefined, (tcm, periodRef) => tcm.setTextTrack(periodRef, trackId));
1490
+ }
1491
+ /**
1492
+ * Disable subtitles for the current content.
1493
+ * @param {string|undefined} [periodId]
1494
+ */
1495
+ disableTextTrack(periodId) {
1496
+ if (this._priv_contentInfos === null) {
1497
+ return;
1498
+ }
1499
+ const { isDirectFile, mediaElementTracksStore } = this._priv_contentInfos;
1500
+ if (isDirectFile) {
1501
+ mediaElementTracksStore === null || mediaElementTracksStore === void 0 ? void 0 : mediaElementTracksStore.disableTextTrack();
1502
+ return;
1503
+ }
1504
+ return this._priv_callTracksStoreGetterSetter(periodId, undefined, (tcm, periodRef) => tcm.disableTrack(periodRef, "text"));
1505
+ }
1506
+ /**
1507
+ * Update the video track for the current Period.
1508
+ * @param {string | Object} arg
1509
+ * @throws Error - the current content has no TracksStore.
1510
+ * @throws Error - the given id is linked to no video track.
1511
+ */
1512
+ setVideoTrack(arg) {
1513
+ var _a;
1514
+ if (this._priv_contentInfos === null) {
1515
+ throw new Error("No content loaded");
1516
+ }
1517
+ const { isDirectFile, mediaElementTracksStore } = this._priv_contentInfos;
1518
+ if (isDirectFile) {
1519
+ try {
1520
+ const videoId = typeof arg === "string" ? arg : arg.trackId;
1521
+ mediaElementTracksStore === null || mediaElementTracksStore === void 0 ? void 0 : mediaElementTracksStore.setVideoTrackById(videoId);
1522
+ return;
1523
+ }
1524
+ catch (e) {
1525
+ throw new Error("player: unknown video track");
1526
+ }
1527
+ }
1528
+ let periodId;
1529
+ let trackId;
1530
+ let switchingMode;
1531
+ let lockedRepresentations = null;
1532
+ let relativeResumingPosition;
1533
+ if (typeof arg === "string") {
1534
+ trackId = arg;
1535
+ }
1536
+ else {
1537
+ trackId = arg.trackId;
1538
+ periodId = arg.periodId;
1539
+ switchingMode = arg.switchingMode;
1540
+ lockedRepresentations = (_a = arg.lockedRepresentations) !== null && _a !== void 0 ? _a : null;
1541
+ relativeResumingPosition = arg.relativeResumingPosition;
1542
+ }
1543
+ return this._priv_callTracksStoreGetterSetter(periodId, undefined, (tcm, periodRef) => tcm.setVideoTrack({
1544
+ periodRef,
1545
+ trackId,
1546
+ switchingMode,
1547
+ lockedRepresentations,
1548
+ relativeResumingPosition,
1549
+ }));
1550
+ }
1551
+ /**
1552
+ * Disable video track for the current content.
1553
+ * @param {string|undefined} [periodId]
1554
+ */
1555
+ disableVideoTrack(periodId) {
1556
+ if (this._priv_contentInfos === null) {
1557
+ return;
1558
+ }
1559
+ const { isDirectFile, mediaElementTracksStore } = this._priv_contentInfos;
1560
+ if (isDirectFile && mediaElementTracksStore !== null) {
1561
+ return mediaElementTracksStore.disableVideoTrack();
1562
+ }
1563
+ return this._priv_callTracksStoreGetterSetter(periodId, undefined, (tcm, periodRef) => tcm.disableTrack(periodRef, "video"));
1564
+ }
1565
+ lockVideoRepresentations(arg) {
1566
+ if (this._priv_contentInfos === null) {
1567
+ throw new Error("No content loaded");
1568
+ }
1569
+ const { isDirectFile } = this._priv_contentInfos;
1570
+ if (isDirectFile) {
1571
+ throw new Error("Cannot lock video Representations in directfile mode.");
1572
+ }
1573
+ let repsId;
1574
+ let periodId;
1575
+ let switchingMode;
1576
+ if (Array.isArray(arg)) {
1577
+ repsId = arg;
1578
+ periodId = undefined;
1579
+ }
1580
+ else {
1581
+ repsId = arg.representations;
1582
+ periodId = arg.periodId;
1583
+ switchingMode = arg.switchingMode;
1584
+ }
1585
+ return this._priv_callTracksStoreGetterSetter(periodId, undefined, (tcm, periodRef) => tcm.lockVideoRepresentations(periodRef, {
1586
+ representations: repsId,
1587
+ switchingMode,
1588
+ }));
1589
+ }
1590
+ lockAudioRepresentations(arg) {
1591
+ if (this._priv_contentInfos === null) {
1592
+ throw new Error("No content loaded");
1593
+ }
1594
+ const { isDirectFile } = this._priv_contentInfos;
1595
+ if (isDirectFile) {
1596
+ throw new Error("Cannot lock audio Representations in directfile mode.");
1597
+ }
1598
+ let repsId;
1599
+ let periodId;
1600
+ let switchingMode;
1601
+ if (Array.isArray(arg)) {
1602
+ repsId = arg;
1603
+ periodId = undefined;
1604
+ }
1605
+ else {
1606
+ repsId = arg.representations;
1607
+ periodId = arg.periodId;
1608
+ switchingMode = arg.switchingMode;
1609
+ }
1610
+ return this._priv_callTracksStoreGetterSetter(periodId, undefined, (tcm, periodRef) => tcm.lockAudioRepresentations(periodRef, {
1611
+ representations: repsId,
1612
+ switchingMode,
1613
+ }));
1614
+ }
1615
+ getLockedVideoRepresentations(periodId) {
1616
+ if (this._priv_contentInfos === null) {
1617
+ return null;
1618
+ }
1619
+ const { isDirectFile } = this._priv_contentInfos;
1620
+ if (isDirectFile) {
1621
+ return null;
1622
+ }
1623
+ return this._priv_callTracksStoreGetterSetter(periodId, null, (tcm, periodRef) => tcm.getLockedVideoRepresentations(periodRef));
1624
+ }
1625
+ getLockedAudioRepresentations(periodId) {
1626
+ if (this._priv_contentInfos === null) {
1627
+ return null;
1628
+ }
1629
+ const { isDirectFile } = this._priv_contentInfos;
1630
+ if (isDirectFile) {
1631
+ return null;
1632
+ }
1633
+ return this._priv_callTracksStoreGetterSetter(periodId, null, (tcm, periodRef) => tcm.getLockedAudioRepresentations(periodRef));
1634
+ }
1635
+ unlockVideoRepresentations(periodId) {
1636
+ if (this._priv_contentInfos === null) {
1637
+ return;
1638
+ }
1639
+ const { isDirectFile } = this._priv_contentInfos;
1640
+ if (isDirectFile) {
1641
+ return;
1642
+ }
1643
+ return this._priv_callTracksStoreGetterSetter(periodId, undefined, (tcm, periodRef) => tcm.unlockVideoRepresentations(periodRef));
1644
+ }
1645
+ unlockAudioRepresentations(periodId) {
1646
+ if (this._priv_contentInfos === null) {
1647
+ return;
1648
+ }
1649
+ const { isDirectFile } = this._priv_contentInfos;
1650
+ if (isDirectFile) {
1651
+ return;
1652
+ }
1653
+ return this._priv_callTracksStoreGetterSetter(periodId, undefined, (tcm, periodRef) => tcm.unlockAudioRepresentations(periodRef));
1654
+ }
1655
+ /**
1656
+ * Get minimum seek-able position.
1657
+ * @returns {number}
1658
+ */
1659
+ getMinimumPosition() {
1660
+ if (this._priv_contentInfos === null) {
1661
+ return null;
1662
+ }
1663
+ if (this._priv_contentInfos.isDirectFile) {
1664
+ return 0;
1665
+ }
1666
+ const { manifest } = this._priv_contentInfos;
1667
+ if (manifest !== null) {
1668
+ return getMinimumSafePosition(manifest);
1669
+ }
1670
+ return null;
1671
+ }
1672
+ /**
1673
+ * Returns the current position for live contents.
1674
+ *
1675
+ * Returns `null` if no content is loaded or if the current loaded content is
1676
+ * not considered as a live content.
1677
+ * Returns `undefined` if that live position is currently unknown.
1678
+ * @returns {number}
1679
+ */
1680
+ getLivePosition() {
1681
+ if (this._priv_contentInfos === null) {
1682
+ return null;
1683
+ }
1684
+ const { isDirectFile, manifest } = this._priv_contentInfos;
1685
+ if (isDirectFile) {
1686
+ return undefined;
1687
+ }
1688
+ if ((manifest === null || manifest === void 0 ? void 0 : manifest.isLive) !== true) {
1689
+ return null;
1690
+ }
1691
+ return getLivePosition(manifest);
1692
+ }
1693
+ /**
1694
+ * Get maximum seek-able position.
1695
+ * @returns {number}
1696
+ */
1697
+ getMaximumPosition() {
1698
+ if (this._priv_contentInfos === null) {
1699
+ return null;
1700
+ }
1701
+ const { isDirectFile, manifest } = this._priv_contentInfos;
1702
+ if (isDirectFile) {
1703
+ if (this.videoElement === null) {
1704
+ throw new Error("Disposed player");
1705
+ }
1706
+ return this.videoElement.duration;
1707
+ }
1708
+ if (manifest !== null) {
1709
+ if (!manifest.isDynamic && this.videoElement !== null) {
1710
+ return this.videoElement.duration;
1711
+ }
1712
+ return getMaximumSafePosition(manifest);
1713
+ }
1714
+ return null;
1715
+ }
1716
+ // ---- Undocumented Private methods. ----
1717
+ //
1718
+ // Those methods are just here either to allow some tools relying on the
1719
+ // RxPlayer instance to work or to improve the RxPlayer's demo.
1720
+ //
1721
+ // They should not be used by any external code.
1722
+ /**
1723
+ * /!\ For demo use only! Do not touch!
1724
+ *
1725
+ * Returns every chunk buffered for a given buffer type.
1726
+ * Returns `null` if no SegmentSink was created for this type of buffer.
1727
+ * @param {string} bufferType
1728
+ * @returns {Array.<Object>|null}
1729
+ */
1730
+ __priv_getSegmentSinkContent(bufferType) {
1731
+ if (this._priv_contentInfos === null ||
1732
+ this._priv_contentInfos.segmentSinksStore === null) {
1733
+ return null;
1734
+ }
1735
+ const segmentSinkStatus = this._priv_contentInfos.segmentSinksStore.getStatus(bufferType);
1736
+ if (segmentSinkStatus.type === "initialized") {
1737
+ return segmentSinkStatus.value.getLastKnownInventory();
1738
+ }
1739
+ return null;
1740
+ }
1741
+ /**
1742
+ * /!\ For tools use only! Do not touch!
1743
+ *
1744
+ * Returns manifest/playlist object.
1745
+ * null if the player is STOPPED.
1746
+ * @returns {Manifest|null} - The current Manifest (`null` when not known).
1747
+ */
1748
+ // TODO remove the need for that public method
1749
+ __priv_getManifest() {
1750
+ if (this._priv_contentInfos === null) {
1751
+ return null;
1752
+ }
1753
+ return this._priv_contentInfos.manifest;
1754
+ }
1755
+ // TODO remove the need for that public method
1756
+ __priv_getCurrentAdaptation() {
1757
+ if (this._priv_contentInfos === null) {
1758
+ return null;
1759
+ }
1760
+ const { currentPeriod, activeAdaptations } = this._priv_contentInfos;
1761
+ if (currentPeriod === null ||
1762
+ activeAdaptations === null ||
1763
+ isNullOrUndefined(activeAdaptations[currentPeriod.id])) {
1764
+ return null;
1765
+ }
1766
+ return activeAdaptations[currentPeriod.id];
1767
+ }
1768
+ // TODO remove the need for that public method
1769
+ __priv_getCurrentRepresentations() {
1770
+ if (this._priv_contentInfos === null) {
1771
+ return null;
1772
+ }
1773
+ const { currentPeriod, activeRepresentations } = this._priv_contentInfos;
1774
+ if (currentPeriod === null ||
1775
+ activeRepresentations === null ||
1776
+ isNullOrUndefined(activeRepresentations[currentPeriod.id])) {
1777
+ return null;
1778
+ }
1779
+ return activeRepresentations[currentPeriod.id];
1780
+ }
1781
+ // ---- Private methods ----
1782
+ /**
1783
+ * Reset all state properties relative to a playing content.
1784
+ */
1785
+ _priv_cleanUpCurrentContentState() {
1786
+ var _a, _b, _c, _d;
1787
+ log.debug("Locking `contentLock` to clean-up the current content.");
1788
+ // lock playback of new contents while cleaning up is pending
1789
+ this._priv_contentLock.setValue(true);
1790
+ (_b = (_a = this._priv_contentInfos) === null || _a === void 0 ? void 0 : _a.tracksStore) === null || _b === void 0 ? void 0 : _b.dispose();
1791
+ (_d = (_c = this._priv_contentInfos) === null || _c === void 0 ? void 0 : _c.mediaElementTracksStore) === null || _d === void 0 ? void 0 : _d.dispose();
1792
+ this._priv_contentInfos = null;
1793
+ this._priv_contentEventsMemory = {};
1794
+ // DRM-related clean-up
1795
+ const freeUpContentLock = () => {
1796
+ if (this.videoElement !== null) {
1797
+ // If not disposed
1798
+ log.debug("Unlocking `contentLock`. Next content can begin.");
1799
+ this._priv_contentLock.setValue(false);
1800
+ }
1801
+ };
1802
+ if (!isNullOrUndefined(this.videoElement)) {
1803
+ clearOnStop(this.videoElement).then(() => {
1804
+ log.debug("API: DRM session cleaned-up with success!");
1805
+ freeUpContentLock();
1806
+ }, (err) => {
1807
+ log.error("API: An error arised when trying to clean-up the DRM session:" +
1808
+ (err instanceof Error ? err.toString() : "Unknown Error"));
1809
+ freeUpContentLock();
1810
+ });
1811
+ }
1812
+ else {
1813
+ freeUpContentLock();
1814
+ }
1815
+ }
1816
+ /**
1817
+ * Triggered when the Manifest has been loaded for the current content.
1818
+ * Initialize various private properties and emit initial event.
1819
+ * @param {Object} contentInfos
1820
+ * @param {Object} manifest
1821
+ */
1822
+ _priv_onManifestReady(contentInfos, manifest) {
1823
+ var _a;
1824
+ if (contentInfos.contentId !== ((_a = this._priv_contentInfos) === null || _a === void 0 ? void 0 : _a.contentId)) {
1825
+ return; // Event for another content
1826
+ }
1827
+ contentInfos.manifest = manifest;
1828
+ if (manifest.manifestFormat === 0 /* ManifestMetadataFormat.Class */) {
1829
+ this._priv_reloadingMetadata.manifest = manifest;
1830
+ }
1831
+ const tracksStore = new TracksStore({
1832
+ preferTrickModeTracks: this._priv_preferTrickModeTracks,
1833
+ defaultAudioTrackSwitchingMode: contentInfos.defaultAudioTrackSwitchingMode,
1834
+ });
1835
+ contentInfos.tracksStore = tracksStore;
1836
+ tracksStore.addEventListener("newAvailablePeriods", (p) => {
1837
+ this.trigger("newAvailablePeriods", p);
1838
+ });
1839
+ tracksStore.addEventListener("brokenRepresentationsLock", (e) => {
1840
+ this.trigger("brokenRepresentationsLock", e);
1841
+ });
1842
+ tracksStore.addEventListener("trackUpdate", (e) => {
1843
+ var _a, _b;
1844
+ this.trigger("trackUpdate", e);
1845
+ const currentPeriod = (_b = (_a = this._priv_contentInfos) === null || _a === void 0 ? void 0 : _a.currentPeriod) !== null && _b !== void 0 ? _b : undefined;
1846
+ if (e.reason === "no-playable-representation" &&
1847
+ e.period.id === (currentPeriod === null || currentPeriod === void 0 ? void 0 : currentPeriod.id)) {
1848
+ this._priv_onAvailableTracksMayHaveChanged(e.trackType);
1849
+ }
1850
+ });
1851
+ contentInfos.tracksStore.addEventListener("warning", (err) => {
1852
+ this.trigger("warning", err);
1853
+ });
1854
+ contentInfos.tracksStore.addEventListener("error", (err) => {
1855
+ this._priv_onFatalError(err, contentInfos);
1856
+ });
1857
+ contentInfos.tracksStore.onManifestUpdate(manifest);
1858
+ }
1859
+ /**
1860
+ * Triggered when the Manifest has been updated for the current content.
1861
+ * Initialize various private properties and emit initial event.
1862
+ * @param {Object} contentInfos
1863
+ * @param {Object} updates
1864
+ */
1865
+ _priv_onManifestUpdate(contentInfos, updates) {
1866
+ var _a, _b, _c;
1867
+ if (this._priv_contentInfos === null || this._priv_contentInfos.manifest === null) {
1868
+ return;
1869
+ }
1870
+ // Update the tracks chosen if it changed
1871
+ if (!isNullOrUndefined(contentInfos === null || contentInfos === void 0 ? void 0 : contentInfos.tracksStore)) {
1872
+ contentInfos.tracksStore.onManifestUpdate(this._priv_contentInfos.manifest);
1873
+ }
1874
+ const currentPeriod = (_b = (_a = this._priv_contentInfos) === null || _a === void 0 ? void 0 : _a.currentPeriod) !== null && _b !== void 0 ? _b : undefined;
1875
+ const currTracksStore = (_c = this._priv_contentInfos) === null || _c === void 0 ? void 0 : _c.tracksStore;
1876
+ if (currentPeriod === undefined || isNullOrUndefined(currTracksStore)) {
1877
+ return;
1878
+ }
1879
+ for (const update of updates.updatedPeriods) {
1880
+ if (update.period.id === currentPeriod.id) {
1881
+ if (update.result.addedAdaptations.length > 0 ||
1882
+ update.result.removedAdaptations.length > 0) {
1883
+ // We might have new (or less) tracks, send events just to be sure
1884
+ const periodRef = currTracksStore.getPeriodObjectFromPeriod(currentPeriod);
1885
+ if (periodRef === undefined) {
1886
+ return;
1887
+ }
1888
+ this._priv_onAvailableTracksMayHaveChanged("audio");
1889
+ this._priv_onAvailableTracksMayHaveChanged("text");
1890
+ this._priv_onAvailableTracksMayHaveChanged("video");
1891
+ }
1892
+ }
1893
+ }
1894
+ }
1895
+ _priv_onDecipherabilityUpdate(contentInfos, elts) {
1896
+ if (contentInfos === null || contentInfos.manifest === null) {
1897
+ return;
1898
+ }
1899
+ if (!isNullOrUndefined(contentInfos === null || contentInfos === void 0 ? void 0 : contentInfos.tracksStore)) {
1900
+ contentInfos.tracksStore.onDecipherabilityUpdates();
1901
+ }
1902
+ /**
1903
+ * Array of tuples only including once the Period/Track combination, and
1904
+ * only when it concerns the currently-selected track.
1905
+ */
1906
+ const periodsAndTrackTypes = elts.reduce((acc, elt) => {
1907
+ var _a, _b, _c;
1908
+ const isFound = arrayFind(acc, (x) => x[0].id === elt.period.id && x[1] === elt.adaptation.type) !== undefined;
1909
+ if (!isFound) {
1910
+ // Only consider the currently-selected tracks.
1911
+ // NOTE: Maybe there's room for optimizations? Unclear.
1912
+ const tStore = contentInfos.tracksStore;
1913
+ if (tStore === null) {
1914
+ return acc;
1915
+ }
1916
+ let isCurrent = false;
1917
+ const periodRef = tStore.getPeriodObjectFromPeriod(elt.period);
1918
+ if (periodRef === undefined) {
1919
+ return acc;
1920
+ }
1921
+ switch (elt.adaptation.type) {
1922
+ case "audio":
1923
+ isCurrent = ((_a = tStore.getChosenAudioTrack(periodRef)) === null || _a === void 0 ? void 0 : _a.id) === elt.adaptation.id;
1924
+ break;
1925
+ case "video":
1926
+ isCurrent = ((_b = tStore.getChosenVideoTrack(periodRef)) === null || _b === void 0 ? void 0 : _b.id) === elt.adaptation.id;
1927
+ break;
1928
+ case "text":
1929
+ isCurrent = ((_c = tStore.getChosenTextTrack(periodRef)) === null || _c === void 0 ? void 0 : _c.id) === elt.adaptation.id;
1930
+ break;
1931
+ }
1932
+ if (isCurrent) {
1933
+ acc.push([elt.period, elt.adaptation.type]);
1934
+ }
1935
+ }
1936
+ return acc;
1937
+ }, []);
1938
+ for (const [period, trackType] of periodsAndTrackTypes) {
1939
+ this._priv_triggerEventIfNotStopped("representationListUpdate", {
1940
+ period: { start: period.start, end: period.end, id: period.id },
1941
+ trackType,
1942
+ reason: "decipherability-update",
1943
+ }, contentInfos.currentContentCanceller.signal);
1944
+ }
1945
+ }
1946
+ /**
1947
+ * Triggered each times the current Period Changed.
1948
+ * Store and emit initial state for the Period.
1949
+ *
1950
+ * @param {Object} contentInfos
1951
+ * @param {Object} periodInfo
1952
+ */
1953
+ _priv_onActivePeriodChanged(contentInfos, { period }) {
1954
+ var _a, _b, _c, _d, _e, _f;
1955
+ if (contentInfos.contentId !== ((_a = this._priv_contentInfos) === null || _a === void 0 ? void 0 : _a.contentId)) {
1956
+ return; // Event for another content
1957
+ }
1958
+ contentInfos.currentPeriod = period;
1959
+ const cancelSignal = contentInfos.currentContentCanceller.signal;
1960
+ if (this._priv_contentEventsMemory.periodChange !== period) {
1961
+ this._priv_contentEventsMemory.periodChange = period;
1962
+ this._priv_triggerEventIfNotStopped("periodChange", { start: period.start, end: period.end, id: period.id }, cancelSignal);
1963
+ }
1964
+ this._priv_triggerEventIfNotStopped("availableAudioTracksChange", this.getAvailableAudioTracks(), cancelSignal);
1965
+ this._priv_triggerEventIfNotStopped("availableTextTracksChange", this.getAvailableTextTracks(), cancelSignal);
1966
+ this._priv_triggerEventIfNotStopped("availableVideoTracksChange", this.getAvailableVideoTracks(), cancelSignal);
1967
+ const tracksStore = (_b = this._priv_contentInfos) === null || _b === void 0 ? void 0 : _b.tracksStore;
1968
+ // Emit initial events for the Period
1969
+ if (!isNullOrUndefined(tracksStore)) {
1970
+ const periodRef = tracksStore.getPeriodObjectFromPeriod(period);
1971
+ if (periodRef) {
1972
+ const audioTrack = tracksStore.getChosenAudioTrack(periodRef);
1973
+ this._priv_triggerEventIfNotStopped("audioTrackChange", audioTrack, cancelSignal);
1974
+ const textTrack = tracksStore.getChosenTextTrack(periodRef);
1975
+ this._priv_triggerEventIfNotStopped("textTrackChange", textTrack, cancelSignal);
1976
+ const videoTrack = tracksStore.getChosenVideoTrack(periodRef);
1977
+ this._priv_triggerEventIfNotStopped("videoTrackChange", videoTrack, cancelSignal);
1978
+ }
1979
+ }
1980
+ else {
1981
+ this._priv_triggerEventIfNotStopped("audioTrackChange", null, cancelSignal);
1982
+ this._priv_triggerEventIfNotStopped("textTrackChange", null, cancelSignal);
1983
+ this._priv_triggerEventIfNotStopped("videoTrackChange", null, cancelSignal);
1984
+ }
1985
+ const audioRepresentation = (_d = (_c = this.__priv_getCurrentRepresentations()) === null || _c === void 0 ? void 0 : _c.audio) !== null && _d !== void 0 ? _d : null;
1986
+ this._priv_triggerEventIfNotStopped("audioRepresentationChange", audioRepresentation, cancelSignal);
1987
+ const videoRepresentation = (_f = (_e = this.__priv_getCurrentRepresentations()) === null || _e === void 0 ? void 0 : _e.video) !== null && _f !== void 0 ? _f : null;
1988
+ this._priv_triggerEventIfNotStopped("videoRepresentationChange", videoRepresentation, cancelSignal);
1989
+ }
1990
+ /**
1991
+ * Triggered each times a new "PeriodStream" is ready.
1992
+ * Choose the right Adaptation for the Period and emit it.
1993
+ * @param {Object} contentInfos
1994
+ * @param {Object} value
1995
+ */
1996
+ _priv_onPeriodStreamReady(contentInfos, value) {
1997
+ var _a;
1998
+ if (contentInfos.contentId !== ((_a = this._priv_contentInfos) === null || _a === void 0 ? void 0 : _a.contentId)) {
1999
+ return; // Event for another content
2000
+ }
2001
+ const { type, period, adaptationRef } = value;
2002
+ const tracksStore = contentInfos.tracksStore;
2003
+ switch (type) {
2004
+ case "video":
2005
+ case "audio":
2006
+ case "text":
2007
+ if (isNullOrUndefined(tracksStore)) {
2008
+ log.error(`API: TracksStore not instanciated for a new ${type} period`);
2009
+ adaptationRef.setValue(null);
2010
+ }
2011
+ else {
2012
+ tracksStore.addTrackReference(type, period, adaptationRef);
2013
+ }
2014
+ break;
2015
+ default:
2016
+ assertUnreachable(type);
2017
+ }
2018
+ }
2019
+ /**
2020
+ * Triggered each times we "remove" a PeriodStream.
2021
+ * @param {Object} contentInfos
2022
+ * @param {Object} value
2023
+ */
2024
+ _priv_onPeriodStreamCleared(contentInfos, value) {
2025
+ var _a;
2026
+ if (contentInfos.contentId !== ((_a = this._priv_contentInfos) === null || _a === void 0 ? void 0 : _a.contentId)) {
2027
+ return; // Event for another content
2028
+ }
2029
+ const { type, period } = value;
2030
+ const tracksStore = contentInfos.tracksStore;
2031
+ // Clean-up track choices from TracksStore
2032
+ switch (type) {
2033
+ case "audio":
2034
+ case "text":
2035
+ case "video":
2036
+ if (!isNullOrUndefined(tracksStore)) {
2037
+ tracksStore.removeTrackReference(type, period);
2038
+ }
2039
+ break;
2040
+ }
2041
+ // Clean-up stored Representation and Adaptation information
2042
+ const { activeAdaptations, activeRepresentations } = contentInfos;
2043
+ if (!isNullOrUndefined(activeAdaptations) &&
2044
+ !isNullOrUndefined(activeAdaptations[period.id])) {
2045
+ const activePeriodAdaptations = activeAdaptations[period.id];
2046
+ delete activePeriodAdaptations[type];
2047
+ if (Object.keys(activePeriodAdaptations).length === 0) {
2048
+ delete activeAdaptations[period.id];
2049
+ }
2050
+ }
2051
+ if (!isNullOrUndefined(activeRepresentations) &&
2052
+ !isNullOrUndefined(activeRepresentations[period.id])) {
2053
+ const activePeriodRepresentations = activeRepresentations[period.id];
2054
+ delete activePeriodRepresentations[type];
2055
+ if (Object.keys(activePeriodRepresentations).length === 0) {
2056
+ delete activeRepresentations[period.id];
2057
+ }
2058
+ }
2059
+ }
2060
+ /**
2061
+ * Triggered each times a new Adaptation is considered for the current
2062
+ * content.
2063
+ * Store given Adaptation and emit it if from the current Period.
2064
+ * @param {Object} contentInfos
2065
+ * @param {Object} value
2066
+ */
2067
+ _priv_onAdaptationChange(contentInfos, { type, adaptation, period, }) {
2068
+ var _a;
2069
+ if (contentInfos.contentId !== ((_a = this._priv_contentInfos) === null || _a === void 0 ? void 0 : _a.contentId)) {
2070
+ return; // Event for another content
2071
+ }
2072
+ // lazily create contentInfos.activeAdaptations
2073
+ if (contentInfos.activeAdaptations === null) {
2074
+ contentInfos.activeAdaptations = {};
2075
+ }
2076
+ const { activeAdaptations, currentPeriod } = contentInfos;
2077
+ const activePeriodAdaptations = activeAdaptations[period.id];
2078
+ if (isNullOrUndefined(activePeriodAdaptations)) {
2079
+ activeAdaptations[period.id] = { [type]: adaptation };
2080
+ }
2081
+ else {
2082
+ activePeriodAdaptations[type] = adaptation;
2083
+ }
2084
+ const { tracksStore } = contentInfos;
2085
+ const cancelSignal = contentInfos.currentContentCanceller.signal;
2086
+ if (tracksStore !== null &&
2087
+ currentPeriod !== null &&
2088
+ !isNullOrUndefined(period) &&
2089
+ period.id === currentPeriod.id) {
2090
+ const periodRef = tracksStore.getPeriodObjectFromPeriod(period);
2091
+ if (periodRef === undefined) {
2092
+ return;
2093
+ }
2094
+ switch (type) {
2095
+ case "audio":
2096
+ const audioTrack = tracksStore.getChosenAudioTrack(periodRef);
2097
+ this._priv_triggerEventIfNotStopped("audioTrackChange", audioTrack, cancelSignal);
2098
+ break;
2099
+ case "text":
2100
+ const textTrack = tracksStore.getChosenTextTrack(periodRef);
2101
+ this._priv_triggerEventIfNotStopped("textTrackChange", textTrack, cancelSignal);
2102
+ break;
2103
+ case "video":
2104
+ const videoTrack = tracksStore.getChosenVideoTrack(periodRef);
2105
+ this._priv_triggerEventIfNotStopped("videoTrackChange", videoTrack, cancelSignal);
2106
+ break;
2107
+ }
2108
+ }
2109
+ }
2110
+ /**
2111
+ * Triggered each times a new Representation is considered during playback.
2112
+ *
2113
+ * Store given Representation and emit it if from the current Period.
2114
+ *
2115
+ * @param {Object} contentInfos
2116
+ * @param {Object} obj
2117
+ */
2118
+ _priv_onRepresentationChange(contentInfos, { type, period, representation, }) {
2119
+ var _a;
2120
+ if (contentInfos.contentId !== ((_a = this._priv_contentInfos) === null || _a === void 0 ? void 0 : _a.contentId)) {
2121
+ return; // Event for another content
2122
+ }
2123
+ // lazily create contentInfos.activeRepresentations
2124
+ if (contentInfos.activeRepresentations === null) {
2125
+ contentInfos.activeRepresentations = {};
2126
+ }
2127
+ const { activeRepresentations, currentPeriod } = contentInfos;
2128
+ const activePeriodRepresentations = activeRepresentations[period.id];
2129
+ if (isNullOrUndefined(activePeriodRepresentations)) {
2130
+ activeRepresentations[period.id] = { [type]: representation };
2131
+ }
2132
+ else {
2133
+ activePeriodRepresentations[type] = representation;
2134
+ }
2135
+ if (!isNullOrUndefined(period) &&
2136
+ currentPeriod !== null &&
2137
+ currentPeriod.id === period.id) {
2138
+ const cancelSignal = this._priv_contentInfos.currentContentCanceller.signal;
2139
+ if (type === "video") {
2140
+ this._priv_triggerEventIfNotStopped("videoRepresentationChange", representation, cancelSignal);
2141
+ }
2142
+ else if (type === "audio") {
2143
+ this._priv_triggerEventIfNotStopped("audioRepresentationChange", representation, cancelSignal);
2144
+ }
2145
+ }
2146
+ }
2147
+ /**
2148
+ * Triggered each time a bitrate estimate is calculated.
2149
+ *
2150
+ * Emit it.
2151
+ *
2152
+ * @param {Object} value
2153
+ */
2154
+ _priv_onBitrateEstimateChange({ type, bitrate, }) {
2155
+ if (bitrate !== undefined) {
2156
+ this._priv_bitrateInfos.lastBitrates[type] = bitrate;
2157
+ }
2158
+ this.trigger(
2159
+ // !!! undocumented API :O !!!
2160
+ /* eslint-disable-next-line */
2161
+ "__priv_bitrateEstimateChange",
2162
+ /* eslint-disable-next-line */
2163
+ { type, bitrate });
2164
+ }
2165
+ /**
2166
+ * Triggered each time the player state updates.
2167
+ *
2168
+ * Trigger the right Player Event.
2169
+ *
2170
+ * @param {string} newState
2171
+ */
2172
+ _priv_setPlayerState(newState) {
2173
+ if (this.state !== newState) {
2174
+ this.state = newState;
2175
+ log.info("API: playerStateChange event", newState);
2176
+ this.trigger("playerStateChange", newState);
2177
+ }
2178
+ }
2179
+ /**
2180
+ * Triggered each time a playback observation.
2181
+ *
2182
+ * Trigger the right Player Event
2183
+ *
2184
+ * @param {Object} contentInfos
2185
+ * @param {Object} observation
2186
+ */
2187
+ _priv_triggerPositionUpdate(contentInfos, observation) {
2188
+ var _a, _b;
2189
+ if (contentInfos.contentId !== ((_a = this._priv_contentInfos) === null || _a === void 0 ? void 0 : _a.contentId)) {
2190
+ return; // Event for another content
2191
+ }
2192
+ const { isDirectFile, manifest } = contentInfos;
2193
+ if ((!isDirectFile && manifest === null) || isNullOrUndefined(observation)) {
2194
+ return;
2195
+ }
2196
+ const maximumPosition = manifest !== null ? getMaximumSafePosition(manifest) : undefined;
2197
+ const positionData = {
2198
+ position: observation.position.getPolled(),
2199
+ duration: observation.duration,
2200
+ playbackRate: observation.playbackRate,
2201
+ maximumPosition,
2202
+ // TODO bufferGap may be undefined
2203
+ bufferGap: observation.bufferGap === undefined || !isFinite(observation.bufferGap)
2204
+ ? 0
2205
+ : observation.bufferGap,
2206
+ };
2207
+ if (manifest !== null && manifest.isLive && observation.position.getPolled() > 0) {
2208
+ const ast = (_b = manifest.availabilityStartTime) !== null && _b !== void 0 ? _b : 0;
2209
+ positionData.wallClockTime = observation.position.getPolled() + ast;
2210
+ const livePosition = getLivePosition(manifest);
2211
+ if (livePosition !== undefined) {
2212
+ positionData.liveGap = livePosition - observation.position.getPolled();
2213
+ }
2214
+ }
2215
+ else if (isDirectFile && this.videoElement !== null) {
2216
+ const startDate = getStartDate(this.videoElement);
2217
+ if (startDate !== undefined) {
2218
+ positionData.wallClockTime = startDate + observation.position.getPolled();
2219
+ }
2220
+ }
2221
+ this.trigger("positionUpdate", positionData);
2222
+ }
2223
+ /**
2224
+ * @param {string} evt
2225
+ * @param {*} arg
2226
+ * @param {Object} currentContentCancelSignal
2227
+ */
2228
+ _priv_triggerEventIfNotStopped(evt, arg, currentContentCancelSignal) {
2229
+ if (!currentContentCancelSignal.isCancelled()) {
2230
+ this.trigger(evt, arg);
2231
+ }
2232
+ }
2233
+ /**
2234
+ * @param {Object} cancelSignal
2235
+ * @returns {Object}
2236
+ */
2237
+ _priv_initializeMediaElementTracksStore(cancelSignal) {
2238
+ var _a, _b, _c;
2239
+ assert(features.directfile !== null, "Initializing `MediaElementTracksStore` without Directfile feature");
2240
+ assert(this.videoElement !== null, "Initializing `MediaElementTracksStore` on a disposed RxPlayer");
2241
+ const mediaElementTracksStore = new features.directfile.mediaElementTracksStore(this.videoElement);
2242
+ this._priv_triggerEventIfNotStopped("availableAudioTracksChange", mediaElementTracksStore.getAvailableAudioTracks(), cancelSignal);
2243
+ this._priv_triggerEventIfNotStopped("availableVideoTracksChange", mediaElementTracksStore.getAvailableVideoTracks(), cancelSignal);
2244
+ this._priv_triggerEventIfNotStopped("availableTextTracksChange", mediaElementTracksStore.getAvailableTextTracks(), cancelSignal);
2245
+ this._priv_triggerEventIfNotStopped("audioTrackChange", (_a = mediaElementTracksStore.getChosenAudioTrack()) !== null && _a !== void 0 ? _a : null, cancelSignal);
2246
+ this._priv_triggerEventIfNotStopped("textTrackChange", (_b = mediaElementTracksStore.getChosenTextTrack()) !== null && _b !== void 0 ? _b : null, cancelSignal);
2247
+ this._priv_triggerEventIfNotStopped("videoTrackChange", (_c = mediaElementTracksStore.getChosenVideoTrack()) !== null && _c !== void 0 ? _c : null, cancelSignal);
2248
+ mediaElementTracksStore.addEventListener("availableVideoTracksChange", (val) => this.trigger("availableVideoTracksChange", val));
2249
+ mediaElementTracksStore.addEventListener("availableAudioTracksChange", (val) => this.trigger("availableAudioTracksChange", val));
2250
+ mediaElementTracksStore.addEventListener("availableTextTracksChange", (val) => this.trigger("availableTextTracksChange", val));
2251
+ mediaElementTracksStore.addEventListener("audioTrackChange", (val) => this.trigger("audioTrackChange", val));
2252
+ mediaElementTracksStore.addEventListener("videoTrackChange", (val) => this.trigger("videoTrackChange", val));
2253
+ mediaElementTracksStore.addEventListener("textTrackChange", (val) => this.trigger("textTrackChange", val));
2254
+ return mediaElementTracksStore;
2255
+ }
2256
+ _priv_callTracksStoreGetterSetter(periodId, defaultValue, cb) {
2257
+ var _a, _b;
2258
+ if (this._priv_contentInfos === null ||
2259
+ this._priv_contentInfos.tracksStore === null) {
2260
+ log.warn("API: Trying to call track API too soon");
2261
+ return defaultValue;
2262
+ }
2263
+ const { tracksStore } = this._priv_contentInfos;
2264
+ const currentPeriod = (_b = (_a = this._priv_contentInfos) === null || _a === void 0 ? void 0 : _a.currentPeriod) !== null && _b !== void 0 ? _b : undefined;
2265
+ const wantedPeriodId = periodId !== null && periodId !== void 0 ? periodId : currentPeriod === null || currentPeriod === void 0 ? void 0 : currentPeriod.id;
2266
+ if (wantedPeriodId === undefined) {
2267
+ return defaultValue;
2268
+ }
2269
+ const periodRef = wantedPeriodId === (currentPeriod === null || currentPeriod === void 0 ? void 0 : currentPeriod.id)
2270
+ ? tracksStore.getPeriodObjectFromPeriod(currentPeriod)
2271
+ : tracksStore.getPeriodObjectFromId(wantedPeriodId);
2272
+ if (periodRef === undefined) {
2273
+ return defaultValue;
2274
+ }
2275
+ return cb(tracksStore, periodRef);
2276
+ }
2277
+ /**
2278
+ * Method to call when some event lead to a high for possibility that the
2279
+ * available tracks for the given type have changed.
2280
+ * Send the corresponding `available*Tracks` change event with the last
2281
+ * available tracks.
2282
+ *
2283
+ * @param {string} trackType
2284
+ * @param {Object|undefined} [oPeriodRef] - optional period object used by the
2285
+ * `tracksStore` API, allows to optimize the method by bypassing this step.
2286
+ */
2287
+ _priv_onAvailableTracksMayHaveChanged(trackType, oPeriodRef) {
2288
+ const contentInfos = this._priv_contentInfos;
2289
+ if (contentInfos === null) {
2290
+ return;
2291
+ }
2292
+ const { currentPeriod, tracksStore, currentContentCanceller } = contentInfos;
2293
+ const cancelSignal = currentContentCanceller.signal;
2294
+ if (isNullOrUndefined(currentPeriod) || tracksStore === null) {
2295
+ return;
2296
+ }
2297
+ const periodRef = oPeriodRef !== null && oPeriodRef !== void 0 ? oPeriodRef : tracksStore.getPeriodObjectFromPeriod(currentPeriod);
2298
+ if (periodRef === undefined) {
2299
+ return;
2300
+ }
2301
+ switch (trackType) {
2302
+ case "video":
2303
+ const videoTracks = tracksStore.getAvailableVideoTracks(periodRef);
2304
+ this._priv_triggerEventIfNotStopped("availableVideoTracksChange", videoTracks !== null && videoTracks !== void 0 ? videoTracks : [], cancelSignal);
2305
+ break;
2306
+ case "audio":
2307
+ const audioTracks = tracksStore.getAvailableAudioTracks(periodRef);
2308
+ this._priv_triggerEventIfNotStopped("availableAudioTracksChange", audioTracks !== null && audioTracks !== void 0 ? audioTracks : [], cancelSignal);
2309
+ break;
2310
+ case "text":
2311
+ const textTracks = tracksStore.getAvailableTextTracks(periodRef);
2312
+ this._priv_triggerEventIfNotStopped("availableTextTracksChange", textTracks !== null && textTracks !== void 0 ? textTracks : [], cancelSignal);
2313
+ break;
2314
+ default:
2315
+ assertUnreachable(trackType);
2316
+ }
2317
+ }
2318
+ /**
2319
+ * Method to call when a fatal error lead to the stopping of the current
2320
+ * content.
2321
+ *
2322
+ * @param {*} err - The error encountered.
2323
+ * @param {Object} contentInfos - The `IPublicApiContentInfos` object linked
2324
+ * to the content for which the error was received.
2325
+ */
2326
+ _priv_onFatalError(err, contentInfos) {
2327
+ const formattedError = formatError(err, {
2328
+ defaultCode: "NONE",
2329
+ defaultReason: "An unknown error stopped content playback.",
2330
+ });
2331
+ formattedError.fatal = true;
2332
+ contentInfos.currentContentCanceller.cancel();
2333
+ this._priv_cleanUpCurrentContentState();
2334
+ this._priv_currentError = formattedError;
2335
+ log.error("API: The player stopped because of an error", formattedError);
2336
+ this._priv_setPlayerState("STOPPED" /* PLAYER_STATES.STOPPED */);
2337
+ // TODO This condition is here because the eventual callback called when the
2338
+ // player state is updated can launch a new content, thus the error will not
2339
+ // be here anymore, in which case triggering the "error" event is unwanted.
2340
+ // This is very ugly though, and we should probable have a better solution
2341
+ if (this._priv_currentError === formattedError) {
2342
+ this.trigger("error", formattedError);
2343
+ }
2344
+ }
2345
+ }
2346
+ Player.version = /* PLAYER_VERSION */ "4.0.0-rc.2";
2347
+ export default Player;