From 933cecd0e6a4c62a4149c9c7ece746f5c0cc3cf9 Mon Sep 17 00:00:00 2001 From: Fen Dweller Date: Tue, 9 Jun 2020 13:57:29 -0400 Subject: [PATCH] Make the box a bit less transparent --- overlay.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/overlay.py b/overlay.py index 9c2959f..cc8c973 100644 --- a/overlay.py +++ b/overlay.py @@ -20,14 +20,14 @@ def overlay(image_in): draw = ImageDraw.Draw(overlay) font = ImageFont.truetype("OptimusPrinceps.ttf", font_size) - draw.rectangle([0, rect_top[1], size[0], rect_bot[1]], fill=(0,0,0, 200)) + draw.rectangle([0, rect_top[1], size[0], rect_bot[1]], fill=(0,0,0, 220)) for y in range(-1, -gradient_range - 1, -1): - c = 200 - 200 * (-y) // gradient_range + c = 220 - 220 * (-y) // gradient_range draw.line([0, rect_top[1] + y, size[0], rect_top[1] + y], fill=(0,0,0,c)) for y in range(1, gradient_range + 1, 1): - c = 200 - 200 * (y) // gradient_range + c = 220 - 220 * (y) // gradient_range draw.line([0, rect_bot[1] + y, size[0], rect_bot[1] + y], fill=(0,0,0,c)) text_size = draw.textsize(message, font=font)