allow bitrate upscaling

This commit is contained in:
Luke Pulverenti 2013-10-23 12:03:22 -04:00
parent 6415776cd1
commit ffcfa2d858

View File

@ -693,15 +693,7 @@ namespace MediaBrowser.Api.Playback
protected int? GetVideoBitrateParam(StreamState state) protected int? GetVideoBitrateParam(StreamState state)
{ {
if (state.VideoRequest.VideoBitRate.HasValue) return state.VideoRequest.VideoBitRate;
{
// Make sure we don't request a bitrate higher than the source
var currentBitrate = state.VideoStream == null ? state.VideoRequest.VideoBitRate.Value : state.VideoStream.BitRate ?? state.VideoRequest.VideoBitRate.Value;
return Math.Min(currentBitrate, state.VideoRequest.VideoBitRate.Value);
}
return null;
} }
protected int? GetAudioBitrateParam(StreamState state) protected int? GetAudioBitrateParam(StreamState state)