master.py: enforce non-antialised upscaling of trophy icons

Either the default changed in PIL, the mode of the source image was
affected, or something else.
This commit is contained in:
Lephe 2021-07-12 20:07:48 +02:00
parent 306f1bab64
commit a6689312cf
Signed by: Lephenixnoir
GPG Key ID: 1BBA026E13FC0495
1 changed files with 1 additions and 1 deletions

View File

@ -228,7 +228,7 @@ def generate_trophy_icons():
icon = img.crop((26*x+1, 26*y+1, 26*x+25, 26*y+25))
# Skip blank squares in the source image
if len(icon.getcolors()) > 1:
yield icon.resize((48,48))
yield icon.resize((48,48), resample=Image.NEAREST)
for (name, icon) in zip(names, trophy_iterator(img)):
icon.save(os.path.join(dst, f"{name}.png"))