ColorTools
RGB24ToName
look up color name by 24-bit color value
Calling Sequence
Parameters
Options
Description
Examples
Compatibility
RGB24ToName(rgb,opts)
rgb
-
list; [r,g,b] color values, integer values 0-255
opts
(optional) equation(s) of the form option=value where option is one of new or default
new boolean : indicates whether to restrict to new color names (true), old color names (false), or no restriction (the default)
default string : default value to return when there is no match
The RGB24ToName procedure converts from RGB color values to a color name.
The new option acts as follows:
new=true: only search new color names
new=false: only search old color names
default (option new not specified): search both new and old color names
If a default value is provided, then that is returned when no match is found, otherwise an error occurs.
with⁡ColorTools:
RGB24ToName⁡0,255,0
Lime
RGB24ToName⁡0,255,0,new=false
green
RGB24ToName⁡255,0,0
Red
RGB24ToName⁡I like cat videos
Error, invalid input: ColorTools:-RGB24ToName expects its 1st argument, rl, to be of type list(integer), but received I like cat videos
The ColorTools[RGB24ToName] command was introduced in Maple 16.
For more information on Maple 16 changes, see Updates in Maple 16.
See Also
Download Help Document
What kind of issue would you like to report? (Optional)