Chlumsky/msdfgen
View on GitHub ↗ ★ 4,964 C++
Multi-channel signed distance field generator
17 mentions on Hacker News by 15 people: 1 story, 16 comments · first 2019-05-27 · latest 2026-06-12
20082026
-
…feeling lucky and lazy". After 10 minutes it had: - Installed msdf_gen library (great library btw https://github.com/chlumsky/msdfgen ) - Created a CLI tool to convert TTF to SDF JSON/XML - Ran the tool, did smoke tests on the resulting…
comment by bel8 · 2026-06-12 · in Claude Fable is relentlessly proactive -
MSDF is worth looking at: https://github.com/Chlumsky/msdfgen and https://steamcdn-a.akamaihd.net/apps/valve/2007/SIGGRAPH2007... The context is GPU's, things like three.js But yes, drawing text is hard.
comment by talkingtab · 2025-11-11 · in Drawing Text Isn't Simple: Benchmarking Console vs. Graphical Rendering -
…and SDF are new to me and very interesting. Another example of what is being done is MSDF here: https://github.com/Chlumsky/msdfgen .
comment by talkingtab · 2025-08-04 · in Perfecting anti-aliasing on signed distance functions -
…it a bit by having multiple distance fields and rendering the intersection of them. See e.g. https://github.com/Chlumsky/msdfgen
comment by account42 · 2025-06-13 · in Rendering Crispy Text on the GPU -
This very well explained here https://github.com/Chlumsky/msdfgen and with more details in linked pdfs. Basically, signed distance fields allow high resolution renders from low resolution rasters which represent character shape. It's used…
comment by febusravenga · 2023-12-11 · in Shader Park Is Kinda Neat -
…separate parts, albeit the colors losing their sharpness above the texture's 1:1 resolution. [1] https://github.com/Chlumsky/msdfgen
comment by FrostKiwi · 2023-07-21 · in Sub-pixel distance transform -
…rounding sharp corners. This is known as a “multi-channel signed distance field”, or “msdf”. https://github.com/Chlumsky/msdfgen
comment by dorkwood · 2023-03-09 · in Leveraging Rust and the GPU to render user interfaces at 120 FPS -
Look into msdf rendering for text in WebGL. https://github.com/Chlumsky/msdfgen
comment by dorkwood · 2022-12-21 · in MelonJS – a fresh and lightweight JavaScript game engine -
…scaling up before looking bad That problem has been solved by multi-channel signed distance fields https://github.com/Chlumsky/msdfgen
comment by johndough · 2022-08-10 · in Vector graphics on GPU -
What I was referring is SDFs/MSDFs as in https://github.com/Chlumsky/msdfgen . Of course you can implement smooth circles directly in a shader the way you describe, but note that there are Vector outline shapes that are not circles...…
comment by jstimpfle · 2022-08-10 · in Vector graphics on GPU -
…in practice. Seems like it would fix, or at least minimize the scaling/offset issues quite nicely. https://github.com/Chlumsky/msdfgen
comment by dubiousconst281 · 2022-07-28 · in Adventures in Text Rendering: Kerning and Glyph Atlases -
…consideration but this project uses real time Multi-channel signed distance field generation : [1] https://github.com/Chlumsky/msdfgen
comment by jimmySixDOF · 2022-02-14 · in Text Rendering Hates You (2019) -
….com/drawing-text-with-signed-distance-fi... MIT-licensed open-source multi-channel glyph generation: https://github.com/Chlumsky/msdfgen The only remaining issue would be the kerning/layout, which is admittedly far from simple.
comment by pvidler · 2021-03-15 · in 2D Graphics on Modern GPU (2019) -
msdfgen : https://github.com/Chlumsky/msdfgen
comment by srgpqt · 2020-03-16 · in Getting started with shaders: signed distance functions -
…somewhat recently a great improvement was made to SDF using multiple channels of information: https://github.com/Chlumsky/msdfgen I wonder how they both compare. I am guessing Slug is more accurate but certainly also much more intensive,…
comment by jchw · 2019-07-19 · in Slug: Dynamic GPU Font Rendering and Advanced Text Layout -
…as you tend to get sharp edges and artefacts [1]. [0] https://github.com/VALIS-software/GPUText [1] https://github.com/Chlumsky/msdfgen/issues/67
comment by haxiomic · 2019-05-27 · in Text rendering using multi channel signed distance fields