rx-player 4.0.0-dev.2024022600 → 4.0.0-dev.2024030400
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/VERSION +1 -1
- package/dist/commonjs/__GENERATED_CODE/embedded_dash_wasm.js +1 -1
- package/dist/commonjs/__GENERATED_CODE/embedded_worker.js +1 -1
- package/dist/commonjs/core/main/worker/worker_main.js +8 -9
- package/dist/commonjs/features/features_object.js +1 -1
- package/dist/commonjs/features/list/dash.js +2 -2
- package/dist/commonjs/features/types.d.ts +8 -3
- package/dist/commonjs/main_thread/api/public_api.js +2 -7
- package/dist/commonjs/main_thread/init/utils/get_loaded_reference.js +5 -0
- package/dist/commonjs/multithread_types.d.ts +1 -1
- package/dist/commonjs/parsers/manifest/dash/common/indexes/timeline/construct_timeline_from_elements.d.ts +4 -3
- package/dist/commonjs/parsers/manifest/dash/common/indexes/timeline/construct_timeline_from_elements.js +11 -4
- package/dist/commonjs/parsers/manifest/dash/common/indexes/timeline/construct_timeline_from_previous_timeline.d.ts +2 -1
- package/dist/commonjs/parsers/manifest/dash/common/indexes/timeline/construct_timeline_from_previous_timeline.js +12 -3
- package/dist/commonjs/parsers/manifest/dash/common/indexes/timeline/find_first_common_start_time.d.ts +3 -2
- package/dist/commonjs/parsers/manifest/dash/common/indexes/timeline/find_first_common_start_time.js +22 -11
- package/dist/commonjs/parsers/manifest/dash/common/indexes/timeline/parse_s_element.d.ts +11 -2
- package/dist/commonjs/parsers/manifest/dash/common/indexes/timeline/parse_s_element.js +74 -3
- package/dist/commonjs/parsers/manifest/dash/common/indexes/timeline/timeline_representation_index.d.ts +2 -1
- package/dist/commonjs/parsers/manifest/dash/common/parse_periods.js +3 -1
- package/dist/commonjs/parsers/manifest/dash/fast-js-parser/index.d.ts +17 -0
- package/dist/commonjs/parsers/manifest/dash/fast-js-parser/index.js +19 -0
- package/dist/commonjs/parsers/manifest/dash/fast-js-parser/node_parsers/AdaptationSet.d.ts +24 -0
- package/dist/commonjs/parsers/manifest/dash/fast-js-parser/node_parsers/AdaptationSet.js +400 -0
- package/dist/commonjs/parsers/manifest/dash/fast-js-parser/node_parsers/BaseURL.d.ts +24 -0
- package/dist/commonjs/parsers/manifest/dash/fast-js-parser/node_parsers/BaseURL.js +33 -0
- package/dist/commonjs/parsers/manifest/dash/fast-js-parser/node_parsers/ContentComponent.d.ts +23 -0
- package/dist/commonjs/parsers/manifest/dash/fast-js-parser/node_parsers/ContentComponent.js +70 -0
- package/dist/commonjs/parsers/manifest/dash/fast-js-parser/node_parsers/ContentProtection.d.ts +22 -0
- package/dist/commonjs/parsers/manifest/dash/fast-js-parser/node_parsers/ContentProtection.js +118 -0
- package/dist/commonjs/parsers/manifest/dash/fast-js-parser/node_parsers/EventStream.d.ts +23 -0
- package/dist/commonjs/parsers/manifest/dash/fast-js-parser/node_parsers/EventStream.js +154 -0
- package/dist/commonjs/parsers/manifest/dash/fast-js-parser/node_parsers/Initialization.d.ts +22 -0
- package/dist/commonjs/parsers/manifest/dash/fast-js-parser/node_parsers/Initialization.js +70 -0
- package/dist/commonjs/parsers/manifest/dash/fast-js-parser/node_parsers/MPD.d.ts +23 -0
- package/dist/commonjs/parsers/manifest/dash/fast-js-parser/node_parsers/MPD.js +221 -0
- package/dist/commonjs/parsers/manifest/dash/fast-js-parser/node_parsers/Period.d.ts +23 -0
- package/dist/commonjs/parsers/manifest/dash/fast-js-parser/node_parsers/Period.js +179 -0
- package/dist/commonjs/parsers/manifest/dash/fast-js-parser/node_parsers/Representation.d.ts +22 -0
- package/dist/commonjs/parsers/manifest/dash/fast-js-parser/node_parsers/Representation.js +256 -0
- package/dist/commonjs/parsers/manifest/dash/fast-js-parser/node_parsers/SegmentBase.d.ts +23 -0
- package/dist/commonjs/parsers/manifest/dash/fast-js-parser/node_parsers/SegmentBase.js +152 -0
- package/dist/commonjs/parsers/manifest/dash/fast-js-parser/node_parsers/SegmentList.d.ts +22 -0
- package/dist/commonjs/parsers/manifest/dash/fast-js-parser/node_parsers/SegmentList.js +60 -0
- package/dist/commonjs/parsers/manifest/dash/fast-js-parser/node_parsers/SegmentTemplate.d.ts +24 -0
- package/dist/commonjs/parsers/manifest/dash/fast-js-parser/node_parsers/SegmentTemplate.js +125 -0
- package/dist/commonjs/parsers/manifest/dash/fast-js-parser/node_parsers/SegmentTimeline.d.ts +22 -0
- package/dist/commonjs/parsers/manifest/dash/fast-js-parser/node_parsers/SegmentTimeline.js +36 -0
- package/dist/commonjs/parsers/manifest/dash/fast-js-parser/node_parsers/SegmentURL.d.ts +24 -0
- package/dist/commonjs/parsers/manifest/dash/fast-js-parser/node_parsers/SegmentURL.js +82 -0
- package/dist/commonjs/parsers/manifest/dash/fast-js-parser/node_parsers/utils.d.ts +176 -0
- package/dist/commonjs/parsers/manifest/dash/fast-js-parser/node_parsers/utils.js +382 -0
- package/dist/commonjs/parsers/manifest/dash/fast-js-parser/parse_from_xml_string.d.ts +24 -0
- package/dist/commonjs/parsers/manifest/dash/fast-js-parser/parse_from_xml_string.js +142 -0
- package/dist/commonjs/parsers/manifest/dash/node_parser_types.d.ts +5 -3
- package/dist/commonjs/public_types.d.ts +1 -1
- package/dist/commonjs/transports/dash/manifest_parser.js +33 -4
- package/dist/commonjs/utils/xml-parser.d.ts +70 -0
- package/dist/commonjs/utils/xml-parser.js +357 -0
- package/dist/es2017/__GENERATED_CODE/embedded_dash_wasm.js +1 -1
- package/dist/es2017/__GENERATED_CODE/embedded_worker.js +1 -1
- package/dist/es2017/core/main/worker/worker_main.js +8 -9
- package/dist/es2017/features/features_object.js +1 -1
- package/dist/es2017/features/list/dash.js +2 -2
- package/dist/es2017/features/types.d.ts +8 -3
- package/dist/es2017/main_thread/api/public_api.js +2 -7
- package/dist/es2017/main_thread/init/utils/get_loaded_reference.js +5 -0
- package/dist/es2017/multithread_types.d.ts +1 -1
- package/dist/es2017/parsers/manifest/dash/common/indexes/timeline/construct_timeline_from_elements.d.ts +4 -3
- package/dist/es2017/parsers/manifest/dash/common/indexes/timeline/construct_timeline_from_elements.js +12 -5
- package/dist/es2017/parsers/manifest/dash/common/indexes/timeline/construct_timeline_from_previous_timeline.d.ts +2 -1
- package/dist/es2017/parsers/manifest/dash/common/indexes/timeline/construct_timeline_from_previous_timeline.js +13 -4
- package/dist/es2017/parsers/manifest/dash/common/indexes/timeline/find_first_common_start_time.d.ts +3 -2
- package/dist/es2017/parsers/manifest/dash/common/indexes/timeline/find_first_common_start_time.js +22 -11
- package/dist/es2017/parsers/manifest/dash/common/indexes/timeline/parse_s_element.d.ts +11 -2
- package/dist/es2017/parsers/manifest/dash/common/indexes/timeline/parse_s_element.js +49 -2
- package/dist/es2017/parsers/manifest/dash/common/indexes/timeline/timeline_representation_index.d.ts +2 -1
- package/dist/es2017/parsers/manifest/dash/common/parse_periods.js +3 -1
- package/dist/es2017/parsers/manifest/dash/fast-js-parser/index.d.ts +17 -0
- package/dist/es2017/parsers/manifest/dash/fast-js-parser/index.js +17 -0
- package/dist/es2017/parsers/manifest/dash/fast-js-parser/node_parsers/AdaptationSet.d.ts +24 -0
- package/dist/es2017/parsers/manifest/dash/fast-js-parser/node_parsers/AdaptationSet.js +358 -0
- package/dist/es2017/parsers/manifest/dash/fast-js-parser/node_parsers/BaseURL.d.ts +24 -0
- package/dist/es2017/parsers/manifest/dash/fast-js-parser/node_parsers/BaseURL.js +30 -0
- package/dist/es2017/parsers/manifest/dash/fast-js-parser/node_parsers/ContentComponent.d.ts +23 -0
- package/dist/es2017/parsers/manifest/dash/fast-js-parser/node_parsers/ContentComponent.js +45 -0
- package/dist/es2017/parsers/manifest/dash/fast-js-parser/node_parsers/ContentProtection.d.ts +22 -0
- package/dist/es2017/parsers/manifest/dash/fast-js-parser/node_parsers/ContentProtection.js +77 -0
- package/dist/es2017/parsers/manifest/dash/fast-js-parser/node_parsers/EventStream.d.ts +23 -0
- package/dist/es2017/parsers/manifest/dash/fast-js-parser/node_parsers/EventStream.js +101 -0
- package/dist/es2017/parsers/manifest/dash/fast-js-parser/node_parsers/Initialization.d.ts +22 -0
- package/dist/es2017/parsers/manifest/dash/fast-js-parser/node_parsers/Initialization.js +45 -0
- package/dist/es2017/parsers/manifest/dash/fast-js-parser/node_parsers/MPD.d.ts +23 -0
- package/dist/es2017/parsers/manifest/dash/fast-js-parser/node_parsers/MPD.js +179 -0
- package/dist/es2017/parsers/manifest/dash/fast-js-parser/node_parsers/Period.d.ts +23 -0
- package/dist/es2017/parsers/manifest/dash/fast-js-parser/node_parsers/Period.js +137 -0
- package/dist/es2017/parsers/manifest/dash/fast-js-parser/node_parsers/Representation.d.ts +22 -0
- package/dist/es2017/parsers/manifest/dash/fast-js-parser/node_parsers/Representation.js +214 -0
- package/dist/es2017/parsers/manifest/dash/fast-js-parser/node_parsers/SegmentBase.d.ts +23 -0
- package/dist/es2017/parsers/manifest/dash/fast-js-parser/node_parsers/SegmentBase.js +111 -0
- package/dist/es2017/parsers/manifest/dash/fast-js-parser/node_parsers/SegmentList.d.ts +22 -0
- package/dist/es2017/parsers/manifest/dash/fast-js-parser/node_parsers/SegmentList.js +41 -0
- package/dist/es2017/parsers/manifest/dash/fast-js-parser/node_parsers/SegmentTemplate.d.ts +24 -0
- package/dist/es2017/parsers/manifest/dash/fast-js-parser/node_parsers/SegmentTemplate.js +84 -0
- package/dist/es2017/parsers/manifest/dash/fast-js-parser/node_parsers/SegmentTimeline.d.ts +22 -0
- package/dist/es2017/parsers/manifest/dash/fast-js-parser/node_parsers/SegmentTimeline.js +33 -0
- package/dist/es2017/parsers/manifest/dash/fast-js-parser/node_parsers/SegmentURL.d.ts +24 -0
- package/dist/es2017/parsers/manifest/dash/fast-js-parser/node_parsers/SegmentURL.js +57 -0
- package/dist/es2017/parsers/manifest/dash/fast-js-parser/node_parsers/utils.d.ts +176 -0
- package/dist/es2017/parsers/manifest/dash/fast-js-parser/node_parsers/utils.js +310 -0
- package/dist/es2017/parsers/manifest/dash/fast-js-parser/parse_from_xml_string.d.ts +24 -0
- package/dist/es2017/parsers/manifest/dash/fast-js-parser/parse_from_xml_string.js +114 -0
- package/dist/es2017/parsers/manifest/dash/node_parser_types.d.ts +5 -3
- package/dist/es2017/public_types.d.ts +1 -1
- package/dist/es2017/transports/dash/manifest_parser.js +33 -4
- package/dist/es2017/utils/xml-parser.d.ts +70 -0
- package/dist/es2017/utils/xml-parser.js +322 -0
- package/dist/mpd-parser.wasm +0 -0
- package/dist/rx-player.js +146 -65
- package/dist/rx-player.min.js +1 -1
- package/dist/worker.js +8 -3
- package/package.json +1 -1
- /package/dist/commonjs/parsers/manifest/dash/{js-parser → native-parser}/index.d.ts +0 -0
- /package/dist/commonjs/parsers/manifest/dash/{js-parser → native-parser}/index.js +0 -0
- /package/dist/commonjs/parsers/manifest/dash/{js-parser → native-parser}/node_parsers/AdaptationSet.d.ts +0 -0
- /package/dist/commonjs/parsers/manifest/dash/{js-parser → native-parser}/node_parsers/AdaptationSet.js +0 -0
- /package/dist/commonjs/parsers/manifest/dash/{js-parser → native-parser}/node_parsers/BaseURL.d.ts +0 -0
- /package/dist/commonjs/parsers/manifest/dash/{js-parser → native-parser}/node_parsers/BaseURL.js +0 -0
- /package/dist/commonjs/parsers/manifest/dash/{js-parser → native-parser}/node_parsers/ContentComponent.d.ts +0 -0
- /package/dist/commonjs/parsers/manifest/dash/{js-parser → native-parser}/node_parsers/ContentComponent.js +0 -0
- /package/dist/commonjs/parsers/manifest/dash/{js-parser → native-parser}/node_parsers/ContentProtection.d.ts +0 -0
- /package/dist/commonjs/parsers/manifest/dash/{js-parser → native-parser}/node_parsers/ContentProtection.js +0 -0
- /package/dist/commonjs/parsers/manifest/dash/{js-parser → native-parser}/node_parsers/EventStream.d.ts +0 -0
- /package/dist/commonjs/parsers/manifest/dash/{js-parser → native-parser}/node_parsers/EventStream.js +0 -0
- /package/dist/commonjs/parsers/manifest/dash/{js-parser → native-parser}/node_parsers/Initialization.d.ts +0 -0
- /package/dist/commonjs/parsers/manifest/dash/{js-parser → native-parser}/node_parsers/Initialization.js +0 -0
- /package/dist/commonjs/parsers/manifest/dash/{js-parser → native-parser}/node_parsers/MPD.d.ts +0 -0
- /package/dist/commonjs/parsers/manifest/dash/{js-parser → native-parser}/node_parsers/MPD.js +0 -0
- /package/dist/commonjs/parsers/manifest/dash/{js-parser → native-parser}/node_parsers/Period.d.ts +0 -0
- /package/dist/commonjs/parsers/manifest/dash/{js-parser → native-parser}/node_parsers/Period.js +0 -0
- /package/dist/commonjs/parsers/manifest/dash/{js-parser → native-parser}/node_parsers/Representation.d.ts +0 -0
- /package/dist/commonjs/parsers/manifest/dash/{js-parser → native-parser}/node_parsers/Representation.js +0 -0
- /package/dist/commonjs/parsers/manifest/dash/{js-parser → native-parser}/node_parsers/SegmentBase.d.ts +0 -0
- /package/dist/commonjs/parsers/manifest/dash/{js-parser → native-parser}/node_parsers/SegmentBase.js +0 -0
- /package/dist/commonjs/parsers/manifest/dash/{js-parser → native-parser}/node_parsers/SegmentList.d.ts +0 -0
- /package/dist/commonjs/parsers/manifest/dash/{js-parser → native-parser}/node_parsers/SegmentList.js +0 -0
- /package/dist/commonjs/parsers/manifest/dash/{js-parser → native-parser}/node_parsers/SegmentTemplate.d.ts +0 -0
- /package/dist/commonjs/parsers/manifest/dash/{js-parser → native-parser}/node_parsers/SegmentTemplate.js +0 -0
- /package/dist/commonjs/parsers/manifest/dash/{js-parser → native-parser}/node_parsers/SegmentTimeline.d.ts +0 -0
- /package/dist/commonjs/parsers/manifest/dash/{js-parser → native-parser}/node_parsers/SegmentTimeline.js +0 -0
- /package/dist/commonjs/parsers/manifest/dash/{js-parser → native-parser}/node_parsers/SegmentURL.d.ts +0 -0
- /package/dist/commonjs/parsers/manifest/dash/{js-parser → native-parser}/node_parsers/SegmentURL.js +0 -0
- /package/dist/commonjs/parsers/manifest/dash/{js-parser → native-parser}/node_parsers/utils.d.ts +0 -0
- /package/dist/commonjs/parsers/manifest/dash/{js-parser → native-parser}/node_parsers/utils.js +0 -0
- /package/dist/commonjs/parsers/manifest/dash/{js-parser → native-parser}/parse_from_document.d.ts +0 -0
- /package/dist/commonjs/parsers/manifest/dash/{js-parser → native-parser}/parse_from_document.js +0 -0
- /package/dist/es2017/parsers/manifest/dash/{js-parser → native-parser}/index.d.ts +0 -0
- /package/dist/es2017/parsers/manifest/dash/{js-parser → native-parser}/index.js +0 -0
- /package/dist/es2017/parsers/manifest/dash/{js-parser → native-parser}/node_parsers/AdaptationSet.d.ts +0 -0
- /package/dist/es2017/parsers/manifest/dash/{js-parser → native-parser}/node_parsers/AdaptationSet.js +0 -0
- /package/dist/es2017/parsers/manifest/dash/{js-parser → native-parser}/node_parsers/BaseURL.d.ts +0 -0
- /package/dist/es2017/parsers/manifest/dash/{js-parser → native-parser}/node_parsers/BaseURL.js +0 -0
- /package/dist/es2017/parsers/manifest/dash/{js-parser → native-parser}/node_parsers/ContentComponent.d.ts +0 -0
- /package/dist/es2017/parsers/manifest/dash/{js-parser → native-parser}/node_parsers/ContentComponent.js +0 -0
- /package/dist/es2017/parsers/manifest/dash/{js-parser → native-parser}/node_parsers/ContentProtection.d.ts +0 -0
- /package/dist/es2017/parsers/manifest/dash/{js-parser → native-parser}/node_parsers/ContentProtection.js +0 -0
- /package/dist/es2017/parsers/manifest/dash/{js-parser → native-parser}/node_parsers/EventStream.d.ts +0 -0
- /package/dist/es2017/parsers/manifest/dash/{js-parser → native-parser}/node_parsers/EventStream.js +0 -0
- /package/dist/es2017/parsers/manifest/dash/{js-parser → native-parser}/node_parsers/Initialization.d.ts +0 -0
- /package/dist/es2017/parsers/manifest/dash/{js-parser → native-parser}/node_parsers/Initialization.js +0 -0
- /package/dist/es2017/parsers/manifest/dash/{js-parser → native-parser}/node_parsers/MPD.d.ts +0 -0
- /package/dist/es2017/parsers/manifest/dash/{js-parser → native-parser}/node_parsers/MPD.js +0 -0
- /package/dist/es2017/parsers/manifest/dash/{js-parser → native-parser}/node_parsers/Period.d.ts +0 -0
- /package/dist/es2017/parsers/manifest/dash/{js-parser → native-parser}/node_parsers/Period.js +0 -0
- /package/dist/es2017/parsers/manifest/dash/{js-parser → native-parser}/node_parsers/Representation.d.ts +0 -0
- /package/dist/es2017/parsers/manifest/dash/{js-parser → native-parser}/node_parsers/Representation.js +0 -0
- /package/dist/es2017/parsers/manifest/dash/{js-parser → native-parser}/node_parsers/SegmentBase.d.ts +0 -0
- /package/dist/es2017/parsers/manifest/dash/{js-parser → native-parser}/node_parsers/SegmentBase.js +0 -0
- /package/dist/es2017/parsers/manifest/dash/{js-parser → native-parser}/node_parsers/SegmentList.d.ts +0 -0
- /package/dist/es2017/parsers/manifest/dash/{js-parser → native-parser}/node_parsers/SegmentList.js +0 -0
- /package/dist/es2017/parsers/manifest/dash/{js-parser → native-parser}/node_parsers/SegmentTemplate.d.ts +0 -0
- /package/dist/es2017/parsers/manifest/dash/{js-parser → native-parser}/node_parsers/SegmentTemplate.js +0 -0
- /package/dist/es2017/parsers/manifest/dash/{js-parser → native-parser}/node_parsers/SegmentTimeline.d.ts +0 -0
- /package/dist/es2017/parsers/manifest/dash/{js-parser → native-parser}/node_parsers/SegmentTimeline.js +0 -0
- /package/dist/es2017/parsers/manifest/dash/{js-parser → native-parser}/node_parsers/SegmentURL.d.ts +0 -0
- /package/dist/es2017/parsers/manifest/dash/{js-parser → native-parser}/node_parsers/SegmentURL.js +0 -0
- /package/dist/es2017/parsers/manifest/dash/{js-parser → native-parser}/node_parsers/utils.d.ts +0 -0
- /package/dist/es2017/parsers/manifest/dash/{js-parser → native-parser}/node_parsers/utils.js +0 -0
- /package/dist/es2017/parsers/manifest/dash/{js-parser → native-parser}/parse_from_document.d.ts +0 -0
- /package/dist/es2017/parsers/manifest/dash/{js-parser → native-parser}/parse_from_document.js +0 -0
package/dist/rx-player.js
CHANGED
|
@@ -7188,7 +7188,8 @@ function normalizeAudioTrack(_language) {
|
|
|
7188
7188
|
var features = {
|
|
7189
7189
|
dashParsers: {
|
|
7190
7190
|
wasm: null,
|
|
7191
|
-
|
|
7191
|
+
"native": null,
|
|
7192
|
+
fastJs: null
|
|
7192
7193
|
},
|
|
7193
7194
|
codecSupportProber: null,
|
|
7194
7195
|
createDebugElement: null,
|
|
@@ -20701,6 +20702,11 @@ function getLoadedReference(playbackObserver, mediaElement, isDirectfile, cancel
|
|
|
20701
20702
|
return;
|
|
20702
20703
|
}
|
|
20703
20704
|
if (!shouldWaitForDataBeforeLoaded(isDirectfile, mediaElement.hasAttribute("playsinline"))) {
|
|
20705
|
+
// The duration is NaN if no media data is available,
|
|
20706
|
+
// which means media is not loaded yet.
|
|
20707
|
+
if (isNaN(mediaElement.duration)) {
|
|
20708
|
+
return;
|
|
20709
|
+
}
|
|
20704
20710
|
if (mediaElement.duration > 0) {
|
|
20705
20711
|
isLoaded.setValue(true);
|
|
20706
20712
|
listenCanceller.cancel();
|
|
@@ -30193,12 +30199,57 @@ function convertElementsToIndexSegment(item, previousItem, nextItem) {
|
|
|
30193
30199
|
* limitations under the License.
|
|
30194
30200
|
*/
|
|
30195
30201
|
|
|
30202
|
+
|
|
30203
|
+
/**
|
|
30204
|
+
* Parse a given <S> element in the MPD under a parsed Node form into a JS
|
|
30205
|
+
* Object.
|
|
30206
|
+
* @param {Object} root
|
|
30207
|
+
* @returns {Object}
|
|
30208
|
+
*/
|
|
30209
|
+
function parseSElementNode(root) {
|
|
30210
|
+
var parsedS = {};
|
|
30211
|
+
for (var _i = 0, _Object$keys = Object.keys(root.attributes); _i < _Object$keys.length; _i++) {
|
|
30212
|
+
var attributeName = _Object$keys[_i];
|
|
30213
|
+
var attributeVal = root.attributes[attributeName];
|
|
30214
|
+
if (is_null_or_undefined_isNullOrUndefined(attributeVal)) {
|
|
30215
|
+
continue;
|
|
30216
|
+
}
|
|
30217
|
+
switch (attributeName) {
|
|
30218
|
+
case "t":
|
|
30219
|
+
var start = parseInt(attributeVal, 10);
|
|
30220
|
+
if (isNaN(start)) {
|
|
30221
|
+
src_log.warn("DASH: invalid t (\"" + attributeVal + "\")");
|
|
30222
|
+
} else {
|
|
30223
|
+
parsedS.start = start;
|
|
30224
|
+
}
|
|
30225
|
+
break;
|
|
30226
|
+
case "d":
|
|
30227
|
+
var duration = parseInt(attributeVal, 10);
|
|
30228
|
+
if (isNaN(duration)) {
|
|
30229
|
+
src_log.warn("DASH: invalid d (\"" + attributeVal + "\")");
|
|
30230
|
+
} else {
|
|
30231
|
+
parsedS.duration = duration;
|
|
30232
|
+
}
|
|
30233
|
+
break;
|
|
30234
|
+
case "r":
|
|
30235
|
+
var repeatCount = parseInt(attributeVal, 10);
|
|
30236
|
+
if (isNaN(repeatCount)) {
|
|
30237
|
+
src_log.warn("DASH: invalid r (\"" + attributeVal + "\")");
|
|
30238
|
+
} else {
|
|
30239
|
+
parsedS.repeatCount = repeatCount;
|
|
30240
|
+
}
|
|
30241
|
+
break;
|
|
30242
|
+
}
|
|
30243
|
+
}
|
|
30244
|
+
return parsedS;
|
|
30245
|
+
}
|
|
30196
30246
|
/**
|
|
30197
|
-
* Parse a given <S> element in the MPD into a JS
|
|
30247
|
+
* Parse a given <S> element in the MPD under an `Element` form into a JS
|
|
30248
|
+
* Object.
|
|
30198
30249
|
* @param {Element} root
|
|
30199
30250
|
* @returns {Object}
|
|
30200
30251
|
*/
|
|
30201
|
-
function
|
|
30252
|
+
function parseSHTMLElement(root) {
|
|
30202
30253
|
var parsedS = {};
|
|
30203
30254
|
for (var j = 0; j < root.attributes.length; j++) {
|
|
30204
30255
|
var attribute = root.attributes[j];
|
|
@@ -30254,20 +30305,26 @@ function parseSElement(root) {
|
|
|
30254
30305
|
* Call this function when the timeline is unknown.
|
|
30255
30306
|
* This function was added to only perform that task lazily, i.e. only when
|
|
30256
30307
|
* first needed.
|
|
30257
|
-
* @param {HTMLCollection} elements - All S nodes constituting
|
|
30258
|
-
* SegmentTimeline node.
|
|
30308
|
+
* @param {Array.<Object>|HTMLCollection} elements - All S nodes constituting
|
|
30309
|
+
* the corresponding SegmentTimeline node.
|
|
30259
30310
|
* @returns {Array.<Object>}
|
|
30260
30311
|
*/
|
|
30261
30312
|
function constructTimelineFromElements(elements) {
|
|
30262
30313
|
var initialTimeline = [];
|
|
30263
|
-
|
|
30264
|
-
|
|
30314
|
+
if (Array.isArray(elements)) {
|
|
30315
|
+
for (var i = 0; i < elements.length; i++) {
|
|
30316
|
+
initialTimeline.push(parseSElementNode(elements[i]));
|
|
30317
|
+
}
|
|
30318
|
+
} else {
|
|
30319
|
+
for (var _i = 0; _i < elements.length; _i++) {
|
|
30320
|
+
initialTimeline.push(parseSHTMLElement(elements[_i]));
|
|
30321
|
+
}
|
|
30265
30322
|
}
|
|
30266
30323
|
var timeline = [];
|
|
30267
|
-
for (var
|
|
30268
|
-
var item = initialTimeline[
|
|
30324
|
+
for (var _i2 = 0; _i2 < initialTimeline.length; _i2++) {
|
|
30325
|
+
var item = initialTimeline[_i2];
|
|
30269
30326
|
var previousItem = timeline[timeline.length - 1] === undefined ? null : timeline[timeline.length - 1];
|
|
30270
|
-
var nextItem = initialTimeline[
|
|
30327
|
+
var nextItem = initialTimeline[_i2 + 1] === undefined ? null : initialTimeline[_i2 + 1];
|
|
30271
30328
|
var timelineElement = convertElementsToIndexSegment(item, previousItem, nextItem);
|
|
30272
30329
|
if (timelineElement !== null) {
|
|
30273
30330
|
timeline.push(timelineElement);
|
|
@@ -30291,13 +30348,14 @@ function constructTimelineFromElements(elements) {
|
|
|
30291
30348
|
* See the License for the specific language governing permissions and
|
|
30292
30349
|
* limitations under the License.
|
|
30293
30350
|
*/
|
|
30351
|
+
|
|
30294
30352
|
/**
|
|
30295
30353
|
* By comparing two timelines for the same content at different points in time,
|
|
30296
30354
|
* retrieve the index in both timelines of the first segment having the same
|
|
30297
30355
|
* starting time.
|
|
30298
30356
|
* Returns `null` if not found.
|
|
30299
30357
|
* @param {Array.<Object>} prevTimeline
|
|
30300
|
-
* @param {
|
|
30358
|
+
* @param {Array.<Object>} newElements
|
|
30301
30359
|
* @returns {Object|null}
|
|
30302
30360
|
*/
|
|
30303
30361
|
function findFirstCommonStartTime(prevTimeline, newElements) {
|
|
@@ -30305,8 +30363,8 @@ function findFirstCommonStartTime(prevTimeline, newElements) {
|
|
|
30305
30363
|
return null;
|
|
30306
30364
|
}
|
|
30307
30365
|
var prevInitialStart = prevTimeline[0].start;
|
|
30308
|
-
var newFirstTAttr = newElements[0].getAttribute("t");
|
|
30309
|
-
var newInitialStart = newFirstTAttr
|
|
30366
|
+
var newFirstTAttr = Array.isArray(newElements) ? newElements[0].attributes.t : newElements[0].getAttribute("t");
|
|
30367
|
+
var newInitialStart = is_null_or_undefined_isNullOrUndefined(newFirstTAttr) ? null : parseInt(newFirstTAttr, 10);
|
|
30310
30368
|
if (newInitialStart === null || Number.isNaN(newInitialStart)) {
|
|
30311
30369
|
return null;
|
|
30312
30370
|
}
|
|
@@ -30351,16 +30409,17 @@ function findFirstCommonStartTime(prevTimeline, newElements) {
|
|
|
30351
30409
|
}
|
|
30352
30410
|
} else {
|
|
30353
30411
|
var newElementsIdx = 0;
|
|
30354
|
-
var
|
|
30412
|
+
var newNodeElt = Array.isArray(newElements) ? newElements[0] : null;
|
|
30413
|
+
var newDomElt = Array.isArray(newElements) ? null : newElements[0];
|
|
30355
30414
|
var currentTimeOffset = newInitialStart;
|
|
30356
30415
|
while (true) {
|
|
30357
|
-
var dAttr =
|
|
30358
|
-
var duration = dAttr
|
|
30416
|
+
var dAttr = newNodeElt !== null ? newNodeElt.attributes.d : newDomElt === null || newDomElt === void 0 ? void 0 : newDomElt.getAttribute("d");
|
|
30417
|
+
var duration = is_null_or_undefined_isNullOrUndefined(dAttr) ? null : parseInt(dAttr, 10);
|
|
30359
30418
|
if (duration === null || Number.isNaN(duration)) {
|
|
30360
30419
|
return null;
|
|
30361
30420
|
}
|
|
30362
|
-
var rAttr =
|
|
30363
|
-
var repeatCount = rAttr
|
|
30421
|
+
var rAttr = newNodeElt !== null ? newNodeElt.attributes.r : newDomElt === null || newDomElt === void 0 ? void 0 : newDomElt.getAttribute("r");
|
|
30422
|
+
var repeatCount = is_null_or_undefined_isNullOrUndefined(rAttr) ? null : parseInt(rAttr, 10);
|
|
30364
30423
|
if (repeatCount !== null) {
|
|
30365
30424
|
if (Number.isNaN(repeatCount) || repeatCount < 0) {
|
|
30366
30425
|
return null;
|
|
@@ -30385,9 +30444,13 @@ function findFirstCommonStartTime(prevTimeline, newElements) {
|
|
|
30385
30444
|
if (newElementsIdx >= newElements.length) {
|
|
30386
30445
|
return null;
|
|
30387
30446
|
}
|
|
30388
|
-
|
|
30389
|
-
|
|
30390
|
-
|
|
30447
|
+
if (Array.isArray(newElements)) {
|
|
30448
|
+
newNodeElt = newElements[newElementsIdx];
|
|
30449
|
+
} else {
|
|
30450
|
+
newDomElt = newElements[newElementsIdx];
|
|
30451
|
+
}
|
|
30452
|
+
var tAttr = newNodeElt !== null ? newNodeElt.attributes.t : newDomElt === null || newDomElt === void 0 ? void 0 : newDomElt.getAttribute("t");
|
|
30453
|
+
var time = is_null_or_undefined_isNullOrUndefined(tAttr) ? null : parseInt(tAttr, 10);
|
|
30391
30454
|
if (time !== null) {
|
|
30392
30455
|
if (Number.isNaN(time)) {
|
|
30393
30456
|
return null;
|
|
@@ -30459,7 +30522,7 @@ function constructTimelineFromPreviousTimeline(newElements, prevTimeline) {
|
|
|
30459
30522
|
return constructTimelineFromElements(newElements);
|
|
30460
30523
|
}
|
|
30461
30524
|
var prevLastElement = newTimeline[newTimeline.length - 1];
|
|
30462
|
-
var newCommonElt =
|
|
30525
|
+
var newCommonElt = Array.isArray(newElements) ? parseSElementNode(newElements[lastCommonEltNewEltsIdx]) : parseSHTMLElement(newElements[lastCommonEltNewEltsIdx]);
|
|
30463
30526
|
var newRepeatCountOffseted = ((_a = newCommonElt.repeatCount) !== null && _a !== void 0 ? _a : 0) - repeatNumberInNewElements;
|
|
30464
30527
|
if (newCommonElt.duration !== prevLastElement.duration || prevLastElement.repeatCount > newRepeatCountOffseted) {
|
|
30465
30528
|
src_log.info('DASH: Cannot perform "based" update. ' + "The new timeline has a different form at the beginning.");
|
|
@@ -30470,13 +30533,19 @@ function constructTimelineFromPreviousTimeline(newElements, prevTimeline) {
|
|
|
30470
30533
|
}
|
|
30471
30534
|
var newEltsToPush = [];
|
|
30472
30535
|
var items = [];
|
|
30473
|
-
|
|
30474
|
-
|
|
30536
|
+
if (Array.isArray(newElements)) {
|
|
30537
|
+
for (var i = lastCommonEltNewEltsIdx + 1; i < newElements.length; i++) {
|
|
30538
|
+
items.push(parseSElementNode(newElements[i]));
|
|
30539
|
+
}
|
|
30540
|
+
} else {
|
|
30541
|
+
for (var _i = lastCommonEltNewEltsIdx + 1; _i < newElements.length; _i++) {
|
|
30542
|
+
items.push(parseSHTMLElement(newElements[_i]));
|
|
30543
|
+
}
|
|
30475
30544
|
}
|
|
30476
|
-
for (var
|
|
30477
|
-
var item = items[
|
|
30545
|
+
for (var _i2 = 0; _i2 < items.length; _i2++) {
|
|
30546
|
+
var item = items[_i2];
|
|
30478
30547
|
var previousItem = newEltsToPush[newEltsToPush.length - 1] === undefined ? prevLastElement : newEltsToPush[newEltsToPush.length - 1];
|
|
30479
|
-
var nextItem = items[
|
|
30548
|
+
var nextItem = items[_i2 + 1] === undefined ? null : items[_i2 + 1];
|
|
30480
30549
|
var timelineElement = convertElementsToIndexSegment(item, previousItem, nextItem);
|
|
30481
30550
|
if (timelineElement !== null) {
|
|
30482
30551
|
newEltsToPush.push(timelineElement);
|
|
@@ -32651,7 +32720,7 @@ function generateStreamEvents(baseIr, periodStart, xmlNamespaces) {
|
|
|
32651
32720
|
try {
|
|
32652
32721
|
xmlData = {
|
|
32653
32722
|
namespaces: allNamespaces,
|
|
32654
|
-
data: utf8ToStr(new Uint8Array(eventIr.eventStreamData))
|
|
32723
|
+
data: typeof eventIr.eventStreamData === "string" ? eventIr.eventStreamData : utf8ToStr(new Uint8Array(eventIr.eventStreamData))
|
|
32655
32724
|
};
|
|
32656
32725
|
} catch (err) {
|
|
32657
32726
|
src_log.error("DASH: Error while parsing event-stream:", err instanceof Error ? err.message : "Unknown error");
|
|
@@ -32981,7 +33050,7 @@ function parseCompleteIntermediateRepresentation(mpdIR, args, warnings, xlinkInf
|
|
|
32981
33050
|
|
|
32982
33051
|
/* harmony default export */ var common = (parseMpdIr);
|
|
32983
33052
|
|
|
32984
|
-
;// CONCATENATED MODULE: ./src/parsers/manifest/dash/
|
|
33053
|
+
;// CONCATENATED MODULE: ./src/parsers/manifest/dash/native-parser/node_parsers/BaseURL.ts
|
|
32985
33054
|
/**
|
|
32986
33055
|
* Copyright 2015 CANAL+ Group
|
|
32987
33056
|
*
|
|
@@ -33013,7 +33082,7 @@ function parseBaseURL(root) {
|
|
|
33013
33082
|
value: value
|
|
33014
33083
|
}, warnings];
|
|
33015
33084
|
}
|
|
33016
|
-
;// CONCATENATED MODULE: ./src/parsers/manifest/dash/
|
|
33085
|
+
;// CONCATENATED MODULE: ./src/parsers/manifest/dash/native-parser/node_parsers/ContentComponent.ts
|
|
33017
33086
|
/**
|
|
33018
33087
|
* Copyright 2015 CANAL+ Group
|
|
33019
33088
|
*
|
|
@@ -33055,7 +33124,7 @@ function parseContentComponent(root) {
|
|
|
33055
33124
|
}
|
|
33056
33125
|
return ret;
|
|
33057
33126
|
}
|
|
33058
|
-
;// CONCATENATED MODULE: ./src/parsers/manifest/dash/
|
|
33127
|
+
;// CONCATENATED MODULE: ./src/parsers/manifest/dash/native-parser/node_parsers/utils.ts
|
|
33059
33128
|
|
|
33060
33129
|
|
|
33061
33130
|
|
|
@@ -33361,7 +33430,7 @@ var MPDError = /*#__PURE__*/function (_Error) {
|
|
|
33361
33430
|
return MPDError;
|
|
33362
33431
|
}( /*#__PURE__*/_wrapNativeSuper(Error));
|
|
33363
33432
|
|
|
33364
|
-
;// CONCATENATED MODULE: ./src/parsers/manifest/dash/
|
|
33433
|
+
;// CONCATENATED MODULE: ./src/parsers/manifest/dash/native-parser/node_parsers/ContentProtection.ts
|
|
33365
33434
|
/**
|
|
33366
33435
|
* Copyright 2015 CANAL+ Group
|
|
33367
33436
|
*
|
|
@@ -33446,7 +33515,7 @@ function parseContentProtection(contentProtectionElement) {
|
|
|
33446
33515
|
attributes: attributes
|
|
33447
33516
|
}, childrenWarnings];
|
|
33448
33517
|
}
|
|
33449
|
-
;// CONCATENATED MODULE: ./src/parsers/manifest/dash/
|
|
33518
|
+
;// CONCATENATED MODULE: ./src/parsers/manifest/dash/native-parser/node_parsers/Initialization.ts
|
|
33450
33519
|
/**
|
|
33451
33520
|
* Copyright 2015 CANAL+ Group
|
|
33452
33521
|
*
|
|
@@ -33488,7 +33557,7 @@ function parseInitialization(root) {
|
|
|
33488
33557
|
}
|
|
33489
33558
|
return [parsedInitialization, warnings];
|
|
33490
33559
|
}
|
|
33491
|
-
;// CONCATENATED MODULE: ./src/parsers/manifest/dash/
|
|
33560
|
+
;// CONCATENATED MODULE: ./src/parsers/manifest/dash/native-parser/node_parsers/SegmentBase.ts
|
|
33492
33561
|
/**
|
|
33493
33562
|
* Copyright 2015 CANAL+ Group
|
|
33494
33563
|
*
|
|
@@ -33598,7 +33667,7 @@ function parseSegmentBase(root) {
|
|
|
33598
33667
|
}
|
|
33599
33668
|
return [attributes, warnings];
|
|
33600
33669
|
}
|
|
33601
|
-
;// CONCATENATED MODULE: ./src/parsers/manifest/dash/
|
|
33670
|
+
;// CONCATENATED MODULE: ./src/parsers/manifest/dash/native-parser/node_parsers/SegmentURL.ts
|
|
33602
33671
|
/**
|
|
33603
33672
|
* Copyright 2015 CANAL+ Group
|
|
33604
33673
|
*
|
|
@@ -33652,7 +33721,7 @@ function parseSegmentURL(root) {
|
|
|
33652
33721
|
}
|
|
33653
33722
|
return [parsedSegmentURL, warnings];
|
|
33654
33723
|
}
|
|
33655
|
-
;// CONCATENATED MODULE: ./src/parsers/manifest/dash/
|
|
33724
|
+
;// CONCATENATED MODULE: ./src/parsers/manifest/dash/native-parser/node_parsers/SegmentList.ts
|
|
33656
33725
|
/**
|
|
33657
33726
|
* Copyright 2015 CANAL+ Group
|
|
33658
33727
|
*
|
|
@@ -33699,7 +33768,7 @@ function parseSegmentList(root) {
|
|
|
33699
33768
|
});
|
|
33700
33769
|
return [ret, warnings];
|
|
33701
33770
|
}
|
|
33702
|
-
;// CONCATENATED MODULE: ./src/parsers/manifest/dash/
|
|
33771
|
+
;// CONCATENATED MODULE: ./src/parsers/manifest/dash/native-parser/node_parsers/SegmentTimeline.ts
|
|
33703
33772
|
/**
|
|
33704
33773
|
* Copyright 2015 CANAL+ Group
|
|
33705
33774
|
*
|
|
@@ -33730,7 +33799,7 @@ function createSegmentTimelineParser(root) {
|
|
|
33730
33799
|
return result;
|
|
33731
33800
|
};
|
|
33732
33801
|
}
|
|
33733
|
-
;// CONCATENATED MODULE: ./src/parsers/manifest/dash/
|
|
33802
|
+
;// CONCATENATED MODULE: ./src/parsers/manifest/dash/native-parser/node_parsers/SegmentTemplate.ts
|
|
33734
33803
|
/**
|
|
33735
33804
|
* Copyright 2015 CANAL+ Group
|
|
33736
33805
|
*
|
|
@@ -33818,7 +33887,7 @@ function parseSegmentTemplate(root) {
|
|
|
33818
33887
|
}
|
|
33819
33888
|
return [ret, warnings];
|
|
33820
33889
|
}
|
|
33821
|
-
;// CONCATENATED MODULE: ./src/parsers/manifest/dash/
|
|
33890
|
+
;// CONCATENATED MODULE: ./src/parsers/manifest/dash/native-parser/node_parsers/Representation.ts
|
|
33822
33891
|
/**
|
|
33823
33892
|
* Copyright 2015 CANAL+ Group
|
|
33824
33893
|
*
|
|
@@ -34045,7 +34114,7 @@ function createRepresentationIntermediateRepresentation(representationElement) {
|
|
|
34045
34114
|
attributes: attributes
|
|
34046
34115
|
}, warnings];
|
|
34047
34116
|
}
|
|
34048
|
-
;// CONCATENATED MODULE: ./src/parsers/manifest/dash/
|
|
34117
|
+
;// CONCATENATED MODULE: ./src/parsers/manifest/dash/native-parser/node_parsers/AdaptationSet.ts
|
|
34049
34118
|
/**
|
|
34050
34119
|
* Copyright 2015 CANAL+ Group
|
|
34051
34120
|
*
|
|
@@ -34415,7 +34484,7 @@ function createAdaptationSetIntermediateRepresentation(adaptationSetElement) {
|
|
|
34415
34484
|
attributes: attributes
|
|
34416
34485
|
}, warnings];
|
|
34417
34486
|
}
|
|
34418
|
-
;// CONCATENATED MODULE: ./src/parsers/manifest/dash/
|
|
34487
|
+
;// CONCATENATED MODULE: ./src/parsers/manifest/dash/native-parser/node_parsers/EventStream.ts
|
|
34419
34488
|
/**
|
|
34420
34489
|
* Copyright 2015 CANAL+ Group
|
|
34421
34490
|
*
|
|
@@ -34520,7 +34589,7 @@ function parseEvent(element) {
|
|
|
34520
34589
|
}
|
|
34521
34590
|
return [eventIR, warnings];
|
|
34522
34591
|
}
|
|
34523
|
-
;// CONCATENATED MODULE: ./src/parsers/manifest/dash/
|
|
34592
|
+
;// CONCATENATED MODULE: ./src/parsers/manifest/dash/native-parser/node_parsers/Period.ts
|
|
34524
34593
|
/**
|
|
34525
34594
|
* Copyright 2015 CANAL+ Group
|
|
34526
34595
|
*
|
|
@@ -34659,7 +34728,7 @@ function createPeriodIntermediateRepresentation(periodElement) {
|
|
|
34659
34728
|
attributes: attributes
|
|
34660
34729
|
}, warnings];
|
|
34661
34730
|
}
|
|
34662
|
-
;// CONCATENATED MODULE: ./src/parsers/manifest/dash/
|
|
34731
|
+
;// CONCATENATED MODULE: ./src/parsers/manifest/dash/native-parser/node_parsers/MPD.ts
|
|
34663
34732
|
/**
|
|
34664
34733
|
* Copyright 2015 CANAL+ Group
|
|
34665
34734
|
*
|
|
@@ -34837,7 +34906,7 @@ function createMPDIntermediateRepresentation(root) {
|
|
|
34837
34906
|
attributes: attributes
|
|
34838
34907
|
}, warnings];
|
|
34839
34908
|
}
|
|
34840
|
-
;// CONCATENATED MODULE: ./src/parsers/manifest/dash/
|
|
34909
|
+
;// CONCATENATED MODULE: ./src/parsers/manifest/dash/native-parser/parse_from_document.ts
|
|
34841
34910
|
/**
|
|
34842
34911
|
* Copyright 2015 CANAL+ Group
|
|
34843
34912
|
*
|
|
@@ -34951,7 +35020,7 @@ function parseFromDocument(document, args) {
|
|
|
34951
35020
|
}
|
|
34952
35021
|
}
|
|
34953
35022
|
}
|
|
34954
|
-
;// CONCATENATED MODULE: ./src/parsers/manifest/dash/
|
|
35023
|
+
;// CONCATENATED MODULE: ./src/parsers/manifest/dash/native-parser/index.ts
|
|
34955
35024
|
/**
|
|
34956
35025
|
* Copyright 2015 CANAL+ Group
|
|
34957
35026
|
*
|
|
@@ -34968,7 +35037,7 @@ function parseFromDocument(document, args) {
|
|
|
34968
35037
|
* limitations under the License.
|
|
34969
35038
|
*/
|
|
34970
35039
|
|
|
34971
|
-
/* harmony default export */ var
|
|
35040
|
+
/* harmony default export */ var native_parser = (parseFromDocument);
|
|
34972
35041
|
;// CONCATENATED MODULE: ./src/transports/dash/manifest_parser.ts
|
|
34973
35042
|
/**
|
|
34974
35043
|
* Copyright 2015 CANAL+ Group
|
|
@@ -35046,12 +35115,17 @@ function generateManifestParser(options) {
|
|
|
35046
35115
|
* @returns {Object|Promise.<Object>}
|
|
35047
35116
|
*/
|
|
35048
35117
|
function runDefaultJsParser() {
|
|
35049
|
-
if (parsers.
|
|
35118
|
+
if (parsers.fastJs !== null) {
|
|
35119
|
+
var manifestStr = getManifestAsString(responseData);
|
|
35120
|
+
var parsedManifest = parsers.fastJs(manifestStr, dashParserOpts);
|
|
35121
|
+
return processMpdParserResponse(parsedManifest);
|
|
35122
|
+
} else if (parsers["native"] !== null) {
|
|
35123
|
+
var manifestDocument = getManifestAsDocument(responseData);
|
|
35124
|
+
var _parsedManifest = parsers["native"](manifestDocument, dashParserOpts);
|
|
35125
|
+
return processMpdParserResponse(_parsedManifest);
|
|
35126
|
+
} else {
|
|
35050
35127
|
throw new Error("No MPD parser is imported");
|
|
35051
35128
|
}
|
|
35052
|
-
var manifestDoc = getManifestAsDocument(responseData);
|
|
35053
|
-
var parsedManifest = parsers.js(manifestDoc, dashParserOpts);
|
|
35054
|
-
return processMpdParserResponse(parsedManifest);
|
|
35055
35129
|
}
|
|
35056
35130
|
/**
|
|
35057
35131
|
* Process return of one of the MPD parser.
|
|
@@ -35186,6 +35260,25 @@ function assertLoadedResourcesFormatArrayBuffer(loadedResources) {
|
|
|
35186
35260
|
throw new Error("Invalid data given to the LoadedRessource");
|
|
35187
35261
|
});
|
|
35188
35262
|
}
|
|
35263
|
+
/**
|
|
35264
|
+
* Try to convert a Manifest from an unknown format to an array of nodes as
|
|
35265
|
+
* parsed by our XML DOM parser.
|
|
35266
|
+
*
|
|
35267
|
+
* Throws if the format cannot be converted.
|
|
35268
|
+
* @param {*} manifestSrc
|
|
35269
|
+
* @returns {Array.<Object | string>}
|
|
35270
|
+
*/
|
|
35271
|
+
function getManifestAsString(manifestSrc) {
|
|
35272
|
+
if (manifestSrc instanceof ArrayBuffer) {
|
|
35273
|
+
return utf8ToStr(new Uint8Array(manifestSrc));
|
|
35274
|
+
} else if (typeof manifestSrc === "string") {
|
|
35275
|
+
return manifestSrc;
|
|
35276
|
+
} else if (manifestSrc instanceof Document) {
|
|
35277
|
+
return manifestSrc.documentElement.outerHTML;
|
|
35278
|
+
} else {
|
|
35279
|
+
throw new Error("DASH Manifest Parser: Unrecognized Manifest format");
|
|
35280
|
+
}
|
|
35281
|
+
}
|
|
35189
35282
|
/**
|
|
35190
35283
|
* Try to convert a Manifest from an unknown format to a `Document` format.
|
|
35191
35284
|
* Useful to exploit DOM-parsing APIs to quickly parse an XML Manifest.
|
|
@@ -37266,7 +37359,7 @@ function addDASHFeature(features) {
|
|
|
37266
37359
|
if (features.transports.dash === undefined) {
|
|
37267
37360
|
features.transports.dash = dash;
|
|
37268
37361
|
}
|
|
37269
|
-
features.dashParsers
|
|
37362
|
+
features.dashParsers["native"] = native_parser;
|
|
37270
37363
|
features.mainThreadMediaSourceInit = MediaSourceContentInitializer;
|
|
37271
37364
|
features.codecSupportProber = main_codec_support_prober;
|
|
37272
37365
|
}
|
|
@@ -50081,13 +50174,6 @@ function getStartDate(mediaElement) {
|
|
|
50081
50174
|
var hasMseInWorker = typeof MediaSource === "function" && /* eslint-disable-next-line */
|
|
50082
50175
|
MediaSource.canConstructInDedicatedWorker === true;
|
|
50083
50176
|
/* harmony default export */ var has_mse_in_worker = (hasMseInWorker);
|
|
50084
|
-
;// CONCATENATED MODULE: ./src/compat/has_webassembly.ts
|
|
50085
|
-
/**
|
|
50086
|
-
* If `true` the current environment support known WebAssembly API to
|
|
50087
|
-
* instantiate a WebAssembly module.
|
|
50088
|
-
*/
|
|
50089
|
-
var hasWebassembly = typeof WebAssembly === "object" && typeof WebAssembly.instantiate === "function";
|
|
50090
|
-
/* harmony default export */ var has_webassembly = (hasWebassembly);
|
|
50091
50177
|
;// CONCATENATED MODULE: ./src/errors/worker_initialization_error.ts
|
|
50092
50178
|
|
|
50093
50179
|
|
|
@@ -52845,7 +52931,6 @@ function public_api_arrayLikeToArray(arr, len) { if (len == null || len > arr.le
|
|
|
52845
52931
|
|
|
52846
52932
|
|
|
52847
52933
|
|
|
52848
|
-
|
|
52849
52934
|
|
|
52850
52935
|
|
|
52851
52936
|
/* eslint-disable @typescript-eslint/naming-convention */
|
|
@@ -52892,7 +52977,7 @@ var Player = /*#__PURE__*/function (_EventEmitter) {
|
|
|
52892
52977
|
// Workaround to support Firefox autoplay on FF 42.
|
|
52893
52978
|
// See: https://bugzilla.mozilla.org/show_bug.cgi?id=1194624
|
|
52894
52979
|
videoElement.preload = "auto";
|
|
52895
|
-
_this.version = /* PLAYER_VERSION */"4.0.0-dev.
|
|
52980
|
+
_this.version = /* PLAYER_VERSION */"4.0.0-dev.2024030400";
|
|
52896
52981
|
_this.log = src_log;
|
|
52897
52982
|
_this.state = "STOPPED";
|
|
52898
52983
|
_this.videoElement = videoElement;
|
|
@@ -52947,10 +53032,6 @@ var Player = /*#__PURE__*/function (_EventEmitter) {
|
|
|
52947
53032
|
src_log.warn("API: Cannot rely on a WebWorker: Worker API unavailable");
|
|
52948
53033
|
return rej(new WorkerInitializationError("INCOMPATIBLE_ERROR", "Worker unavailable"));
|
|
52949
53034
|
}
|
|
52950
|
-
if (!has_webassembly) {
|
|
52951
|
-
src_log.warn("API: Cannot rely on a WebWorker: WebAssembly unavailable");
|
|
52952
|
-
return rej(new WorkerInitializationError("INCOMPATIBLE_ERROR", "WebAssembly unavailable"));
|
|
52953
|
-
}
|
|
52954
53035
|
if (typeof workerSettings.workerUrl === "string") {
|
|
52955
53036
|
_this2._priv_worker = new Worker(workerSettings.workerUrl);
|
|
52956
53037
|
} else {
|
|
@@ -55320,7 +55401,7 @@ var Player = /*#__PURE__*/function (_EventEmitter) {
|
|
|
55320
55401
|
}]);
|
|
55321
55402
|
return Player;
|
|
55322
55403
|
}(EventEmitter);
|
|
55323
|
-
Player.version = /* PLAYER_VERSION */"4.0.0-dev.
|
|
55404
|
+
Player.version = /* PLAYER_VERSION */"4.0.0-dev.2024030400";
|
|
55324
55405
|
/* harmony default export */ var public_api = (Player);
|
|
55325
55406
|
;// CONCATENATED MODULE: ./src/main_thread/api/index.ts
|
|
55326
55407
|
/**
|