Method

GimpImageselect_color

since: 2.8

Declaration [src]

gboolean
gimp_image_select_color (
  GimpImage* image,
  GimpChannelOps operation,
  GimpDrawable* drawable,
  GeglColor* color
)

Description [src]

Create a selection by selecting all pixels (in the specified drawable) with the same (or similar) color to that specified.

This tool creates a selection over the specified image. A by-color selection is determined by the supplied color under the constraints of the current context settings. Essentially, all pixels (in the drawable) that have color sufficiently close to the specified color (as determined by the threshold and criterion context values) are included in the selection. To select transparent regions, the color specified must also have minimum alpha.

This procedure is affected by the following context setters: gimp_context_set_antialias(), gimp_context_set_feather(), gimp_context_set_feather_radius(), gimp_context_set_sample_merged(), gimp_context_set_sample_criterion(), gimp_context_set_sample_threshold(), gimp_context_set_sample_transparent().

In the case of a merged sampling, the supplied drawable is ignored.

Available since: 2.8

Parameters

operation

Type: GimpChannelOps

The selection operation.

drawable

Type: GimpDrawable

The affected drawable.

The data is owned by the caller of the function.
color

Type: GeglColor

The color to select.

The data is owned by the caller of the function.

Return value

Type: gboolean

TRUE on success.