I think the biggest takeaway from WebRender is that a vector rendering API is generally overkill for UI. You mostly just need a fast blitter, plus some specialized code to prerender assets (fonts, border pieces, etc.) and a handful of shaders for special effects.
-
Show this thread
-
Replying to @pcwalton
this feels like something we could have learned from Qt 2
1 reply 0 retweets 5 likes -
Replying to @whitequark
Yeah, it’s kind of obvious in retrospect. As is often the case, game developers figured it out early on.
2 replies 1 retweet 13 likes -
Replying to @pcwalton @whitequark
It feels like you basically need Blit Draw shape Draw shape with linear gradient Everything else is kinda superfluous
1 reply 0 retweets 7 likes -
wr is basically: fill-rect, clear-rect, text, line, border, shadow, box-shadow, linear-gradient, radial-gradient, image, repeated-image, clip/mask, create-sub-layer (w/transforms + filters), create-hit-testable-region
1 reply 0 retweets 6 likes -
And most of it goes through the “brush shader” which follows the pattern “render something with specialized shader to a cache if necessary, then blit it”. The cache has a high hit rate so it mostly just ends up being blitting.
1 reply 0 retweets 3 likes -
yeah the shaders are fine but the nasty stuff is the glue between the two ends: caching/interning, snapping, clipping, batching, tiling, auto-layerization, async compositor updates/queries, animated svg perf hacks, ...
1 reply 0 retweets 3 likes
I’ll forever be grateful that we managed to avoid a dynamic runtime shader generator like Skia/Ganesh.
Loading seems to be taking a while.
Twitter may be over capacity or experiencing a momentary hiccup. Try again or visit Twitter Status for more information.