Helix facets — design spec (2026-07-10)
Three new 3-D data-viz facets, generalizing the existing facett_graph3d::Layout3D::Helix (facett-graph3d/src/lib.rs:111). Reuse what's there: Graph3D/Node3, the injected-clock spin (FC-7, with_clock), the neon painters (neon::paint_node_orb/paint_edge_particles/ paint_shockwave), DecorPolicy, the GPU path (graph_gpu.wgsl), look::Theme, state_json.
The unifying invariant: Z = DEPTH = the stack of layers/versions; the circle (cross- section) holds the per-layer data; dims beyond the circle's 2-3 spatial axes spill into colour (then size/glow).
Variant A — DNA Helix (facett-dnahelix or Layout3D::Dna)
A true double-helix. Each data record = one rung (base pair) at step i. Two backbone strands spiral around a central axis; a rung connects strandA_i ↔ strandB_i.
Geometric roles (fixed) ← data fields (user-choosable via a column picker):
| geometric role | what it does | default data field |
| axial position (along the helix) | which rung / where up the ladder | z — the "pinnarna i DNA-stegen" (progression / time / index). matches user. |
| rung radius R_i (half-length) | fat/thin helix at that step | x — "randen av pinnen" (magnitude). matches user. |
| rung tilt / base-pair asymmetry | signed lean of the rung | y ← MY ANSWER (see below). |
| twist θ_i = i·pitch | the helical spin itself | constant pitch (choosable); optionally data-driven |
| colour | 4th dimension | optional field |
The y answer ("y vet jag inte — hjälp mig"): map y to base-pair asymmetry / rung lean — DNA's two strands give you a signed second variable for free. strandA_i sits at radius R·(1 + k·y_i), strandB_i at R·(1 − k·y_i). At y=0 the rung is symmetric through the axis; y>0 pushes the pair toward strand A, y<0 toward strand B — the ladder visibly leans. So: x = how wide the rung is, y = which way it leans (a signed value), z = how far up the ladder. (Alternative if you'd rather: y = local pitch — vertical rise between rungs, so y stretches/compresses the helix. Make it a DnaAxis::{Tilt, Pitch} toggle so both ship.)
Strands drawn as glowing tubes (neon orbs along each), rungs as glowing edges. Spins on the axis by default. state_json exposes the axis→field mapping + spin/yaw.
Variant B — Time Helix / Time Vortex (facett-timehelix) ⬅ the Doctor-Who one
A rotatable cylinder viewed down its axis — you fly into the tunnel.
- Z = depth into the cylinder = layer index (time / version). Discrete layers z=0,1,2,…
- Each layer = a circular cross-section disc at depth z. Data points placed within the disc by (x,y) — default polar (angle=x, radius=y) so the circle fills naturally (cartesian optional). At z=0 the point (x1,y1) is on the nearest disc; z=1 (x2,y2) sits on the disc behind it, etc. — exactly the user's layering.
- Do NOT draw the circle outline; per layer, an optional faint bluish glow ring (weak, additive) — the "svag blåaktig cirkel faint".
- A 3rd spatial dim can bow the disc into a cylinder-segment (bent circle); 4th+ dims → colour, then size/glow. Z always stays depth.
- Rotatable: whole cylinder swirls around the depth axis (injected-clock spin).
Doctor Who intro — deep analysis → the render treatment
The title "time vortex": a tunnel/wormhole the camera flies through forever; swirling cloud walls in teal/cyan shot with gold lightning; the tunnel recedes to a bright core / vanishing point while distant walls dissolve into darkness (depth fog); the walls spiral as you fly; energy filaments streak forward; heavy additive bloom + motion blur + a sense of infinite depth and speed. Translate that to the facet:
- Camera down the axis toward a bright vanishing point — radial core gradient (cyan-white centre → deep indigo rim).
- Perspective shrink + exponential depth fade (this is the "tona ner som en flygsimulator"):
alpha_layer = exp(-depth·k), and colour lerps toward deep blue with depth (atmospheric fog). Near layer = big/bright/saturated; far layer = small/dim/blue → dissolves to black. - Slow axial swirl via the injected clock.
- Additive glow points (
neon::paint_node_orb) + faint per-layer glow rings. - Energy filaments = optional inter-layer edges as glowing curved streaks (
neon::paint_edge_particles) — this is literally Variant C's version-wires. - Palette: cyan/teal + gold accents on deep indigo/black; theme-aware via
look::Theme. Optionally a subtle volumetric cloud shimmer ingraph_gpu.wgsl.
Variant C — Component-DAG Time Helix (nornir follow-on)
The generalized Z-helix where each layer = a moment in time (release/commit/version) and each layer holds a component dependency DAG (components as disc nodes + intra-layer dep edges). Inter-layer wires connect component C in layer z → C in layer z+1 (its next version) = the glowing filaments = version evolution. Fly down the vortex to watch the whole dependency graph evolve over time.
Nornir uses (after A+B land in facett):
- Funnel-DAG: funnel cards/plan over time as the layered vortex.
- Component-DAG: workspace crate deps across releases, versions threaded layer-to-layer.
Build plan / sequencing
-
facett: Variant A (DNA Helix) + Variant B (Time Vortex) as first-class
Facets (headlessstate_json, injected-clock spin, theme-aware, pointer-drag orbit takeover). -
facett-demo: wire both into tabs (e.g.
dna+timehelix), seeded with realistic demo data; add toLEGEND+mega_matrixcoverage gate + a robot-drive step. -
Commit on a branch in facett + facett-demo.
cargo build/cargo test -p facett-demo-p facett-graph3d/new-crate green.
-
nornir (separate, follow-on): Variant C for Funnel-DAG + Component-DAG. (Note nornir
cargo testis currently RED — see workspace FIXQUEUE N10 — fix that first.)