-
-
Notifications
You must be signed in to change notification settings - Fork 1.4k
smartcrop: bad extract area #1134
Copy link
Copy link
Closed
Labels
Milestone
Description
In very specific case resizing with cropping set to sharp.strategy.attention or sharp.strategy.entropy will result with error smartcrop: bad extract area
Repository to reproduce - https://github.com/pieh/sharp-smartcrop-bad-extract-area-repro
This happens when width is set to 1110 and height is unspecified using image from above repository (it is 1600 x 1200)
In readme of repository I placed more outputs where it works fine:
- with crop set to
sharp.gravity.center - with slightly higher and lower widths (
1120and1100respectively) - with specified height (both calculated using source image aspect ratio and full image height)
This was originally reported in gatsbyjs/gatsby#4142 (just to keep paper trail - reproduction repository should be enough)
Reactions are currently unavailable