Closed cruvie closed 1 year ago
oh I see the method ,
// Thumbnail resizes the image to the given width and height.
// crop decides algorithm vips uses to shrink and crop to fill target,
func (r *ImageRef) Thumbnail(width, height int, crop Interesting) error {
out, err := vipsThumbnail(r.image, width, height, crop, SizeBoth)
if err != nil {
return err
}
r.setImage(out)
return nil
}
when I use
inputImage.Resize()
I can just input scale , but how to input a special with or height to resize?