From 68bfabbaba2fc6f7b5b6cd63b388f4669a476713 Mon Sep 17 00:00:00 2001 From: gnattu Date: Wed, 8 May 2024 13:50:03 +0800 Subject: Add option to extract keyframe only during trickplay image generation This would be significantly faster than decoding every frame, but it does have compatibility issues. Not all decoders support this mode, notably the VP9 decoder, CUVID decoders, and QSV decoders. Some videos with very long key-frame intervals may also perform poorly with this mode, as the image timing could become too inaccurate to reflect the actual frame. Signed-off-by: gnattu --- MediaBrowser.Controller/MediaEncoding/IMediaEncoder.cs | 2 ++ 1 file changed, 2 insertions(+) (limited to 'MediaBrowser.Controller/MediaEncoding/IMediaEncoder.cs') diff --git a/MediaBrowser.Controller/MediaEncoding/IMediaEncoder.cs b/MediaBrowser.Controller/MediaEncoding/IMediaEncoder.cs index 26c353a54..038c6c7f6 100644 --- a/MediaBrowser.Controller/MediaEncoding/IMediaEncoder.cs +++ b/MediaBrowser.Controller/MediaEncoding/IMediaEncoder.cs @@ -153,6 +153,7 @@ namespace MediaBrowser.Controller.MediaEncoding /// The input/output thread count for ffmpeg. /// The qscale value for ffmpeg. /// The process priority for the ffmpeg process. + /// Whether to only extract key frames. /// EncodingHelper instance. /// The cancellation token. /// Directory where images where extracted. A given image made before another will always be named with a lower number. @@ -168,6 +169,7 @@ namespace MediaBrowser.Controller.MediaEncoding int? threads, int? qualityScale, ProcessPriorityClass? priority, + bool enableKeyFrameOnlyExtraction, EncodingHelper encodingHelper, CancellationToken cancellationToken); -- cgit v1.2.3