From 6ffa9539bbfbfb1090b02cebc8a28283a8c69041 Mon Sep 17 00:00:00 2001 From: cvium Date: Tue, 11 Jan 2022 23:30:30 +0100 Subject: Refactor and add scheduled task --- .../Extractors/IKeyframeExtractor.cs | 24 ++++++++++++++++++++++ 1 file changed, 24 insertions(+) create mode 100644 src/Jellyfin.MediaEncoding.Hls/Extractors/IKeyframeExtractor.cs (limited to 'src/Jellyfin.MediaEncoding.Hls/Extractors/IKeyframeExtractor.cs') diff --git a/src/Jellyfin.MediaEncoding.Hls/Extractors/IKeyframeExtractor.cs b/src/Jellyfin.MediaEncoding.Hls/Extractors/IKeyframeExtractor.cs new file mode 100644 index 000000000..497210f41 --- /dev/null +++ b/src/Jellyfin.MediaEncoding.Hls/Extractors/IKeyframeExtractor.cs @@ -0,0 +1,24 @@ +using System; +using System.Diagnostics.CodeAnalysis; +using Jellyfin.MediaEncoding.Keyframes; + +namespace Jellyfin.MediaEncoding.Hls.Extractors; + +/// +/// Keyframe extractor. +/// +public interface IKeyframeExtractor +{ + /// + /// Gets a value indicating whether the extractor is based on container metadata. + /// + bool IsMetadataBased { get; } + + /// + /// Attempt to extract keyframes. + /// + /// The path to the file. + /// The keyframes. + /// A value indicating whether the keyframe extraction was successful. + bool TryExtractKeyframes(string filePath, [NotNullWhen(true)] out KeyframeData? keyframeData); +} -- cgit v1.2.3