Proposal: Mirror basic nodecanvas interface
Mirroring the basic node-canvas interface, has already done with createCanvas function, could be a great boost to adoption, especially for JSDOM.
@asturur hey, storkeText and fillText are ready now, feel free to play with it. Note the ~~maxWidth~~ and measureText is still in developing.
The maxWidth has been implemented.
yes i want to resume this test. I see that skia canvas also has been updated, how this package relate to the other? is skia-canvas a dependency of this one?
I see that skia canvas also has been updated, how this package relate to the other? is skia-canvas a dependency of this one?
No, skia-canvas is depended on rust-skia, another skia library created by me.
This project is depended on skia from scratch, because rust-skia was designed for more general usage, like rendering on OpenGL and Vulkan API, modify the build config on it is very complicated. So I started this project and build skia for only offscreen rendering usage, and also without any system dependencies!
The major differences between this project and skia-canvas is:
- skia canvas support more features now, because rust-skia has done the most of jobs. But skr-canvs (this project) will provide the same extra features in future if needed.
- skr-canvas has 0 system dependencies, so it's out of box solution for docker users. But skia-canvas dependent on
fontconfig. - skr-canvas support more platforms and CPU arch. Like I said below, modify the build config of rust-skia is very hard, so skia-canvas now only support
linux-x64-gnuwindows-x64macOS-x64andmacOS-arm64. But skr-canvas support more wildly used platforms and CPU arch. Likelinux-x64-muslwhich is very import fornode:lts-aplineusers, andlinux-arm64-gnuandlinux-arm64-musl, which is important for users who is using m1 chip macOS with docker.
And this project is dependent on skia directly, so the performance is better than the other implementations: https://github.com/Brooooooklyn/canvas#performance