raw - with names to-XXX and from-XXX where XXX is color space name.List of color spaces are listed under colorspaces-list variable. ConversionsĬolor can be converted from RGB to other color space (and back). To change saturation call saturate / desaturate. To make color darker/brighter use darken / lighten functions. General set-channel and get-channel can work with any colorspace. Set-ch0, set-ch1, set-ch2 and set-alpha return new color with respective channel set to new value. hue-polar - to get hue from polar transformation.hue - to get hue value in degrees (range from 0 to 360).luma - to get luma or brightness (range from 0 (black) to 255 (white)).blue or ch2 - to get third channel value.green or ch1 - to get second channel value.red or ch0 - to get first channel value.You can access individual channels by calling on of the following: To create gray for given intensity call gray.īy default color is treated as RGB with values from ranges inclusive.Īll funtions internally convert any color representation to Vec4 type using to-color function.Ĭoloured list of all names Color/ channel manipulations To create color from individual channel values use color function. Conversion is done by applying content to color function. any seqable - list, vector containing 2-4 elements.String - CSS ( #rgb or #rgba) or string containg hexadecimal representation (“ffaa01”). If value is less than 0xff000000, alpha is set to 0xff. keyword - one of the defined names (see named-colors-list).Use to-awt-color to convert to this representation. fastmath Vec3 - 3 channels (RGB), assuming alpha set to value of 255.color, gray creators returns Vec4 representation. fastmath Vec4 - this is core type representing 3 color channels and alpha (RGBA).This namespace contains color manipulation functions which can be divided into following groups:Ĭolor can be represented by following types:
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |