wlrfx/scenefx GitHub Issues Discord

wlrfx project · MIT licensed

scenefx

The wlroots scene API, with the eye candy left in.

scenefx is a drop-in replacement for the wlroots scene API. It swaps the plain wlr renderer for an fx renderer that draws blur, drop shadows, and rounded corners as part of the normal scene commit — so a compositor keeps the scene graph's simplicity without giving up those effects.

How it works

wlroots' scene API already solves the hard part of compositing: it manages a tree of nodes, tracks damage, and hands you a finished frame. The catch is that it renders through wlr_renderer, which is intentionally minimal — no blur, no shadows, no rounded corners. Getting those meant abandoning the scene API and writing a renderer from scratch.

scenefx removes that trade-off. It keeps the same scene-node types and function names as wlroots' own scene API — wlr_scene_create, wlr_scene_tree_create, wlr_scene_buffer_create, and so on — but backs them with its own fx renderer, so effects are drawn as part of the normal scene commit, with damage tracking and culling still handled for you.

Without scenefxWith scenefx
1. wlr_scene node tree1. wlr_scene node tree
2. wlr_renderer2. fx renderer
3. flat, undecorated output3. blur, shadow, rounded corners

Full walkthrough, including a build snippet and a basic usage example: Using scenefx in your project →

Effects

Background blur
Translucent surfaces sample and blur what's behind them, per-node, so panels and floating windows can read as glass instead of a flat overlay.
Drop shadows
Soft shadows give floating and stacked windows real depth, rendered alongside the surface instead of faked with a compositor-side hack.
Rounded corners
Corners are clipped in the renderer itself, so they stay correct under resize, damage tracking, and direct scanout.

Compositors using scenefx

scenefx already renders the eye candy in a handful of wlroots-based compositors, from full window managers to minimal ones running a patch.

CompositorNotes
SwayFXsway, with eye candy
Mangowlroots compositor
Umbrielwlroots compositor
naukawlroots compositor
mwcwlroots compositor
dwlvia patch
Note on stability: scenefx is used in production by SwayFX (currently on version 0.5), but the project isn't yet at a 1.0 release and isn't considered ready for other compositors to depend on. Track remaining work on the 1.0 milestone.

More on this wiki