ui: show fluid results in the viewport with the part, legend and controls

The window built a deformed copy of the model for every results plot,
which drops the geometry surfaces, so after a fluid solve the bracket
vanished and nothing else was drawn.

A fluid step's plot keeps the part as it is and draws the engine's flow
display through it (the same scene as the headless pictures): the
field on a slice, the part coloured by the flow beside it and
streamlines. The legend shows the field with its bands and the cells
of its extremes (Max/Min mark and turn the view to them); the results
panel swaps the deformation rows for the slice's normal and position,
the obstacles' colours, the streamlines and a frame slider, all
running the results.* commands. The status line describes the new
commands.

Part of #193.
This commit is contained in:
Christian Svensson authored and Irakli Kourtis committed 2026-10-17 07:25:04 -04:00
1 parent f7dcd46b2f
commit a0c7d6ce9d
6 files changed
+303 -72

No files matched your search

+4 -2
View File
@@ -67,8 +67,10 @@ Reynolds number and rises as it falls); the lattice's mass changes by less than
![The L-bracket the air flows past, as the sample opens](media/examples/flow-past.png)
The picture shows the bracket only: the viewport does not draw flow results yet (velocity
slices and streamlines are planned in M12), so the results are numbers for now.
The picture shows the bracket as the sample opens. After Solve the viewport draws the flow:
velocity magnitude on a slice through the middle of the box (`results.slice`; pressure with
`field: "pressure"`), the bracket coloured by the flow beside it (`results.surface`) and
streamlines seeded upstream of it, coloured by speed (`results.streamlines`).
## Heated bracket (`heated-bracket`)