dev builds
themes manual
device status forums
mailing lists
IRC bugs
dev guide

Rockbox mail archive

Subject: Re[2]: Loadable fonts patch

Re[2]: Loadable fonts patch

From: Alex Gitelman <>
Date: Fri, 2 Aug 2002 09:54:30 -0700

>> [ check how the output ajf file looks like ]
>> $ od -x system.ajf
>> 0000000 bdfc 0041 4c54 3878 3800 0000 0000 0000
>> 0000020 0000 0000 0000 0000 0000 0000 0000 0000
>> 0000040 0000 0008 0008 0000 0000 0008 0000 0000

DS> I guess that this is because I run this on a SPARC cpu which is reversed
DS> endian to the i386. Does it sound reasonable?
I think that's what is going on. On my cygwin:
$ od -x system.ajf
0000000 fcbd 6100 746c 7836 3031 0000 0000 0000
0000020 0000 0000 0000 0000 0000 0000 0000 0000
0000040 0000 0600 0a00 0000 0000 0c00 0000 0000
bdf2ajf should write things as bytes so hopefully
it's only output problem.

DS> Also, the attached patch makes the font converter more fun for *nix users.
Thanks. I really have very little chance to test things on Unix - your
patch is very helpful.

DS> In the function ajf_get_charbuf() you have a loop to detect where the start
DS> of the particular letter starts. I don't like this having to loop from 0 to
DS> ASCII-code for each single letter we want to output. I would instead suggest
DS> that whe you load the font, you create a lookup-index for each letter as
DS> it'll make it a lot faster.

That's on my schedule for sure.

DS> Where can I find a bdf font that has the same size as the smallest default
DS> Rockbox font (6x8)? We can't have any bigger as the smallest default, it
DS> would be insane...!

Actually I would like to find it myself. I don't think it's in
collection of fonts I got. Rockbox works fine though with, say 6x10
chars (except that WPC display is a bit hard to maintain). As you so I
changed most places to take height into account.
I also have a font which is 8x8 but I don't like how it looked.
Notice that I only looked in BDF 2.1, so I don't know if bdf2ajf will
work with BDF 2.2.

Thanks for comments
Received on 2002-08-02

Page template was last modified "Tue Sep 7 00:00:02 2021" The Rockbox Crew -- Privacy Policy