@raphlinus Hey! I was inspired by font-rs to take a crack at fonts. I took a different approach to glyph outlines that's roughly 2x faster than font-rs's; take a look:https://github.com/mooman219/fontdue/blob/master/src/raster.rs#L43 …
-
-
Ohhhh I see what you're doing. It's a Bresenham-like DDA where you're getting all the line / pixel square crossings and then doing triangle within that. Clever.
-
Yep, using just the line height coverage in scanline order with accumulation gives you exact horizontal shading. I approximate vertical shading by smearing based on the center of the line subdivision within each pixel.
- 2 more replies
New conversation -
Loading seems to be taking a while.
Twitter may be over capacity or experiencing a momentary hiccup. Try again or visit Twitter Status for more information.