truce-gui
Built-in GPU-free GUI runtime for truce plugins.
Overview
Provides a complete widget toolkit that renders entirely on the CPU using
tiny-skia for software rasterization. This gives plugins a zero-dependency GUI
that works on every platform without requiring a GPU. The BuiltinEditor
can auto-generate a full UI from your parameter layout, or you can compose
widgets manually for a custom look.
Windowing is handled through baseview; the tiny-skia pixmap is uploaded to a wgpu surface each frame for compositing. All supported formats (CLAP, VST3, VST2, AU, LV2, AAX, standalone) use the same path.
truce-gui is the heavy half of the GUI split - the
BuiltinEditor and its runtime dependencies (tiny-skia,
baseview, fontdue, truce-font) live here. The lightweight
trait + data surface (GridLayout, RenderBackend,
WidgetType, Theme, …) lives in
truce-gui-types so alt-GUI backends
(truce-egui / truce-iced / truce-slint) and plugin authors
using a custom editor don't transitively pull in the
rasterisation + windowing stack.
Key types
BuiltinEditor-- the mainEditorimplementation; auto-generates UI from paramsCpuBackend-- default tiny-skia software rasterizer (theRenderBackendtrait it implements lives intruce-gui-types)BaseviewTranslator-- mapsbaseview::Events into theInputEventstream consumed bytruce_gui_types::interaction::dispatchColorExt-- extension trait that addsto_skia()/to_premultiplied()to the lighttruce_gui_types::theme::Colortype (the rasterizer-specific conversions live here so the light crate stays tiny-skia-free)- Re-exports of every
truce-gui-typesandtruce-pluginpublic symbol so existingtruce_gui::layout::*/truce_gui::PluginLogicpaths keep resolving
Widgets
Knobs, sliders, toggles, dropdowns, XY pads, level meters, labels, and
parameter groups. All widgets bind directly to truce parameters. The
widget data types + draw helpers live in truce-gui-types::widgets;
this crate provides the CPU rasterizer that the draw helpers paint
into.
Usage