+ added helper scripts

+ moved uis into own files
+ log is not rerendered in full anymore
This commit is contained in:
Timo Niemann
2026-07-01 15:11:25 +02:00
parent 28d0fcc7dc
commit b7d7665fde
11 changed files with 588 additions and 408 deletions
+20
View File
@@ -0,0 +1,20 @@
from PIL import Image
import os
import sys
TARGET = (480, 800)
INPUT_DIR = sys.argv[1] if len(sys.argv) > 1 else "."
EXTENSIONS = {".jpg", ".jpeg", ".png", ".webp", ".bmp"}
for filename in os.listdir(INPUT_DIR):
ext = os.path.splitext(filename)[1].lower()
if ext not in EXTENSIONS:
continue
path = os.path.join(INPUT_DIR, filename)
img = Image.open(path)
img.thumbnail(TARGET, Image.LANCZOS)
img.save(path)
print(f"{filename}: {img.size}")