Gimp.RGB.prototype.luminance_uchar

function luminance_uchar(): Number(guint8) {
    // Gjs wrapper for gimp_rgb_luminance_uchar()
}
  

Since 2.4

Returns

the luminous intensity in the range from 0 to 255.