what are VGA fonts, and can I get some :)

Posted:
Dec 17, 2005 @ 10:22pm
by MikeL
Hi, I want to use the DrawVGAText function to blit some text. I have no idea what VGA fonts are and googling didn't help much
Any help would be appreciated,
Thanks,
michael

Posted:
Dec 18, 2005 @ 9:38am
by Conan
is it just fonts you want which are compatible with Frank's VGA font function? if so I know that at one time he posted lots of them. The supersample demo has only 2 enclosed. I have Frank's vgafont.zip file and can email if you don't find a link. It has lots of fonts (around 100).
update:
Frank has hosted them on his new sourceforge site.

Posted:
Dec 19, 2005 @ 7:12am
by fzammetti
Just to give some further info...
VGA fonts are basically the native font format you would find in video ROM, like what you see when you first turn on your computer when you see the POST tests and such.
They are 8x16 pixels in size, and each of the 16 rows is represented by a single byte (each bit represents one pixel). There are 256 characters in a VGA font, 0-255, matching up with standard ASCII from 0-127, and the IBM extended ASCII set beyond character 127 (of course, you can rearrange things however you like). Hence, they are always 4k in size (16x256=4096 bytes).
Some of the nice things about them...
* 4k is nothing for a complete font
* They are always fixed-width, which makes it easy to calculate how much space a given string will take up
* They are easy to create (at one point I had a simple editor in Excel that spit them out!)
* Because of their simplicity and linear nature, they are both easy to write code for (see the code for DrawVGAText, it's ridiculously simple) and can also be drawn quite fast (DrawVGAText was never a particularly efficient function, yet it can churn them out pretty quickly)
* Again because they are so simple, you can do some neat trick by manipulating the font data on-the-fly. This is in fact the technique that was used for many of the most famous demo effects back in the day, and they can almost all still be accomplished with VGA fonts
* There are a lot of them floating around, ant most are old enough that they probably have passed into the public domain (at worst, no one is going to be looking for them!)
They may be hard to find now (as you seem to have discovered), but the link Conan posted should get you over 100 fonts as I recall.
FYI, I *believe* you can create them using any drawing program that can write RAW files... I think I played with this a bit and it was possible, although it was probably 2-3 years ago, I doubt I remember the details.