imageflow
imageflow copied to clipboard
Constraint mode fit_pad works incorrectly
Hello!
Documentation says:
fit_pad - Pad to desired aspect ratio, then downscale or upscale to fit If only one dimension is specified, behaves like fit.
But it does same as fit_crop
Example image:
Example request:
{ "constrain": { "mode": "fit_pad", "w": 800, "h": 420, "hints": { "sharpen_percent": 15, "down_filter": "robidoux", "up_filter": "ginseng", "scaling_colorspace": "linear", "background_color": "transparent", "resample_when": "size_differs_or_sharpening_requested", "sharpen_when": "downscaling" }, "gravity": { "percentage": { "x": 50, "y": 50}}, "canvas_color": { "srgb": { "hex" : "ffffff" } } } }
Result - same as fit_crop:

Expected result:
