removing same conatainer check that forced re-ecnoded after ffmpeg upgrade this is no longer necassary

This commit is contained in:
reven
2021-12-12 12:40:51 +13:00
parent 84617fca6b
commit 1562fdeb85
8 changed files with 4 additions and 7 deletions
Binary file not shown.
+1 -4
View File
@@ -92,9 +92,6 @@ namespace FileFlows.VideoNodes
bool audioRightCodec = bestAudio?.Codec?.ToLower() == AudioCodec && videoInfo.AudioStreams[0] == bestAudio;
args.Logger?.ILog("Best Audio: ", bestAudio == null ? "null" : (object)bestAudio);
bool sameContainer = new FileInfo(args.WorkingFile).Extension.ToLower() == Extension.ToLower();
string crop = args.GetParameter<string>(DetectBlackBars.CROP_KEY) ?? "";
if (crop != string.Empty)
crop = " -vf crop=" + crop;
@@ -125,7 +122,7 @@ namespace FileFlows.VideoNodes
TotalTime = videoInfo.VideoStreams[0].Duration;
if (audioRightCodec == false || sameContainer == false) // if container changes, re-encode audio, otherwise this can lead to failed encodings (mp4 to mkv this can happen... a lot)
if (audioRightCodec == false)
ffArgs.Add($"-map 0:{bestAudio!.Index} -c:a {AudioCodec}");
else
ffArgs.Add($"-map 0:{bestAudio!.Index} -c:a copy");