Properly set initial video quality

pull/270/head
ElementalAlchemist 3 years ago committed by Mike Lang
parent e515c448eb
commit 8e8ace6f3c

@ -70,6 +70,11 @@ async function loadVideoPlayer(playlistURL) {
setUpVideoControls(); setUpVideoControls();
}); });
videoElement.addEventListener("loadeddata", (_event) => {
const qualitySelector = document.getElementById("video-controls-quality");
globalPlayer.currentLevel = +qualitySelector.value;
});
globalPlayer = new Hls(); globalPlayer = new Hls();
globalPlayer.attachMedia(video); globalPlayer.attachMedia(video);
return new Promise((resolve, _reject) => { return new Promise((resolve, _reject) => {

Loading…
Cancel
Save