webgl-operate
webgl-operate copied to clipboard
support msdf fonts for text rendering
https://soimy.github.io/msdf-bmfont-xml/ seems to be an excellent msdf generator (utf-8 support, good parameterization etc.). The glyph fragment shader needs to account for 4 channel distance fields instead of a single one.
- [ ] Implement switch to enable MSDF instead of SDF
- [ ] Implement simple example comparing both techniques side by side
I have generated a file using Roboto. The resolution is rather medium. Could be sufficient for normal text, while large text might come with quality issues (which you already can see at their preview here, the rendered text borders look rather blurry)