aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLuke Pulverenti <luke.pulverenti@gmail.com>2016-10-27 23:15:34 -0400
committerLuke Pulverenti <luke.pulverenti@gmail.com>2016-10-27 23:15:34 -0400
commit8030370cfad2fe3426f7c178407af1ffca8c9abc (patch)
treec31d32c53b841e6d696f28bed53458d77357fa3f
parentbdcaf5dd023a6bc0470915e07cc7fe7a46cb6c5d (diff)
remove audio channel limit from transcoding conditions
-rw-r--r--MediaBrowser.Api/Playback/BaseStreamingService.cs7
1 files changed, 2 insertions, 5 deletions
diff --git a/MediaBrowser.Api/Playback/BaseStreamingService.cs b/MediaBrowser.Api/Playback/BaseStreamingService.cs
index a05a84b98..b9f4473c6 100644
--- a/MediaBrowser.Api/Playback/BaseStreamingService.cs
+++ b/MediaBrowser.Api/Playback/BaseStreamingService.cs
@@ -893,12 +893,9 @@ namespace MediaBrowser.Api.Playback
resultChannels = Math.Min(request.MaxAudioChannels.Value, channelLimit);
}
- if (resultChannels.HasValue && !string.Equals(codec, "copy", StringComparison.OrdinalIgnoreCase))
+ if (request.TranscodingMaxAudioChannels.HasValue && !string.Equals(codec, "copy", StringComparison.OrdinalIgnoreCase))
{
- if (request.TranscodingMaxAudioChannels.HasValue)
- {
- resultChannels = Math.Min(request.TranscodingMaxAudioChannels.Value, resultChannels.Value);
- }
+ resultChannels = Math.Min(request.TranscodingMaxAudioChannels.Value, resultChannels ?? inputChannels ?? request.TranscodingMaxAudioChannels.Value);
}
return resultChannels ?? request.AudioChannels;