Print ffmpeg log while waiting for autoenc to finish

This commit is contained in:
N00MKRAD
2021-01-06 21:44:09 +01:00
parent c31c6872e8
commit 36c8a17dff
8 changed files with 20 additions and 10 deletions

View File

@@ -51,16 +51,14 @@ namespace Flowframes
if (outLine == null || outLine.Data == null)
return;
string line = outLine.Data;
lastOutputFfmpeg = lastOutputFfmpeg + line + "\n";
lastOutputFfmpeg = lastOutputFfmpeg + "\n" + line;
bool hidden = currentLogMode == LogMode.Hidden;
bool replaceLastLine = currentLogMode == LogMode.OnlyLastLine;
string trimmedLine = line.Remove("q=-0.0").Remove("size=N/A").Remove("bitrate=N/A").TrimWhitespaces();
Logger.Log(trimmedLine, hidden, replaceLastLine, "ffmpeg");
if(line.Contains("Could not open file"))
{
Interpolate.Cancel("Failed to write frames - Make sure the folder is not restricted!");
}
Interpolate.Cancel($"FFmpeg Error: {line}");
}
static void FfmpegOutputHandlerSilent (object sendingProcess, DataReceivedEventArgs outLine)