From c3b9224694fd68e40369c64feb8981f225f05b6f Mon Sep 17 00:00:00 2001 From: Your Name Date: Thu, 27 Aug 2026 10:16:45 -0400 Subject: [PATCH] fix unsane etc --- patches/go-vod-sheepflix.patch | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/patches/go-vod-sheepflix.patch b/patches/go-vod-sheepflix.patch index db03738..2034497 100644 --- a/patches/go-vod-sheepflix.patch +++ b/patches/go-vod-sheepflix.patch @@ -123,3 +123,18 @@ diff --git a/transcoder/stream.go b/transcoder/stream.go scaler = "scale_vaapi" scalerArgs = append(scalerArgs, "format=nv12") } else if CV == ENCODER_NVENC { +@@ -509,6 +517,13 @@ func (s *Stream) transcodeArgs(startAt float64, isHls bool) []string { + // Audio output specs + args = append(args, []string{ + "-map", "0:a:0?", + "-c:a", "aac", ++ // ffmpeg decodes AC-3/DTS 5.1 as layout "5.1(side)", which the AAC ++ // encoder cannot express as a standard channel_configuration, so it ++ // emits a PCE and sets channel_configuration=0. hls.js does not parse ++ // the PCE, writes channelCount=0 into the fMP4 init segment, and every ++ // browser then rejects the audio SourceBuffer. Restricting to standard ++ // layouts maps 5.1(side) -> 5.1 and leaves mono/stereo untouched. ++ "-af", "aformat=channel_layouts=mono|stereo|5.1", + }...) + + return args