gradient

A derived output: the slope of .x at every cell as .xy, ready for a displacement.

gradient(): GradientOp

Import op from shaders/std and use op.gradient.

Example

derive: {slope: op.gradient()}