(cosine-coefficients c1 c2)
Computes coefficients defining a cosine gradient between the two given colors. The colors can be in any color space, but the resulting gradient will always be computed in RGB.
amp = (R1 - R2) / 2 dc = R1 - amp freq = -0.5
Computes coefficients defining a cosine gradient between the two given colors. The colors can be in any color space, but the resulting gradient will always be computed in RGB. amp = (R1 - R2) / 2 dc = R1 - amp freq = -0.5
(cosine-gradient n spec)
(cosine-gradient n t spec)
(cosine-gradient n t offset amp fmod phase)
Takes a length n and 4 cosine coefficients (for colors usually 3 or
4-element vectors) and produces vector of n new RGBA colors, with
each of its elements defined by an AM & FM cosine wave and clamped
to the [0 1] interval. The fn t
is used to ramp the gradient and
remap the interpolation interval (e.g. use m/mix-circular)
Takes a length n and 4 cosine coefficients (for colors usually 3 or 4-element vectors) and produces vector of n new RGBA colors, with each of its elements defined by an AM & FM cosine wave and clamped to the [0 1] interval. The fn `t` is used to ramp the gradient and remap the interpolation interval (e.g. use m/mix-circular)
cljdoc is a website building & hosting documentation for Clojure/Script libraries
× close