fix(reduce): resolve conflicts with master

This commit is contained in:
Tomas Aparicio 2017-09-10 20:30:24 +02:00
commit bd028cd5da
3 changed files with 22 additions and 1 deletions

12
vips.go
View file

@ -528,6 +528,18 @@ func vipsShrink(input *C.VipsImage, shrink int) (*C.VipsImage, error) {
return image, nil
}
func vipsReduce(input *C.VipsImage, xshrink float64, yshrink float64) (*C.VipsImage, error) {
var image *C.VipsImage
defer C.g_object_unref(C.gpointer(input))
err := C.vips_reduce_bridge(input, &image, C.double(xshrink), C.double(yshrink))
if err != 0 {
return nil, catchVipsError()
}
return image, nil
}
func vipsEmbed(input *C.VipsImage, left, top, width, height int, extend Extend, background Color) (*C.VipsImage, error) {
var image *C.VipsImage