Skip muxing if original input video no longer exists at expected path

This commit is contained in:
N00MKRAD
2021-03-03 22:30:00 +01:00
parent 6fef12dd08
commit be4170a488

View File

@@ -173,6 +173,12 @@ namespace Flowframes.Media
public static async Task MergeStreamsFromInput (string inputVideo, string interpVideo, string tempFolder)
{
if (!File.Exists(inputVideo))
{
Logger.Log("Warning: Input video file not found, can't copy audio/subtitle streams to output video!");
return;
}
string containerExt = Path.GetExtension(interpVideo);
string tempPath = Path.Combine(tempFolder, $"vid{containerExt}");
string outPath = Path.Combine(tempFolder, $"muxed{containerExt}");
@@ -191,8 +197,6 @@ namespace Flowframes.Media
if (!Config.GetBool("keepSubs"))
subArgs = "-sn";
// TODO: Check if movflags faststart is needed here!
if (QuickSettingsTab.trimEnabled)
{
string otherStreamsName = $"otherStreams{containerExt}";