Skip to content

ariadne(lsystem): live per-node tweak panels as reusable components (Phase 5) - #566

Merged
transfix merged 1 commit into
masterfrom
feat/lsys-node-controls
Oct 4, 2026
Merged

transfix merged 1 commit into
masterfrom
feat/lsys-node-controls

Conversation

@transfix

@transfix transfix commented Oct 4, 2026

Copy link
Copy Markdown
Owner

What

Adds windows to tweak each lsystem node's procedural settings live, as reusable .ari components — one per node type. The node realizers now read their params from bound state keys (forest.* / sea.* / sky.*) that they seed from the authored .ari props, so a control panel bound to the same keys starts at the document's values and then drives the node live.

Live response (lsystem_nodes.cpp)

  • wave_sea — reads sea.wave_amp / sea.sea_level on every refill (the field re-fills each frame anyway) → fully live, no regen.
  • cloud_sky — sky.drift / sky.morph (scroll + crossfade speed) and sky.shadow (toggles the ground dappling; off re-bakes plain albedo once). Cloud shape stays baked (regen is seconds, not a slider).
  • forest_trees — wind every frame; the structural params (count/seed/species/span/levels/…) regenerate the mesh on change (grow_forest → GeometryNode::setGeometry + rebuilt route-C wind buffers). Ariadne sliders commit on release, so that's one regen per edit, not per drag-frame. The needle node is always created so a live species change to pine can fill it.

Reusable components (src/cvc/ariadne/components/)

forest_controls.ari, sea_controls.ari, sky_controls.ari — lsystem_forest.ari imports + arranges them in a second panel column.

Verified

In the browser (wasm, generic ariadne_hello): the three panels appear seeded from the .ari values; dragging Tree count 80 → 13 re-grows the forest live. Tests: cvcgl_ariadne_realize +2 (realizers seed forest.count / sea.wave_amp from props); realize suite green; native + wasm compile.

before after
80 trees (authored) 13 trees after dragging the Tree count slider — regenerated live

…Phase 5)

Add windows that let the user tweak each lsystem node's procedural settings LIVE, as reusable .ari
components — one per node type. The node realizers now read their params from BOUND STATE KEYS
(forest.* / sea.* / sky.*) that they SEED from the authored .ari props, so a control panel bound to
the same keys starts at the document's values and then drives the node live.

Live response in lsystem_nodes.cpp:
  - wave_sea — reads sea.wave_amp / sea.sea_level on every refill (the depth field is re-filled each
    frame anyway) → FULLY live, no regeneration.
  - cloud_sky — reads sky.drift / sky.morph (scroll + crossfade speed) and sky.shadow (toggles the
    cloud→ground dappling; turning it off re-bakes the plain band albedo once) each stride. The cloud
    SHAPE stays baked (regenerating it is seconds, not a live slider).
  - forest_trees — wind is applied every frame; the STRUCTURAL params (count/seed/species/span/
    sea_level/scale/length/radius/levels/branches/pine_scale) regenerate the mesh on change —
    grow_forest → GeometryNode::setGeometry(wood)+(needle) + rebuilt route-C wind buffers. Ariadne
    sliders commit on release, so that's ONE regen per edit, not per drag-frame. The needle node is
    always created (even for a branchy-only forest) so a live species change to pine can fill it.

Reusable components (src/cvc/ariadne/components/): forest_controls.ari (count/seed/species-combo/
span/sea_level/levels/branches/pine_scale/wind), sea_controls.ari (wave_amp/sea_level),
sky_controls.ari (shadow/drift/morph). lsystem_forest.ari imports + arranges them in a second panel
column.

Verified in the browser (wasm, generic ariadne_hello host): the three panels appear seeded from the
.ari values; dragging Tree count 80 → 13 re-grows the forest live. Tests: cvcgl_ariadne_realize +2
(the realizers seed forest.count / sea.wave_amp from their props); realize suite green; native +
wasm compile.
@transfix
transfix enabled auto-merge (squash) October 4, 2026 19:18
@transfix
transfix merged commit 97c8ae3 into master Oct 4, 2026
14 checks passed
@transfix
transfix deleted the feat/lsys-node-controls branch October 29, 2026 20:52
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant