From 40bf3b529ea62ed3b6e2deed9b46797f16f35d6a Mon Sep 17 00:00:00 2001 From: reven Date: Fri, 14 Jan 2022 17:47:58 +1300 Subject: [PATCH] updating black bars to not count x/y when determining threshold --- VideoNodes/LogicalNodes/DetectBlackBars.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/VideoNodes/LogicalNodes/DetectBlackBars.cs b/VideoNodes/LogicalNodes/DetectBlackBars.cs index 99f207d6..1e199871 100644 --- a/VideoNodes/LogicalNodes/DetectBlackBars.cs +++ b/VideoNodes/LogicalNodes/DetectBlackBars.cs @@ -108,7 +108,7 @@ namespace FileFlows.VideoNodes args.Logger?.DLog($"Video dimensions: {vidWidth}x{vidHeight}"); - int diff = x + y + (vidWidth - width) + (vidHeight - height); + int diff = (vidWidth - width) + (vidHeight - height); bool willCrop = diff > CroppingThreshold; args.Logger?.ILog($"Crop detection, x:{x}, y:{y}, width: {width}, height: {height}, total:{diff}, threshold:{CroppingThreshold}, above threshold: {willCrop}");