slint-ui / slint

Slint is a declarative GUI toolkit to build native user interfaces for Rust, C++, or JavaScript apps.
https://slint.dev
Other
17.64k stars 607 forks source link

Initial support for partial rendering with Skia's software renderer #6833

Closed tronical closed 2 days ago

tronical commented 2 days ago

This shares some code between the software renderer and Skia, and also reports damages to soft buffer (no drm support yet).

This functionality is hidden behind SLINT_SKIA_PARTIAL_RENDERING. A value set means it's enabled, a value of debug also shows reddish rectangles around the changed regions.

tronical commented 2 days ago

Nice!

What's the status of things that draw out of their bounds? (Text, Shadow, Rotated Image)

Not covered yet :). For Text we can probably clip if we're partially rendering, but for the others I think we should introduce a bounding rect in the vtable or let the render functions return the bounding rect.