zone_painter_legacy_rollout_spec - ryzom/ryzomcore GitHub Wiki
2026-07-29. Reference for the zone painter's patch-mode panel UI: the legacy in-Max plugin's rollouts, contents, placement, enable rules, and icon and cursor motifs. Controls are named by on-screen label and function; icons and cursors by motif for new art in the painter's style. Gaps researched and added here.
The tile machinery (tile mode, tile steps, transitions, keep-mapping, the Tile sub-object level, tile number/rotation, per-patch U/V tessellation and balance, edge no-smooth, bind/unbind, turn) is NeL-original (Nevrax).
- "NeL Patch Edit" (shown in the modifier stack as NeL Edit) — the structural editor. Five rollouts, four of them described below; this is the model for the zone painter's patch mode panel.
- "NeL Painter" — the paint modifier. Its command panel presence is a single tiny rollout (titled Geometry): a large Paint push button that launches the fullscreen painter, plus two checkboxes — Meshes (include mesh objects in the paint scene) and Preload Tiles. Everything else about the painter lives inside the fullscreen UI, which the zone painter has already reimplemented and surpassed; nothing more to take from it here.
The command panel is a single scrolling column of collapsible rollouts, ~108 dialog units wide (the standard modifier panel width). The legacy modifier mounts, in order:
- Selection — always present.
- Geometry — always present. One very tall rollout (~4× the height of Selection) holding all operations.
- A per-level properties rollout, swapped in and out as the sub-object level changes:
- Surface Properties — only at Patch level.
- Tile Properties — only at Tile level.
- Edge Properties — only at Edge level.
- Vertex and Object level mount no third rollout.
Open/collapsed state is remembered per rollout across level switches and edit sessions (each rollout records whether it was open when torn down and restores that). This matches the zone painter's existing rollout column exactly (mode-gated visibility, open-state remembered; see the painter panel).
There is also a dormant object-level Surface Properties variant in the resources (tessellation source, mesh/displacement toggle, fixed/parametric/spatial/curvature approximation, an "Advanced" popup) — the mount call is commented out in the legacy code since 1999 and the panel never appears. Do not reimplement. The real tessellation controls that matter live in the Geometry rollout's Surface and Tiles groups.
Object, Vertex, Edge, Patch, Tile — in that order. Level selection is a four-button icon toolbar (Vertex, Edge, Patch, Tile) at the top of the Selection rollout; Object level is the state with no button pressed, and clicking the pressed button again returns to Object level (toggle-off). Exactly one can be pressed. Tooltips name the levels.
The zone painter already has these levels behind keyboard/script (vertex/edge/patch); the toolbar gives them their mouse path. Tile level exists in the legacy plugin as a selection of tiles with its own selection set; what it should do in the zone painter is still the open backlog question — the legacy answer (it exists so tile properties and the painter can address tile selections) is recorded here for when that question is picked up.
Top to bottom:
- Level toolbar (described above), centered.
- Named Selections group: two buttons, Copy and Paste. Copy stores the current level's selection under a name (via a picker dialog listing existing sets); Paste is enabled only when the clipboard holds a set of the current level's kind. No named sets at Tile level. (Named-set naming conflicts on paste open a small rename dialog.) The actual named-set dropdown lives on the main toolbar, not in the rollout.
- Filter group: two checkboxes side by side, Vertices and Vectors — they gate what vertex-level hit-testing picks (corner points vs tangent handles). Both default on; unchecking one disables the other checkbox's toggle until it's re-checked (you cannot filter both away).
- Lock Handles checkbox: when on, moving one tangent handle moves the matching handles together (the legacy "locked handles" behaviour).
- Selection readout: one right-aligned text line, e.g. "Whole Object Selected", "Vertex 12 Selected", "34 Vertices Selected", and the same singular/plural pair for edges, patches, and tiles.
- A build/version line (the legacy panel shows dll version and build date; the zone painter has no need for it in the rollout — its About lives elsewhere).
Two display checkboxes (Lattice, Surface) exist in the resource but are hidden and disabled — leftovers, do not carry over.
One tall rollout, five titled groups in vertical order. Buttons are ~43 units wide, two per row. Per-level enabling is central: controls stay visible but grey out when the current level can't use them.
Interactive command modes (Attach, Extrude, Bevel, Bind — and the two-step Add Tri/Add Quad flow) are sticky check buttons with a green-highlight active state: pressing one enters a viewport command mode, pressing again (or completing/cancelling) leaves it.
| Control | Type | Range/default | Enabled |
|---|---|---|---|
| View Steps | int spinner | 0–100 | when Tiled mode is OFF |
| Render Steps | int spinner | 0–100 | when Tiled mode is OFF |
| Show Interior Edges | checkbox | always |
| Control | Type | Range/default | Enabled |
|---|---|---|---|
| Tile Steps | int spinner | −5…+5 | when Tiled mode is ON |
| Transitions | int spinner | 1–3 | when Tiled mode is ON |
| Tiled mode | checkbox | always | |
| Keep mapping | checkbox | when Tiled mode is ON |
Tiled mode is the master switch: turning it on swaps the effective tessellation source from View/Render Steps to Tile Steps + Transitions and enables Keep mapping (preserve the UV map channel through the tile conversion — the mapped-heritage corpus objects are exactly the ones saved with this on).
| Control | Enabled at level | Notes |
|---|---|---|
| Add Tri | Edge | command mode: pick an open edge, a triangular patch is grown from it |
| Add Quad | Edge | same, quad patch |
| Weld + threshold spinner | Vertex | threshold in world units, default 0.1, huge max; welds selected vertices within threshold |
| Detach (+ Reorient, Copy checkboxes) | Patch | detaches selection as a new object; name dialog ("Detach as:") |
| Attach (+ Reorient checkbox) | always | sticky pick mode: click another patch object to merge it in |
| Delete | Vertex/Edge/Patch | delete selection |
| Reset | Vertex | NeL addition, sits beside Delete |
| Hide | Vertex/Edge/Patch | hide selection |
| Unhide All | all except Tile | |
| Turn CCW / Turn CW | Patch | NeL addition: rotates the patch's internal orientation (tile frame) a quarter-turn |
| Control | Enabled at level | Notes |
|---|---|---|
| Subdivide | Edge/Patch | splits selected edges/patches |
| Propagate | Edge/Patch | checkbox; carry subdivision across neighbours to keep continuity |
| Bind | Vertex | sticky command mode: drag from a free corner vertex onto an edge to bind it (T-junction) |
| Unbind | Vertex | releases selected bound vertices |
Extrude and Bevel sticky-mode buttons; Extrusion and Outlining float spinners (unbounded, type-in or drag); Normal: Group/Local radio pair (Local default); Bevel Smoothing: two radio columns Start and End, each Smooth/Linear/None (Smooth default both).
The legacy viewport ops post back into this rollout (a scripted/quad-menu "subdivide" just presses the Subdivide button), so the rollout is the single behaviour surface — worth keeping in the zone painter: panel buttons are the operations; hotkeys and menus alias them.
- Material group: material ID int spinner (1–65535 nominal; Max material ID), and a Select By ID button (dialog: ID spinner + "Clear Selection" checkbox).
- Smoothing Groups: a 4-row × 8-column grid of small toggle buttons labelled 1–32, tri-state display (on/off/indeterminate across the selection); Select By SG (dialog with the same 32-button grid + "Clear Selection") and Clear All buttons.
- Tiles group (NeL addition): U tess and V tess int spinners (1–4, i.e. up to the default tessellation), and Balance Selected — evens the tessellation across the selected patches.
- Tile#: int spinner 0–65535 — the tile index under the selected tile(s).
- Rotation: int spinner 0–3 — quarter-turns.
(The fullscreen painter long ago superseded this as the way tiles actually get painted; the rollout is the inspection/nudge path.)
A single No smooth tri-state checkbox — marks the selected edges as smoothing breaks (indeterminate when the selection mixes both states). Writes the per-edge flag in the NeL patch data. This plus Unbind/Bind are the Tier B ops that need no stream encoder.
At Vertex level, right-clicking over a vertex appends to the viewport context menu a separator and a checked-radio pair Coplanar / Corner (the vertex's tangent-continuity type, applied to the clicked/selected vertices). At Patch level the same pattern gives Auto Interior / Manual Interior. The check mark reflects the clicked element's current state. The zone painter's scene context menu is the natural home for both pairs.
| Dialog | Contents |
|---|---|
| Detach | name field ("Detach as:"), OK/Cancel |
| Select By Material ID | ID spinner, Clear Selection checkbox, OK/Cancel |
| Select By Smooth Groups | 32-button group grid, Clear Selection checkbox, OK/Cancel |
| Copy Named Selection | list box of existing sets, OK/Cancel |
| Paste Named Selection (rename) | message + name field, shown on name collision |
(The "Advanced Surface Approx." dialog belongs to the dormant object-level surface panel — skip.)
(The complete tool-wide art list — toolbar, panel, board glyphs, all cursors — is
zone_painter_icon_manifest.md; this section covers what the legacy modifier itself
used.)
The only toolbar strip the patch-edit code actually loads is the sub-object level strip: eight cells of 24×23 px — four icons in normal state plus the same four in pressed state (legacy palette: red glyphs, black accents; grey background normal, yellow background pressed, with a 1-bit transparency mask). Motifs, in order:
- Vertex — four small plus-cross markers arranged at the corners of an implied diamond/quad; no outline.
- Edge — the outline of a quad drawn as dotted/beaded segments (points along the border), unfilled.
- Patch — a solid filled quad, slightly rotated/foreshortened, dark outline with corner ticks.
- Tile — the same filled quad subdivided into a 2×2 grid by two dark cross lines.
For the zone painter these get redrawn in the toolbar's own visual language (same perspective and stroke style as the existing mode faces); the motifs above are the spec, not the pixels. Pressed state in NLGUI comes from the pushed face, so no separate pressed art is needed.
Unused bitmaps in the legacy resource directory (mesh/spline selection strips, boolean and mirror strips, UV-unwrap tool faces, "bulb" toggles) are out of scope for the painter.
Cursors the patch-edit code actually sets, by motif (all 32×32 monochrome with mask):
- Extrude — a square face lifted above a hatched base (pulling a face out), small plus-cross at lower left.
- Bevel — a flat trapezoid (a beveled profile) with a small cross above-left.
- Bind (aim) — two short beaded line segments angled together plus a small cross: "drag vertex onto edge".
- Pick-target cross — a plain thick plus cross (used while hovering valid bind/attach targets).
- Attach — a small circle with an arrow leading out of it to the lower right, cross below (object pick).
The paint plugin's four (for completeness; the zone painter's paint modes already have their own cursor manifest): eyedropper (pick color), paint bucket pouring (fill), eyedropper + question mark (inspect tile), and a cross + vertical tick utility cursor.
The zone painter's cursor manifest (above the select-mode table in the source) already lists the needed paint-side cursors; the five edit-side motifs above join that list when the corresponding Tier B ops land.
New rollout Patch (working title), visible only in patch mode, joining the existing mode-gated column:
- Selection block — the four-icon level toolbar (toggle-off returns to object level), the selection readout line, Filter Vertices/Vectors, Lock Handles. Named selections: defer (needs a design pass against board sessions).
- Properties block, level-swapped like the legacy third rollout: edge → No smooth; patch → smoothing groups + U/V tess + balance; tile → tile#/rotation (pending the Tile level design question); vertex → nothing (Coplanar/Corner goes to the context menu).
- Geometry block — populated op by op as Tier B lands, in legacy group order (Surface/Tiles groups only if the zone painter ever edits tessellation settings; the Topology and Subdivision groups are the near-term content: Bind/Unbind and No smooth first — no encoder needed — then Weld/Delete/Subdivide/Add as the encoder milestones arrive).
- Panel buttons are the single op surface;
painter.*script bindings and hotkeys alias the buttons, so gates exercise the same path the mouse does — the standing dispatch-blind-spot lesson applies to every new button.