Graph-building helpers the Tidewater water-effect graphs share: draw a set of particles
in one of the seven looks with the fx_particle shader.
material(g: any, shaderRef: any, look: string, shape: string, facing: string, extra: { [string]: any }?) → void
A material of the fx_particle shader for one shape and facing in a look.
| arg | type | description |
|---|
| g | any | |
| shaderRef | any | |
| look | string | |
| shape | string | |
| facing | string | |
| extra | { [string]: any }? | |
draw(g: any, shaderRef: any, pts: any, o: { [string]: any }) → any
Draw solver particles (or any points carrying `size`, `life`, `seed`) as instanced cards
or, in the lowpoly look for droplets/chunks, as flat-shaded octahedra.
o: { look, shape, facing, scale (size multiplier), grow (size growth over life), extra (shader props) }
| arg | type | description |
|---|
| g | any | |
| shaderRef | any | |
| pts | any | |
| o | { [string]: any } | |
clockBursts(g: any, o: { [string]: any }) → any
Things that lie still on the water and only grow and fade (rings, a foam patch), with no
particle solver: `count` points at the origin, the i-th born at `start + (i - 1) * gap` s and
living `life` s, its `size`, `life` (0..1) and `seed` read off the graph clock. Every solver a
play holds costs it seconds of device setup the first time it is built, so anything that does
not move is drawn this way. o: { count, start, gap, life, size (socket or number), seed, points
(points to stand them on instead of `count` at the origin) }
| arg | type | description |
|---|
| g | any | |
| o | { [string]: any } | |
clockLoop(g: any, o: { [string]: any }) → any
Like `clockBursts`, but repeating for as long as the play runs: each of `points` shows a
ring (or patch) `life` s long once every `period` s, the points out of step with each other.
For rings that keep appearing where drips land, with no solver. o: { points, period (socket
or number), life, size, seed }
| arg | type | description |
|---|
| g | any | |
| o | { [string]: any } | |
uniformField(g: any, v: any) → any
A constant vector as a field a solver force can read at every particle.
| arg | type | description |
|---|
| g | any | |
| v | any | |
show(g: any, layers: { any }, name: string?) → void
Show every drawn layer of an effect, each under an output of its own (layers wear
different materials, which one merged population cannot carry on the device).
| arg | type | description |
|---|
| g | any | |
| layers | { any } | |
| name | string? | |