color gradient - part-cw/lambdanative GitHub Wiki
(color-gradient type value)
color-gradient returns a color based on the gradient type
Parameter | Description |
---|---|
type | Gradient type: GRADIENT_GRAY, GRADIENT_RAINBOW, GRADIENT_THERMAL or GRADIENT_COPPER |
value | Index value (0-1) |
Example
Example 1: Check the red channel value of a grayscale gradient half way through the spectrum.
> (color-red (color-gradient GRADIENT_GRAY 0.5))
127