FF-1493: Added ability to save images to the file log

This commit is contained in:
John Andrews
2024-04-24 19:28:16 +12:00
parent 29fe04b5c3
commit b6d1604127
3 changed files with 4 additions and 6 deletions

Binary file not shown.

Binary file not shown.

View File

@@ -254,10 +254,11 @@ public class FfmpegBuilderCropBlackBars : FfmpegBuilderNode
{
process.Kill();
args.Logger?.ELog("Timed out extracting image");
Console.WriteLine(outputBuilder.ToString());
return File.Exists(destination);
}
if (File.Exists(destination))
return true;
// Get the output and error messages
string output = outputBuilder.ToString();
string error = errorBuilder.ToString();
@@ -268,13 +269,10 @@ public class FfmpegBuilderCropBlackBars : FfmpegBuilderNode
Console.WriteLine(output);
}
if (!string.IsNullOrWhiteSpace(error))
if (string.IsNullOrWhiteSpace(error) == false)
{
args.Logger?.WLog($"Error from ffmpeg: {error}");
}
if (File.Exists(destination))
return true;
args.Logger?.WLog($"Error extracting frame: {error}");
return false;
}