Closed DrMeers closed 2 years ago
Happy to create a PR for this.
We could:
WEBP_METHOD
setting that gets used in save_pil_image
if format == 'WEBP'
generate_thumbnail
to take additional parameters, or look within thumbnail_options
for extra save_pil_image
optionsIt might be worth adding a cleaner way of forcing which format you want to save the thumbnail in rather than my namer
hack described above too.
@SmileyChris am I missing anything with respect to there being no way to set which format the thumbnails should be saved in except for hacking the namer
?
Also any feedback/preference on the PR options above?
Released in v2.8.1
e.g. when generating a
.webp
thumbnail, I'd like to passmethod=6
toImage.save
viasave_pil_image
's**options
, howeverengine
only passes a few (other) specific parameters.Currently this means saving
webp
thumbnails (which I'm doing via a customnamer
which checks if the alias containedwebp
and passes that as theextension
, btw, a bit of a hack...) generate images about 4x larger file size than the (slower-but-better)method=6
equivalents.I can't see any way to fix this apart from forking and modifying the codebase, or am I missing something?