PrivatelayerPrivatelayersMap from path to LayerInfo
PrivatelastPath of the last clicked layer (anchor for Shift+click range)
PrivatelistenersChange listeners
PrivatesoloToggle-restore solo capture (see solo); null when not soloed.
Get the number of layers
Path of the layer currently soloed via solo, else null.
Initialize layers from the scene graph.
Walks children recursively and collects nodes with layer: true.
PrivatewalkPrivatepushA sound node exposed as a layer: eye = mute, slider = gain, tooltip =
licence. Every appearance field is a neutral placeholder — nothing here
reaches a material — so the row can sit in the same list as the geometry.
Set a sound layer's live gain (clamped to [0, 2]); a no-op on other layers.
Get all layers in display order
Select a layer with napari-style modifiers.
Get all currently selected layers
Get the "primary" selected layer (last clicked) for showing in controls
Toggle-restore solo ("hide all others"). The first call captures the
current visibility set and shows only path; soloing the SAME path
again restores the captured set (for layers that still exist); soloing
a DIFFERENT path re-targets while keeping the original capture, so the
eventual un-solo restores the true pre-solo state. A manual visibility
change or a scene reload clears the capture. One notification per
transition (never per-layer).
Set visibility for many layers with a SINGLE change notification (setVisible notifies per call, so an N-layer sweep would re-render the panel N times). Clears any solo capture — a batch visibility change supersedes the remembered pre-solo state.
Replace a layer's state with a freshly derived LayerInfo
(per-layer reset). Preserves selected, and clears any solo capture —
the reset rewrites visibility behind the capture's back, so a later
un-solo restore would silently overwrite it (and soloedPath would lie
about which layers are showing in the meantime). Notifies once. The
live object is mutated in place, so references held by callers stay
valid.
Set display range for a layer
Set gamma for a layer
Set opacity for a layer
Set colormap for a layer
Re-default the display window after the layer's colormap was toggled.
The window maps the RENDERED VALUE to [0, 1], and toggling a colormap changes what that value is — so the sensible default changes with it:
updateScalarRange(0, 1) onto amplitudes that
live in ~[1e-4, 0.02] and render near-black (the #522 failure).A window carried over from the other mode is meaningless, so this deliberately overwrites a user-set one.
The slider BOUNDS follow the mode too, landing on exactly what a natively authored layer of that mode gets at init. Merely widening them instead would leave the useful window as an unusable sliver of the track — a gsplat amplitude window of [1e-4, 0.02] inside [0, 1] bounds is 2% of it.
Set blending mode for a layer. A user pick marks the mode EXPLICIT.
Set (or clear) a layer's authored cross-layer draw order.
undefined CLEARS it, which is not the same authored state as setting 0:
both resolve to band 0, but only the latter remains a stated value in the
panel and authored-band diagnostics. Clearing must therefore also clear
layerOrderExplicit, or liveLayerAttrs would keep emitting the stale
value as this layer's own setter.
Set absorption (volumetric κ) for a layer
Apply a mutation to all selected layers. The mutator receives each selected LayerInfo to modify in place.
Subscribe to state changes. Returns an unsubscribe function.
PrivatenotifyClear all state
Ordered list of layer paths (insertion order from scene graph walk)