Java-Gaming.org Hi !
Featured games (83)
games approved by the League of Dukes
Games in Showcase (527)
Games in Android Showcase (127)
games submitted by our members
Games in WIP (594)
games currently in development
News: Read the Java Gaming Resources, or peek at the official Java tutorials
 
    Home     Help   Search   Login   Register   
Pages: [1]
  ignore  |  Print  
  Hiero - Bitmap Font Tool  (Read 9804 times)
0 Members and 1 Guest are viewing this topic.
Online kevglass

« JGO Spiffy Duke »


Medals: 210
Projects: 24
Exp: 18 years


Coder, Trainee Pixel Artist, Game Reviewer


« Posted 2007-01-16 08:29:24 »

Since there doesn't seem to be a cross platform equivilent to BMFont (if some one can show me one, it'd save me some work), I'm putting one together.

It's not far along yet, it can generate font textures as you'd expect but doesn't do much else:

http://slick.cokeandcode.com/demos/hiero.jnlp

I need to get Linux/Mac testing going to try and work out how to find the fonts on the system (note I can't use just Java font detection since I need the file to load approprite kerning information from the TTF).

For the webstartly challenged: http://slick.cokeandcode.com/downloads/hiero.zip

An old screenshot:



Any testing appreciated, though it's a bit early for anything other than it works or it doesn't Smiley

Kev

Offline markush

Senior Newbie




Plöp!


« Reply #1 - Posted 2007-01-16 09:27:08 »

Works with OSX 10.4 Intel after adding a font directory manually.

OSX stores fonts in /Library/Fonts and /System/library/Fonts and "user.home"/Library/Fonts. Unfortunatly most fonts are not ttf fonts, so I only have 3 fonts in the list. But wth those 3 fonts (Apple Symbols, Euphemia UCAS and Plantagenet Cherokee) its working.

There are more ttf files in those directorys, but they don't get loaded. The log says: Unable to process: /System/Library/Fonts/<fontname>.ttf

There are some more font directories on osx: /usr/X11R6/lib/X11/fonts/TTF/ if X11 is installed, which is not installed by default. And "java.home"/lib/fonts for the java fonts. All those fonts load without errors.

I do get a "Exception in thread "AWT-EventQueue-0" java.lang.OutOfMemoryError: Java heap space" if I add to much font directorys in one session, though.
Offline PeterB

Junior Devvie





« Reply #2 - Posted 2007-01-17 22:22:08 »

cool i've thought before of coding this myself for generating font textures for games, but I never found the time!
Quick question: is the demo you put up meant to only show a jumbled assortment of numbers and letters?

Picking the Arial font (on windows XP)  shows only a selection of letters and symbols, not the usual 0-9, A-Z, etc:

()@{|}$[]jQ#%&/CGOS\035689?J
Ubdfgpqty!1247ABDEFHIKLMNP
RTVWXYZhikl;  aceosu:<>mnrv
wxz+^*="'`~-._


Vault101 / Mace The Game
There are 10 kinds of people in the world. Those who understand binary and those who don't.
Games published by our own members! Check 'em out!
Legends of Yore - The Casual Retro Roguelike
Online kevglass

« JGO Spiffy Duke »


Medals: 210
Projects: 24
Exp: 18 years


Coder, Trainee Pixel Artist, Game Reviewer


« Reply #3 - Posted 2007-01-17 22:25:33 »

I got the MacOS X thing fixed.

The letters shown are sometimes referred to as the NeHe character set - because a NeHe tutorial uses them - most common characters. However, the character set can be changed on the pull down to the right, and should soon support custom configuration (maybe based on Unicode).

The order the of letters is sort of random in that the characters are arranged to fit the quads on to the texture in best way it can (at the moment only using horizontal slices which seems to be pretty reasonable).

Still working on this stuff tho Smiley

Kev

Offline markush

Senior Newbie




Plöp!


« Reply #4 - Posted 2007-01-18 10:34:03 »

Seems the tool now finds fonts on osx, unfortunatly I get a OutOfMemoryError now on load. It happens after loading some fonts. Maybe I have too much fonts on my system?
Online kevglass

« JGO Spiffy Duke »


Medals: 210
Projects: 24
Exp: 18 years


Coder, Trainee Pixel Artist, Game Reviewer


« Reply #5 - Posted 2007-01-18 11:03:30 »

Yeah, I should probably either:

a) Up the the stack size
b) Only load fonts on use - would slow everything down

Probably go for a  - memory's cheap Smiley

EDIT: Or maybe not, seems like theres a 128m heap already allowed - either Mac OSX doesn't obey the webstart heap setting or I need to take a look at how much data is being loaded! Smiley

Kev

Online kevglass

« JGO Spiffy Duke »


Medals: 210
Projects: 24
Exp: 18 years


Coder, Trainee Pixel Artist, Game Reviewer


« Reply #6 - Posted 2007-01-20 00:16:35 »

New version is up:

- Hopefully cleared the memory up
- Added custom character sets
- Added pluggable effects

New screenies:





Bear in mind my extreme lack of artistic ability

Kev

Offline CommanderKeith
« Reply #7 - Posted 2007-01-20 05:45:41 »

Cool program, worked here on windows XP no troubles, I even managed to find and load some fonts in C:/WINDOWS/Fonts.  Colouring is neat and easy.

But can you spell out how to use the fonts/bitmaps?  Once I save them, then what?

Cheers,
Keith


Offline Matzon

JGO Knight


Medals: 19
Projects: 1


I'm gonna wring your pants!


« Reply #8 - Posted 2007-01-20 08:50:12 »

grab http://slick.cokeandcode.com Smiley

Online kevglass

« JGO Spiffy Duke »


Medals: 210
Projects: 24
Exp: 18 years


Coder, Trainee Pixel Artist, Game Reviewer


« Reply #9 - Posted 2007-01-20 09:33:54 »

The tool is developed as part of slick but it attempts to output the text file format of the AngelCode font tool. Essentially the tool only exists because AngelCode isn't cross platform - so I've just tried to use the same format so existing font code should work. I've always been happy with the angel code tool but linux/mac users don't get the option :/

I'll probably be adding at some point in the future

- XML AngelCode font code
- Saving/Loading font configuration (font face, size, effects, charset etc)
- Documentation on how you plug in effects

But right now I really want to get on with my game Smiley

Kev

EDIT: But yes, the render above is from the AngelCode loader in Slick

Games published by our own members! Check 'em out!
Legends of Yore - The Casual Retro Roguelike
Offline oNyx

JGO Coder


Medals: 2


pixels! :x


« Reply #10 - Posted 2007-01-20 14:17:03 »

BlurShadowEffect


http://kaioa.com/k/bseffect.jar (goes into <user>/.hiro/)

edit:
<aho> but i forgot to clear the images
<aho> meep
<aho> so it wont work correctly on mac/linux right now

Will be fixed soonish :f

edit2:
done Smiley

edit3:
another image added

弾幕 ☆ @mahonnaiseblog
Pages: [1]
  ignore  |  Print  
 
 
You cannot reply to this message, because it is very, very old.

 

Add your game by posting it in the WIP section,
or publish it in Showcase.

The first screenshot will be displayed as a thumbnail.

PocketCrafter7 (12 views)
2014-11-28 16:25:35

PocketCrafter7 (8 views)
2014-11-28 16:25:09

PocketCrafter7 (8 views)
2014-11-28 16:24:29

toopeicgaming1999 (75 views)
2014-11-26 15:22:04

toopeicgaming1999 (65 views)
2014-11-26 15:20:36

toopeicgaming1999 (15 views)
2014-11-26 15:20:08

SHC (29 views)
2014-11-25 12:00:59

SHC (27 views)
2014-11-25 11:53:45

Norakomi (32 views)
2014-11-25 11:26:43

Gibbo3771 (28 views)
2014-11-24 19:59:16
Understanding relations between setOrigin, setScale and setPosition in libGdx
by mbabuskov
2014-10-09 22:35:00

Definite guide to supporting multiple device resolutions on Android (2014)
by mbabuskov
2014-10-02 22:36:02

List of Learning Resources
by Longor1996
2014-08-16 10:40:00

List of Learning Resources
by SilverTiger
2014-08-05 19:33:27

Resources for WIP games
by CogWheelz
2014-08-01 16:20:17

Resources for WIP games
by CogWheelz
2014-08-01 16:19:50

List of Learning Resources
by SilverTiger
2014-07-31 16:29:50

List of Learning Resources
by SilverTiger
2014-07-31 16:26:06
java-gaming.org is not responsible for the content posted by its members, including references to external websites, and other references that may or may not have a relation with our primarily gaming and game production oriented community. inquiries and complaints can be sent via email to the info‑account of the company managing the website of java‑gaming.org
Powered by MySQL Powered by PHP Powered by SMF 1.1.18 | SMF © 2013, Simple Machines | Managed by Enhanced Four Valid XHTML 1.0! Valid CSS!