3.5.12.14 rgb

Description

To split RGB value. It will be very useful for getting separate RGB value from image type matrix cell.

Syntax

int rgb(int val, string channel)

Parameters

val

the RGB value to be split.

channel

channel can be “r”, “g”, “b”, “a”

Return

Return the separate RGB value

Example

See Also

ocolor2rgb