Docs Visual
ColorGen
A colour palette generator: a lookup of any length shaped by a phase step per channel and per channel exponents, with a lookup ramp as a second output.
◧ Visual ◆ Patreon:Base
This tool unlocks with Patreon. It installs through the same picker as everything else and unlocks with the Patreon Base tier or higher, connected from inside TouchDesigner. Everything else in the toolkit stays free and MIT, and the membership is what keeps that work moving.
What it is
ColorGen makes a palette by formula, so it loops cleanly and animates with a single Phase. The three channels are the same curve offset against each other by a phase step, and an exponent per channel bends each one, which is enough for most gradients without touching a coefficient table. Length sets how many colours the lookup holds; the palette comes out as a colour strip and as a lookup ramp, ready for a Lookup TOP or a CHOP to Table.
For the full cosine palette coefficients, an RGB and D mode and a blackout region, see ColorGenPro. It is a member of the FNS operator family: pick it from the FNS tab of the OP Create dialog and it lands as one node.
Inputs and outputs
- in1 (TOP): the image to colour through the palette; with nothing wired, a built-in 0 to 1 ramp is used, so both outputs show the palette on a bare drop.
- out_col (TOP): the palette strip.
- out_lookup (TOP): the input coloured through the palette.
Parameters
Custom
| Control | Type / default | What it does |
|---|---|---|
LengthLength |
number255 | Number of colours in the palette: the width in pixels of out_col, and of the fallback ramp that feeds the lookup when nothing is connected to the input. |
Phase Step per ChannelPhasestep |
number0.101 | Phase offset between the R, G and B curves: R stays put, B is shifted by twice this many palette cycles, G by a share of that set by Exponent Shift. 0 keeps the channels in step (greys). |
PhasePhase |
number0 | Scrolls all three curves along the palette. 1 is one full cycle and lands back where it started; 0.5 mirrors the palette. Animate it to cycle the colours. |
Exponent ShiftExpval |
number1 | Exponent that places G's phase between R and B: 1 puts it halfway, higher values move it toward R, values below 1 toward B. |
Exponent RExpval1 |
number1 | Exponent shaping the red curve along the palette: 1 is linear, higher values keep the channel dark for longer, below 1 brightens it early. |
Exponent GExpval2 |
number1 | Exponent shaping the green curve along the palette: 1 is linear, higher values keep the channel dark for longer, below 1 brightens it early. |
Exponent BExpval3 |
number1 | Exponent shaping the blue curve along the palette: 1 is linear, higher values keep the channel dark for longer, below 1 brightens it early. |