aboutsummaryrefslogtreecommitdiff
path: root/Jellyfin.Api/Helpers
AgeCommit message (Collapse)Author
25 hoursRun tree-wide dotnet formatjakobkukla
2026-04-06Fix GHSA-jh22-fw8w-2v9xShadowghost
2026-04-06Add additional validationsShadowghost
2026-03-28Add spec-compliant dvh1 HLS variant for Dolby Vision Profile 5 (#16362)NoFear0411
* Add spec-compliant dvh1 HLS variant for Dolby Vision Profile 5 DV Profile 5 has no backward-compatible base layer, so SUPPLEMENTAL-CODECS cannot be used. The master playlist currently labels P5 streams as hvc1 in the CODECS field, even though DynamicHlsController already passes -tag:v:0 dvh1 -strict -2 to FFmpeg for P5 copy-codec streams, writing a dvh1 FourCC and dvvC configuration box into the fMP4 init segment. This mismatch between the manifest (hvc1) and the bitstream (dvh1) causes spec-compliant clients like Apple TV and webOS 24+ to set up an HDR10 pipeline instead of a Dolby Vision one. Add a dvh1 variant before the existing hvc1 variant for P5 copy-codec streams. Both variants point to the same stream URL. Spec-compliant clients select dvh1 and activate the DV decoder path. Legacy clients that reject dvh1 in CODECS fall through to the hvc1 variant and detect DV from the init segment, preserving existing behavior. Fixes #16179 * Address review: support AV1 DoVi P10, add client capability check - GetDoviString: add isAv1 parameter, return dav1 FourCC for AV1 DoVi (P10 bl_compat_id=0) and dvh1 for HEVC DoVi (P5) - Remove redundant IsDovi() check; VideoRangeType.DOVI is sufficient and correctly limits to profiles without a compatible base layer - Replace IsDoviRemoved() with client capability check using GetRequestedRangeTypes(state.VideoStream.Codec) to only emit the dvh1/dav1 variant for clients that declared DOVI support - Update comments and doc summary to reflect P5 + P10/bl0 scope * Use codec string instead of boolean for DoVi FourCC mapping Replace bool isAv1 with string codec in GetDoviString for future-proofing when DoVi extends to H.266/VVC or AV2. * Move AppendDoviPlaylist next to AppendPlaylist * Fix SA1508: remove blank line before closing brace * Use AppendLine() instead of Append(Environment.NewLine)
2026-02-18Fix malformed query string in StreamInfo.ToUrl() causing 500 error via proxiesCosmin Dumitru
StreamInfo.ToUrl() generated URLs like `/master.m3u8?&DeviceId=...` (note `?&`) because `?` was appended to the path and all parameters started with `&`. When the first optional parameter (DeviceProfileId) was null, the result was a malformed query string. This is harmless when clients hit Jellyfin directly (ASP.NET Core tolerates `?&`), but when accessed through a reverse proxy that parses and re-serializes the URL (e.g. Home Assistant ingress via aiohttp/yarl), `?&` becomes `?=&` — introducing an empty-key query parameter. ParseStreamOptions then crashes on `param.Key[0]` with IndexOutOfRangeException. Changes: - StreamInfo.ToUrl(): Track query start position and replace the first `&` with `?` after all parameters are appended, producing valid query strings - ParseStreamOptions: Guard against empty query parameter keys - Tests: Remove .Replace("?&", "?") workaround that masked the bug Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-01-18Merge pull request #15926 from abitofevrything/feat/accurate_hls_seekingAbitofevrything
Refactor HLS transcode seeking
2026-01-14Update to .NET 10.0Bond_009
2026-01-06Add TrueHD and DTS codes string for HLSnyanmisaka
Signed-off-by: nyanmisaka <nst799610810@gmail.com>
2025-12-28Backport pull request #15833 from jellyfin/release-10.11.znyanmisaka
Fix missing H.264 and AV1 SDR fallbacks in HLS playlist Original-merge: 01b20d3b75e00909e7a531a625eda5ecb1a76f42 Merged-by: Bond-009 <bond.009@outlook.com> Backported-by: Bond_009 <bond.009@outlook.com>
2025-12-28Backport pull request #15690 from jellyfin/release-10.11.zmartenumberto
Fix: Add .ts fallback for video streams to prevent crash Original-merge: 2a0b90e3852edae22d9f7cec197e6e81e9415632 Merged-by: crobibero <cody@robibe.ro> Backported-by: Bond_009 <bond.009@outlook.com>
2025-08-03Merge pull request #14021 from sususu98/enhancement/strmSeekJoshua M. Boniface
Enhanced HTTP Range request support for. strm file
2025-07-20Use RequestHelpers.GetSession in SessionWebSocketListener (#14494)Niels van Velzen
2025-04-29Enhanced HTTP Range request support for. strm filesususu98
Forward the Range, Accept-Ranges, and Content- Range headers, improve User-Agent handling, and adjust the default Content-Type.
2025-04-08Only reselect audio streams when user preference is respected (#13832)gnattu
2025-04-02Improve dynamic HDR metadata handling (#13277)gnattu
* Add support for bitstream filter to remove dynamic hdr metadata * Add support for ffprobe's only_first_vframe for HDR10+ detection * Add BitStreamFilterOptionType for metadata removal check * Map HDR10+ metadata to VideoRangeType.cs Current implementation uses a hack that abuses the EL flag to avoid database schema changes. Should add proper field once EFCore migration is merged. * Add more Dolby Vision Range types Out of spec ones are problematic and should be marked as a dedicated invalid type and handled by the server to not crash the player. Profile 7 videos should not be treated as normal HDR10 videos at all and should remove the metadata before serving. * Remove dynamic hdr metadata when necessary * Allow direct playback of HDR10+ videos on HDR10 clients * Only use dovi codec tag when dovi metadata is not removed * Handle DV Profile 7 Videos better * Fix HDR10+ with new bitmask * Indicate the presence of HDR10+ in HLS SUPPLEMENTAL-CODECS * Fix Dovi 8.4 not labeled as HLG in HLS * Fallback to dovi_rpu bsf for av1 when possible * Fix dovi_rpu cli for av1 * Use correct EFCore db column for HDR10+ * Undo outdated migration * Add proper hdr10+ migration * Remove outdated migration * Rebase to new db code * Add migrations for Hdr10PlusPresentFlag * Directly use bsf enum * Add xmldocs for SupportsBitStreamFilterWithOption * Make `VideoRangeType.Unknown` explicitly default on api models. * Unset default for non-api model class * Use tuples for bsf dictionary for now
2025-03-28Reduce allocations, simplifed code, faster implementation, included tests - ↵Tim Eisele
StreamInfo.ToUrl (#9369) * Rework PR 6168 * Fix test
2025-03-25Fixed namespacesJPVenson
2025-03-25WIP fixed namespacesJPVenson
2025-02-05Merge remote-tracking branch 'jellyfinorigin/master' into feature/pgsql_providerJPVenson
2025-02-03Backport pull request #13169 from jellyfin/release-10.10.zgnattu
Check if the video has an audio track before codec fallback Original-merge: ff4f3b04411833dd7675be870dde9212394acf95 Merged-by: Bond-009 <bond.009@outlook.com> Backported-by: Bond_009 <bond.009@outlook.com>
2025-02-03Backport pull request #13127 from jellyfin/release-10.10.zgnattu
Fallback to lossy audio codec for bitrate limit Original-merge: 65f722f23c781d6346741589a681b8b00579fc8a Merged-by: crobibero <cody@robibe.ro> Backported-by: Bond_009 <bond.009@outlook.com>
2025-02-02Merge remote-tracking branch 'jellyfinorigin/master' into feature/pgsql_providerJPVenson
2025-01-28Remove useless checks and dead code (#13405)Bond-009
* Remove useless checks and dead code * Enable adaptive bitrate streaming again * Disable adaptive bitrate streaming by default
2025-01-28Fix spelling (#13444)Josh Soref
* spelling: anamorphic Signed-off-by: Josh Soref <2119212+jsoref@users.noreply.github.com> * spelling: associated Signed-off-by: Josh Soref <2119212+jsoref@users.noreply.github.com> * spelling: channelinfo Signed-off-by: Josh Soref <2119212+jsoref@users.noreply.github.com> * spelling: eagerly Signed-off-by: Josh Soref <2119212+jsoref@users.noreply.github.com> * spelling: enumerable Signed-off-by: Josh Soref <2119212+jsoref@users.noreply.github.com> * spelling: greater than/less than Signed-off-by: Josh Soref <2119212+jsoref@users.noreply.github.com> * spelling: greater Signed-off-by: Josh Soref <2119212+jsoref@users.noreply.github.com> * spelling: lineup Signed-off-by: Josh Soref <2119212+jsoref@users.noreply.github.com> * spelling: logs out Signed-off-by: Josh Soref <2119212+jsoref@users.noreply.github.com> * spelling: names Signed-off-by: Josh Soref <2119212+jsoref@users.noreply.github.com> * spelling: paging Signed-off-by: Josh Soref <2119212+jsoref@users.noreply.github.com> * spelling: playlist Signed-off-by: Josh Soref <2119212+jsoref@users.noreply.github.com> * spelling: sanitized Signed-off-by: Josh Soref <2119212+jsoref@users.noreply.github.com> * spelling: saving Signed-off-by: Josh Soref <2119212+jsoref@users.noreply.github.com> --------- Signed-off-by: Josh Soref <2119212+jsoref@users.noreply.github.com>
2025-01-26Prepared Seperation of Database components for future multi provider supportJPVenson
2025-01-25Merge pull request #12798 from JPVenson/feature/EFUserDataJoshua M. Boniface
Refactor library.db into jellyfin.db and EFCore
2025-01-22Enable adaptive bitrate streaming againBond_009
2025-01-22Remove useless checks and dead codeBond_009
2025-01-11Prefer ApiKey over api_key in generated URL's (#13342)Niels van Velzen
2024-10-09Ported new Item Repository architectureJPVenson
2024-09-21Better bitrate and resolution normalization (#12644)gnattu
2024-09-22Conditionally add burn in option for remote sourcegnattu
2024-09-22Let HLS Controller decide if subtitle should be burn ingnattu
Previously, we predicted whether the subtitle should be burned in with transcode reasons, but that was not accurate because the actual transcoding codec is only determined after the client has requested the stream. This pass through the option to the `DynamicHlsController` to handle the subtitle burn-in during the actual transcoding process. Now the client should be responsible to conditionally load the subtitle when this option is enabled.
2024-09-12Add option to always burn in subtitles if transcoding is triggered (#12430)gnattu
2024-09-07Make Live TV compatibility profiles customizable (#12529)gnattu
2024-09-07Add SUPPLEMENTAL-CODECS for Dolby Vision video with fallbacks (#12605)gnattu
2024-09-07Add MediaStream.ReferenceFrameRate for problematic video files (#12603)gnattu
Co-authored-by: Nyanmisaka <nst799610810@gmail.com>
2024-08-30Remove BOM from UTF-8 filesBond_009
I think some people need to change their IDE configuration ;)
2024-08-28Use Apple reccomended values for HLS CODECSBond_009
2024-08-28Merge pull request #11665 from Bond-009/getuserbyidCody Robibero
2024-08-05Change arguments AssertCanUpdateUser to take a userBond_009
2024-08-05Merge branch 'master' into fix-hwa-video-rotationNyanmisaka
2024-07-23Merge branch 'master' into fix-hwa-video-rotationNyanmisaka
2024-07-20Don't buffer content in GetStaticRemoteStreamResultBond_009
2024-07-18Merge pull request #11399 from jellyfin/audio-remuxCody Robibero
2024-07-17Merge pull request #11489 from jellyfin/allow-vp9-remuxingCody Robibero
2024-07-17feat: add audio remux to UniversalAudioControllergnattu
Signed-off-by: gnattu <gnattuoc@me.com>
2024-06-23Backport pull request #12017 from jellyfin/release-10.9.zgnattu
Overwrite supported codecs for livetv Original-merge: 2b789807474ec4e7d5f8837a6503a7684fa94778 Merged-by: Bond-009 <bond.009@outlook.com> Backported-by: Joshua M. Boniface <joshua@boniface.me>
2024-06-01Backport pull request #11851 from jellyfin/release-10.9.zgnattu
Relax remuxing requirement for LiveTV Original-merge: 0392daa10397c40d62e2068cd85e030d9ca2d898 Merged-by: crobibero <cody@robibe.ro> Backported-by: Joshua M. Boniface <joshua@boniface.me>
2024-05-25Backport pull request #11801 from jellyfin/release-10.9.zgnattu
Force more compatible transcoding profile for LiveTV Original-merge: e7b1162cb30601297f987a6409a7d76b40aa74a6 Merged-by: crobibero <cody@robibe.ro> Backported-by: Joshua M. Boniface <joshua@boniface.me>