update program titles

This commit is contained in:
Luke Pulverenti
2017-01-21 15:27:07 -05:00
parent 0bf95da493
commit 2ef30a3ba8
27 changed files with 288 additions and 286 deletions

View File

@@ -1064,6 +1064,8 @@ namespace Emby.Server.Implementations.LiveTv.EmbyTV
var isAudio = false;
await new LiveStreamHelper(_mediaEncoder, _logger).AddMediaInfoWithProbe(stream, isAudio, cancellationToken).ConfigureAwait(false);
stream.InferTotalBitrate();
return new List<MediaSourceInfo>
{
stream

View File

@@ -96,15 +96,7 @@ namespace Emby.Server.Implementations.LiveTv
}
// Try to estimate this
if (!mediaSource.Bitrate.HasValue)
{
var total = mediaSource.MediaStreams.Select(i => i.BitRate ?? 0).Sum();
if (total > 0)
{
mediaSource.Bitrate = total;
}
}
mediaSource.InferTotalBitrate();
}
}
}

View File

@@ -459,15 +459,7 @@ namespace Emby.Server.Implementations.LiveTv
}
// Set the total bitrate if not already supplied
if (!mediaSource.Bitrate.HasValue)
{
var total = mediaSource.MediaStreams.Select(i => i.BitRate ?? 0).Sum();
if (total > 0)
{
mediaSource.Bitrate = total;
}
}
mediaSource.InferTotalBitrate();
if (!(service is EmbyTV.EmbyTV))
{

View File

@@ -200,15 +200,7 @@ namespace Emby.Server.Implementations.LiveTv
}
// Try to estimate this
if (!mediaSource.Bitrate.HasValue)
{
var total = mediaSource.MediaStreams.Select(i => i.BitRate ?? 0).Sum();
if (total > 0)
{
mediaSource.Bitrate = total;
}
}
mediaSource.InferTotalBitrate();
}
public Task CloseMediaSource(string liveStreamId)

View File

@@ -431,6 +431,8 @@ namespace Emby.Server.Implementations.LiveTv.TunerHosts.HdHomerun
IsInfiniteStream = true
};
mediaSource.InferTotalBitrate();
return mediaSource;
}

View File

@@ -25,7 +25,6 @@ namespace Emby.Server.Implementations.LiveTv.TunerHosts.HdHomerun
private readonly TaskCompletionSource<bool> _liveStreamTaskCompletionSource = new TaskCompletionSource<bool>();
private readonly MulticastStream _multicastStream;
public HdHomerunLiveStream(MediaSourceInfo mediaSource, string originalStreamId, IFileSystem fileSystem, IHttpClient httpClient, ILogger logger, IServerApplicationPaths appPaths, IServerApplicationHost appHost)
: base(mediaSource)
{

View File

@@ -164,6 +164,8 @@ namespace Emby.Server.Implementations.LiveTv.TunerHosts
IsRemote = true
};
mediaSource.InferTotalBitrate();
return new List<MediaSourceInfo> { mediaSource };
}
return new List<MediaSourceInfo>();