aboutsummaryrefslogtreecommitdiff
path: root/Emby.Server.Implementations/LiveTv/LiveStreamHelper.cs
diff options
context:
space:
mode:
authorLuke Pulverenti <luke.pulverenti@gmail.com>2017-02-08 14:59:49 -0500
committerLuke Pulverenti <luke.pulverenti@gmail.com>2017-02-08 14:59:49 -0500
commit4941aa4d14f2a901890f91966c50f96308bb03ec (patch)
tree75b1761b45d69430f8884de9b7ec5022baba7b51 /Emby.Server.Implementations/LiveTv/LiveStreamHelper.cs
parentaba4933a5c7d80df44f546f1b9ae722a674e27ce (diff)
assume interlaced for external plugins
Diffstat (limited to 'Emby.Server.Implementations/LiveTv/LiveStreamHelper.cs')
-rw-r--r--Emby.Server.Implementations/LiveTv/LiveStreamHelper.cs14
1 files changed, 13 insertions, 1 deletions
diff --git a/Emby.Server.Implementations/LiveTv/LiveStreamHelper.cs b/Emby.Server.Implementations/LiveTv/LiveStreamHelper.cs
index 0313e6fde..2ee6869f6 100644
--- a/Emby.Server.Implementations/LiveTv/LiveStreamHelper.cs
+++ b/Emby.Server.Implementations/LiveTv/LiveStreamHelper.cs
@@ -6,6 +6,7 @@ using System.Threading.Tasks;
using MediaBrowser.Controller.MediaEncoding;
using MediaBrowser.Model.Dlna;
using MediaBrowser.Model.Dto;
+using MediaBrowser.Model.Entities;
using MediaBrowser.Model.Logging;
namespace Emby.Server.Implementations.LiveTv
@@ -21,7 +22,7 @@ namespace Emby.Server.Implementations.LiveTv
_logger = logger;
}
- public async Task AddMediaInfoWithProbe(MediaSourceInfo mediaSource, bool isAudio, CancellationToken cancellationToken)
+ public async Task AddMediaInfoWithProbe(MediaSourceInfo mediaSource, bool isAudio, bool assumeInterlaced, CancellationToken cancellationToken)
{
var originalRuntime = mediaSource.RunTimeTicks;
@@ -95,6 +96,17 @@ namespace Emby.Server.Implementations.LiveTv
videoStream.IsAVC = null;
}
+ if (assumeInterlaced)
+ {
+ foreach (var mediaStream in mediaSource.MediaStreams)
+ {
+ if (mediaStream.Type == MediaStreamType.Video)
+ {
+ mediaStream.IsInterlaced = true;
+ }
+ }
+ }
+
// Try to estimate this
mediaSource.InferTotalBitrate(true);
}