From 80940c0c57bc180d88b57da5b797fef949f85200 Mon Sep 17 00:00:00 2001 From: gnattu Date: Wed, 1 Jan 2025 00:15:39 +0800 Subject: [PATCH] Don't generate trickplay for backdrops (#13183) --- .../Trickplay/TrickplayManager.cs | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/Jellyfin.Server.Implementations/Trickplay/TrickplayManager.cs b/Jellyfin.Server.Implementations/Trickplay/TrickplayManager.cs index af57bc134d..b9965085fd 100644 --- a/Jellyfin.Server.Implementations/Trickplay/TrickplayManager.cs +++ b/Jellyfin.Server.Implementations/Trickplay/TrickplayManager.cs @@ -194,6 +194,14 @@ public class TrickplayManager : ITrickplayManager return; } + // We support video backdrops, but we should not generate trickplay images for them + var parentDirectory = Directory.GetParent(mediaPath); + if (parentDirectory is not null && string.Equals(parentDirectory.Name, "backdrops", StringComparison.OrdinalIgnoreCase)) + { + _logger.LogDebug("Ignoring backdrop media found at {Path} for item {ItemID}", mediaPath, video.Id); + return; + } + // The width has to be even, otherwise a lot of filters will not be able to sample it var actualWidth = 2 * (width / 2);