Allow deduplication of last frame if loop is enabled

This commit is contained in:
N00MKRAD
2021-01-22 02:07:03 +01:00
parent 76c896a568
commit a24d9e1d9d
2 changed files with 5 additions and 2 deletions

View File

@@ -128,7 +128,8 @@ namespace Flowframes
else
Dedupe.ClearCache();
await Utils.CopyLastFrame(currentInputFrameCount);
if(!Config.GetBool("enableLoop"))
await Utils.CopyLastFrame(currentInputFrameCount);
if (Config.GetInt("dedupMode") > 0)
await Dedupe.CreateDupesFile(current.framesFolder, currentInputFrameCount);

View File

@@ -73,7 +73,7 @@ namespace Flowframes.Main
Program.mainForm.SetProgress(0);
while (Program.busy)
{
if (!progressPaused && AiProcess.processTime.IsRunning && !i.canceled && Directory.Exists(currentOutdir))
if (!progressPaused && AiProcess.processTime.IsRunning && Directory.Exists(currentOutdir))
{
if (firstProgUpd && Program.mainForm.IsInFocus())
Program.mainForm.SetTab("preview");
@@ -97,6 +97,8 @@ namespace Flowframes.Main
public static void UpdateInterpProgress(int frames, int target, string latestFramePath = "")
{
if (i.canceled) return;
frames = frames.Clamp(0, target);
int percent = (int)Math.Round(((float)frames / target) * 100f);
Program.mainForm.SetProgress(percent);