1
0
Fork 0
mirror of https://github.com/jellyfin/jellyfin-web synced 2025-03-30 19:56:21 +00:00

use mp4 with firefox

This commit is contained in:
Luke Pulverenti 2013-09-30 14:49:30 -04:00
parent 90aef42513
commit 4f1de0b027

View file

@ -498,7 +498,7 @@
} }
// Webm must be ahead of mp4 due to the issue of mp4 playing too fast in chrome // Webm must be ahead of mp4 due to the issue of mp4 playing too fast in chrome
var prioritizeWebmOverH264 = true; var prioritizeWebmOverH264 = $.browser.chrome || $.browser.msie;
var h264Codec = 'h264'; var h264Codec = 'h264';
var h264AudioCodec = 'aac'; var h264AudioCodec = 'aac';
@ -507,8 +507,13 @@
var videoCodec = (videoStream.Codec || '').toLowerCase(); var videoCodec = (videoStream.Codec || '').toLowerCase();
if (videoCodec.indexOf('h264') != -1) { if (videoCodec.indexOf('h264') != -1 &&
// h264Codec = 'copy'; videoStream.Width &&
videoStream.Width <= 1280 &&
videoStream.BitRate &&
videoStream.BitRate <= 2000000) {
//h264Codec = 'copy';
} }
} }
@ -561,7 +566,6 @@
html += '<source type="video/webm" src="' + webmVideoUrl + '" />'; html += '<source type="video/webm" src="' + webmVideoUrl + '" />';
html += '<source type="video/mp4" src="' + mp4VideoUrl + '" />'; html += '<source type="video/mp4" src="' + mp4VideoUrl + '" />';
} else { } else {
html += '<source type="video/mp4" src="' + mp4VideoUrl + '" />'; html += '<source type="video/mp4" src="' + mp4VideoUrl + '" />';
html += '<source type="video/webm" src="' + webmVideoUrl + '" />'; html += '<source type="video/webm" src="' + webmVideoUrl + '" />';
} }