thirtybees
thirtybees copied to clipboard
Images: Can we fill the background with set color?
I was using the ImageMagic plugin that was doing this but after the introduction of webp format it was causing some issues so I had to remove it.
After the regeneration of all images the ones where the source is not square are showing with the same proportions in FO. Which is not nice.
Can we have some setting in Images where with chechmark admins can select if this fill up to the set square (or not) size is needed and another field to choose the fill color?
This might interfere with many modules that manipulate this field but I believe it's a must for more consistent images and should be part of Core not in a module.
A workaround is -> get source images -> open in software, edit, export a square image -> use in site.
Slow and inneficient even with bulk export.
After the regeneration of all images the ones where the source is not square are showing with the same proportions in FO. Which is not nice.
Generated thumbnail webp images are square, with only a transparent background.
If you modify line 354 in ImageManager class to for example: $transparent = imagecolorallocatealpha($destImage, 0, 128, 0, 0);
This background will be green.
I didn't know that.
Nevertheless this is not a viable option if I make weekly updates to edge (as I do)... Can I make an orverride somewhere?
Of course that you can add override of ImageManager class with modified resize() method. And then the updates will not affect background color of generated thumbnails.