Thumbnailing: use webp (support RGBA) and increase dims to 768

Signed-off-by: Olivier 'reivilibre <git.contact@librepush.net>
This commit is contained in:
Olivier 'reivilibre 2025-09-06 18:47:01 +01:00
parent 4f7e4d395b
commit c314efb146

View File

@ -17,9 +17,9 @@ def prepare_processable(search_in: str):
for file in sorted(os.listdir(search_in)):
if file.endswith(extension):
full_path = search_in + "/" + file
thumb_path = tmp_dir + "/" + file + ".jpg"
thumb_path = tmp_dir + "/" + file + ".webp"
image = Image.open(file)
image.thumbnail((512, 512))
image.thumbnail((768, 768))
image.save(thumb_path)
# also search for raw CR2