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