diff --git a/MediaBrowser.Api/Playback/BaseStreamingService.cs b/MediaBrowser.Api/Playback/BaseStreamingService.cs
index 5d772527c1..9609d8c290 100644
--- a/MediaBrowser.Api/Playback/BaseStreamingService.cs
+++ b/MediaBrowser.Api/Playback/BaseStreamingService.cs
@@ -1,5 +1,4 @@
-using MediaBrowser.Api.Playback.Hls;
-using MediaBrowser.Common.Extensions;
+using MediaBrowser.Common.Extensions;
using MediaBrowser.Common.IO;
using MediaBrowser.Controller.Channels;
using MediaBrowser.Controller.Configuration;
diff --git a/MediaBrowser.Api/Playback/Hls/DynamicHlsService.cs b/MediaBrowser.Api/Playback/Hls/DynamicHlsService.cs
index 6657bf6de1..a098d26daa 100644
--- a/MediaBrowser.Api/Playback/Hls/DynamicHlsService.cs
+++ b/MediaBrowser.Api/Playback/Hls/DynamicHlsService.cs
@@ -342,7 +342,7 @@ namespace MediaBrowser.Api.Playback.Hls
AppendPlaylist(builder, playlistUrl, totalBitrate);
- if (state.VideoRequest.VideoBitRate.HasValue)
+ if (EnableAdaptiveBitrateStreaming(state))
{
var requestedVideoBitrate = state.VideoRequest.VideoBitRate.Value;
@@ -360,6 +360,17 @@ namespace MediaBrowser.Api.Playback.Hls
return builder.ToString();
}
+ private bool EnableAdaptiveBitrateStreaming(StreamState state)
+ {
+ if (string.IsNullOrWhiteSpace(state.MediaPath))
+ {
+ // Opening live streams is so slow it's not even worth it
+ return false;
+ }
+
+ return state.VideoRequest.VideoBitRate.HasValue;
+ }
+
private void AppendPlaylist(StringBuilder builder, string url, int bitrate)
{
builder.AppendLine("#EXT-X-STREAM-INF:PROGRAM-ID=1,BANDWIDTH=" + bitrate.ToString(UsCulture));
@@ -368,8 +379,8 @@ namespace MediaBrowser.Api.Playback.Hls
private int GetBitrateVariation(int bitrate)
{
- // By default, vary by just 200k
- var variation = 200000;
+ // By default, vary by just 100k
+ var variation = 100000;
if (bitrate >= 10000000)
{
@@ -391,6 +402,10 @@ namespace MediaBrowser.Api.Playback.Hls
{
variation = 300000;
}
+ else if (bitrate >= 600000)
+ {
+ variation = 200000;
+ }
return variation;
}
diff --git a/MediaBrowser.WebDashboard/Api/DashboardService.cs b/MediaBrowser.WebDashboard/Api/DashboardService.cs
index 186cf9fe34..aff19791de 100644
--- a/MediaBrowser.WebDashboard/Api/DashboardService.cs
+++ b/MediaBrowser.WebDashboard/Api/DashboardService.cs
@@ -426,9 +426,7 @@ namespace MediaBrowser.WebDashboard.Api
var files = new[]
{
"scripts/all.js" + versionString,
- "thirdparty/jstree1.0/jquery.jstree.min.js",
- "thirdparty/jquery.unveil-custom.js",
- "https://www.gstatic.com/cv/js/sender/v1/cast_sender.js"
+ "thirdparty/jstree1.0/jquery.jstree.min.js"
};
var tags = files.Select(s => string.Format("", s)).ToArray();
@@ -451,6 +449,9 @@ namespace MediaBrowser.WebDashboard.Api
await AppendResource(memoryStream, "thirdparty/jquery-2.0.3.min.js", newLineBytes).ConfigureAwait(false);
await AppendResource(memoryStream, "thirdparty/jquerymobile-1.4.3/jquery.mobile-1.4.3.min.js", newLineBytes).ConfigureAwait(false);
+ await AppendResource(memoryStream, "thirdparty/jquery.unveil-custom.js", newLineBytes).ConfigureAwait(false);
+ await AppendResource(memoryStream, "thirdparty/cast_sender.js", newLineBytes).ConfigureAwait(false);
+
await AppendLocalization(memoryStream).ConfigureAwait(false);
await memoryStream.WriteAsync(newLineBytes, 0, newLineBytes.Length).ConfigureAwait(false);
@@ -585,8 +586,6 @@ namespace MediaBrowser.WebDashboard.Api
"livetvstatus.js",
"livetvtimers.js",
- "localsettings.js",
-
"loginpage.js",
"logpage.js",
"medialibrarypage.js",
diff --git a/MediaBrowser.WebDashboard/MediaBrowser.WebDashboard.csproj b/MediaBrowser.WebDashboard/MediaBrowser.WebDashboard.csproj
index e08da4e004..cabc7ef975 100644
--- a/MediaBrowser.WebDashboard/MediaBrowser.WebDashboard.csproj
+++ b/MediaBrowser.WebDashboard/MediaBrowser.WebDashboard.csproj
@@ -278,9 +278,6 @@
PreserveNewest
-
- PreserveNewest
-
PreserveNewest
@@ -461,21 +458,9 @@
PreserveNewest
-
- PreserveNewest
-
PreserveNewest
-
- PreserveNewest
-
-
- PreserveNewest
-
-
- PreserveNewest
-
PreserveNewest
@@ -674,9 +659,6 @@
PreserveNewest
-
- PreserveNewest
-
PreserveNewest
@@ -806,6 +788,9 @@
PreserveNewest
+
+ PreserveNewest
+
PreserveNewest