# Gimp.Drawable.prototype.threshold

    function threshold(channel: Gimp.HistogramChannel, low_threshold: Number(gdouble), high_threshold: Number(gdouble)): Boolean {
        // Gjs wrapper for gimp_drawable_threshold()
    }

Threshold the specified drawable.

This procedures generates a threshold map of the specified drawable. All pixels between the values of 'low_threshold' and 'high_threshold', on the scale of 'channel' are replaced with white, and all other pixels with black.

Since 2.10

channel

  The channel to base the threshold on.

low_threshold

  The low threshold value.

high_threshold

  The high threshold value.

Returns

  TRUE on success.