mirror of
https://github.com/jellyfin/jellyfin-web
synced 2025-03-30 19:56:21 +00:00
update components
This commit is contained in:
parent
2a72f0256e
commit
048ba20590
26 changed files with 1377 additions and 136 deletions
|
@ -60,11 +60,12 @@ class LevelController extends EventHandler {
|
|||
|
||||
// only keep level with supported audio/video codecs
|
||||
levels = levels.filter(function(level) {
|
||||
var checkSupported = function(codec) { return MediaSource.isTypeSupported(`video/mp4;codecs=${codec}`);};
|
||||
var checkSupportedAudio = function(codec) { return MediaSource.isTypeSupported(`audio/mp4;codecs=${codec}`);};
|
||||
var checkSupportedVideo = function(codec) { return MediaSource.isTypeSupported(`video/mp4;codecs=${codec}`);};
|
||||
var audioCodec = level.audioCodec, videoCodec = level.videoCodec;
|
||||
|
||||
return (!audioCodec || checkSupported(audioCodec)) &&
|
||||
(!videoCodec || checkSupported(videoCodec));
|
||||
return (!audioCodec || checkSupportedAudio(audioCodec)) &&
|
||||
(!videoCodec || checkSupportedVideo(videoCodec));
|
||||
});
|
||||
|
||||
if(levels.length) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue