stormcloud-video-player 0.6.6 → 0.7.1
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/dist/stormcloud-vp.min.js +1 -1
- package/lib/index.cjs +1340 -118
- package/lib/index.cjs.map +1 -1
- package/lib/index.d.cts +65 -1
- package/lib/index.d.ts +65 -1
- package/lib/index.js +1306 -100
- package/lib/index.js.map +1 -1
- package/lib/player/StormcloudVideoPlayer.cjs +40 -0
- package/lib/player/StormcloudVideoPlayer.cjs.map +1 -1
- package/lib/player/StormcloudVideoPlayer.d.cts +4 -0
- package/lib/players/HlsPlayer.cjs +40 -0
- package/lib/players/HlsPlayer.cjs.map +1 -1
- package/lib/players/index.cjs +40 -0
- package/lib/players/index.cjs.map +1 -1
- package/lib/ui/OverlayRenderer.cjs +1189 -0
- package/lib/ui/OverlayRenderer.cjs.map +1 -0
- package/lib/ui/OverlayRenderer.d.cts +15 -0
- package/lib/ui/StormcloudVideoPlayer.cjs +1300 -94
- package/lib/ui/StormcloudVideoPlayer.cjs.map +1 -1
- package/lib/ui/StormcloudVideoPlayer.d.cts +1 -0
- package/lib/utils/overlays.cjs +286 -0
- package/lib/utils/overlays.cjs.map +1 -0
- package/lib/utils/overlays.d.cts +60 -0
- package/package.json +1 -1
|
@@ -5982,6 +5982,46 @@ var StormcloudVideoPlayer = /*#__PURE__*/ function() {
|
|
|
5982
5982
|
return this.isLiveStream;
|
|
5983
5983
|
}
|
|
5984
5984
|
},
|
|
5985
|
+
{
|
|
5986
|
+
key: "getMinHlsResolution",
|
|
5987
|
+
value: function getMinHlsResolution() {
|
|
5988
|
+
var _this_hls;
|
|
5989
|
+
var levels = (_this_hls = this.hls) === null || _this_hls === void 0 ? void 0 : _this_hls.levels;
|
|
5990
|
+
if (!levels || levels.length === 0) return null;
|
|
5991
|
+
var min = null;
|
|
5992
|
+
var minPixels = Infinity;
|
|
5993
|
+
var _iteratorNormalCompletion = true, _didIteratorError = false, _iteratorError = undefined;
|
|
5994
|
+
try {
|
|
5995
|
+
for(var _iterator = levels[Symbol.iterator](), _step; !(_iteratorNormalCompletion = (_step = _iterator.next()).done); _iteratorNormalCompletion = true){
|
|
5996
|
+
var level = _step.value;
|
|
5997
|
+
if (level.width && level.height) {
|
|
5998
|
+
var pixels = level.width * level.height;
|
|
5999
|
+
if (pixels < minPixels) {
|
|
6000
|
+
minPixels = pixels;
|
|
6001
|
+
min = {
|
|
6002
|
+
width: level.width,
|
|
6003
|
+
height: level.height
|
|
6004
|
+
};
|
|
6005
|
+
}
|
|
6006
|
+
}
|
|
6007
|
+
}
|
|
6008
|
+
} catch (err) {
|
|
6009
|
+
_didIteratorError = true;
|
|
6010
|
+
_iteratorError = err;
|
|
6011
|
+
} finally{
|
|
6012
|
+
try {
|
|
6013
|
+
if (!_iteratorNormalCompletion && _iterator.return != null) {
|
|
6014
|
+
_iterator.return();
|
|
6015
|
+
}
|
|
6016
|
+
} finally{
|
|
6017
|
+
if (_didIteratorError) {
|
|
6018
|
+
throw _iteratorError;
|
|
6019
|
+
}
|
|
6020
|
+
}
|
|
6021
|
+
}
|
|
6022
|
+
return min;
|
|
6023
|
+
}
|
|
6024
|
+
},
|
|
5985
6025
|
{
|
|
5986
6026
|
key: "videoElement",
|
|
5987
6027
|
get: function get() {
|