Hacker News new | ask | show | jobs
by viler 2239 days ago
Impressive research work (and results)!

I actually went through the same experimentation when I worked on the fonts and the website at https://int10h.org/oldschool-pc-fonts/. I ended up with a slightly different solution - the Bits'N'Picas converter, which works very much like potrace-pixelperfect, and takes either .png or actual bitmap fonts as input: https://github.com/kreativekorp/bitsnpicas.

What would be ideal is if the bitmap strikes themselves could be rendered in the browser - not really a tall order since they're part of the TrueType specs, and a rasterizer is supposed to use them when they exist. Unfortunately, it turned out that most browsers run the OpenType Sanitizer on the webfonts they parse, and it removes certain tables including the ones that specify the bitmaps. :(

1 comments

Oh wow, i've stumbled on your site before. It's a masterpiece, and was definitely an inspiration for the work we talk about in this blog post.

Super interesting, what you're saying about the OpenType Sanitizer – i'd wondered why it appears you can't use bitmapped fonts in browsers (although another commenter claims you can – i don't know either way).

I'll have a look at Bits'N'Picas, thanks for the heads up!

Thanks, appreciated! I'm planning an update soon - speaking of which, I might take a page from your own site with the custom scrollbars. :)

AFAIK bitmapped fonts can be rendered in-browser, but only if they're installed on the host (aka the 'old' way), not as css webfonts. Embedding bitmap strikes in a TrueType font is a neat trick used by e.g. Terminus, and by many CJK fonts shipped with Windows, etc., but the browser sanitizer thing just strips them - more info here: https://stackoverflow.com/a/57930594

(Unfortunately this type of font has its pitfalls even outside of the browser. E.g. Windows makes you jump through a completely unreasonable series of hoops to make them work: https://int10h.org/blog/2016/01/windows-cleartype-truetype-f...)