Skip to content

feat(gui): show post-processing as a chain of effects - #908

Open
Leonhardmaster2 wants to merge 5 commits into
ottolink-dev:devfrom
Leonhardmaster2:feat/post-process-chain-gui
Open

Leonhardmaster2 wants to merge 5 commits into
ottolink-dev:devfrom
Leonhardmaster2:feat/post-process-chain-gui

Conversation

@Leonhardmaster2

@Leonhardmaster2 Leonhardmaster2 commented Nov 18, 2026 •

Copy link
Copy Markdown
Contributor

This replaces the Post-Processing section with a chain of effects, like we discussed on Discord. Right now every node with post-processing gets up to eight rows that mostly sit on values that do nothing, and you can't tell from the collapsed header if any of it is in use. Now the node gets a row of small toggles at the bottom of the properties panel. Switching an effect on adds its controls above the row, switching it off takes them away.

This builds on #907. The first two commits here are that PR, the last three are the GUI.

What changes for users

  • Only the effects a node actually uses take up space. A node that uses none just shows the row of toggles.
  • Effects are listed in the order the pass applies them. That order is fixed by the engine, the chain only shows it.
  • Each effect has a small icon of what it does. For gamma, gain, smoothing and the two ranges it follows the value.
  • Removing gamma, gain, smoothing or mix puts the value back to neutral. Undo brings it back. Remap and saturate remember their last range.
  • Switching on a Remap or Saturate that was off starts at 0 to 1. Before it started at -1 to 2.
  • With one node in the panel the chain sits at the bottom edge and stays there while the list scrolls. With several nodes (pinned or selected together) each node keeps its own chain at the end of its block.

Saved projects

Saves get the state.active flag from the model PR, one boolean on mix, gamma, gain and smoothing. Old projects open the same. Anything set away from neutral shows up as a switched-on effect. For example GradientNorm in CoastalErosionDiffusion.hsd opens with its gain of 2.14 as a stage.

Code

The widget is post_process_dock.cpp. It reuses Meta's slider rows, the RangeBar and the section reveal from the industrial design, and doesn't change Meta. NodeAttributesWidget keeps the post-process attributes out of its sections and builds the chain after them. NodeSettingsWidget moves it to the bottom edge when only one node is shown.

Tested

All on Windows 11 with MSVC 2022 and Qt 6.10.3, one monitor, the default panel design.

  • Full Release build on current dev with its submodules. Each commit builds on its own. No new warnings from these files.
  • CoastalErosionDiffusion.hsd, GammaCorrection.hsd and CellularNoise.hsd load and compute without errors in batch mode.
  • In the app on this branch:
    • adding, editing and removing stages, from the toggles and from the stage's own icon
    • undo, redo (from the Edit menu) and Reset Settings
    • the three range presets in a stage's right-click menu
    • the settings popup on the graph canvas has the chain too, and stays in sync with the panel
    • a short window: the chain stops at its height limit (60% of the panel) and scrolls, the list above scrolls on its own
    • the saved gain in CoastalErosionDiffusion.hsd shows as a stage
    • the stock panel design with the chain at the bottom
    • a stage opening animates. I recorded it frame by frame, the card grows over about 200 ms
  • In the app on the same code before the rebase: dragging a value back to neutral keeps its stage, switching containers (CellularNoise Grid and Lines), a narrow panel, and two nodes in the panel.

Not tested

  • Linux and Mac. Fonts, HiDPI scaling and animation timing could look different there.
  • How the animations feel. I only checked that they run.
  • Node presets from the preset box.

Leonhardmaster2 and others added 5 commits November 18, 2026 21:29
…perties panel

Name the undo and recompute handlers in NodeAttributesWidget so another editor
in the widget can use them too, and move the reserved scrollbar setup in
NodeSettingsWidget into a helper. No behaviour change.
…perties

Nodes with the shared post-processing no longer get a Post-Processing section.
A row of toggles, one per effect, sits after the node's sections instead.
Switching an effect on adds its controls above the row. Switching it off takes
them away and puts the value back to neutral. Effects are listed in the order
the pass applies them, each with a small icon of what it does.

The attributes, their keys and the processing are unchanged, and a project that
uses an effect shows it switched on.
…ies panel

When the panel shows a single node, its chain moves out of the list and sits at
the bottom edge, where it stays while the attributes scroll. With several nodes
in the panel each chain stays with its own node.
@otto-link

Copy link
Copy Markdown
Member

Thanks for the PR! The post-process chain UI is clearly a nice improvement.

There are a few structural and UI polish items to address before merging:

  • Split post_process_dock.cpp: It currently bundles a bunch of widgets/helper classes (EffectChip, StageScope, StageLabel, RangeEditor, StageRow, Tray, PostProcessDock::Impl) plus paint_glyph() into a single file. Please extract the sub-widgets into dedicated files so the dock is easier to maintain and put them in one the gui/widgets/... folders.

  • Reuse meta_qt instead of custom RangeEditor: RangeEditor reimplements a dual-thumb range slider. Can we reuse meta_qt's existing range control here? with a tag to remove the toggle buttons if needed.

  • Deduplicate color/menu helpers: with_alpha, mix_colors, readable_on, and style_menu look like duplicates of existing theme/UI helpers: reuse the existing ones where available.

  • Lighten active effect icon color: Switch the active effect icon color to gray to keep the UI visually lighter.

This branch has not been deployed

No deployments
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.

2 participants