jellyfin/MediaBrowser.Controller
scheilch 5cfa466d8b
fix: cap GetVideoBitrateParamValue at 400 Mbps (#16467)
* fix: cap GetVideoBitrateParamValue at 400 Mbps

The previous cap of int.MaxValue / 2 (~1073 Mbps) is far beyond any
realistic transcode target and allows encoder parameters derived from
it (e.g. -bufsize = bitrate * 4 for QSV) to grow to multi-gigabit
values, which is incorrect regardless of whether the encoder tolerates it.

400 Mbps is a safe upper bound for all current hardware encoders:
- Intel QSV H.264 peaks at ~300 Mbps (High 5.1 CPB = 168.75 Mbit)
- HEVC High Tier Level 5.x supports ~240 Mbps
- AV1 hardware encoders have no meaningful real-world constraint at
  this level

The existing FallbackMaxStreamingBitrate mechanism (default 30 Mbps)
provides a similar guard but only when LiveStreamId is set, covering
M3U and HDHR sources. Plugin-provided streams and any source that
bypasses the LiveTV pipeline are not subject to it and can pass
unreasonably high values downstream. This cap closes that gap for
all encoder paths.

Suggested by @nyanmisaka in review of #16376.

* Update MediaBrowser.Controller/MediaEncoding/EncodingHelper.cs

---------

Co-authored-by: Bond-009 <bond.009@outlook.com>
2026-03-29 12:39:16 +02:00
..
Authentication Merge pull request #14950 from nielsvanvelzen/security-remove-has-password 2025-11-27 16:31:05 +01:00
BaseItemManager
Channels
Chapters Remove chapters on file change (#14984) 2025-10-13 12:32:41 -06:00
ClientEvent
Collections
Configuration
Devices
Drawing
Dto Cleanup ItemFields (#13818) 2025-03-31 17:46:21 -06:00
Entities Merge pull request #16388 from theguymadmax/respect-library-country-code 2026-03-13 20:25:08 +01:00
Events
Extensions Avoid constant arrays as arguments (#14784) 2025-09-12 13:58:28 -06:00
IO Backport pull request #15568 from jellyfin/release-10.11.z 2025-12-03 14:04:23 -05:00
Library Backport pull request #15965 from jellyfin/release-10.11.z 2026-01-18 11:30:39 -05:00
LibraryTaskScheduler Fix tests 2026-01-14 18:55:47 +01:00
LiveTv
Lyrics
MediaEncoding fix: cap GetVideoBitrateParamValue at 400 Mbps (#16467) 2026-03-29 12:39:16 +02:00
MediaSegments Fix existing media segments not being handled on scan (#14218) 2025-06-10 07:45:09 -06:00
Net Allow non-admin users to subscribe to their own Sessions (#13767) 2025-09-12 14:15:00 -06:00
Persistence Backport pull request #15899 from jellyfin/release-10.11.z 2026-01-18 11:30:38 -05:00
Playlists Change moveToTop in AddItemToPlaylistAsync to 0-based position 2025-10-23 19:27:34 -05:00
Plugins
Properties
Providers
QuickConnect
Resolvers
Security
Session Backport pull request #16109 from jellyfin/release-10.11.z 2026-01-28 12:11:30 -05:00
Sorting Replace AlphanumericComparator with new CompareOptions.NumericOrdering 2026-01-14 18:55:47 +01:00
Streaming
Subtitles
SyncPlay Return SyncPlay group info after creation, add GET group endpoint (#13935) 2025-04-20 19:40:23 -06:00
SystemBackupService Add declarative backups for migrations (#14135) 2025-06-03 16:49:41 -06:00
Trickplay Cleanup external item data cleanup (#14072) 2025-05-09 08:35:29 -06:00
TV
IDisplayPreferencesManager.cs Refactor Display preference manager (#14056) 2025-09-05 14:39:15 -06:00
IServerApplicationHost.cs Add Full system backup feature (#13945) 2025-05-18 18:39:04 -06:00
IServerApplicationPaths.cs Check for path overlaps (#12832) 2025-04-26 09:30:25 -06:00
ISystemManager.cs Add Api and startup check for sufficient storage capacity (#13888) 2025-04-20 20:06:50 -06:00
MediaBrowser.Controller.csproj Update to .NET 10.0 2026-01-14 18:55:47 +01:00