3 ms·
> And at that point, you really can't complain about Cairo being slow, can you? You're not even doing vector graphics at this point, you're back in raster graph
by bjourne 9y ago
> And at that point, you really can't complain about Cairo being slow, can you? You're not even doing vector graphics at this point, you're back in raster graphics territory.
The dichotomy between vector and raster graphics does not exist on screens built using pixels. Eventually whatever you are doing you end up with pixel data. It is incredibly common to require access to this pixel data for some reason. For example, for a long time Cairo used pre-multiplied alpha for alpha compositing which caused all sorts of grief for people who required straight alpha.
You idea of Cairo hiding the image data would have made it impossible for use for rendering transparent PNGs as they have (or had, I don't know how Cairo works these day) a pixel format Cairo doesn't support. Or for using cairo with SDL for that matter.
Your description of how raster APIs works is wrong. What they do is that they write to an image buffer which is then uploaded to the X server. But if the server has the shm extension, they just write the pixels to a shared buffer.
Wayland doesn't impose any rendering API on clients. It gives you a pixel buffer or a GL context and lets you draw whatever you want.
TL;DR pure vector graphics does not work. And the sooner you vector weenies realize that, the better. :p