Gradient

Read with AI
All docs in one file (llms-full.txt)
gen.gradient #Generator #Node
Gradient

A pure generator that produces an angled gradient. The gradient is turned into a triangle wave, so the color does not jump at the band boundaries.

  • Angle — the direction of the gradient (degrees). 0–360, default 0
  • Bands — the number of stripes across the screen. 1–16, default 1
  • Scroll — how many bands it advances per cycle. 0–1, default 0 (= stopped)
  • ColorA / ColorB — the two colors
  • Speed — how many cycles per second
  • Seed — not used by this shader

The output resolution is chosen from the dropdown on the node, from FullHD / HD (default) / SD.

Phase uses an external value only when it is connected; when it is not, the fractional part of the internal time (a 0→1 sawtooth) is fed in. Since Phase is a sawtooth, the position jumps at the wrap unless the advance per cycle is a whole number of bands. So Scroll × Bands is rounded internally and quantized to whole bands, making the loop close exactly in one cycle (a design intended for tempo sync).

Video

Input ports

Port IDType
Speedfloat
Phasefloat
Seedint

Output ports

Port IDType
Render TextureRenderTexture

Scriptable members

PathType
speedInputfloat
phaseInputfloat
seedInputint

Synapse Apps (scripting)

await synapse.modules.create({ type: "gen.gradient" })