Skip to content

The line scenes' cosine ramp — what hue actually looks like

This is the default palette — what a line scene colours through when its preset declares no [palette]. It is the spectrum gradient, i.e. the same iq cosine the engine has always used, and it is not a hue wheel. The three channels are cosines at the same frequency with different phases, which means the ramp walks a fixed loop through colour space rather than rotating through hues at an even rate. Guessing a value costs a render round-trip; this table is so you do not have to.

(On parametric_curve, lsystem and star_pattern it is a default rather than a ceiling — set a [palette] and these swatches stop applying.)

It doubles as the backdrop’s table. bg_hue reads the same gradient, so with no [palette] declared these swatches are what a bg_hue value looks like — and, for the same reason, they stop applying to bg_hue the moment a preset declares one. There is deliberately no second table for the backdrop: an independently-measured colour table drifted from the one in the code once already, and every name in it was wrong (design-backlog 0014).

Swatches are the ramp at brightness = 1, sRGB, computed from the shader’s own arithmetic and confirmed against rendered strokes:

hueswatchreads as
0.00#F44667coral rose
0.05#E6188Bcerise
0.10#D30DABmagenta
0.15#BC3EC6orchid
0.20#9F67DClavender-violet
0.25#7D8BECperiwinkle
0.30#57ABF8cornflower blue
0.35#2BC6FEsky
0.40#00DCFFcyan
0.45#2BECFAaqua
0.50#57F8EFturquoise
0.55#7DFEDFpale aquamarine
0.60#9FFFCAmint
0.65#BCFAB1pale green
0.70#D3EF92lime cream
0.75#E6DF6Fpale yellow
0.80#F4CA46gold
0.85#FCB118amber
0.90#FF920Dorange
0.95#FC6F3Evermilion

Reading it:

  • It is cyclic, unlike ember / ice / mono / aurora: hue = 1.0 is hue = 0.0, so a binding that sweeps hue continuously never hits a seam.

  • The ends of the loop are the warm half. Red through orange lives at the wrap (0.900.05); there is no deep-red-to-black end, because the ramp never leaves full saturation. If you want a dark look here, that is brightness, not hue.

  • The cool half is over-represented. Roughly 0.300.65 is blue through green, a third of the range for what a hue wheel gives a quarter of. Fine distinctions between two blues need smaller steps than between two ambers.

  • brightness scales the ramp; overlap does not preserve it. The line renderer blends additively, so where strokes cross, channels sum and the crossing reads paler than the swatch. A dense figure at high brightness therefore looks less saturated than its hue says. Lower brightness (or thickness) rather than chasing the colour with hue.

    It does not approach white, though. The composite carries linear light past 1.0 and the engine tonemap rolls it off by scaling all three channels by the same factor, taken from the brightest one — so the ratios between R, G and B survive the roll-off exactly and a saturated crossing keeps its hue instead of climbing toward white a channel at a time. A dense figure reads paler at its crossings, because the sum genuinely is less saturated; it does not go colourless.


Built from a8ce055 at version 0.115.0. This site tracks main and is not versioned per release.