Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

Yeah, Skia itself has multiple backends, including CPU and GPU implementations. The wasm one must use the CPU path, where Skia in your browser can use a CPU or GPU path based on whatever is fastest. So already wasm is necessarily equal-or-slower.

Wasm also does have some overhead too; some of that will get better with upcoming changes; at least wasm-SIMD support and threads are both only available in some environments.

But don't get me wrong, I'm certainly not suggesting the skia-wasm project is pointless, there's just trade-offs here.



What are the uses of skia wasm then?

So far I’ve mostly heard about porting apps that require native skia to the web. But that wouldn’t explain why google spent all that effort building a canvas compatible api and didn’t just stick to the skia api

I was hoping that skia would be more efficient in this tiling context where rendering tile images and putting them together in the final view isn’t that great with browser canvas. But I realize now that lack of multithreaded tile rendering means it doesn’t matter much anyways whether image tiles can be copied to another image quickly or not

Now I have a feeling that webgl might be a necessary step for me to look at.

This project has been dormant for a year now and I have to start again. Not an easy area to navigate with all those different and not necessarily comparable solutions

Last I played around with canvaskit I found the performance in the browser to be better than native canvas for certain things but worse for most. Why that is or if this follows any rules I don’t know. Perhaps I’m also mistaken




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: