mirror of
https://github.com/storytold/lightcraft.git
synced 2026-10-27 03:27:14 -06:00
The parametric graph is now a control surface. Each of the four regions has a handle on its own bump: drag it up or down and that region's slider moves with it. Each of the three splits has a notch on the graph's bottom edge: drag it left or right and the region boundary moves. Every write goes through `develop.set` on the frame it happens, so the sliders under the graph, the curve and the handles are all the same state and are seen to agree mid-drag. A drag runs inside one `develop` interaction, so a whole gesture is one undo step and Ctrl+Z takes it back at once rather than unwinding it frame by frame. Details that make it usable: - The handle is the one under the *press*, not under the pointer once the drag threshold has passed — that is most of a handle's width away, and hit-testing the moved pointer grabbed nothing at all on a short drag. - The drag follows the pointer's motion from the handle's own centre, so a grab never makes the control jump by the distance from the pointer to that centre. - Splits are looked for before region handles: a notch sits on the bottom edge where the curve itself passes on the dark end of a shallow line, so on equal terms a region handle would always win and a notch could never be grabbed. - A split is kept a step clear of its neighbours, and a region handle saturates at ±100 rather than jumping when the pointer goes past what the region can reach. ⌥ is a tenth of the motion, as the point curve's drag is. Tests cover a region drag down and up, a split drag (including its bounds), a drag that starts off every handle moving nothing, the readout naming the control under the pointer, the level/amount inverse, and one undo step per gesture. Co-Authored-By: deepseek-flash <noreply@deepseek.com>