allow specification of m3u stream limit

This commit is contained in:
Luke Pulverenti
2017-11-17 16:54:33 -05:00
parent ceee0cdcca
commit 1dc8ff9e91
10 changed files with 57 additions and 24 deletions

View File

@@ -1341,13 +1341,11 @@ namespace MediaBrowser.Model.Dlna
return false;
}
if (!item.Bitrate.HasValue)
{
_logger.Info("Cannot " + playMethod + " due to unknown content bitrate");
return false;
}
// If we don't know the bitrate, then force a transcode if requested max bitrate is under 40 mbps
var itemBitrate = item.Bitrate ??
40000000;
if (item.Bitrate.Value > maxBitrate.Value)
if (itemBitrate > maxBitrate.Value)
{
_logger.Info("Bitrate exceeds " + playMethod + " limit: media bitrate: {0}, max bitrate: {1}", item.Bitrate.Value.ToString(CultureInfo.InvariantCulture), maxBitrate.Value.ToString(CultureInfo.InvariantCulture));
return false;

View File

@@ -47,6 +47,7 @@ namespace MediaBrowser.Model.LiveTv
public bool EnableStreamLooping { get; set; }
public bool EnableNewHdhrChannelIds { get; set; }
public string Source { get; set; }
public int TunerCount { get; set; }
public TunerHostInfo()
{