Method
GimpImageselect_polygon
since: 2.8
Declaration [src]
gboolean
gimp_image_select_polygon (
GimpImage* image,
GimpChannelOps operation,
gsize num_segs,
const gdouble* segs
)
Description [src]
Create a polygonal selection over the specified image.
This tool creates a polygonal selection over the specified image. The polygonal region can be either added to, subtracted from, or replace the contents of the previous selection mask. The polygon is specified through an array of floating point numbers and its length. The length of array must be 2n, where n is the number of points. Each point is defined by 2 floating point values which correspond to the x and y coordinates. If the final point does not connect to the starting point, a connecting segment is automatically added.
This procedure is affected by the following context setters: gimp_context_set_antialias(), gimp_context_set_feather(), gimp_context_set_feather_radius().
Available since: 2.8
Parameters
operation
-
Type:
GimpChannelOps
The selection operation.
num_segs
-
Type:
gsize
Number of points (count 1 coordinate as two points).
segs
-
Type: An array of
double
Array of points: { p1.x, p1.y, p2.x, p2.y, …, pn.x, pn.y}.
The length of the array is specified in the num_segs
argument.The data is owned by the caller of the function.