Important: This documentation covers Yarn 1 (Classic).
For Yarn 2+ docs and migration guide, see yarnpkg.com.

Package detail

fontpath-renderer

mattdesl126MIT4.0.0

a generic text renderer for canvas/webgl/etc

fontpath, font, ttf, otf, glyph, render, fillText, canvas, webgl, gl, freetype

readme

fontpath-renderer

experimental

A generic renderer for fontpath glyphs.

This is a low-level module and is mostly used internally.

Instead, you are encouraged to use fontpath-canvas for 2D canvas, fontpath-gl for WebGL, or fontpath-simple-renderer for basic render-agnostic custom solutions.

However, this produces the least amount of GC thrashing, and is best suited for highly optimized font rendering.

NPM

demo

In the demo folder is a simple implementation rendering triangles with some mouse interaction.

Result

You can run the demo here.

License

MIT.