From f4dd90aa906643a2b9d5a1c07107224eed914c75 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Kacper=20Michaj=C5=82ow?= Date: Thu, 31 Aug 2023 23:52:27 +0200 Subject: [PATCH] autocrop.lua: don't remove crop on startup/exit No need to remove/clean crop unlike with filters. Allows using autocrop with auto=false and custom --video-crop. --- TOOLS/lua/autocrop.lua | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/TOOLS/lua/autocrop.lua b/TOOLS/lua/autocrop.lua index 62aee7c89a..57581cf7a5 100644 --- a/TOOLS/lua/autocrop.lua +++ b/TOOLS/lua/autocrop.lua @@ -142,7 +142,10 @@ function cleanup() -- Remove all existing filters. for key, value in pairs(labels) do - remove_filter(value) + -- No need to remove initial crop in vo_crop mode + if not (options.use_vo_crop and value == labels.crop) then + remove_filter(value) + end end -- Kill all timers.