Emake Fonts

Reporter: fundies  |  Status: open  |  Last Modified: August 05, 2019, 11:15:25 AM
This PR adds support for emake fonts.


  • emake can now load fonts
  • All fonts now go through the same code path regardless of if they're from the gmx, or added later using font_add / font_add_sprite
  • LGM also now uses the same path as emake in-order to keep consistent rendering between builds
  • I've fixed a regression where enigma was no longer compressing the font data
  • All font data (excluding image data) is now written to source instead of tacked on the exe


  • I've added font finding functions but they depend on c++17 and could use more rigorous testing
  • I've put a framework in place to load gmx fonts with pre-rendered texture atlases but I have no idea how the gmx attributes translate to our GlyphMetrics struct
  • font_add() and font_add_sprite() are completely untested and likely broken
  • I've added a generic interface to the rect_packer that should be applied in texture_atlas.cpp
  • We should be able to use one generic function for loading all compressed data on exe. I started one in fontinit.cpp but perhaps that can be continued in another PR
  • We probably want to include some font to use as a default as only windows users are likely to have arial. We can grab it via install.sh or whatever.
  • It seems my lastest changes to AssetArray have broken the default font
  • I'm not sure how the line height / yoffset are calculated in GM so that bits wrong


  • The compiler is now dependent on freetype and c++17 in-order to load fonts properly
  • <
Please sign in to post comments, or you can view this issue on GitHub.