aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLuke Pulverenti <luke.pulverenti@gmail.com>2016-09-21 13:07:18 -0400
committerLuke Pulverenti <luke.pulverenti@gmail.com>2016-09-21 13:07:18 -0400
commitd94598a75e303c0b4f76392e1e26b819d73e87c1 (patch)
tree1c8d6ff2b5fc4c61ae9a1aa32567aa7d7c7177df
parent61ee765de96eeffa28b0042d633166ba5d214850 (diff)
update recording screens
-rw-r--r--MediaBrowser.Api/Playback/BaseStreamingService.cs4
-rw-r--r--MediaBrowser.Controller/Entities/IHasMetadata.cs2
-rw-r--r--MediaBrowser.MediaEncoding/Encoder/MediaEncoder.cs21
-rw-r--r--MediaBrowser.Server.Implementations/LiveTv/EmbyTV/EmbyTV.cs18
-rw-r--r--MediaBrowser.Server.Implementations/LiveTv/Listings/SchedulesDirect.cs24
-rw-r--r--MediaBrowser.Server.Startup.Common/ApplicationHost.cs17
6 files changed, 56 insertions, 30 deletions
diff --git a/MediaBrowser.Api/Playback/BaseStreamingService.cs b/MediaBrowser.Api/Playback/BaseStreamingService.cs
index 9a3659f07..7ef9a1d5b 100644
--- a/MediaBrowser.Api/Playback/BaseStreamingService.cs
+++ b/MediaBrowser.Api/Playback/BaseStreamingService.cs
@@ -367,6 +367,8 @@ namespace MediaBrowser.Api.Playback
{
param += " -crf 23";
}
+
+ param += " -tune zerolatency";
}
else if (string.Equals(videoEncoder, "libx265", StringComparison.OrdinalIgnoreCase))
@@ -1232,7 +1234,7 @@ namespace MediaBrowser.Api.Playback
private void StartThrottler(StreamState state, TranscodingJob transcodingJob)
{
- if (EnableThrottling(state) && !string.Equals(state.OutputVideoCodec, "copy", StringComparison.OrdinalIgnoreCase))
+ if (EnableThrottling(state))
{
transcodingJob.TranscodingThrottler = state.TranscodingThrottler = new TranscodingThrottler(transcodingJob, Logger, ServerConfigurationManager);
state.TranscodingThrottler.Start();
diff --git a/MediaBrowser.Controller/Entities/IHasMetadata.cs b/MediaBrowser.Controller/Entities/IHasMetadata.cs
index cf2f7db64..ae73dbeed 100644
--- a/MediaBrowser.Controller/Entities/IHasMetadata.cs
+++ b/MediaBrowser.Controller/Entities/IHasMetadata.cs
@@ -1,4 +1,5 @@
using System;
+using System.Collections.Generic;
namespace MediaBrowser.Controller.Entities
{
@@ -62,5 +63,6 @@ namespace MediaBrowser.Controller.Entities
int? GetInheritedParentalRatingValue();
int InheritedParentalRatingValue { get; set; }
+ List<string> GetInheritedTags();
}
}
diff --git a/MediaBrowser.MediaEncoding/Encoder/MediaEncoder.cs b/MediaBrowser.MediaEncoding/Encoder/MediaEncoder.cs
index a2707aace..b2c2b71f8 100644
--- a/MediaBrowser.MediaEncoding/Encoder/MediaEncoder.cs
+++ b/MediaBrowser.MediaEncoding/Encoder/MediaEncoder.cs
@@ -108,11 +108,6 @@ namespace MediaBrowser.MediaEncoding.Encoder
{
get
{
- if (_hasExternalEncoder)
- {
- return "External";
- }
-
if (string.IsNullOrWhiteSpace(FFMpegPath))
{
return null;
@@ -177,12 +172,6 @@ namespace MediaBrowser.MediaEncoding.Encoder
{
ConfigureEncoderPaths();
- if (_hasExternalEncoder)
- {
- LogPaths();
- return;
- }
-
// If the path was passed in, save it into config now.
var encodingOptions = GetEncodingOptions();
var appPath = encodingOptions.EncoderAppPath;
@@ -207,11 +196,6 @@ namespace MediaBrowser.MediaEncoding.Encoder
public async Task UpdateEncoderPath(string path, string pathType)
{
- if (_hasExternalEncoder)
- {
- return;
- }
-
Tuple<string, string> newPaths;
if (string.Equals(pathType, "system", StringComparison.OrdinalIgnoreCase))
@@ -256,11 +240,6 @@ namespace MediaBrowser.MediaEncoding.Encoder
private void ConfigureEncoderPaths()
{
- if (_hasExternalEncoder)
- {
- return;
- }
-
var appPath = GetEncodingOptions().EncoderAppPath;
if (string.IsNullOrWhiteSpace(appPath))
diff --git a/MediaBrowser.Server.Implementations/LiveTv/EmbyTV/EmbyTV.cs b/MediaBrowser.Server.Implementations/LiveTv/EmbyTV/EmbyTV.cs
index 2dd23857a..d4b21102d 100644
--- a/MediaBrowser.Server.Implementations/LiveTv/EmbyTV/EmbyTV.cs
+++ b/MediaBrowser.Server.Implementations/LiveTv/EmbyTV/EmbyTV.cs
@@ -843,6 +843,7 @@ namespace MediaBrowser.Server.Implementations.LiveTv.EmbyTV
if (recordingEndDate <= DateTime.UtcNow)
{
_logger.Warn("Recording timer fired for timer {0}, Id: {1}, but the program has already ended.", timer.Name, timer.Id);
+ _timerProvider.Delete(timer);
return;
}
@@ -1273,6 +1274,15 @@ namespace MediaBrowser.Server.Implementations.LiveTv.EmbyTV
writer.WriteElementString("rating", timer.CommunityRating.Value.ToString(CultureInfo.InvariantCulture));
}
+ if (timer.IsSports)
+ {
+ AddGenre(timer.Genres, "Sports");
+ }
+ if (timer.IsKids)
+ {
+ AddGenre(timer.Genres, "Kids");
+ }
+
foreach (var genre in timer.Genres)
{
writer.WriteElementString("genre", genre);
@@ -1294,6 +1304,14 @@ namespace MediaBrowser.Server.Implementations.LiveTv.EmbyTV
}
}
+ private void AddGenre(List<string> genres, string genre)
+ {
+ if (!genres.Contains(genre, StringComparer.OrdinalIgnoreCase))
+ {
+ genres.Add(genre);
+ }
+ }
+
private ProgramInfo GetProgramInfoFromCache(string channelId, string programId)
{
var epgData = GetEpgDataForChannel(channelId);
diff --git a/MediaBrowser.Server.Implementations/LiveTv/Listings/SchedulesDirect.cs b/MediaBrowser.Server.Implementations/LiveTv/Listings/SchedulesDirect.cs
index 0bc84a2e5..c3907c045 100644
--- a/MediaBrowser.Server.Implementations/LiveTv/Listings/SchedulesDirect.cs
+++ b/MediaBrowser.Server.Implementations/LiveTv/Listings/SchedulesDirect.cs
@@ -339,13 +339,18 @@ namespace MediaBrowser.Server.Implementations.LiveTv.Listings
channelNumber = channelNumber.TrimStart('0');
_logger.Debug("Found channel: " + channelNumber + " in Schedules Direct");
- if (root.stations != null)
+
+ var schChannel = (root.stations ?? new List<ScheduleDirect.Station>()).FirstOrDefault(item => string.Equals(item.stationID, map.stationID, StringComparison.OrdinalIgnoreCase));
+ if (schChannel != null)
{
- var schChannel = root.stations.FirstOrDefault(item => string.Equals(item.stationID, map.stationID, StringComparison.OrdinalIgnoreCase));
- if (schChannel != null)
+ AddToChannelPairCache(listingsId, channelNumber, schChannel);
+ }
+ else
+ {
+ AddToChannelPairCache(listingsId, channelNumber, new ScheduleDirect.Station
{
- AddToChannelPairCache(listingsId, channelNumber, schChannel);
- }
+ stationID = map.stationID
+ });
}
}
_logger.Info("Added " + GetChannelPairCacheCount(listingsId) + " channels to the dictionary");
@@ -361,8 +366,11 @@ namespace MediaBrowser.Server.Implementations.LiveTv.Listings
channel.ImageUrl = station.logo.URL;
channel.HasImage = true;
}
- string channelName = station.name;
- channel.Name = channelName;
+
+ if (!string.IsNullOrWhiteSpace(station.name))
+ {
+ channel.Name = station.name;
+ }
}
else
{
@@ -993,7 +1001,7 @@ namespace MediaBrowser.Server.Implementations.LiveTv.Listings
var name = channelNumber;
var station = GetStation(listingsId, channelNumber, null);
- if (station != null)
+ if (station != null && !string.IsNullOrWhiteSpace(station.name))
{
name = station.name;
}
diff --git a/MediaBrowser.Server.Startup.Common/ApplicationHost.cs b/MediaBrowser.Server.Startup.Common/ApplicationHost.cs
index d8d3614e6..9312e1501 100644
--- a/MediaBrowser.Server.Startup.Common/ApplicationHost.cs
+++ b/MediaBrowser.Server.Startup.Common/ApplicationHost.cs
@@ -873,6 +873,23 @@ namespace MediaBrowser.Server.Startup.Common
try
{
ServerManager.Start(GetUrlPrefixes(), CertificatePath);
+ return;
+ }
+ catch (Exception ex)
+ {
+ Logger.ErrorException("Error starting http server", ex);
+
+ if (HttpPort == 8096)
+ {
+ throw;
+ }
+ }
+
+ HttpPort = 8096;
+
+ try
+ {
+ ServerManager.Start(GetUrlPrefixes(), CertificatePath);
}
catch (Exception ex)
{