[WIP] apng provider

This commit is contained in:
Paddy Xu
2018-08-28 00:16:25 +03:00
parent ee6bca704d
commit 3bcb48a43c
11 changed files with 163 additions and 103 deletions

View File

@@ -17,6 +17,7 @@
using System;
using System.Threading.Tasks;
using System.Windows;
using System.Windows.Media.Animation;
using System.Windows.Media.Imaging;
using System.Windows.Threading;
@@ -25,23 +26,19 @@ namespace QuickLook.Plugin.ImageViewer.AnimatedImage
{
internal abstract class AnimationProvider : IDisposable
{
protected AnimationProvider(string path, NConvert meta, Dispatcher uiDispatcher)
protected AnimationProvider(string path)
{
Path = path;
Meta = meta;
Dispatcher = uiDispatcher;
}
public Dispatcher Dispatcher { get; }
public string Path { get; }
public NConvert Meta { get; }
public Int32AnimationUsingKeyFrames Animator { get; protected set; }
public abstract void Dispose();
public abstract Task<BitmapSource> GetThumbnail(Size size, Size fullSize);
public abstract Task<BitmapSource> GetRenderedFrame(int index);
}
}