aboutsummaryrefslogtreecommitdiff
path: root/MediaBrowser.MediaEncoding/Transcoding/TranscodeManager.cs
diff options
context:
space:
mode:
authornyanmisaka <nst799610810@gmail.com>2024-08-05 11:01:28 -0400
committerBond_009 <bond.009@outlook.com>2024-08-05 11:01:28 -0400
commit7ee9c9b7a07bcfe64eba7fa24f012b41f31cf148 (patch)
treee27e24c84b49f16e87cf17ac8c2e8dcf9a4a6698 /MediaBrowser.MediaEncoding/Transcoding/TranscodeManager.cs
parent0675b06bea62ba9d79601598ce346d97e519f9a4 (diff)
Backport pull request #12374 from jellyfin/release-10.9.z
Fix compatibility between TranscodingThrottler and FFmpeg 7.0 Original-merge: ee0094d889fe99cc3e27b556d5470e94b2521a3e Merged-by: crobibero <cody@robibe.ro> Backported-by: Bond_009 <bond.009@outlook.com>
Diffstat (limited to 'MediaBrowser.MediaEncoding/Transcoding/TranscodeManager.cs')
-rw-r--r--MediaBrowser.MediaEncoding/Transcoding/TranscodeManager.cs6
1 files changed, 5 insertions, 1 deletions
diff --git a/MediaBrowser.MediaEncoding/Transcoding/TranscodeManager.cs b/MediaBrowser.MediaEncoding/Transcoding/TranscodeManager.cs
index 67a2dddb8..42f355b05 100644
--- a/MediaBrowser.MediaEncoding/Transcoding/TranscodeManager.cs
+++ b/MediaBrowser.MediaEncoding/Transcoding/TranscodeManager.cs
@@ -51,6 +51,8 @@ public sealed class TranscodeManager : ITranscodeManager, IDisposable
o.PoolInitialFill = 1;
});
+ private readonly Version _maxFFmpegCkeyPauseSupported = new Version(6, 1);
+
/// <summary>
/// Initializes a new instance of the <see cref="TranscodeManager"/> class.
/// </summary>
@@ -555,7 +557,9 @@ public sealed class TranscodeManager : ITranscodeManager, IDisposable
private void StartThrottler(StreamState state, TranscodingJob transcodingJob)
{
- if (EnableThrottling(state))
+ if (EnableThrottling(state)
+ && (_mediaEncoder.IsPkeyPauseSupported
+ || _mediaEncoder.EncoderVersion <= _maxFFmpegCkeyPauseSupported))
{
transcodingJob.TranscodingThrottler = new TranscodingThrottler(transcodingJob, _loggerFactory.CreateLogger<TranscodingThrottler>(), _serverConfigurationManager, _fileSystem, _mediaEncoder);
transcodingJob.TranscodingThrottler.Start();