Only tangentially related but I've recently looked into how fonts usually work (OpenType, TrueType and the like) and it's astonishing to me how complicated this all is.
For example: TrueType includes the ability to embed small executable programs in your font to adjust little details in the rasterization process (I believe it's called "hinting"). It has its own VM and bytecode for that!
If you really break it down, a font is just a pixel shader that happens to embed its own texture atlas.
(I wonder if we could achieve a win by actually having a font-format that is just an abstract pixel shader that could be handed off to the GPU driver for compilation? Either way, we'd probably just pre-render glyph tiles to a texture, so I'm not sure it'd make much of a difference.)
Thanks for the mention - I should note that there's a rather large update coming soon, with even more of them. :)
There's also a bigger pile of system/bitmap fonts in raw binary format, included with my DOS-based font editor (https://int10h.org/blog/2019/05/fontraption-vga-text-mode-fo...). Perhaps more pertinent to this thread, since the format is natural for embedded systems/direct video chip usage.
When I was learning to program games in my teens on the Atari 8-bit, one of my favorite passtimes was making fonts and sprites. This takes me right back in time. And I can use it for mini game assets, maybe tiny raster fonts for code (like log windows). Thanks for making it and sharing.
Thanks! That's right, and I haven't even thought about it at all. So cool :)
It's a hobby/educational project, but I'm happy to see it solving some people's problems. I once wanted to add a good-looking font to my e-paper display for the air quality monitor project and I stumbled upon a simple MacOS app that converted images with text to byte arrays (https://luckyresistor.me/font-to-byte/). I picked it up, updated to Swift 3 and adjusted to my needs. When I blogged about it, somebody complained that it's MacOS only, so I decided to rewrite it in C++ with Qt (learning some modern C++ on that occasion).
The app was still quite cumbersome as it required you to prepare input images in external software like GIMP or Ps, and people had a hard time understanding the process. I was being asked repeatedly to help generate an image for a given font, so I figured out that the app could (should) be generating those input images programmatically. From there I added a minimal graphical editor to allow making corrections to auto-generated bitmaps (or drawing ones from scratch) and here we are.
Last but not least, I had a great fun learning C++17 and writing a template-based source code generator.
While this is cool, I think it would be better to write a set of convertors to and from well-recognised formats like BDF. There are far more professional tools that work with those, e.g. gbdfed, FontForge and Bits'N'Picas:
Thanks for sharing that, I'll have a read. Knowing very little on the subject, I was missing the keywords to duck-duck-go for to find any info on the topic of generating font sprites for embedded systems.
Thanks, this looks very nice! A similar tool I've used before is LCD Assistant, but there are several limitations (and I had to use MS Paint to create and edit the bitmaps). http://en.radzio.dxp.pl/bitmap_converter/
This kind of reminds me of IcoFX (https://icofx.ro/), which I recommend for pixel-by-pixel editing of small graphics. I'm wondering if this project could turn into a FOSS implementation of the same concept.
Well timed! I'm working on an LED matrix project and wanted my own font that would fit my specifics. Started writing something like this using the canvas element and JavaScript, but this should save me.
[+] [-] t0astbread|5 years ago|reply
For example: TrueType includes the ability to embed small executable programs in your font to adjust little details in the rasterization process (I believe it's called "hinting"). It has its own VM and bytecode for that!
[+] [-] derefr|5 years ago|reply
(I wonder if we could achieve a win by actually having a font-format that is just an abstract pixel shader that could be handed off to the GPU driver for compilation? Either way, we'd probably just pre-render glyph tiles to a texture, so I'm not sure it'd make much of a difference.)
[+] [-] pan69|5 years ago|reply
For anyone interested, there is a nice collection of system fonts available on int10h.org:
https://int10h.org/oldschool-pc-fonts/fontlist/
[+] [-] lioeters|5 years ago|reply
http://robhagemans.github.io/monobit/
They're in some kind of human-readable text format:
https://github.com/robhagemans/hoard-of-bitfonts
[+] [-] viler|5 years ago|reply
There's also a bigger pile of system/bitmap fonts in raw binary format, included with my DOS-based font editor (https://int10h.org/blog/2019/05/fontraption-vga-text-mode-fo...). Perhaps more pertinent to this thread, since the format is natural for embedded systems/direct video chip usage.
[+] [-] karmakaze|5 years ago|reply
When I was learning to program games in my teens on the Atari 8-bit, one of my favorite passtimes was making fonts and sprites. This takes me right back in time. And I can use it for mini game assets, maybe tiny raster fonts for code (like log windows). Thanks for making it and sharing.
[+] [-] ayoy|5 years ago|reply
It's a hobby/educational project, but I'm happy to see it solving some people's problems. I once wanted to add a good-looking font to my e-paper display for the air quality monitor project and I stumbled upon a simple MacOS app that converted images with text to byte arrays (https://luckyresistor.me/font-to-byte/). I picked it up, updated to Swift 3 and adjusted to my needs. When I blogged about it, somebody complained that it's MacOS only, so I decided to rewrite it in C++ with Qt (learning some modern C++ on that occasion).
The app was still quite cumbersome as it required you to prepare input images in external software like GIMP or Ps, and people had a hard time understanding the process. I was being asked repeatedly to help generate an image for a given font, so I figured out that the app could (should) be generating those input images programmatically. From there I added a minimal graphical editor to allow making corrections to auto-generated bitmaps (or drawing ones from scratch) and here we are.
Last but not least, I had a great fun learning C++17 and writing a template-based source code generator.
[+] [-] andrewshadura|5 years ago|reply
https://github.com/kreativekorp/bitsnpicas
[+] [-] ayoy|5 years ago|reply
[+] [-] roland35|5 years ago|reply
[+] [-] maxbaines|5 years ago|reply
[+] [-] jasonhansel|5 years ago|reply
[+] [-] spongeb00b|5 years ago|reply
[+] [-] xgenecloud|5 years ago|reply
[+] [-] masnao|5 years ago|reply
[+] [-] ayoy|5 years ago|reply
[+] [-] RL_Quine|5 years ago|reply
[+] [-] skrebbel|5 years ago|reply