int
vips_smartcrop (
VipsImage* in,
VipsImage** out,
int width,
int height,
...
)
Description [src]
Crop an image down to a specified width and height by removing boring parts.
Use interesting
to pick the method vips uses to decide which bits of the image should be kept.
You can test xoffset / yoffset on out
to find the location of the crop within the input image.
Optional arguments
interesting
: VipsInteresting
to use to find interesting areas (default: VIPS_INTERESTING_ATTENTION
)premultiplied
: gboolean
, input image already has premultiplied alphaattention_x
: gint
, output, horizontal position of attention centre when using attention based croppingattention_y
: gint
, output, vertical position of attention centre when using attention based croppingThis method is not directly available to language bindings.
Parametersout
Type: VipsImage
Output image.
The argument will be set by the function. The caller of the method takes ownership of the returned data, and is responsible for freeing it.width
Type: int
Width of area to extract.
height
Type: int
Height of area to extract.
...
Type:
NULL
-terminated list of optional named arguments.
Type: int
0 on success, -1 on error.
RetroSearch is an open source project built by @garambo | Open a GitHub Issue
Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo
HTML:
3.2
| Encoding:
UTF-8
| Version:
0.7.4