Free, open-source 3D sculpting for Linux, macOS and Windows: dense meshes, remeshing, painting, built-in AI (image/text to 3D), Send to Unreal, game-ready LODs, Gaussian splats and OpenUSD.
C++ 3d3d-sculptingcppdear-imguidigital-sculptingfbxgame-developmentgaussian-splattinggltfimage-to-3dmcpopenglopenusdsculptingtext-to-3dunreal-engine
Docs: the UI spec describes SculptForge's own shell (other apps' reference notes dropped); the keymap comparison notes leave the repository, the guide's Coming from ZBrush chapter covers them
islandmedd6695863f591
diff --git a/docs/ui-design.md b/docs/ui-design.mdindex 9ac18c97..134791eb 100644--- a/docs/ui-design.md+++ b/docs/ui-design.md@@ -1,53 +1,24 @@-# SculptForge UI spec: a ZBrush-shaped shell+# SculptForge UI spec: the shellStatus: design spec, ready to implement. Target: Dear ImGui **1.91.9** (pinned in `cmake/Dependencies.cmake`, non-docking), SDL3, OpenGL.-Reference picture: `~/Downloads/Core-interface.jpg` (ZBrush Core 1920x1080).## 0. Goals and non-goals-ZBrush users should feel at home within a minute:+Sculptors should find their way around within a minute:- a **bounded central canvas**, surrounded by **shelves** that hold the most-used controls (Tab hides them);- an **alphabetical palette bar** under the title strip that holds *every* function; palettes open as drop-downs and can be pinned into the **left or right tray**;- **Library** on `,` (comma): a horizontal thumbnail strip along the top of the canvas;-- a **ZScript-style console** at the bottom;+- a **script console** at the bottom;- **Ctrl+hover** on any control shows its description and shortcut;- **Customize**: Preferences > Config > Enable Customize, Ctrl+Alt+drag to move or remove items, **Store Config (Ctrl+Shift+I)**, **Restore Standard UI**.-Not goals: free-floating or OS-level detachable panels, tabbed docking, a full keymap editor, ZBrush 2.5D canvas or pixols. These need ImGui's docking branch or aren't worth the cost (see §12).+Not goals: free-floating or OS-level detachable panels, tabbed docking, a full keymap editor, a 2.5D canvas or pixols. These need ImGui's docking branch or aren't worth the cost (see §12).The current UI (screenshot, 1600x960) is a menu bar (File/Edit/Mesh/View/Help) plus floating windows over a full-window viewport: Tools (250 px, left), Parts, Layers / Blend Shapes, Game Ready, Brush Lab (open by default, covers the model), and optionally Vertex Paint & Materials, Generate 3D, Gaussian Splats. All of the features stay. Only where they live changes.----## 1. What ZBrush (and others) actually do: reference notes--| Element | Concrete behaviour (source) |-|---|---|-| Title bar | Left: version, memory, PolyCount / ActivePoints. Right: Snapshot, See-through slider, "Menus" toggle (show or hide the palette bar), DefaultZScript, layout preset cycle buttons, help [R1][picture] |-| Palette bar | Palettes listed **alphabetically** under the title bar (Alpha, Brush, Color, Document, Draw, Edit, File, Layer, Light, ... Tool, Transform, Zoom, Zplugin, Zscript). Clicking a name drops the palette down. Sub-palettes inside are context-sensitive [R1][R2] |-| Sub-palettes | One open at a time by default; **Shift+click** opens more (Preferences > Interface > One Subpalette) [R2][R3] |-| Trays | Left and right trays hold whole palettes. Right is open by default, left closed. **Double-click or click the divider** to toggle. A palette goes into a tray when you click its icon (top-left of the palette) or drag that icon to a tray. Only palettes go in trays [R1][R3][R4] |-| Shelves | Surround the canvas. Each grows to fit its largest item. **Tab** hides or shows them. Menus can't go on shelves [R1][R2][R4] |-| Top shelf | Library button; Draw / Move / Scale / Rotate (Q W E R); Mrgb / Rgb / M; Rgb Intensity; Add / Sub; Intensity; Falloff; Draw Size; ActivePoints / TotalPoints readout [picture][R1] |-| Left shelf | Big thumbnail buttons: Brush, Stroke, Alpha, Texture, Material, then a colour picker, two swatches, "Alternate", "FillObject" [picture][R1] |-| Right shelf | Canvas: BPR, Scroll, Zoom, Actual, AAHalf. Object: Persp, Floor, Local, L.Sym, Xyz, **Frame, Move, Scale, Rotate** (drag on the button to navigate), Wire, Transp, Ghost, Solo [picture][R1] |-| Bottom shelf (Core) | One row of the most-used brushes: Clay Block, Standard, Sharp Crease, Move, Trim, Hard Polish, Pinch, Inflate, IMM Primitives, Paint, Transpose, Select Lasso, Select Rectangle [picture] |-| Pop-up pickers | Any preview thumbnail with changeable contents opens a pop-up grid when clicked (Tool, Brush, Stroke, Alpha, Texture, Material) [R1] |-| Brush pop-up | **B** opens it. Typing a letter narrows the grid to brushes starting with that letter and shows a second key on each. Pressing it selects (B, S, T = Standard). Holding Ctrl while you pick chooses a masking brush [R5][R6] |-| Library | **`,`** toggles it. Category tabs along its top: Project, Tool, Brush, Material, Alpha, Texture, Light Editor, Snapshots (+ Recent). Back and forward arrows; an up-folder tile; **double-click** to enter folders or load items; drag in the strip to scrub sideways; 1-4 rows of icons; placement top or bottom (preference); thumbnail glow and label brightness preferences. Assets split into built-in (Maxon) and User [R7] |-| Ctrl-hover help | **Ctrl + cursor over item** shows the item's description when "Popup Info" is on. **Ctrl+Alt + hover** shows an alternative description. Opacity is set by Preferences > Icolors > Quick Info Opacity [R6][R8] |-| Quick Info | Large thumbnail viewer when you hover items in the Alpha, Material, Texture and Tool palettes. Has a delay slider, a "Large Quick Info Text" option, and Preview Material On Mesh [R9] |-| Customize | Preferences > Config > **Enable Customize**, then **Ctrl+Alt+drag** an item to move it. Dragging it to an invalid place (e.g. the canvas) **removes** it. Custom menus are made with Custom UI > Create New Menu. Items fill left to right. Element sizes are 1, 3/4, 1/2 or 1/4 of the width, 1/8 high [R4] |-| Config | **Store Config = Ctrl+Shift+I** (ZBrush never saves preferences automatically). Alt+Ctrl+Shift+I stores an alternate layout, Ctrl+L loads one. **Restore Standard UI** returns to the default; Restore Custom UI goes back to the stored one [R2][R4][R10] |-| Shortcuts | Tab shelves, `,` Library, B brush pop-up, Space Quick Menu, S / I / O size / intensity / focal, X symmetry, F frame, Shift+F polyframe, Ctrl+D divide, D / Shift+D sdiv up / down, Ctrl+Z / Ctrl+Shift+Z, Shift+Ctrl+I store config, H hide ZScript [R6] |-| Blender 4.3+ | Brushes are assets in an **asset shelf** at the bottom of the viewport (Shift+Space toggles it; drag its border to resize). Right-click a brush > Assign Shortcut [R11][R12] |-| Nomad Sculpt | Tools on the right; Radius / Intensity sliders and a "Sub" (invert) button on the left; a bottom bar of shortcuts that users can bind (Undo, Redo, Solo by default); top-left stats; nav cube; a mirrored left-handed layout [R13] |-| 3DCoat | "Rooms" show only the tools for one task. The Brush Options panel starts with an alpha preview. An "Activity bar" of pop-up libraries (Brushes, Strips, Stencils, Smart Materials...). Space shows the tool pop-up [R14] |--What we take from the others: Blender's **brush asset shelf**, which is our bottom shelf, plus "Assign Shortcut" on right-click. Nomad's **left-handed mirror** costs almost nothing in a data-driven layout (swap left and right). The command palette and console are our own additions. They exist because every SculptForge action is already a named, described command.-----## 2. Target layout@@ -110,7 +81,7 @@ Canvas = x 96..1240, y 110..900 (1144 x 790). With Library open (1 row), it cove### 2.3 1920 x 1080-Same structure. The right tray is 320 wide (x 1600..1920), the divider is at 1592, and the right shelf is at 1540..1592. Canvas = x 96..1540, y 110..1020 (**1444 x 910**). The extra width goes to the canvas only. Shelves keep their fixed sizes, as in ZBrush.+Same structure. The right tray is 320 wide (x 1600..1920), the divider is at 1592, and the right shelf is at 1540..1592. Canvas = x 96..1540, y 110..1020 (**1444 x 910**). The extra width goes to the canvas only. Shelves keep their fixed sizes.### 2.4 Narrow windows (< 1280 logical px wide)@@ -142,7 +113,7 @@ Notation: `cmd:name` = CommandRegistry command, `act:id` = UI action (§8), `widLeft to right:1. App glyph + "SculptForge".2. Document name + `*` when `doc.dirty`. Click: Save.-3. Info readout (dim text, like ZBrush's memory and PolyCount line): `Verts 5.1k Tris 10.2k SubTool <name> (2/5) Layer <name|Base> 60 fps`. Splat count when splats are loaded.+3. Info readout (dim text): `Verts 5.1k Tris 10.2k Part <name> (2/5) Layer <name|Base> 60 fps`. Splat count when splats are loaded.4. Status message (`status_`), elided. Errors in orange-red for 6 s.5. Right-aligned:- `[QuickSave]`: `act:file.quicksave` writes a timestamped `.sfproj` to `<user lib>/QuickSave/`, keeping the last 10. It shows up in the Library Snapshots tab.@@ -171,10 +142,10 @@ Every palette's body is one function `void drawPalette_<Id>()`, and the same fun| **Script** | Show console (`` ` ``), Run script file..., Copy session as script, Clear console || **Splats** | `drawSplatSection` body (info, clean, transform, to mesh, save, clear) || **Stroke** | Stroke type (Dots, Drag Stamp, Spray, Lazy Stroke) and its settings (spray scatter, lazy radius) |-| **Tool** | The ZBrush "Tool" palette. Header: active Part name + tri count, `[Open] [Save] [Import]`. Sub-palettes (collapsing headers, one open at a time, Shift+click for more): **Part** (Parts panel body), **Layers** (Layers / Blend Shapes body), **Geometry** (Lower Res / Higher Res, SDiv slider, Del Lower / Del Higher, Reconstruct Subdiv, Divide Ctrl+D + Smt, Subdivide, Decimate, `cmd:decimate`), **Remesh** (Voxel remesh + resolution, the "DynaMesh" analogue), **Masking** (`drawMaskingSection`), **Face Groups** (`drawPolygroupsSection`), **Visibility** (Show all, Invert visibility, Delete hidden), **Export** (Game Ready panel body: LODs, Unreal, GLB/LOD chain), **Display** (wireframe, show mask/groups, material colour) |+| **Tool** | The model palette. Header: active Part name + tri count, `[Open] [Save] [Import]`. Sub-palettes (collapsing headers, one open at a time, Shift+click for more): **Part** (Parts panel body), **Layers** (Layers / Blend Shapes body), **Geometry** (Lower Res / Higher Res, SDiv slider, Del Lower / Del Higher, Reconstruct Subdiv, Divide Ctrl+D + Smt, Subdivide, Decimate, `cmd:decimate`), **Remesh** (Voxel remesh + resolution, the "DynaMesh" analogue), **Masking** (`drawMaskingSection`), **Face Groups** (`drawPolygroupsSection`), **Visibility** (Show all, Invert visibility, Delete hidden), **Export** (Game Ready panel body: LODs, Unreal, GLB/LOD chain), **Display** (wireframe, show mask/groups, material colour) || **Transform** | Draw / Move / Scale / Rotate (Q W E R, Gizmo: pivot, World / Surface axes, Mask, All Parts, Falloff, numeric entry; `cmd:transform`), Symmetry X / Y / Z (X), Frame (F), Solo (`cmd:subtool_solo`), Wireframe |-ZBrush has no separate top-level Part / Layer / Masking / Face Groups palettes, so they are **Tool** sub-palettes only. The Mesh and View menus disappear, and their items move to Tool > Geometry/Remesh and Render. Palettes are sorted by name at registration, so a new palette lands in alphabetical order automatically.+Part / Layer / Masking / Face Groups are **Tool** sub-palettes, not top-level palettes. The Mesh and View menus disappear, and their items move to Tool > Geometry/Remesh and Render. Palettes are sorted by name at registration, so a new palette lands in alphabetical order automatically.### 3.3 Top shelf (h 64, two rows)Row 1:@@ -189,7 +160,7 @@ Row 1:Row 2:- `[AI Brush]` (toggles the Brush Lab window)- `[Front]` (front faces only)-- `[Dynamic]` dynamic topology (`act:draw.dynamic`, ZBrush's Sculptris Pro) and `Detail 50` slider (w 120; contextual: only while Dynamic is on)+- `[Dynamic]` dynamic topology (`act:draw.dynamic`) and `Detail 50` slider (w 120; contextual: only while Dynamic is on)- `[X][Y][Z]` symmetry (`X` toggles X)- `[Pressure>Str] [Pressure>Size]`- right-aligned `5.1k / 10.2k` (ActivePoints / TotalPoints analogue: visible vs total tris)@@ -199,7 +170,7 @@ needs a texture, Splats needs a capture, Detail needs Dynamic on) is *hidden* whshelves don't fill with dead buttons. Customize mode shows them all so they can be moved or removed. Paletteentries stay visible and disabled (with the reason in Ctrl help), because palettes are where users look things up.-Sliders use the ZBrush style: the label sits inside the frame (`SliderFloat("##size", ..., "Draw Size %.0f")`), and the grab is a thin accent bar.+Sliders put the label inside the frame (`SliderFloat("##size", ..., "Draw Size %.0f")`), and the grab is a thin accent bar.### 3.4 Left shelf (w 88)A vertical stack of **thumbnail tiles** (76x76, label under). A click opens the pop-up picker beside the tile (§4):@@ -209,17 +180,17 @@ A vertical stack of **thumbnail tiles** (76x76, label under). A click opens the4. Material: lit sphere sphere. Picker = material grid.5. Colour: a 76x76 SV square + hue strip (`ImGui::ColorPicker3` with `NoSidePreview|NoInputs|NoLabel`, width 76), then two swatches (primary / secondary, a click swaps them, like "Alternate"), then `[Fill]` (`cmd:paint_fill`).-ZBrush's Texture slot is left out (no texture feature yet). It's reserved in the layout data so it can be added later.+A Texture slot is left out (no texture feature yet). It's reserved in the layout data so it can be added later.### 3.5 Right shelf (w 52)Icon + tiny label, 44x40 each. Groups are separated by 8 px.-- **Navigation**: Frame (F). **Move, Zoom and Rotate are drag buttons**: left-drag on the button pans / zooms / orbits the camera, as in ZBrush. Implement with `InvisibleButton` + `IsItemActive()` + `io.MouseDelta`, feeding the existing camera functions.+- **Navigation**: Frame (F). **Move, Zoom and Rotate are drag buttons**: left-drag on the button pans / zooms / orbits the camera. Implement with `InvisibleButton` + `IsItemActive()` + `io.MouseDelta`, feeding the existing camera functions.- **View**: Persp (only if the camera supports ortho; otherwise leave it out), Floor (optional grid, only if cheap), Wire = wireframe (Shift+F; W is the Gizmo's Move since 0.5), Groups (`showPolygroups`), Mask (`showMask`), Paint (`showPolypaint`).- **Object**: Solo (`cmd:subtool_solo`), Splats (show splats; shown only when splats are loaded).Toggles that are on get an accent background.-### 3.6 Bottom shelf (h 78, Medium tiles): quick brushes (ZBrush Core / Blender asset shelf)+### 3.6 Bottom shelf (h 78, Medium tiles): quick brushesDefault contents, in order: Standard, Clay, Clay Block, Sharp Crease, Move, Smooth, Inflate, Pinch, Flatten, Crease, Trim, Tendril, Layer, Nudge, Paint. Then any custom brushes the user adds, and a `[+]` tile that opens the brush picker in "add to shelf" mode.Tiles are 40 px brush thumbnails with the name under them. The active brush gets an accent outline. Hotkey digits (1-9, 0) are drawn small in the tile's top-left. Right-click a tile: "Remove from shelf", "Assign shortcut...". Right-click in the brush picker: "Add to bottom shelf".@@ -228,21 +199,21 @@ Tiles are 40 px brush thumbnails with the name under them. The active brush gets- Right tray default stack: **Tool** (Parts sub-palette open).- Trays scroll vertically. Palette headers are full-width bars (h 22, `#2e2e32`) with the tray icon (click returns the palette to the bar), the title and a collapse arrow.- Divider: 8 px. Click or double-click toggles the tray, and dragging resizes it (cursor `ResizeEW`). It draws a 2 px grip in its centre.-- With Preferences > Interface > "Auto Collapse", opening one palette in a tray collapses the others when they'd overflow (ZBrush default: on for the left tray, off for the right).+- With Preferences > Interface > "Auto Collapse", opening one palette in a tray collapses the others when they'd overflow (default: on for the left tray, off for the right).### 3.8 Floating windows that stay floatingBrush Lab, Generate 3D, About, Controls, project / Part confirmation pop-ups. They keep their current ImGui windows and their imgui.ini persistence. Two changes: **Brush Lab defaults to closed**, opened from the top-shelf `[AI Brush]` or Brush palette. Its first-use position is the canvas top-left + (16,16), so it no longer sits over the model at 1600x960.----## 4. Pop-up pickers (ZBrush-style)+## 4. Pop-up pickersAll pickers are ImGui pop-up windows (`BeginPopup`). They open next to the shelf tile that opened them (to its right, top-aligned), or **under the mouse** when opened from a key. They close on pick, Esc, or a click outside. Tiles are 64x64 + 16 label, 6 px gap, 6 columns (max width ~460), with section headers ("Built-in", "Custom", "Library").### 4.1 Brush picker (B, or click the Brush tile)- A "Recent" row of the last 8 brushes at the top.- Grid sections: **Built-in** (the 14 `BrushType`s + Paint), **Custom** (`doc.brushes` recipes, with AI-made ones marked by a small sparkle badge), **Library** (`.sfbrush` files in `<user lib>/Brushes` that aren't loaded yet; picking one runs `cmd:brush_load`).-- **Type-to-filter, the ZBrush way.** The first letter typed keeps only brushes whose name starts with it, and the grid shows letter-index chips A-Z with counts at the top. Each remaining tile then shows an **orange key badge**: the shortest next letter that tells it apart (Standard after S -> `T`, Tendril -> `N`, Smooth -> `M`). Pressing that letter picks the brush.+- **Type-to-filter.** The first letter typed keeps only brushes whose name starts with it, and the grid shows letter-index chips A-Z with counts at the top. Each remaining tile then shows an **orange key badge**: the shortest next letter that tells it apart (Standard after S -> `T`, Tendril -> `N`, Smooth -> `M`). Pressing that letter picks the brush.- If no prefix matches, fall back to a substring match (shown in a filter field at the top).- Backspace undoes one letter. Enter picks the first match.- Thumbnails come from §6 (fallback: Lucide glyph + name).@@ -252,13 +223,13 @@ All pickers are ImGui pop-up windows (`BeginPopup`). They open next to the shelf### 4.2 Stroke, Alpha and Material pickers- Same tile grid, no letter badges (few items), but typing still filters.- **Material** is also opened with **M** (currently unbound in SculptForge).-- Hovering a material tile previews it on the model (ZBrush "Preview Material On Mesh"): set `renderSettings_.matcap` temporarily and restore it on leave.+- Hovering a material tile previews it on the model : set `renderSettings_.matcap` temporarily and restore it on leave.### 4.3 Size / Strength at cursor`S` and `I` open a one-slider pop-up under the mouse ("Draw Size 60", 200 px wide, already focused for drag or typing). It closes on release, Enter or Esc. `[` and `]` keep working.### 4.4 Optional: Space quick menu (P2)-Holding Space shows a compact panel under the cursor: Brush / Stroke / Alpha / Material tiles + Draw Size + Strength. Releasing Space closes it. Only do this if time allows. It's ZBrush's QuickMenu.+Holding Space shows a compact panel under the cursor: Brush / Stroke / Alpha / Material tiles + Draw Size + Strength. Releasing Space closes it. Only do this if time allows. It's the Quick Menu.---@@ -268,19 +239,19 @@ Holding Space shows a compact panel under the cursor: Brush / Stroke / Alpha / M- An overlay window anchored to the **top edge of the canvas**, full canvas width, `NoDecoration|NoMove|NoSavedSettings`, background `#141416` at 96%. Preference "Placement: bottom" anchors it above the bottom shelf instead.- **Header row (h 28)**: tabs (text buttons, active = accent underline):`Project | Tool | Brush | Alpha | Material | Image | Splats | Snapshots | Recent`- then back / forward arrows (tab+folder history), a breadcrumb (`User > Tools > creatures`), a filter field (w 160, our addition; ZBrush has none), the rows selector `[1][2][3][4]`, `[Open folder...]` (picks a folder and adds it as a library root), and close.+ then back / forward arrows (tab+folder history), a breadcrumb (`User > Tools > creatures`), a filter field (w 160), the rows selector `[1][2][3][4]`, `[Open folder...]` (picks a folder and adds it as a library root), and close.- **Strip**: tiles 96x96 + 22 label (elided, full name in hover). Tiles flow top-to-bottom within the row count, then left to right, so the strip scrolls **horizontally**.- The mouse wheel scrolls sideways.- - Left-drag on empty space or a tile **scrubs** (ZBrush). Drag starts after 4 px, so a click is still a click.+ - Left-drag on empty space or a tile **scrubs**. Drag starts after 4 px, so a click is still a click.- The first tile in a sub-folder is the up-folder tile. Folders show a folder glyph and are entered with a double-click.-- Hover: 1.5x scale glow (ZBrush thumbnail glow) and full path. Ctrl+hover shows Ctrl help with file size, modified date and (for meshes) the cached triangle count.+- Hover: 1.5x scale glow and full path. Ctrl+hover shows Ctrl help with file size, modified date and (for meshes) the cached triangle count.### 5.2 Sources (what SculptForge shows)Library roots:- **Built-in**: assets shipped with the app. `assets/demo/*` (lion-head.glb, teddy-sketch.png), built-in brushes, built-in alphas, lit spheres, primitives.- **User**: `SDL_GetUserFolder(SDL_FOLDER_DOCUMENTS)/SculptForge/`, created on first run with `Projects/ Tools/ Brushes/ Alphas/ Images/ Splats/ QuickSave/`. The Preferences > Library "library folder" setting overrides it.-Each tab shows a "Built-in" and a "User" folder at its root, as ZBrush shows Maxon and User.+Each tab shows a "Built-in" and a "User" folder at its root.| Tab | Shows | Double-click | Other actions ||---|---|---|---|@@ -297,7 +268,7 @@ Each tab shows a "Built-in" and a "User" folder at its root, as ZBrush shows Max- Right-click any tile: Open / Append as Part (meshes) / Show in file manager (`SDL_OpenURL("file://...")`) / Refresh thumbnail.- Dragging a tile onto the canvas = double-click.- Directory listing runs on a worker thread and is re-scanned when a tab opens and every 5 s while Library is open (cheap `last_write_time` check).-- Preferences > Library > "Show at startup" defaults **on**, opening the Project tab (ZBrush behaviour). It's forced off for `--ui-test`, `--render`, recording and demos.+- Preferences > Library > "Show at startup" defaults **on**, opening the Project tab. It's forced off for `--ui-test`, `--render`, recording and demos.---@@ -346,7 +317,7 @@ Each tab shows a "Built-in" and a "User" folder at its root, as ZBrush shows Max- Shift+Enter on a command with parameters opens the console with `name ` pre-typed.- Commands with **required** parameters always go to the console instead of running.-### 7.3 Console (the "ZScript window"; `` ` `` toggles it, Script palette)+### 7.3 Console ( `` ` `` toggles it, Script palette)- Bottom strip above the bottom shelf, h 160 (drag the top edge, 100-400). Font: ImGui's built-in ProggyClean via `AddFontDefault()` (MIT, ships inside ImGui, no new file) at 13 x scale.- **Log**: every `App::runCommand` (UI, keys, palette, AI agent, MCP) echoes as a script line followed by its result:```@@ -408,11 +379,11 @@ bool ActionButton(App&, const char* actionId, ImVec2 size = {}, Look = Look::Lab// toggles draw accent when checked(); Ctrl help; Ctrl+Alt drag source in customize modevoid HelpText(const char* title, const char* shortcut, const char* description, const char* path = nullptr); // for the last itemvoid HelpAction(const char* actionId); // for the last item-bool SliderInside(const char* id, float* v, float lo, float hi, const char* fmt, ImGuiSliderFlags = 0); // ZBrush-style label-in-frame+bool SliderInside(const char* id, float* v, float lo, float hi, const char* fmt, ImGuiSliderFlags = 0); // label inside the frame}```-**Default shortcut map.** Existing bindings are kept, ZBrush ones are added, and nothing existing changes meaning:+**Default shortcut map.** Existing bindings are kept, new ones are added, and nothing existing changes meaning:| Key | Action | | Key | Action ||---|---|---|---|---|@@ -425,7 +396,7 @@ bool SliderInside(const char* id, float* v, float lo, float hi, const char* fmt,`onKey`'s switch becomes `actions_.handleKey(...)` with these defaults. The F1 Controls window is generated from the registry, grouped by palette. User overrides are stored with Store Config.-Optional (P2): ZBrush-style shortcut assignment. Ctrl+Alt+click any ActionButton, then press a key ("Press a key for 'Clay'... Esc cancels"). Conflicts reassign, as in ZBrush.+Optional (P2): shortcut assignment in place. Ctrl+Alt+click any ActionButton, then press a key ("Press a key for 'Clay'... Esc cancels"). Conflicts reassign.---@@ -456,14 +427,14 @@ Json toJson(const UiLayout&); bool fromJson(const Json&, UiLayout&, std::string&- **Ctrl+Alt+drag** any ActionButton or shelf widget. It works from palettes and pickers too, which is how you *add* an item to a shelf.- ImGui drag source, payload `"SF_UIITEM"` = `{ itemId, fromShelf, fromIndex }`.- Shelves draw insertion targets between items (2 px accent line).- - **Dropping anywhere that isn't a shelf (e.g. the canvas) removes the item** if it came from a shelf (ZBrush semantics).+ - **Dropping anywhere that isn't a shelf (e.g. the canvas) removes the item** if it came from a shelf.- Palettes can't be dropped on shelves, only into trays (`"SF_PALETTE"` payload from the palette header icon).- **Store Config (Ctrl+Shift+I)** writes `<prefDir>/ui.json` = `{ layout, shortcuts: overrides, prefs: {popupInfo, uiScale, oneSubpalette, autoCollapse, lightbox...} }`. Status: "UI configuration stored".-- **Restore Standard UI**: `layout_ = standardLayout()` and shortcut overrides cleared. Not persisted until Store Config, as in ZBrush.+- **Restore Standard UI**: `layout_ = standardLayout()` and shortcut overrides cleared. Not persisted until Store Config.- **Restore Custom UI**: reload `ui.json`.- **Save UI... / Load UI... (Ctrl+L)**: the same JSON at a chosen path (for sharing layouts).- At startup `ui.json` is loaded if it's there, otherwise the standard layout. `--ui-test`, `--render` and recording **always** use the standard layout (deterministic tests and videos).-- ZBrush never auto-saves the layout. To avoid surprising non-ZBrush users, the first time the layout changes in a session (tray moved, shelf edited) the status line hints once: "Layout changed - Ctrl+Shift+I to keep it".+- The layout is never saved automatically. So nobody is surprised, the first time the layout changes in a session (tray moved, shelf edited) the status line hints once: "Layout changed - Ctrl+Shift+I to keep it".### 9.3 Presets (title-strip `[1][2][3]`)1. **Standard** (§2).@@ -517,7 +488,7 @@ Style:- **Why Lucide over Material Symbols (Apache-2.0)**:- Lucide's codepoints are all in the BMP. `IconsLucide.h` defines `ICON_MIN_LC 0xe038` and `ICON_MAX_16_LC == ICON_MAX_LC 0xe6fd`, so it works with ImGui's default 16-bit `ImWchar`.- The TTF is small (a few hundred KB).- - Thin outline glyphs suit a dense, ZBrush-like UI.+ - Thin outline glyphs suit a dense UI.- Material Symbols is a 10 MB+ variable font. Its full range goes past 16-bit (IconFontCppHeaders has a separate `ICON_MAX_16_MS`), and Apache-2.0 adds NOTICE handling. [R16][R17]- **Files** (vendored, pinned to one `lucide-static` version; codepoints aren't stable across versions, so header and TTF must come from the same version):- `assets/fonts/lucide.ttf` from `https://unpkg.com/lucide-static@<pinned>/font/lucide.ttf`@@ -532,7 +503,7 @@ Style:Repeat the merge for the 12 px shelf font. In the right shelf, use a separate non-merged 20 px Lucide font for the large icons.- With ImGui >= 1.92 (dynamic fonts), the glyph ranges can be dropped. Not relevant on 1.91.9.- **Glyphs to use** (check each name against the pinned header): `brush, paintbrush, spray-can, move-3d, rotate-3d, scale-3d, scan (frame), hand (pan), zoom-in, grid-3x3 (wireframe), eye, eye-off, boxes (subtools), layers, droplet (mask), shapes (polygroups), palette (color), circle-dashed (alpha), sun (material), image, folder, folder-open, save, undo-2, redo-2, search, square-terminal, circle-help, settings, sparkles (AI), wand-sparkles, package (export), gamepad-2 (game ready), panel-left, panel-right, chevron-*, x`.-- Sculpt-specific visuals (brushes, alphas, materials, models) use **rendered thumbnails** (§6), not glyphs. No icon set has good sculpting-brush icons, and ZBrush itself uses rendered previews.+- Sculpt-specific visuals (brushes, alphas, materials, models) use **rendered thumbnails** (§6), not glyphs. No icon set has good sculpting-brush icons.---@@ -546,7 +517,7 @@ Works without the docking branch:Each shell window needs `NoFocusOnAppearing` and must not steal keyboard focus, so `onKey` still gets keys. Draw order: shells first, then Library, then floating windows, then pop-ups and help.-**Needs the docking branch (flagged, not planned):** dragging panels out into separate OS windows (multi-viewport); arbitrary tabbed or split docking of palettes; ImGui-native persistence of dock layouts. ZBrush has none of these either: elements "cannot be undocked outside the window" [R1].+**Needs the docking branch (flagged, not planned):** dragging panels out into separate OS windows (multi-viewport); arbitrary tabbed or split docking of palettes; ImGui-native persistence of dock layouts.---@@ -596,20 +567,6 @@ Create these with real declarations and **stub** implementations, so all three s---## References-- [R1] ZBrush User Interface (reference guide): https://help.maxon.net/zbr/en-us/Content/html/reference-guide/interface-overview/interface-overview.html-- [R2] Finding Your Way Around: https://help.maxon.net/zbr/en-us/Content/html/getting-started/finding-your-way-around/finding-your-way-around.html-- [R3] Interface Operation: https://help.maxon.net/zbr/en-us/Content/html/user-guide/customizing-zbrush/interface-operation/interface-operation.html-- [R4] Areas for Customization / Custom Interface: https://help.maxon.net/zbr/en-us/Content/html/user-guide/customizing-zbrush/interface-layout/custom-interface/custom-interface.html-- [R5] ZBrushCentral, brush pop-up letter selection: https://www.zbrushcentral.com/t/does-nobody-use-shortcuts-for-brushes/397885 and https://www.zbrushcentral.com/t/popup-hotkey/320306-- [R6] ZBrush Shortcuts by Palette: https://help.maxon.net/zbr/en-us/Content/html/user-guide/keyboard-shortcuts/shortcuts-by-palette/shortcuts-by-palette.html (PDF: https://help.maxon.net/zbr/en-us/Content/Resources/Uploads/ZBrush-Shortcuts.pdf)-- [R7] Library: https://help.maxon.net/zbr/en-us/Content/html/getting-started/basic-concepts/lightbox/lightbox.html-- [R8] ZBrushCentral, tooltip (Quick Info) opacity: https://www.zbrushcentral.com/t/how-can-i-change-tooltip-transparency-answered/310810-- [R9] Preferences > Quick Info: https://help.maxon.net/zbr/en-us/Content/html/reference-guide/preferences/quick-info/quick-info.html-- [R10] Preferences > Config: https://help.maxon.net/zbr/en-us/Content/html/reference-guide/preferences/config/config.html-- [R11] Blender manual, Brush introduction / asset shelf: https://docs.blender.org/manual/en/dev/sculpt_paint/brush/introduction.html-- [R12] Blender 4.3 sculpting features: https://www.blendernation.com/2024/11/09/blender-4-3-new-sculpting-features/-- [R13] Nomad Sculpt manual, Getting started / Interface: https://nomadsculpt.com/manual/gettingstarted , https://nomadsculpt.com/manual/interface-- [R14] 3DCoat documentation (rooms, panels, activity bar): https://3dcoat.com/documentation/?p=2248- [R15] Lucide licence: https://lucide.dev/license- [R16] IconFontCppHeaders (zlib; IconsLucide.h, ImGui merge example): https://github.com/juliettef/IconFontCppHeaders- [R17] Material Symbols guide (Apache-2.0): https://developers.google.com/fonts/docs/material_symbolsdiff --git a/docs/zbrush-parity.md b/docs/zbrush-parity.mddeleted file mode 100644index 3a0f8402..00000000--- a/docs/zbrush-parity.md+++ /dev/null@@ -1,130 +0,0 @@-# ZBrush parity audit--What a ZBrush sculptor does without thinking in the first hour, what SculptForge does, and how big the gap is.-Written for the v0.7 "ZBrush feel" pass (branch feat/zfeel, 2026-10-24) after a working ZBrush modeler tried-v0.2 and uninstalled it because it "didn't feel like ZBrush".--**Gap**: none / small (works, but differently enough to notice) / big (missing, or the hands do the wrong thing).-**Priority**: P1 trips a ZBrush user in the first hour, P2 noticed within a day, P3 nice to have.-**Status** is what the v0.7 pass did about it (*fixed*, *kept* = deliberately different, *open*).--ZBrush behaviour is checked against Maxon's official shortcut sheet [1] and the ZBrush documentation [2-5];-rows marked † come from ZBrush practice and community references [6] where Maxon's sheet is silent, and should-be confirmed by a ZBrush user.--## Navigation (Edit mode, a 3D mesh)--| ZBrush | SculptForge before v0.7 | Gap | Pri | Status |-|---|---|---|---|---|-| Drag on the background: free rotate [1 §3] | Same (free rotation is the default since v0.3, Turntable is a preference) | none | – | – |-| Alt+drag on the background: move (pan) [1 §3] | Same | none | – | – |-| Alt+click, release Alt, drag: scale (zoom) [1 §3] | Same | none | – | – |-| Shift pressed during a rotation: snap to 90 degree views [1 §3] | Same | none | – | – |-| Shift+click, release Shift, drag: rotate around the view axis (Z) [1 §3] | Shift+drag snapped; releasing Shift before moving just orbited | big | P2 | fixed: roll |-| Right-click navigation (Preferences): rotate, Alt pans, Ctrl scales, also over the model [1 §3.1] | Same, always on | none | – | – |-| F: fit the mesh to the view [1 §6] | Same (frames every visible Part) | none | – | – |-| Shift+Alt+click a SubTool: frame it [1 §6.1] | Missing | small | P3 | fixed |-| P: perspective on / off [1 §6] | P is Paint; Numpad 5 switches perspective / orthographic | small | P3 | partly (orthographic on Numpad 5; P stays Paint) |-| Mouse wheel | ZBrush does not zoom with the wheel by default; SculptForge does | none (extra) | – | kept |--## Sculpting modifiers--| ZBrush | SculptForge before v0.7 | Gap | Pri | Status |-|---|---|---|---|---|-| Alt held: ZAdd / ZSub swap [1 §5] | Same (and the ring turns red) | none | – | – |-| Shift held: Smooth brush [2] | Same | none | – | – |-| Smooth keeps its own Z Intensity: holding Shift, the slider shows and sets Smooth's value [2] | Smooth used the active brush's Strength, so a gentle Standard (0.1) smoothed at 0.1 | big | P1 | fixed: separate Smooth intensity, Shift shows it |-| Shift pressed after a stroke starts: the stroke is constrained to a straight line † [6] | Nothing (Shift mid-stroke ignored) | big | P2 | fixed: straight line, snapping to 45 degrees |-| Ctrl held: paint the mask (MaskPen) [1 §6.6] | Same | none | – | – |-| Ctrl+Alt held: erase the mask [1 §6.6] | Same | none | – | – |-| Ctrl+click on the mesh: blur the mask [1 §6.6] | Painted a dot of mask | big | P1 | fixed |-| Ctrl+Alt+click on the mesh: sharpen the mask [1 §6.6] | Erased a dot of mask | big | P1 | fixed |-| Ctrl+click the background: invert the mask [1 §6.6] | Same | none | – | – |-| Ctrl+click+drag the background: clear the mask [1 §6.6] | Same, but with nothing masked the drag zoomed the view | small | P2 | fixed: ZBrush style does nothing; SculptForge style keeps the zoom |-| MaskLasso / MaskRect (Ctrl+drag) [3] | Same (v0.3) | none | – | – |-| Ctrl+A mask all, Ctrl+Shift+A clear mask, Ctrl+I invert mask, Ctrl+H view mask [1 §6.6] | Buttons only, no keys | big | P1 | fixed |--## Visibility and face groups--| ZBrush | SculptForge before v0.7 | Gap | Pri | Status |-|---|---|---|---|---|-| Ctrl+Shift+drag: show inside (green); press Alt during the drag: hide inside (red) [1 §6.9] | Same; the keys can be let go during the drag, as in ZBrush | none | – | – |-| Ctrl+Shift+click the background: show everything [1 §6.9] | Same | none | – | – |-| Ctrl+Shift+click a polygroup on a fully visible mesh: show only it [1 §6.9] | Same | none | – | – |-| Ctrl+Shift+click a polygroup on a partly hidden mesh: hide that group [1 §6.9] | Isolated the clicked group instead | big | P1 | fixed |-| Ctrl+Shift+click twice: hide the group (the second click inverts the isolation) [1 §6.9] | Same | none | – | – |-| Ctrl+Shift+click+drag on the background: reverse visibility [1 §6.9] | A rectangle around nothing failed with "Nothing visible inside" | small | P2 | fixed: a selection that encloses nothing inverts the visibility |-| Ctrl+Shift+Alt+click a polygroup: hide it | Same (SculptForge extra, harmless) | none | – | kept |-| Ctrl+W: group masked and clear the mask [1 §6.8] | Tool > Face Groups > From mask, no key, mask kept | big | P1 | fixed: Ctrl+W; with nothing masked it groups what is visible † |-| Ctrl+Shift+W | Not a default ZBrush shortcut in Maxon's sheet [1] | – | – | – |-| Shift+F: PolyFrame and polygroups [1 §6] | Same | none | – | – |--## Keys--| ZBrush | SculptForge before v0.7 | Gap | Pri | Status |-|---|---|---|---|---|-| B then two letters: B S T Standard [1 §5.1] | Same pop-up | none | – | – |-| B C B ClayBuildup, B D S DamStandard, B M V Move, B I N Inflate, B P I Pinch, B S M Smooth, B S H SnakeHook † | Letters were "first free letter": B C A, B D A, B M O ... | big | P1 | fixed: ZBrush letters for the brushes both apps have |-| S: Draw Size at the cursor [1 §5] | Same | none | – | – |-| U: Z Intensity at the cursor [1 §5] | Missing (I was Strength) | big | P1 | fixed |-| I: RGB Intensity at the cursor [1 §5] | I opened Strength (= Intensity); paint had no intensity of its own | big | P1 | fixed: RGB Intensity for paint; SculptForge style keeps I = Strength |-| O: Focal Shift at the cursor [1 §5] | No focal shift | big | P2 | fixed: Falloff (falloff), inner ring shows it |-| [ and ]: Draw Size steps [1 §5] | Same (10% steps) | none | – | – |-| Space (or right-click): QuickMenu at the cursor [1 §1] | Missing | big | P1 | fixed: Space Quick Menu (right-click stays navigation, as with ZBrush's RightClick Navigation on) |-| L: Lazy Mouse on / off [1 §5.3] | Missing | small | P2 | fixed |-| C: pick the colour under the cursor [1 §5.2] | Same | none | – | – |-| V: switch main and secondary colour [1 §5.2] | Clicking the swatch only | small | P2 | fixed |-| Q W E R: Draw, Move, Scale, Rotate [1 §5] | Same (Gizmo instead of the Transpose line) | small | – | kept (Gizmo, documented) |-| T: Edit mode on / off [1 §5] | No 2.5D canvas mode: always in Edit | none | – | kept (documented) |-| X: symmetry [1 §6] | Same | none | – | – |-| Ctrl+Z / Ctrl+Shift+Z [1 §1] | Same (Ctrl+Y too) | none | – | – |-| Ctrl+D divide, D / Shift+D higher / lower res [1 §6.2] | Same (subdivision levels since v0.5) | none | – | – |-| , LightBox, Tab hide palettes, Ctrl+Alt+click assign a hotkey, Ctrl+Shift+I Store Config, Ctrl+L load UI [1] | Same | none | – | – |-| Ctrl+Shift+Alt+I: save the UI configuration [1 §12] | Missing | small | P3 | fixed |-| N: list all SubTools [1 §6.1] | Missing | small | P3 | open (the Parts palette is in the right tray) |-| 9: QuickSave [1 §1] | 9 was the Sharp Crease brush (1-0 pick brushes) | small | P2 | fixed: ZBrush style 9 = Save Snapshot, digits free; SculptForge style keeps 1-0 brushes |-| 1, 2, 3, Shift+1: replay / record strokes [1 §5.3] | Missing (1-0 picked brushes) | small | P3 | open (no stroke replay yet) |-| F1-F6 pop-ups (tools, brushes, strokes ...) [1 §1] | F1 Controls, F3 command palette | small | P3 | kept (B, M and the left-shelf tiles pop the same lists) |-| H: ZScript window [1 §13] | ` opens the console | small | P3 | kept |-| Ctrl+E edge loop, Ctrl+U reload ZScript | Ctrl+E export GLB, Ctrl+U Send to Unreal | small | P3 | kept (no edge loop tool) |--## Feel and defaults--| ZBrush | SculptForge | Gap | Pri | Status |-|---|---|---|---|---|-| Draw Size in screen pixels, constant on screen while zooming [4] | Same (radius in pixels, default 60; ZBrush 64) | none | – | – |-| Pen pressure drives Z Intensity, not size, by default [4] | Same (Pressure > Strength on, Size off; global curve in Preferences > Tablet) | none | – | – |-| Dab spacing: even along the stroke, independent of frame rate | Same: every input sample counts, dabs every 15% of the radius | none | – | – |-| LazyMouse with a small radius on by default for most brushes † | Dots stroke, no lazy; L now toggles Lazy Stroke | small | P3 | kept |-| Cursor: outer ring = Draw Size, inner ring = Focal Shift [4] | The inner ring showed Strength | small | P2 | fixed: inner ring shows Falloff |-| Brush falloff: smooth curve, Focal Shift 0 by default [4] | Smoothstep; Falloff added (0 = unchanged maths) | none | – | – |-| Open mesh borders | Smooth treats border vertices like the others, so an open edge pulls in a little with every pass. ZBrush's Smooth holds open borders better † | small | P3 | open (brush maths, out of scope for this pass) |-| Alt+click a SubTool selects it [1 §6.1] | Same | none | – | – |-| Paint without sculpting: Zadd off, Rgb on | P toggles the Paint brush (SculptForge) | none | – | kept |--## The "SculptForge" input style--The few places where SculptForge's own defaults differ and some users like them are kept behind-**Preferences > Input > Style** (ZBrush-style by default at the time of this audit; new installs now start with the SculptForge keys):--| | ZBrush (default) | SculptForge |-|---|---|---|-| 1 ... 0 | free (9 = QuickSave) | pick the ten built-in brushes |-| I | RGB Intensity at the cursor | Strength (Intensity) at the cursor |-| Ctrl+drag on the background with nothing masked | nothing (clears the mask) | zooms |--## Sources--1. Maxon, *ZBrush Shortcuts and Mouse Actions* (PDF):- <https://help.maxon.net/zbr/en-us/Content/Resources/Uploads/ZBrush-Shortcuts.pdf> (section numbers in brackets)-2. Maxon ZBrush documentation, *Brush* and *Smooth brushes*:- <https://help.maxon.net/zbr/en-us/Content/html/reference-guide/brush/brush.html>-3. Maxon ZBrush documentation, *Masking Essentials*:- <https://help.maxon.net/zbp/en-us/Content/html/5_sculpting-and-painting_masking-essentials.html>-4. Maxon ZBrush documentation, *Draw palette* (Draw Size, Falloff, Z / RGB Intensity):- <https://help.maxon.net/zbr/en-us/Content/html/reference-guide/draw/draw.html>-5. Maxon ZBrush documentation, *Masking sub-palette*:- <https://help.maxon.net/zbr/en-us/Content/html/zbrushcore/reference-guide/tool/masking/masking.html>-6. ZBrushCentral and Polycount threads on Shift-constrained strokes (behaviour changed with Lazy Stroke 2.0 in- 4R8): <https://www.zbrushcentral.com/t/4r8-drawing-straight-lines/206837>,- <https://polycount.com/discussion/comment/833245>diff --git a/src/app/App.h b/src/app/App.hindex 80362f9b..9ad9f506 100644--- a/src/app/App.h+++ b/src/app/App.h@@ -1345,7 +1345,7 @@ private:float move[3] = {0, 0, 0}, rotate[3] = {0, 0, 0}, scale = 100.0f;} gizmo_;// ---- end Gizmo 3D ----- // ---- ZBrush feel (Input.cpp, docs/zbrush-parity.md) ----+ // ---- ZBrush feel (Input.cpp, docs/guide/coming-from-zbrush.md) ----// Preferences > Input (the ZBrush or SculptForge key style), the Space QuickMenu, the intensities and Focal// Shift (U / I / O), ZBrush's mask and polygroup keys, Shift-constrained straight strokes and the// Shift+click, release Shift, drag roll.diff --git a/src/app/Input.cpp b/src/app/Input.cppindex ba5e725e..ec816ea9 100644--- a/src/app/Input.cpp+++ b/src/app/Input.cpp@@ -1,7 +1,7 @@// SculptForge - open source digital sculpting// SPDX-License-Identifier: GPL-3.0-or-later//-// The ZBrush feel (docs/zbrush-parity.md): ZBrush's keys that SculptForge lacked (U Z Intensity, I RGB+// The ZBrush feel (docs/guide/coming-from-zbrush.md): ZBrush's keys that SculptForge lacked (U Z Intensity, I RGB// Intensity, O Focal Shift, Space QuickMenu, L LazyMouse, V switch colour, Ctrl+A / Ctrl+Shift+A / Ctrl+I /// Ctrl+H for the mask, Ctrl+W group masked), Preferences > Input with the ZBrush and SculptForge key styles,// the QuickMenu itself and Shift-constrained straight strokes. The mouse gestures live with the rest of thediff --git a/tests/ui/zbrush_feel.sfui b/tests/ui/zbrush_feel.sfuiindex 50783b33..ca6348c8 100644--- a/tests/ui/zbrush_feel.sfui+++ b/tests/ui/zbrush_feel.sfui@@ -1,4 +1,4 @@-# The ZBrush feel (docs/zbrush-parity.md): U / I / O at the cursor, Smooth's own Z Intensity, ZBrush's brush+# The ZBrush-style keys (docs/guide/coming-from-zbrush.md): U / I / O at the cursor, Smooth's own Z Intensity, ZBrush's brush# letters, L, V, Space QuickMenu, the mask keys (Ctrl+A, Ctrl+Shift+A, Ctrl+I, Ctrl+H), Ctrl+click to blur and# Ctrl+Alt+click to sharpen the mask, Ctrl+W, Ctrl+Shift+click on a partly hidden mesh, Shift-constrained# straight strokes, Shift+click / release Shift / drag to roll, and the ZBrush / SculptForge input styles.