From 89811a1203c89a6fa642141162d8c6a94ff6747b Mon Sep 17 00:00:00 2001 From: Jason Dove Date: Mon, 7 Feb 2022 12:44:12 -0600 Subject: [PATCH] wait for one segment by default (#617) --- .../FFmpegProfiles/Queries/GetFFmpegSettingsHandler.cs | 2 +- .../Streaming/Commands/StartFFmpegSessionHandler.cs | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/ErsatzTV.Application/FFmpegProfiles/Queries/GetFFmpegSettingsHandler.cs b/ErsatzTV.Application/FFmpegProfiles/Queries/GetFFmpegSettingsHandler.cs index cb6d9fcdf..4cf520a66 100644 --- a/ErsatzTV.Application/FFmpegProfiles/Queries/GetFFmpegSettingsHandler.cs +++ b/ErsatzTV.Application/FFmpegProfiles/Queries/GetFFmpegSettingsHandler.cs @@ -46,7 +46,7 @@ namespace ErsatzTV.Application.FFmpegProfiles.Queries PreferredLanguageCode = await preferredLanguageCode.IfNoneAsync("eng"), HlsSegmenterIdleTimeout = await hlsSegmenterIdleTimeout.IfNoneAsync(60), WorkAheadSegmenterLimit = await workAheadSegmenterLimit.IfNoneAsync(1), - InitialSegmentCount = await initialSegmentCount.IfNoneAsync(4) + InitialSegmentCount = await initialSegmentCount.IfNoneAsync(1) }; foreach (int watermarkId in watermark) diff --git a/ErsatzTV.Application/Streaming/Commands/StartFFmpegSessionHandler.cs b/ErsatzTV.Application/Streaming/Commands/StartFFmpegSessionHandler.cs index 916cd3779..ddc81af27 100644 --- a/ErsatzTV.Application/Streaming/Commands/StartFFmpegSessionHandler.cs +++ b/ErsatzTV.Application/Streaming/Commands/StartFFmpegSessionHandler.cs @@ -71,7 +71,7 @@ namespace ErsatzTV.Application.Streaming.Commands IConfigElementRepository repo = scope.ServiceProvider.GetRequiredService(); int initialSegmentCount = await repo.GetValue(ConfigElementKey.FFmpegInitialSegmentCount) - .Map(maybeCount => maybeCount.Match(identity, () => 4)); + .Map(maybeCount => maybeCount.Match(identity, () => 1)); await WaitForPlaylistSegments(playlistFileName, initialSegmentCount, worker);