linux bitmap font generator.

General discussion about LÖVE, Lua, game development, puns, and unicorns.
Post Reply
User avatar
Pangit
Party member
Posts: 148
Joined: Thu Jun 16, 2016 9:20 am

linux bitmap font generator.

Post by Pangit »

Hi,

What I would like to do is make a number of different sized pixel fonts for use in love, but I am running into a problem finding a tool to create the pngs.

I know there are a few windows programs to do this, but I can't seem to find any to generate bitmap fonts for use in love for linux.

http://www.angelcode.com/products/bmfont/

So I was trying to find a program like this for linux. But it seems not to exist.

Will I need to do this in gimp? If so are there any pointers how best to create the file for use with love?
User avatar
zorg
Party member
Posts: 3436
Joined: Thu Dec 13, 2012 2:55 pm
Location: Absurdistan, Hungary
Contact:

Re: linux bitmap font generator.

Post by zorg »

BMFont files would be a bit difficult to create with hand, but Löve supported and still supports a simpler imagefont type that's easier to create.

The [wiki]ImageFontFormat[/wiki] page on the wiki explains it well, though i'd add to it that you can create both mono or not monospaced fonts with that as well.

Also, i might be wrong on this one, but i think that having multiple rows is also allowed now... but i'd test that out first at the beginning, just to make sure, and to not have to reorder everything afterwards if i turn out to be wrong. :3
Me and my stuff :3True Neutral Aspirant. Why, yes, i do indeed enjoy sarcastically correcting others when they make the most blatant of spelling mistakes. No bullying or trolling the innocent tho.
User avatar
Pangit
Party member
Posts: 148
Joined: Thu Jun 16, 2016 9:20 am

Re: linux bitmap font generator.

Post by Pangit »

Thanks will look into this. Its to try and get the Navi library working with different font sizes. the 8 pixel one is a bit small to see on the screen.
User avatar
Pangit
Party member
Posts: 148
Joined: Thu Jun 16, 2016 9:20 am

Re: linux bitmap font generator.

Post by Pangit »

So the way I got round this was using inkscape then gimp to trim the final png.

But what's weird is I get this strange error with one of the pixel fonts. It's like there are still parts of the yellow bars that get rendered. I don't know why.
pixelfont3.png
pixelfont3.png (36.07 KiB) Viewed 8254 times
See it worked with one pixel font where all the characters were pretty much the same size, but when I extended it to include uppercase and lowercase, and numerals ect it seems to have caused a problem.
ImageFont4.png
ImageFont4.png (15.17 KiB) Viewed 8251 times
See this one works,
ImageFont5.png
ImageFont5.png (63.89 KiB) Viewed 8251 times
Where as this one does not...
User avatar
substitute541
Party member
Posts: 484
Joined: Fri Aug 24, 2012 9:04 am
Location: Southern Leyte, Visayas, Philippines
Contact:

Re: linux bitmap font generator.

Post by substitute541 »

Your yellows are bleeding all over the place. Make sure your image fonts are pixel perfect.
Attachments
ss (2016-08-02 at 07.10.50).png
ss (2016-08-02 at 07.10.50).png (9.31 KiB) Viewed 8242 times
Currently designing themes for WordPress.

Sometimes lurks around the forum.
User avatar
zorg
Party member
Posts: 3436
Joined: Thu Dec 13, 2012 2:55 pm
Location: Absurdistan, Hungary
Contact:

Re: linux bitmap font generator.

Post by zorg »

Another image:
bleed.png
bleed.png (32.86 KiB) Viewed 8238 times
You can see the artefacts for both the glyphs and the boxes as well.
Me and my stuff :3True Neutral Aspirant. Why, yes, i do indeed enjoy sarcastically correcting others when they make the most blatant of spelling mistakes. No bullying or trolling the innocent tho.
User avatar
Pangit
Party member
Posts: 148
Joined: Thu Jun 16, 2016 9:20 am

Re: linux bitmap font generator.

Post by Pangit »

Cheers, will hit the zoom and fix it.

Lol - well that's significantly more tedious than I thought. Such a pity there are no linux tools to do this property. saving to png from inkscape is such a roll of the dice with pixel accurate stuff.
User avatar
ivcore
Prole
Posts: 2
Joined: Sat Jul 02, 2016 6:35 am
Location: Caracas.

Re: linux bitmap font generator.

Post by ivcore »

Can't you use Gimp? I haven't worked much with Linux, but, as far as I know, Inkscape is a vector graphics editor, like Illustrator. It isn't as good as Photoshop (or Gimp, I think) to make/work with the pixel-accuracy of the pngs/bitmaps.
:monocle:
Post Reply

Who is online

Users browsing this forum: No registered users and 2 guests