gbadev.org forum archive

This is a read-only mirror of the content originally found on forum.gbadev.org (now offline), salvaged from Wayback machine copies. A new forum can be found here.

Coding > Need explanation about fonts

#64559 - mentz - Fri Dec 23, 2005 3:44 pm

I would like to know (even with code examples in C or Arm) the "mapping" system of fonts (either fixed and variable width)

I would like to make a simple project using both the system...


Thanks to all...
and Merry Xmas....
_________________
xXx

#64567 - tepples - Fri Dec 23, 2005 5:26 pm

Start with agbtty and then once you know how that works, I'll teach you to customize it.
_________________
-- Where is he?
-- Who?
-- You know, the human.
-- I think he moved to Tilwick.

#64588 - mentz - Fri Dec 23, 2005 8:53 pm

Thank you very much....

:)

agbtty works with HAM2.8 ?
_________________
xXx

#64920 - mentz - Wed Dec 28, 2005 3:03 pm

I've found some interesting and different method to handle standard fonts (fixed and 8x8 pixel) using "bitmap font and a look up table" or font "drawned" with "0" and "1" and stored in a sort of array...

However no one used 8x16 fonts or mapped in memory treating them like sprite...
_________________
xXx

#65217 - jake2431 - Sun Jan 01, 2006 12:07 am

Check out the last program in chapter five of J. Harbour' book http://www.jharbour.com/gameboy/default.aspx. It is a very good example of how to use a hardcoded font and display it. He shows you the functions needed to display the Print function that you create. It's an amazing book! Hope this helps.

#65225 - tepples - Sun Jan 01, 2006 2:31 am

mentz wrote:
However no one used 8x16 fonts

Using 8x16 fonts is easy: draw all the top halves on one row of tiles and then draw all the bottom halves on the next row of tiles. I seem to remember that my GSM Player does this.
_________________
-- Where is he?
-- Who?
-- You know, the human.
-- I think he moved to Tilwick.

#65247 - mentz - Sun Jan 01, 2006 1:25 pm

jake2431 wrote:
Check out the last program in chapter five of J. Harbour' book http://www.jharbour.com/gameboy/default.aspx. It is a very good example of how to use a hardcoded font and display it. He shows you the functions needed to display the Print function that you create. It's an amazing book! Hope this helps.


Yes...It's a very great book...(I'm doing all the exercise!)
_________________
xXx

#65299 - wintermute - Sun Jan 01, 2006 11:02 pm

mentz wrote:
jake2431 wrote:
Check out the last program in chapter five of J. Harbour' book http://www.jharbour.com/gameboy/default.aspx. It is a very good example of how to use a hardcoded font and display it. He shows you the functions needed to display the Print function that you create. It's an amazing book! Hope this helps.


Yes...It's a very great book...(I'm doing all the exercise!)


Actually it's an awful book. The information and tutorials found at http://user.chem.tue.nl/jakvijn/index.htm will give you a much better grounding in GBA programming.

#65310 - Cearn - Mon Jan 02, 2006 12:11 am

I'm working on a text page for tonc, covering simple (well, I think they're simple :P) and flexible text systems for pretty much all modes. I should be done after I add the accompanying text for the last two demos. I'll see if I can add a work in progress version in a few days.

You are expected to understand the basics of GBA programming, though; it won't be a beginner section.

Also, 8x16 font systems are actually not that difficult to create, it's just a little more book-keeping, but it's difficult to give concrete advise on it because there are so many ways of doing it that depends very much on howmuch room you have left in VRAM, tilemaps vs bitmaps vs sprites, etc, etc. Like tepples said, learn 8x8 first, then change it for your own specific purposes.

#65345 - jake2431 - Mon Jan 02, 2006 6:23 am

Hi wintermute, I wouldn't say that it is a awful book. I have learned a lot from it, but thanks a lot for that link. It looks really interesting, and I will look at it in more detail when I get a chance :)

Edit: I have checked out the site. I just wanted to thank you again. It looks like it will be amazing. I can't wait to play with the "mode 7" stuff :). Also, Cearn if it your site? If it is exellent work, and if it isn't.... well.... it's still exellent work!

#65538 - mentz - Tue Jan 03, 2006 9:52 pm

Thanks to all for important information...


Quote:

You are expected to understand the basics of GBA programming, though; it won't be a beginner section.


I know the basic (hardware, some code of arm7, simple demo in arm code)...
But this is the first time i start to programming in C...
_________________
xXx