From 75a7d0486c280564881d95a156c55e2ce41e2717 Mon Sep 17 00:00:00 2001 From: PAlexanderFranklin Date: Fri, 2 Aug 2024 13:51:08 -0700 Subject: [PATCH] Fix comments --- src/screenmonitor.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/screenmonitor.py b/src/screenmonitor.py index fcae286..c2a1a8e 100644 --- a/src/screenmonitor.py +++ b/src/screenmonitor.py @@ -21,11 +21,12 @@ def capture_screenshot(): # Apply blur blurred_screenshot = screenshot.filter(ImageFilter.GaussianBlur(10)) - # Randomly turn 10% of the pixels black + # resize width, height = blurred_screenshot.size width, height = width // 5, height // 5 blurred_screenshot = blurred_screenshot.resize((width, height), Image.NEAREST) + # Randomly turn 10% of the pixels grey pixels = blurred_screenshot.load() total_pixels = width * height black_pixels_count = int(total_pixels * 0.1)