mirror of
https://github.com/n00mkrad/flowframes.git
synced 2025-12-16 16:37:48 +01:00
WIP: VFR Dedupe - Added code to create timecode file
This commit is contained in:
@@ -18,9 +18,8 @@ namespace Flowframes.UI
|
||||
public static async Task ExtractVideo(string videoPath, bool withAudio)
|
||||
{
|
||||
string outPath = Path.ChangeExtension(videoPath, null) + "-extracted";
|
||||
bool rgb8 = Formats.preprocess.Contains(Path.GetExtension(videoPath).ToLower());
|
||||
Program.mainForm.SetWorking(true);
|
||||
await FFmpegCommands.VideoToFrames(videoPath, Path.Combine(outPath, "frames"), false, rgb8, false, false);
|
||||
await FFmpegCommands.VideoToFrames(videoPath, Path.Combine(outPath, "frames"), false, false);
|
||||
File.WriteAllText(Path.Combine(outPath, "fps.ini"), Interpolate.currentInFps.ToString());
|
||||
if (withAudio)
|
||||
await FFmpegCommands.ExtractAudio(videoPath, Path.Combine(outPath, "audio"));
|
||||
@@ -94,7 +93,8 @@ namespace Flowframes.UI
|
||||
Program.mainForm.SetWorking(true);
|
||||
await Task.Delay(10);
|
||||
framesPath = Path.ChangeExtension(inPath, null) + "-frames";
|
||||
await Interpolate.ExtractFrames(inPath, framesPath);
|
||||
Directory.CreateDirectory(framesPath);
|
||||
await Interpolate.ExtractFrames(inPath, framesPath, false);
|
||||
}
|
||||
else
|
||||
{
|
||||
@@ -103,7 +103,7 @@ namespace Flowframes.UI
|
||||
Program.mainForm.SetWorking(true);
|
||||
Logger.Log("Running frame de-duplication", true);
|
||||
await Task.Delay(10);
|
||||
await FrameDedup.Run(framesPath, testRun);
|
||||
await MagickDedupe.Run(framesPath, testRun);
|
||||
IOUtils.TryDeleteIfExists(framesPath);
|
||||
Program.mainForm.SetProgress(0);
|
||||
Program.mainForm.SetWorking(false);
|
||||
|
||||
Reference in New Issue
Block a user