Documentation / Node reference / tex nodes

tex/Solver

Repeats a chain of texture nodes on its own result: a simulation that runs frame after frame, or a filter applied several times.

Network

The nodes inside the solver are one step. Inside, a tex/SubnetInput set to input 0 gives the picture as it is now: the picture on the solver's first input before the first step, then the result of the step before. The tex/Output inside gives the picture after the step, which the solver keeps and shows. The solver's other inputs reach the tex/SubnetInput nodes set to 1, 2 and 3 unchanged, every step.

mode PER_FRAME runs a simulation. Each time the scene time moves forward, the solver runs `iterations` steps on the picture it kept from the frame before. Reaction-diffusion is the classic one: a tex/Builder inside reads the picture's neighbours and writes how two chemicals spread and react, 20 steps a frame, and patterns of spots or stripes grow out of a few seeded dots. The solver starts over from its first input at `startFrame` and before it, and whenever time goes back, so to start again, go back to `startFrame`. Pausing holds the picture as it is. Jumping forward on the timeline does not run the frames skipped: it runs one frame's steps. Changing a param, inside or on the solver, does not step either.

mode COUNT runs a filter several times. Every cook starts from the first input and runs `iterations` steps: a tex/Blur inside with iterations 10 blurs the picture ten times, a tex/Brightness of 0.9 with iterations 5 darkens it to 0.9 times 0.9 times 0.9 times 0.9 times 0.9. Nothing is kept between frames.

The solver only steps when something shows its picture, a material or a preview: a solver nothing displays does not cook, so it does not step. Bypassing it shows its first input and steps nothing.

Parameters

Name Type What it does
mode UInt8 PER_FRAME · COUNT When the steps run. PER_FRAME: each time the scene time moves forward, continuing from the picture of the frame before, for a simulation. COUNT: on every cook, starting from the first input each time, to apply the nodes inside several times.
iterations UInt32 How many times the nodes inside run: per frame with PER_FRAME, per cook with COUNT. 0 shows the first input. The solver runs at most 1000 at a time and warns above that.
startFrame UInt32 The frame at which the simulation starts. At this frame and before it, the solver shows its first input; the steps begin on the frame after. Going back to it starts the simulation over.

Examples

Scenes you can open in the editor that teach this node.

The tex/ReactionDiffusion node grows a pattern in a 64 by 64 by 64 texture: two chemicals spread through the volume and react, and three seeded spheres grow into a maze of folded sheets. The viewer draws them as fog with a mat/Volume, and beside it as a solid with a mat/VolumeSurface, both reading the texture where the GPU wrote it. Open the texture panel to see it slice by slice or raymarched.

tex/PolyNode tex/Solver tex/Builder code/TextureLaplacian mat/Volume mat/VolumeSurface

Materials Animation

See also

This page is generated from the engine, so it describes the release you can download. The same text is in the editor's Help panel next to the node itself.