Brooooooklyn / canvas

High performance skia binding to Node.js. Zero system dependencies and pure npm packages without any postinstall scripts nor node-gyp.
https://vercel.skia.rs
MIT License
1.66k stars 71 forks source link

Disabling anti-aliasing with SVG rendering? #805

Open thonkinator opened 3 months ago

thonkinator commented 3 months ago

I'm trying to disable anti-aliasing when rendering SVGs to canvas, but ctx.imageSmoothingEnabled and ctx.imageSmoothingQuality seem to have no effect. I also tried setting shape-rendering="crispEdges" on the SVG itself, but that doesn't seem to change anything either. Is there a way to achieve this?