Re:AvaloniaUI: Create Multi-Platform Apps with .NET
by esprehn on Sunday February 04, 2024 @06:57AM
(#39249552)
Chromium (and Firefox) do GPU accelerated raster as well as composition. That page you linked is about a very specific case of wanting to get the pixels back to reuse in a different context. In that situation doing the work on the GPU and then copying back to the CPU may be slower than keeping it on the CPU the whole time.
[ Parent
| on HN ]
Re:AvaloniaUI: Create Multi-Platform Apps with .NET
by fxtentacle on Sunday February 04, 2024 @11:33AM
(#39251649)
This source code:
https://github.com/servo/webrender/blob/master/wr_glyph_rast...
suggests to me that the glyph rasterization (which is the CPU-limiting factor for text rendering) in WebRender (which is the new FF 93+ GPU-accelerated rendering engine) is implemented in Rust and to be run on CPU. On Linux it appears to use FreeType (which is CPU-only):
https://github.com/servo/webrender/blob/master/wr_glyph_rast...
Also, that approach of pre-rendering text into textures is, sadly, very common. For example, see:
https://stackoverflow.com/questions/44062566/how-do-hardware...