Closed mrwormhole closed 3 years ago
Would be good if there were examples for each processor so people wouldn't need to try each of them.
'ProcessorPipeline', 'Adjust', 'Reflection', 'Transpose', 'Anchor', 'MakeOpaque',
'TrimBorderColor', 'Crop', 'SmartCrop',
'Resize', 'ResizeToCover', 'ResizeToFill', 'SmartResize', 'ResizeCanvas', 'AddBorder', 'ResizeToFit', 'Thumbnail'
After trying all the options that are provided "ResizeCanvas" worked for proper resizing for a given width and height without cropping like autistic
ResizeToFit
will not crop. ResizeToFill
will crop because it's impossible to fill if the ratio of the image and the desired size are different.
Here's a list of the resizers used in the processor, it's pretty clear what each of them do in the comments:
https://github.com/matthewwithanm/pilkit/blob/master/pilkit/processors/resize.py
ResizeToFill doesn't work properly, it crops the images with the ratio. How do I do image resizing without cropping as PIL does? there is not enough info at docs