Typophile

rasterizing fonts at low point sizes while keeping antialiasing and hinting active

Anapan

Hey all, some discussions here touched on this, but I still can't find a good answer.
I'm using Windows, and I'm trying to render some true type fonts to fit into an 8x8 grid and then reduce the grayscale to 1 or 2 grays for use in old video game roms. I tried several methods and most came out really crappy. While trying to find a better way I found out that the solution is hinting to keep the clarity at low point sizes while still softening the edges of the curves. This works really well, except Windows' font smoothing kicks out at those font sizes except in a few fonts I've tried it with. So-far the only solution I found that might work - a CSS webpage tag that forces antialiasing at small sizes didn't work for me. Does anyone know a program, dll modification, or font data modification to make windows keep it's antialiasing active at the font sizes I wish to use? Will a mac computer's rasterizer do what I want?

FreeType might be able to do that, although its defaults are exactly what you describe.

Although I seriously doubt a character on an 8x8 grid wil look anything like the original font.

(A post-edit thought: why not draw the characters in black & white, at 200% scale, then downscale to get 4 levels of grey? Or indeed, as large as you want, and clip grey values when downscaling.)

You could try editing the font's GASP table, which controls which kinds of gridfitting/antialiasing are applied at which sizes:

http://www.microsoft.com/typography/otspec/gasp.htm

Thanks for the replies!
Helvetica turned out really well in notepad. I was amazed.
http://www3.telus.net/anapan8/ldj/lsdjfonts_3.gif
The 200+% method works, but the horizontal and vertical lines tend to come out as shades of gray with all the scaling methods I tried unless I moved the letters around trial-and-error like. Too messy.

I'll try out Freetype and see if there's any way to coax it into doing what I want. Sourcecode is available so I may be able to do something with that.

Thanks for the link, I'll load up Fontographer and hunt down the GASP dialog.

I knew I was asking in the right place.

I don't think Fontographer gives you access to the GASP table. FontLab, Font Forge do. If that's all you want to do, you can use TTX.

Did you try using Curves in Photoshop on a
fully grayscale rendering of 8 point type?

> for use in old video game roms.

Could you elaborate? Are you actually making new ROMs for old video game systems, and want to have the type rendered as nice as possible? Or are you trying to simulate the type from an old game system? I've heard of some old Atari games that used grayscaled bitmap fonts, but that was extremely rare - I've never seen it.

> I seriously doubt a character on an 8x8
> grid wil look anything like the original font.

But remember: nothing looks like itself at a different size.

hhp

Oh cool! I think TTX is just what I'm looking for.

I'll give Photoshop a try first, I'm more familiar with Paint Shop Pro, so that's what I've been using. It's rasterizer is OK, but doesn't seem to use hinting. Still it worked better than the resizing method.

Right now I'm replacing the fonts in Little Sound DJ for Gameboy. It's important to have a really readable font on a screen that small, and I didn't like the default fonts it had available. I posted my first results to 8 Bit Collective, and had requests for some True Type fonts. I've done this kinda thing on other games and programs for older systems - Pocketnes for GBA, and some other rom hacks. Whenever I tried to convert a TTF I got mixed results, and windows font smoothing (or lack of it) has always been where I hit a brick wall. After Helvetica turned out so good I started searching for a way to replicate it with some other good fonts and wound up here. I'm glad you guys have such good suggestions. I've been trying to figure this one out on and off for years.

What you really need is a hand-made 8 ppem grayscale bitmap font.
The people who do that sort of work can be counted on the fingers of
one of Mickey's hands. I know because I happen to be one of them. :-)

http://www.themicrofoundry.com/manademo/

But the smallest I've gone is 11. However, if you have
a budget, I can make an 8 ppem one for your project.

hhp

>and had requests for some True Type fonts.

Be sure to use only open-source or freeware fonts which are licensed for modification and/or redistribution. Posting hacked Helvetica TTFs will draw unwanted attention from Linotype's attorneys.

Captured from web.archive.org on 31 Jan 2010. view this capture