Adding a test, verifying both ways of enabling SmartCrop work

This commit is contained in:
Mark van der Velden 2017-05-25 09:38:39 +02:00
parent 855de7ca55
commit 33bf9bdff6
4 changed files with 63 additions and 13 deletions

View file

@ -249,7 +249,7 @@ func extractOrEmbedImage(image *C.VipsImage, o Options) (*C.VipsImage, error) {
inHeight := int(image.Ysize)
switch {
case o.Gravity == GravitySmart:
case o.Gravity == GravitySmart, o.SmartCrop:
image, err = vipsSmartCrop(image, o.Width, o.Height)
break
case o.Crop: