@bitmovin/player-web-x 10.0.0-beta.10

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 (255) hide show
  1. package/COMPAT.md +201 -0
  2. package/README.md +196 -0
  3. package/bundles/playerx-bitmovin-v8-core.d.ts +1 -0
  4. package/bundles/playerx-bitmovin-v8-core.js +10 -0
  5. package/bundles/playerx-bitmovin-v8.d.ts +1 -0
  6. package/bundles/playerx-bitmovin-v8.js +10 -0
  7. package/bundles/playerx-core.d.ts +1 -0
  8. package/bundles/playerx-core.js +10 -0
  9. package/bundles/playerx-dash.d.ts +1 -0
  10. package/bundles/playerx-dash.js +10 -0
  11. package/bundles/playerx-hls.d.ts +1 -0
  12. package/bundles/playerx-hls.js +10 -0
  13. package/bundles/playerx-playlist.d.ts +1 -0
  14. package/bundles/playerx-playlist.js +10 -0
  15. package/bundles/playerx-tv.d.ts +1 -0
  16. package/bundles/playerx-tv.js +10 -0
  17. package/framework-types/BaseTypes.d.ts +15 -0
  18. package/framework-types/Types.d.ts +11 -0
  19. package/framework-types/abortable/Abortable.d.ts +29 -0
  20. package/framework-types/abortable/Types.d.ts +10 -0
  21. package/framework-types/api-manager/ApiManager.d.ts +10 -0
  22. package/framework-types/api-manager/Errors.d.ts +5 -0
  23. package/framework-types/data-structures/MapWithDefault.d.ts +3 -0
  24. package/framework-types/data-structures/Types.d.ts +3 -0
  25. package/framework-types/effect/EffectFactory.d.ts +4 -0
  26. package/framework-types/effect/Types.d.ts +7 -0
  27. package/framework-types/effects/AbortableEffect.d.ts +4 -0
  28. package/framework-types/effects/LoopEffect.d.ts +3 -0
  29. package/framework-types/effects/TimeoutEffect.d.ts +4 -0
  30. package/framework-types/error/FrameworkDisposedError.d.ts +5 -0
  31. package/framework-types/error/FrameworkError.d.ts +4 -0
  32. package/framework-types/event-bus/EventBus.d.ts +11 -0
  33. package/framework-types/execution-context/ExecutionContext.d.ts +25 -0
  34. package/framework-types/execution-context/Types.d.ts +11 -0
  35. package/framework-types/framework.d.ts +7 -0
  36. package/framework-types/index.d.ts +1 -0
  37. package/framework-types/package-api/Package.d.ts +10 -0
  38. package/framework-types/package-api/PackageApi.d.ts +11 -0
  39. package/framework-types/package-api/PackageApiUtils.d.ts +7 -0
  40. package/framework-types/polyfills/AbortController.d.ts +1 -0
  41. package/framework-types/polyfills/FlatMap.d.ts +1 -0
  42. package/framework-types/polyfills/Polyfills.d.ts +1 -0
  43. package/framework-types/registry/Registry.d.ts +44 -0
  44. package/framework-types/registry/RegistryInterface.d.ts +9 -0
  45. package/framework-types/task/Task.d.ts +4 -0
  46. package/framework-types/task/TaskUtils.d.ts +3 -0
  47. package/framework-types/task/Types.d.ts +13 -0
  48. package/framework-types/thread/Thread.d.ts +45 -0
  49. package/framework-types/thread/ThreadEventBus.d.ts +22 -0
  50. package/framework-types/utils/Deferred.d.ts +8 -0
  51. package/framework-types/utils/StringUtils.d.ts +1 -0
  52. package/framework-types/utils/debug/thread/ThreadDecorator.d.ts +2 -0
  53. package/package.json +31 -0
  54. package/packages/playerx-adaptation.package.d.ts +1 -0
  55. package/packages/playerx-adaptation.package.js +10 -0
  56. package/packages/playerx-bitmovin-source-api.package.d.ts +1 -0
  57. package/packages/playerx-bitmovin-source-api.package.js +10 -0
  58. package/packages/playerx-bitmovin-ui.package.d.ts +1 -0
  59. package/packages/playerx-bitmovin-ui.package.js +10 -0
  60. package/packages/playerx-bitmovin-v8-core.package.d.ts +1 -0
  61. package/packages/playerx-bitmovin-v8-core.package.js +10 -0
  62. package/packages/playerx-bitmovin-v8-static-api.package.d.ts +1 -0
  63. package/packages/playerx-bitmovin-v8-static-api.package.js +10 -0
  64. package/packages/playerx-bitmovin-video-element-utils.package.d.ts +1 -0
  65. package/packages/playerx-bitmovin-video-element-utils.package.js +10 -0
  66. package/packages/playerx-capabilities.package.d.ts +1 -0
  67. package/packages/playerx-capabilities.package.js +10 -0
  68. package/packages/playerx-container-mp4.package.d.ts +1 -0
  69. package/packages/playerx-container-mp4.package.js +10 -0
  70. package/packages/playerx-container-ts.package.d.ts +1 -0
  71. package/packages/playerx-container-ts.package.js +10 -0
  72. package/packages/playerx-core.package.d.ts +1 -0
  73. package/packages/playerx-core.package.js +10 -0
  74. package/packages/playerx-dash-parsing.package.d.ts +1 -0
  75. package/packages/playerx-dash-parsing.package.js +10 -0
  76. package/packages/playerx-dash-translation.package.d.ts +1 -0
  77. package/packages/playerx-dash-translation.package.js +10 -0
  78. package/packages/playerx-dash.package.d.ts +1 -0
  79. package/packages/playerx-dash.package.js +10 -0
  80. package/packages/playerx-data.package.d.ts +1 -0
  81. package/packages/playerx-data.package.js +10 -0
  82. package/packages/playerx-hls-parsing.package.d.ts +1 -0
  83. package/packages/playerx-hls-parsing.package.js +10 -0
  84. package/packages/playerx-hls-translation.package.d.ts +1 -0
  85. package/packages/playerx-hls-translation.package.js +10 -0
  86. package/packages/playerx-hls.package.d.ts +1 -0
  87. package/packages/playerx-hls.package.js +10 -0
  88. package/packages/playerx-network.package.d.ts +1 -0
  89. package/packages/playerx-network.package.js +10 -0
  90. package/packages/playerx-playback-state.package.d.ts +1 -0
  91. package/packages/playerx-playback-state.package.js +10 -0
  92. package/packages/playerx-playlist.package.d.ts +1 -0
  93. package/packages/playerx-playlist.package.js +10 -0
  94. package/packages/playerx-presentation.package.d.ts +1 -0
  95. package/packages/playerx-presentation.package.js +10 -0
  96. package/packages/playerx-resize-tracker.package.d.ts +1 -0
  97. package/packages/playerx-resize-tracker.package.js +10 -0
  98. package/packages/playerx-segment-processing.package.d.ts +1 -0
  99. package/packages/playerx-segment-processing.package.js +10 -0
  100. package/packages/playerx-source-api.package.d.ts +1 -0
  101. package/packages/playerx-source-api.package.js +10 -0
  102. package/packages/playerx-source.package.d.ts +1 -0
  103. package/packages/playerx-source.package.js +10 -0
  104. package/packages/playerx-sources-api.package.d.ts +1 -0
  105. package/packages/playerx-sources-api.package.js +10 -0
  106. package/packages/playerx-trick-play.package.d.ts +1 -0
  107. package/packages/playerx-trick-play.package.js +10 -0
  108. package/packages/playerx-ts-transmuxer.package.d.ts +1 -0
  109. package/packages/playerx-ts-transmuxer.package.js +10 -0
  110. package/packages/playerx-tv.package.d.ts +1 -0
  111. package/packages/playerx-tv.package.js +10 -0
  112. package/playerx-framework-utils.d.ts +1 -0
  113. package/playerx-framework-utils.js +10 -0
  114. package/types/BaseTypes.d.ts +19 -0
  115. package/types/bundles/BitmovinV8.bundle.d.ts +45 -0
  116. package/types/bundles/BitmovinV8Core.bundle.d.ts +27 -0
  117. package/types/bundles/Core.bundle.d.ts +18 -0
  118. package/types/bundles/Dash.bundle.d.ts +36 -0
  119. package/types/bundles/Hls.bundle.d.ts +38 -0
  120. package/types/bundles/Playlist.bundle.d.ts +16 -0
  121. package/types/bundles/Tv.bundle.d.ts +33 -0
  122. package/types/bundles/Types.d.ts +13 -0
  123. package/types/framework/FrameworkUtils.d.ts +3 -0
  124. package/types/framework/Types.d.ts +46 -0
  125. package/types/framework/core/Types.d.ts +8 -0
  126. package/types/framework/core/adaptation/Adaptation.package.d.ts +102 -0
  127. package/types/framework/core/adaptation/AdaptationStateAtom.d.ts +36 -0
  128. package/types/framework/core/adaptation/RingBufferAtom.d.ts +16 -0
  129. package/types/framework/core/adaptation/WishConfigAtom.d.ts +43 -0
  130. package/types/framework/core/adaptation/WishDataAtom.d.ts +14 -0
  131. package/types/framework/core/capabilities/Capabilities.package.d.ts +39 -0
  132. package/types/framework/core/capabilities/Types.d.ts +9 -0
  133. package/types/framework/core/container/container-mp4/ContainerMp4.package.d.ts +52 -0
  134. package/types/framework/core/container/container-ts/ContainerTs.package.d.ts +49 -0
  135. package/types/framework/core/container/ts-transmuxer/TsTransmuxer.package.d.ts +50 -0
  136. package/types/framework/core/core/Constants.d.ts +21 -0
  137. package/types/framework/core/core/Core.package.d.ts +144 -0
  138. package/types/framework/core/core/FrameworkError.d.ts +4 -0
  139. package/types/framework/core/core/effects/EventListenerEffectFactory.d.ts +28 -0
  140. package/types/framework/core/core/metrics/MetricsAtom.d.ts +19 -0
  141. package/types/framework/core/core/metrics/network/NetworkSampleAtom.d.ts +30 -0
  142. package/types/framework/core/core/network/NetworkAtom.d.ts +21 -0
  143. package/types/framework/core/core/state/ArrayStateAtom.d.ts +21 -0
  144. package/types/framework/core/core/state/MapStateAtom.d.ts +8 -0
  145. package/types/framework/core/core/state/PrimitiveAtom.d.ts +9 -0
  146. package/types/framework/core/core/state/StoreEffectFactory.d.ts +5 -0
  147. package/types/framework/core/core/state/Symbols.d.ts +2 -0
  148. package/types/framework/core/core/state/Types.d.ts +26 -0
  149. package/types/framework/core/core/state/codec-map/CodecMapAtom.d.ts +15 -0
  150. package/types/framework/core/core/state/data-ranges/DataRangesAtom.d.ts +30 -0
  151. package/types/framework/core/core/state/data-stream/DataStreamAtom.d.ts +27 -0
  152. package/types/framework/core/core/state/segment/SegmentAtom.d.ts +74 -0
  153. package/types/framework/core/core/state/segment/SegmentDataAtom.d.ts +32 -0
  154. package/types/framework/core/core/state/segment/SegmentTimingAtom.d.ts +20 -0
  155. package/types/framework/core/core/state/segment/SegmentTypeGuards.d.ts +4 -0
  156. package/types/framework/core/core/state/segment/SegmentUtils.d.ts +10 -0
  157. package/types/framework/core/core/state/selection-group/SelectionGroupAtom.d.ts +68 -0
  158. package/types/framework/core/core/state/selection-group/SelectionGroupTypeGuards.d.ts +4 -0
  159. package/types/framework/core/core/state/selection-group/SelectionGroupUtils.d.ts +7 -0
  160. package/types/framework/core/core/state/state-effect/StateEffectFactory.d.ts +26 -0
  161. package/types/framework/core/core/state/state-effect/Types.d.ts +8 -0
  162. package/types/framework/core/core/state/stream/StreamAtom.d.ts +64 -0
  163. package/types/framework/core/core/state/stream-timeline/StreamSectionAtom.d.ts +21 -0
  164. package/types/framework/core/core/state/stream-timeline/StreamSequenceMapAtom.d.ts +7 -0
  165. package/types/framework/core/core/state/stream-timeline/StreamTimelineMapAtom.d.ts +5 -0
  166. package/types/framework/core/core/state/track/TrackAtom.d.ts +81 -0
  167. package/types/framework/core/core/state/track/TrackTypeGuards.d.ts +5 -0
  168. package/types/framework/core/core/utils/ArrayHelper.d.ts +24 -0
  169. package/types/framework/core/core/utils/CodecStringHelper.d.ts +47 -0
  170. package/types/framework/core/core/utils/FormatError.d.ts +5 -0
  171. package/types/framework/core/core/utils/Logger.d.ts +40 -0
  172. package/types/framework/core/core/utils/RangesHelper.d.ts +20 -0
  173. package/types/framework/core/core/utils/StateUtils.d.ts +39 -0
  174. package/types/framework/core/core/utils/StringHelper.d.ts +13 -0
  175. package/types/framework/core/core/utils/TypedArrayHelper.d.ts +5 -0
  176. package/types/framework/core/core/utils/Types.d.ts +20 -0
  177. package/types/framework/core/core/utils/UrlHelper.d.ts +15 -0
  178. package/types/framework/core/data/Data.package.d.ts +124 -0
  179. package/types/framework/core/manifest/dash/parsing/DashParsing.package.d.ts +34 -0
  180. package/types/framework/core/manifest/dash/parsing/DashParsingTask.d.ts +2 -0
  181. package/types/framework/core/manifest/dash/parsing/Errors.d.ts +4 -0
  182. package/types/framework/core/manifest/dash/parsing/Types.d.ts +8 -0
  183. package/types/framework/core/manifest/dash/root/Dash.package.d.ts +119 -0
  184. package/types/framework/core/manifest/dash/root/ManifestLoadTask.d.ts +3 -0
  185. package/types/framework/core/manifest/dash/root/Types.d.ts +3 -0
  186. package/types/framework/core/manifest/dash/translation/DashTranslation.package.d.ts +48 -0
  187. package/types/framework/core/manifest/dash/translation/Types.d.ts +3 -0
  188. package/types/framework/core/manifest/dash/translation/manifests/DashPlaylistTranslatorTask.d.ts +3 -0
  189. package/types/framework/core/manifest/hls/parsing/Errors.d.ts +7 -0
  190. package/types/framework/core/manifest/hls/parsing/HlsParsing.package.d.ts +38 -0
  191. package/types/framework/core/manifest/hls/parsing/HlsParsingFunctions.d.ts +16 -0
  192. package/types/framework/core/manifest/hls/parsing/HlsParsingTask.d.ts +2 -0
  193. package/types/framework/core/manifest/hls/parsing/Types.d.ts +272 -0
  194. package/types/framework/core/manifest/hls/parsing/m3u8/AbstractStream.d.ts +9 -0
  195. package/types/framework/core/manifest/hls/parsing/m3u8/DefaultTagParsers.d.ts +6 -0
  196. package/types/framework/core/manifest/hls/parsing/m3u8/TranslatorStream.d.ts +59 -0
  197. package/types/framework/core/manifest/hls/root/Hls.package.d.ts +128 -0
  198. package/types/framework/core/manifest/hls/root/ManifestLoadTask.d.ts +3 -0
  199. package/types/framework/core/manifest/hls/root/Types.d.ts +3 -0
  200. package/types/framework/core/manifest/hls/translation/HlsTranslation.package.d.ts +51 -0
  201. package/types/framework/core/manifest/hls/translation/Types.d.ts +14 -0
  202. package/types/framework/core/manifest/hls/translation/manifests/HlsMultivariantPlaylistTranslatorTask.d.ts +4 -0
  203. package/types/framework/core/manifest/hls/translation/manifests/HlsVariantTranslationTask.d.ts +11 -0
  204. package/types/framework/core/network/FetchTask.d.ts +5 -0
  205. package/types/framework/core/network/Network.package.d.ts +79 -0
  206. package/types/framework/core/network/NetworkMessageTypes.d.ts +44 -0
  207. package/types/framework/core/network/NetworkTask.d.ts +12 -0
  208. package/types/framework/core/network/Types.d.ts +70 -0
  209. package/types/framework/core/presentation/Presentation.package.d.ts +122 -0
  210. package/types/framework/core/segment-processing/Errors.d.ts +8 -0
  211. package/types/framework/core/segment-processing/SegmentProcessing.package.d.ts +31 -0
  212. package/types/framework/core/segment-processing/SegmentProcessingComponent.d.ts +2 -0
  213. package/types/framework/core/segment-processing/Types.d.ts +95 -0
  214. package/types/framework/core/source/Source.package.d.ts +108 -0
  215. package/types/framework/core/source/SourceThread.d.ts +2 -0
  216. package/types/framework/core/source/atoms/BufferConfigAtom.d.ts +24 -0
  217. package/types/framework/core/source/atoms/MediaTypeMapAtom.d.ts +14 -0
  218. package/types/framework/core/source/atoms/PlaybackAtom.d.ts +17 -0
  219. package/types/framework/core/source/atoms/PlayheadAtom.d.ts +16 -0
  220. package/types/framework/core/source/atoms/SourceStateAtom.d.ts +47 -0
  221. package/types/framework/core/source/atoms/StartupOptionsAtom.d.ts +17 -0
  222. package/types/framework/core/source/atoms/VideoElementAtom.d.ts +12 -0
  223. package/types/framework/core/source-api/SourceApi.package.d.ts +56 -0
  224. package/types/framework/core/source-api/Types.d.ts +8 -0
  225. package/types/framework/core/sources-api/PlaybackApi.d.ts +9 -0
  226. package/types/framework/core/sources-api/SourcesApi.package.d.ts +67 -0
  227. package/types/framework/core/sources-api/Types.d.ts +17 -0
  228. package/types/framework/core/sources-api/VideoElementUtils.d.ts +8 -0
  229. package/types/framework/core/trick-play/TrickPlay.package.d.ts +71 -0
  230. package/types/framework/player/bitmovin-v8-compat/BitmovinUi.package.d.ts +27 -0
  231. package/types/framework/player/bitmovin-v8-compat/BitmovinV8Core.package.d.ts +28 -0
  232. package/types/framework/player/bitmovin-v8-compat/BitmovinV8StaticApi.package.d.ts +54 -0
  233. package/types/framework/player/bitmovin-v8-compat/apis/BufferApi.d.ts +4 -0
  234. package/types/framework/player/bitmovin-v8-compat/apis/DrmApi.d.ts +3 -0
  235. package/types/framework/player/bitmovin-v8-compat/apis/ManifestApi.d.ts +4 -0
  236. package/types/framework/player/bitmovin-v8-compat/apis/SubtitleApi.d.ts +9 -0
  237. package/types/framework/player/bitmovin-v8-compat/enums/PlayerExports.d.ts +384 -0
  238. package/types/framework/player/bitmovin-v8-compat/event-handling/EventListenerAtom.d.ts +16 -0
  239. package/types/framework/player/bitmovin-v8-compat/source-api/BitmovinSourceApi.package.d.ts +83 -0
  240. package/types/framework/player/bitmovin-v8-compat/types/AdvertisingConfig.d.ts +87 -0
  241. package/types/framework/player/bitmovin-v8-compat/types/DrmConfig.d.ts +90 -0
  242. package/types/framework/player/bitmovin-v8-compat/types/NetworkConfig.d.ts +58 -0
  243. package/types/framework/player/bitmovin-v8-compat/types/PlayerConfig.d.ts +419 -0
  244. package/types/framework/player/bitmovin-v8-compat/types/Types.d.ts +191 -0
  245. package/types/framework/player/bitmovin-v8-compat/video-element/BitmovinVideoElementUtils.package.d.ts +42 -0
  246. package/types/framework/player/playback-state/PlaybackState.package.d.ts +72 -0
  247. package/types/framework/player/playback-state/PlaybackStateAtom.d.ts +40 -0
  248. package/types/framework/player/playback-state/Types.d.ts +7 -0
  249. package/types/framework/player/playback-state/VideoElementStateAtom.d.ts +9 -0
  250. package/types/framework/player/playlist/Playlist.package.d.ts +63 -0
  251. package/types/framework/player/resize-tracker/ResizeObserverEffectFactory.d.ts +11 -0
  252. package/types/framework/player/resize-tracker/ResizeTracker.package.d.ts +73 -0
  253. package/types/framework/player/resize-tracker/ResizeTrackerStateAtom.d.ts +9 -0
  254. package/types/framework/player/resize-tracker/VideoElementStateAtom.d.ts +9 -0
  255. package/types/framework/player/tv/Tv.package.d.ts +59 -0
package/COMPAT.md ADDED
@@ -0,0 +1,201 @@
1
+ # Compatibility with v8
2
+
3
+ PWX is not natively compatible with v8, as it is a new design. However, the package system is powerful enough to allow us to write a compatibility layer, so that is what we have done.
4
+
5
+ Here are some examples of usage:
6
+
7
+
8
+ ## Easy mode
9
+
10
+ Just include the compatibility bundle:
11
+
12
+ ```html
13
+ <!DOCTYPE html>
14
+ <html lang="en">
15
+ <head>
16
+ <title>Bitmovin Player Demo</title>
17
+ <meta charset="UTF-8"/>
18
+ <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
19
+ <meta name="viewport" content="width=device-width, initial-scale=1.0">
20
+
21
+ <!-- Bitmovin Player X with v8 compatibility packages -->
22
+ <script type="text/javascript" src="./sdk/bundles/playerx-bitmovin-v8.js"></script>
23
+
24
+ <style>
25
+ .container {
26
+ color: white;
27
+ text-align: center;
28
+ max-width: 2200px;
29
+ }
30
+ .container a {
31
+ color: white;
32
+ }
33
+ .container h1 {
34
+ margin-bottom: 22px;
35
+ line-height: 66px;
36
+ }
37
+ .container h2 {
38
+ font-weight: normal;
39
+ margin-bottom: 36px;
40
+ line-height: 26px;
41
+ }
42
+ .player-wrapper {
43
+ width: 95%;
44
+ max-height: 95%;
45
+ margin: 20px auto;
46
+ box-shadow: 0 0 30px rgba(0,0,0,0.7);
47
+ }
48
+ </style>
49
+ </head>
50
+ <body>
51
+ <div class="container">
52
+ <div class="content">
53
+ <div class="player-wrapper">
54
+ <div id="player"></div>
55
+ </div>
56
+ </div>
57
+ </div>
58
+ <script type="text/javascript">
59
+
60
+ // This part is just like with the Bitmovin Player v8 :)
61
+
62
+ const conf = {
63
+ key: '<YOUR PLAYER KEY>',
64
+ playback: { autoplay: true, muted: true },
65
+ logs: { level: 'debug' },
66
+ events: {},
67
+ location: {
68
+ ui: 'https://cdn.bitmovin.com/player/web/8/bitmovinplayer-ui.js',
69
+ ui_css: 'https://cdn.bitmovin.com/player/web/8/bitmovinplayer-ui.css',
70
+ },
71
+ };
72
+
73
+ const source = {
74
+ hls: 'https://cdn.bitmovin.com/content/assets/streams-sample-video/sintel/m3u8/index.m3u8',
75
+ };
76
+
77
+ const player = new bitmovin.player.Player(document.getElementById('player'), conf);
78
+
79
+
80
+ player.load(source);
81
+ </script>
82
+ </body>
83
+ </html>
84
+ ```
85
+
86
+ ## Package mode
87
+
88
+ In this version, you can see we include the individual packages:
89
+
90
+ ```html
91
+ <!DOCTYPE html>
92
+ <html lang="en">
93
+ <head>
94
+ <title>Bitmovin Player Demo</title>
95
+ <meta charset="UTF-8"/>
96
+ <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
97
+ <meta name="viewport" content="width=device-width, initial-scale=1.0">
98
+
99
+ <!-- Bitmovin Player X with v8 compatibility packages -->
100
+ <script type="text/javascript" src="./sdk/bundles/playerx-bitmovin-v8-core.js"></script>
101
+ <script type="text/javascript" src="./sdk/packages/playerx-data.package.js"></script>
102
+ <script type="text/javascript" src="./sdk/packages/playerx-capabilities.package.js"></script>
103
+ <script type="text/javascript" src="./sdk/packages/playerx-hls.package.js"></script>
104
+ <script type="text/javascript" src="./sdk/packages/playerx-hls-translation.package.js"></script>
105
+ <script type="text/javascript" src="./sdk/packages/playerx-hls-parsing.package.js"></script>
106
+ <script type="text/javascript" src="./sdk/packages/playerx-network.package.js"></script>
107
+ <script type="text/javascript" src="./sdk/packages/playerx-presentation.package.js"></script>
108
+ <script type="text/javascript" src="./sdk/packages/playerx-source.package.js"></script>
109
+ <script type="text/javascript" src="./sdk/packages/playerx-source-api.package.js"></script>
110
+ <script type="text/javascript" src="./sdk/packages/playerx-bitmovin-source-api.package.js"></script>
111
+ <script type="text/javascript" src="./sdk/packages/playerx-bitmovin-v8-static-api.package.js"></script>
112
+ <script type="text/javascript" src="./sdk/packages/playerx-bitmovin-ui.package.js"></script>
113
+ <script type="text/javascript" src="./sdk/packages/playerx-bitmovin-video-element-utils.package.js"></script>
114
+ <script type="text/javascript" src="./sdk/packages/playerx-adaptation.package.js"></script>
115
+ <script type="text/javascript" src="./sdk/packages/playerx-container-mp4.package.js"></script>
116
+ <script type="text/javascript" src="./sdk/packages/playerx-segment-processing.package.js"></script>
117
+
118
+
119
+ <style>
120
+ .container {
121
+ color: white;
122
+ text-align: center;
123
+ max-width: 2200px;
124
+ }
125
+ .container a {
126
+ color: white;
127
+ }
128
+ .container h1 {
129
+ margin-bottom: 22px;
130
+ line-height: 66px;
131
+ }
132
+ .container h2 {
133
+ font-weight: normal;
134
+ margin-bottom: 36px;
135
+ line-height: 26px;
136
+ }
137
+ .player-wrapper {
138
+ width: 95%;
139
+ max-height: 95%;
140
+ margin: 20px auto;
141
+ box-shadow: 0 0 30px rgba(0,0,0,0.7);
142
+ }
143
+ </style>
144
+ </head>
145
+ <body>
146
+ <div class="container">
147
+ <div class="content">
148
+ <div class="player-wrapper">
149
+ <div id="player"></div>
150
+ </div>
151
+ </div>
152
+ </div>
153
+ <script type="text/javascript">
154
+
155
+ // Once again, just like with v8
156
+
157
+ const conf = {
158
+ key: '<YOUR PLAYER KEY>',
159
+ playback: { autoplay: true, muted: true },
160
+ logs: { level: 'debug' },
161
+ events: {},
162
+ location: {
163
+ ui: 'https://cdn.bitmovin.com/player/web/8/bitmovinplayer-ui.js',
164
+ ui_css: 'https://cdn.bitmovin.com/player/web/8/bitmovinplayer-ui.css',
165
+ },
166
+ };
167
+
168
+ const source = {
169
+ hls: 'https://cdn.bitmovin.com/content/assets/streams-sample-video/sintel/m3u8/index.m3u8',
170
+ };
171
+
172
+ const player = new bitmovin.player.Player(document.getElementById('player'), conf);
173
+
174
+ // Slightly different: once the player is instantiated, we can add the packages.
175
+
176
+ player.packages.add(bitmovin.playerx['data'].default);
177
+ player.packages.add(bitmovin.playerx['capabilities'].default);
178
+ player.packages.add(bitmovin.playerx['segment-processing'].default);
179
+ player.packages.add(bitmovin.playerx['container-mp4'].default);
180
+ player.packages.add(bitmovin.playerx['adaptation'].default);
181
+ player.packages.add(bitmovin.playerx['network'].default);
182
+ player.packages.add(bitmovin.playerx['hls'].default);
183
+ player.packages.add(bitmovin.playerx['hls-translation'].default);
184
+ player.packages.add(bitmovin.playerx['hls-parsing'].default);
185
+ player.packages.add(bitmovin.playerx['presentation'].default);
186
+ player.packages.add(bitmovin.playerx['source'].default);
187
+ player.packages.add(bitmovin.playerx['bitmovin-video-element-utils'].default);
188
+ player.packages.add(bitmovin.playerx['source-api'].default);
189
+ player.packages.add(bitmovin.playerx['bitmovin-v8-static-api'].default);
190
+ player.packages.add(bitmovin.playerx['bitmovin-source-api'].default);
191
+ player.packages.add(bitmovin.playerx['bitmovin-ui'].default); // Note the addition of the ui compatibility layer
192
+
193
+ // Load a source as usual
194
+ player.load(source);
195
+ </script>
196
+ </body>
197
+ </html>
198
+ ```
199
+
200
+
201
+ That's all there is to it!
package/README.md ADDED
@@ -0,0 +1,196 @@
1
+ # player-web-x
2
+
3
+ The next-gen Bitmovin web player.
4
+
5
+ Welcome to the future!
6
+
7
+ This package is several things.
8
+
9
+ The first thing is simply a web streaming video player. Currently, this player can play HLS streams using the fMP4 segment format.
10
+
11
+ If that's what you need, you are in luck, as it's a high performance player. So let's dive into how to implement it in your web application or page.
12
+
13
+ You will need a Bitmovin player account, you can sign up for either Player or Streams here: https://dashboard.bitmovin.com/signup. If you just want to kick the tyres, don't worry, we offer a fully featured trial account, no credit card needed.
14
+
15
+ Once you have a licence key, all you need to do is to include the player in your web application, and run it:
16
+
17
+ ### Simple Usage Example
18
+
19
+ This is an example of the HTML that would be required to run the player in a page as a monolith. This leverages our build system to compile together multiple packages into one loadable file.
20
+
21
+ Once the file is loaded, the player is available on the namespace `bitmovin.playerx.Player` and can be instantiated by passing a config to the constructor function.
22
+
23
+ This returns an object which exposes the api through which playback can be controlled.
24
+
25
+ ```html
26
+ <!DOCTYPE html>
27
+ <html lang="en">
28
+ <head>
29
+ <title>Bitmovin Player Web X Demo</title>
30
+ <script type="text/javascript" src="./bundles/playerx-hls.js"></script>
31
+ <style>
32
+ #player-container {
33
+ width: 95%;
34
+ margin: 20px auto;
35
+ }
36
+ video {
37
+ display: block;
38
+ }
39
+ </style>
40
+ </head>
41
+ <body>
42
+ <div id="player-container"></div>
43
+
44
+ <script type="text/javascript">
45
+ const player = bitmovin.playerx.Player({
46
+ key: 'YOUR-PLAYER-KEY',
47
+ });
48
+
49
+ const source = player.sources.add('https://cdn.bitmovin.com/content/assets/streams-sample-video/tos/m3u8/index.m3u8');
50
+ </script>
51
+ </body>
52
+ </html>
53
+ ```
54
+
55
+ The following example, by contrast, loads the packages one by one, effectively building a player out of its constituent parts. This would allow you to build targeted players for streams with different formats or features for example, while remaining as lightweight as possible.
56
+
57
+ All our packages are connected to the `bitmovin.playerx` namespace here, but that is a configuration choice. Third-party package authors can use different namespaces without a problem.
58
+
59
+ ### Package Example
60
+ ```html
61
+ <!DOCTYPE html>
62
+ <html lang="en">
63
+ <head>
64
+ <title>Bitmovin Player Web X Demo</title>
65
+ <meta charset="UTF-8"/>
66
+ <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
67
+ <meta name="viewport" content="width=device-width, initial-scale=1.0">
68
+ <script type="text/javascript" src="./bundles/playerx-core.js"></script>
69
+ <script type="text/javascript" src="./packages/playerx-capabilities.package.js"></script>
70
+ <script type="text/javascript" src="./packages/playerx-segment-processing.package.js"></script>
71
+ <script type="text/javascript" src="./packages/playerx-container-mp4.package.js"></script>
72
+ <script type="text/javascript" src="./packages/playerx-data.package.js"></script>
73
+ <script type="text/javascript" src="./packages/playerx-network.package.js"></script>
74
+ <script type="text/javascript" src="./packages/playerx-hls-translation.package.js"></script>
75
+ <script type="text/javascript" src="./packages/playerx-hls-parsing.package.js"></script>
76
+ <script type="text/javascript" src="./packages/playerx-hls.package.js"></script>
77
+ <script type="text/javascript" src="./packages/playerx-presentation.package.js"></script>
78
+ <script type="text/javascript" src="./packages/playerx-source.package.js"></script>
79
+ <script type="text/javascript" src="./packages/playerx-sources-api.package.js"></script>
80
+ <script type="text/javascript" src="./packages/playerx-adaptation.package.js"></script>
81
+
82
+ <style>
83
+ #player-container {
84
+ width: 95%;
85
+ margin: 20px auto;
86
+ box-shadow: 0 0 30px rgba(0, 0, 0, 0.7);
87
+ }
88
+ video {
89
+ display: block;
90
+ }
91
+ </style>
92
+ </head>
93
+ <body>
94
+ <div id="player-container"></div>
95
+ <script type="text/javascript">
96
+ const player = bitmovin.playerx.Player({
97
+ key: 'YOUR-PLAYER-KEY',
98
+ });
99
+
100
+ player.packages.add(bitmovin.playerx['capabilities'].default);
101
+ player.packages.add(bitmovin.playerx['segment-processing'].default);
102
+ player.packages.add(bitmovin.playerx['container-mp4'].default);
103
+ player.packages.add(bitmovin.playerx['data'].default);
104
+ player.packages.add(bitmovin.playerx['network'].default);
105
+ player.packages.add(bitmovin.playerx['hls-translation'].default);
106
+ player.packages.add(bitmovin.playerx['hls-parsing'].default);
107
+ player.packages.add(bitmovin.playerx['hls'].default);
108
+ player.packages.add(bitmovin.playerx['presentation'].default);
109
+ player.packages.add(bitmovin.playerx['source'].default);
110
+ player.packages.add(bitmovin.playerx['sources-api'].default);
111
+ player.packages.add(bitmovin.playerx['adaptation'].default);
112
+
113
+ player.sources.add('https://cdn.bitmovin.com/content/assets/streams-sample-video/sintel/m3u8/index.m3u8');
114
+ </script>
115
+ </body>
116
+ </html>
117
+ ```
118
+ ### Simple TypeScript Usage Example
119
+
120
+ This example shows how to use the monolithic player from npm. First you will need to install the player (this package) to your project:
121
+
122
+ ```shell
123
+ npm install @bitmovin/player-web-x
124
+ ```
125
+
126
+ ```typescript
127
+ import { Player } from '@bitmovin/player-web-x/bundles/playerx-hls';
128
+ import type { PlayerAndSourcesApi } from '@bitmovin/player-web-x/types/framework/core/sources-api/Types';
129
+
130
+ const player = Player({ key: 'YOUR-PLAYER-KEY' }) as PlayerAndSourcesApi;
131
+
132
+ player.sources.add('https://cdn.bitmovin.com/content/assets/streams-sample-video/sintel/m3u8/index.m3u8');
133
+ ```
134
+
135
+ ### TypeScript Package Example
136
+
137
+ This is the same, but with the packages.
138
+
139
+ ```typescript
140
+ import { Player } from '@bitmovin/player-web-x/bundles/playerx-core';
141
+ import { AdaptationPackage } from '@bitmovin/player-web-x/packages/playerx-adaptation.package';
142
+ import { CapabilitiesPackage } from '@bitmovin/player-web-x/packages/playerx-capabilities.package';
143
+ import { ContainerMp4Package } from '@bitmovin/player-web-x/packages/playerx-container-mp4.package';
144
+ import { DataPackage } from '@bitmovin/player-web-x/packages/playerx-data.package';
145
+ import { HlsPackage } from '@bitmovin/player-web-x/packages/playerx-hls.package';
146
+ import { HlsParsingPackage } from '@bitmovin/player-web-x/packages/playerx-hls-parsing.package';
147
+ import { HlsTranslationPackage } from '@bitmovin/player-web-x/packages/playerx-hls-translation.package';
148
+ import { NetworkPackage } from '@bitmovin/player-web-x/packages/playerx-network.package';
149
+ import { PresentationPackage } from '@bitmovin/player-web-x/packages/playerx-presentation.package';
150
+ import { SegmentProcessingPackage } from '@bitmovin/player-web-x/packages/playerx-segment-processing.package';
151
+ import { SourcePackage } from '@bitmovin/player-web-x/packages/playerx-source.package';
152
+ import { SourcesApiPackage } from '@bitmovin/player-web-x/packages/playerx-sources-api.package';
153
+ import type { PlayerAndSourcesApi } from '@bitmovin/player-web-x/types/framework/core/sources-api/Types';
154
+
155
+ const player = Player({ key: 'YOUR-PLAYER-KEY' }) as PlayerAndSourcesApi;
156
+
157
+ player.packages.add(CapabilitiesPackage);
158
+ player.packages.add(SegmentProcessingPackage);
159
+ player.packages.add(ContainerMp4Package);
160
+ player.packages.add(DataPackage);
161
+ player.packages.add(NetworkPackage);
162
+ player.packages.add(HlsTranslationPackage);
163
+ player.packages.add(HlsParsingPackage);
164
+ player.packages.add(HlsPackage);
165
+ player.packages.add(PresentationPackage);
166
+ player.packages.add(SourcePackage);
167
+ player.packages.add(AdaptationPackage);
168
+ player.packages.add(SourcesApiPackage);
169
+
170
+ player.sources.add('https://cdn.bitmovin.com/content/assets/streams-sample-video/sintel/m3u8/index.m3u8');
171
+ ```
172
+
173
+ ## Bitmovin Player V8 compatibility
174
+
175
+ To avoid disruption, we have also built a compatibility layer to allow you to use this player as a dropin for v8.
176
+
177
+ > [!CAUTION]
178
+ > This Player is not yet feature complete. Only use it as a replacement for V8 if it covers your use case.
179
+ >
180
+ > To find out how to use this compatibility mode, please see [COMPAT.md](/COMPAT.md).
181
+
182
+ ## Package template repository
183
+
184
+ To find out more about packages and how to build them, please check out our [package template repository](https://github.com/bitmovin/pwx-package-template). It includes examples of packages of various types, and also functions as a package build system.
185
+
186
+ ## Why is this player different?
187
+
188
+ Above, it was mentioned that this package is several things. Let's return to that statement a bit. More than just being a player, PWX can also be seen as a playback platform.
189
+ This is because it is built using our custom framework, Phoenix (now you know where that namespace comes from).
190
+ The framework is a structured concurrency implementation which is designed to be plugin first: on its own it doesn't implement any business logic, which is all loaded via packages.
191
+ That is what the call to `bitmovin.playerx.Player` does in fact, it just loads the framework. You can see that all functionality, even network requests, are added subsequently.
192
+ What this means for our users is that by using packages, any conceivable integration is possible (and usually fairly easy) to accomplish. We will soon release some examples of adding functionality via packages.
193
+
194
+ That is what is meant by playback platform. If your app or website is based around playback, Player Web X will allow you to build a tailored, powerful and performant integration to support your business needs.
195
+
196
+ We're very excited about that.
@@ -0,0 +1 @@
1
+ export * from '../types/bundles/BitmovinV8Core.bundle';