Commit Graph

18 Commits

Author SHA1 Message Date
NoFear0411
e5bbb1ea0c Add spec-compliant dvh1 HLS variant for Dolby Vision Profile 5 (#16362)
Some checks failed
CodeQL / Analyze (csharp) (push) Has been cancelled
OpenAPI / OpenAPI - HEAD (push) Has been cancelled
OpenAPI / OpenAPI - BASE (push) Has been cancelled
OpenAPI / OpenAPI - Difference (push) Has been cancelled
OpenAPI / OpenAPI - Publish Unstable Spec (push) Has been cancelled
OpenAPI / OpenAPI - Publish Stable Spec (push) Has been cancelled
Tests / run-tests (macos-latest) (push) Has been cancelled
Tests / run-tests (ubuntu-latest) (push) Has been cancelled
Tests / run-tests (windows-latest) (push) Has been cancelled
Merge Conflict Labeler / Labeling (push) Has been cancelled
Project Automation / Project board (push) Has been cancelled
Stale PR Check / Check PRs with merge conflicts (push) Has been cancelled
* 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✌️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-03-28 22:12:06 +01:00
nyanmisaka
582a1d9866 Add TrueHD and DTS codes string for HLS
Signed-off-by: nyanmisaka <nst799610810@gmail.com>
2026-01-06 23:15:06 +08:00
Bond_009
97a02f5803 Remove BOM from UTF-8 files
I think some people need to change their IDE configuration ;)
2024-08-30 15:29:48 +02:00
Bond_009
d352d883d3 Use Apple reccomended values for HLS CODECS 2024-08-28 22:57:42 +02:00
gnattu
5df171b3f9 Add remuxing support for VP9
Add VP9 as a valid HLS format to enable remuxing. This is useful when audio processing is required, but the VP9 video can be passed as-is to avoid unnecessary video transcoding.

No VP9 encoder is enabled and should not be enabled. AV1 and HEVC should be preferred over VP9 if video transcoding is required.

Signed-off-by: gnattu <gnattuoc@me.com>
2024-05-16 09:34:21 +08:00
gnattu
0af101cbf7 fix: av1 codecs string (#11280)
Co-authored-by: Dmitry Lyzo <56478732+dmitrylyzo@users.noreply.github.com>
2024-04-02 07:03:58 -06:00
Jan Müller
19fb061381 Correct the HLS Opus codec string
Apple doesn't support Opus via HLS yet, but if they ever do, they will
definitely expect "Opus" instead of "opus".

See https://mp4ra.org/#/codecs

Fixes: #10066
2023-08-01 19:06:30 +02:00
Jan Müller
e9f23c61c9 Fix the fLaC/flac HLS issue also for audio-only
I moved the first application of the workaround out of the if block
so that it also applies to audio-only streams. The workaround was
extended likewise.

We should first and foremost adhere to the specifications and apply
workarounds afterwards for software that doesn't follow them. So I
turned around the workaround to first output the fLaC variant and then
the alternative flac variant.

Fixes: #10066
2023-08-01 17:11:32 +02:00
Nyanmisaka
f8d7f4acdb Apply suggestions from code review
Co-authored-by: Shadowghost <Shadowghost@users.noreply.github.com>
2023-06-20 05:09:22 +08:00
Nyanmisaka
3b12dc6d7a Apply suggestions from code review
Co-authored-by: Cody Robibero <cody@robibe.ro>
2023-06-20 04:18:55 +08:00
nyanmisaka
0df6fd9cf2 Add AV1 support in HLS streaming
Signed-off-by: nyanmisaka <nst799610810@gmail.com>
2023-06-20 03:50:02 +08:00
Shadowghost
f5f890e685 Migrate to file-scoped namespaces 2023-02-02 18:50:33 +01:00
nyanmisaka
37daeffafa Add support for OPUS and fixes for FLAC case issue in HLS
Signed-off-by: nyanmisaka <nst799610810@gmail.com>
2022-10-13 18:49:25 +08:00
nyanmisaka
488dbdb31d Merge remote-tracking branch 'upstream/master' into fmp4-hls 2020-11-16 12:36:55 +08:00
crobibero
01355e0498 Fix nullability errors in Jellyfin.Api (part 1) 2020-11-13 09:04:31 -07:00
nyanmisaka
5048719a64 minor changes per suggestions 2020-11-08 09:01:58 +00:00
nyanmisaka
85965741f5 add initial support for HEVC over FMP4-HLS 2020-11-08 01:39:32 +08:00
crobibero
f645e2f884 Move DynamicHlsService to Jellyfin.Api 2020-07-31 15:09:17 -06:00