My Mono version is 2.10.8, as listed here. It could be that my version is too old or that I do not have a Mono package installed that manages these fonts. I’m not sure which one it could be though. I have a lot of available mono packages. They are here. I’d rather not install them all if I don’t need them, so are there any you want me to try to install and see if they make it work?
Probably mono cannot create messagebox from background worker. Moved the messagebox outside the background thread in the new beta 3. The link is FontPackerBeta3.zip
If you get that error again, reopen the application and test the generated font file.
Thanks for testing. I’ll change the main post tomorrow morning.
The error is now gone and it works completely fine.
It’s because mono can only create controls or dialogs only on the starting thread. Glad it’s working fine. Thanks for testing.
Could anybody recommend me of an opensource licence for this?
I’d like this tool to be used even in commercial apps for free.
I’ve licenced it with LGPL v3. Also written a Readme for GitHub. See the changes.
Use the GNU General Public License v3.
Could anyone point me on a tutorial on how to pack bitmaps into texture atlases? I don’t want to load another library (like apache commons codec) to decode the images.
So, can I use this with LibGDX, or not? An XML file oO?
You can for sure use this with libGDX. Download the source from GitHub and compile the [icode]JFontPack[/icode] library. It requires [icode]Apache Commons Codec[/icode] in your classpath to compile and run. Then you can use it like
// Construct a PackedFont
PackedFont font = new PackedFont("MyPackedFont.fntpack");
// Get the glyph for a character i.e., the character to render on screen.
java.awt.Image glyph = font.getGlyph('A');
// After rendering, move the x-coordinate by the advance width of that char.
xpos += font.getAdvanceWidth('A');
The only requirements are that you need to convert the [icode]java.awt.Image[/icode] to an OpenGL 2D texture and include Apache Commons Codec.
You can use these fonts without any other dependancies. See the article Using FontPacker with libGdx
Now also exports in BMFont text format. Here’s the new screenshot.
I’ll update the source and binaries shortly.
I’m currently testing it on Mac OSX. Here are the screenshots.
In MONO 3.2.3
In WINE with Microsoft’s .NET 4.5
I don’t know why the preview pane is not working in WINE version (But FontTester is working).
What about adding the ability to add your own .ttf files?