ZenitUI
Retained-mode C++20 UI framework
Loading...
Searching...
No Matches
Canvas.hpp File Reference

An off-screen rendering surface with optional post-effect. More...

#include "Common.hpp"
#include "Layout.hpp"

Go to the source code of this file.

Classes

class  ZenitUI::UI::CanvasLayout
 A subtree rendered into an off-screen target. More...

Detailed Description

An off-screen rendering surface with optional post-effect.

CanvasLayout renders its entire subtree into an off-screen target, then blits the target into its own rect with an optional shader effect applied. The target is created lazily on first draw, re-created when the canvas size changes, and released on detach or destruction.