mirror of
https://github.com/jellyfin/jellyfin.git
synced 2024-09-06 11:34:57 +02:00
Merge pull request #7449 from crobibero/revert-clamp
This commit is contained in:
commit
cf47ee6261
1 changed files with 2 additions and 1 deletions
|
@ -909,8 +909,9 @@ namespace MediaBrowser.Model.Dlna
|
|||
}
|
||||
|
||||
// Make sure the video bitrate is lower than bitrate settings but at least 64k
|
||||
// Don't use Math.Clamp as availableBitrateForVideo can be lower then 64k.
|
||||
var currentValue = playlistItem.VideoBitrate ?? availableBitrateForVideo;
|
||||
playlistItem.VideoBitrate = Math.Clamp(currentValue, 64_000, availableBitrateForVideo);
|
||||
playlistItem.VideoBitrate = Math.Max(Math.Min(availableBitrateForVideo, currentValue), 64_000);
|
||||
}
|
||||
|
||||
_logger.LogInformation(
|
||||
|
|
Loading…
Reference in a new issue