core-ktx / androidx.graphics / android.graphics.Color / component3

component3

inline operator fun Color.component3(): Float

Returns the third component of the color. For instance, when the color model of the color is android.graphics.ColorSpace.Model.RGB, the third component is "blue". = * This method allows to use destructuring declarations when working with colors, for example:

val (red, green, blue) = myColor