All Manuals > CAPI User Guide and Reference Manual > 24 COLOR Reference Entries

color-blue

color-green

color-red

color-hue

color-saturation

color-value Functions

Summary

Returns the associated component of a color specification.

Package

color

Signatures

color-blue color-spec => color-component

color-green color-spec => color-component

color-red color-spec => color-component

color-hue color-spec => color-component

color-saturation color-spec => color-component

color-value color-spec => color-component

Arguments
color-spec
A color specification.
Values
color-component
A color component from the appropriate color model.
Description

These functions return the specified component of color-spec.

If color-spec is not from the appropriate color model (:rgb in the case of color-red, color-green and color-blue, and :hsv in the case of color-hue, color-saturation and color-value) then the component is calculated.

Examples
CL-USER 31 > (color:make-rgb 1.0s0 0.0s0 0.0s0)
#(:RGB 1.0S0 0.0S0 0.0S0)
 
CL-USER 32 > (color:color-red *)
1.0S0
 
CL-USER 33 > (color:color-green **)
0.0S0
 
CL-USER 34 > (color:color-value ***)
1.0S0
 
CL-USER 35 > 
See also

make-hsv
make-rgb
make-gray
color-model
color-level


CAPI User Guide and Reference Manual (Macintosh version) - 01 Dec 2021 19:31:50