PDA

View Full Version : would like some advice on fonts



langecrew
01-22-2008, 08:50 AM
Hi everybody

I've been writing an openGL based "line chart" and I'm running into some issues rendering fonts. In my line chart I have a little data box that appears when you mouse over a point in the chart; it displays some text with information about the point you moused over. I also have some text drawn on the sides of the chart along with tick marks along the axes; some of this text needs to be rotated so the chart does not look too jumbled.

I've been going by NeHe lessons 13 and 14, Bitmap fonts and Outline fonts.

I started by using Bitmap fonts. I like them because they look nice and they are really easy to setup and to deal with. The only problem is that they apparently cannot be rotated at all. Then I started trying to use Outline fonts and I found that, while I can rotate them all day, they look like total crap! They look like I typed a document, took the font down to the smallest size, took a jpeg of the document, and then blew the jpeg up to normal size...all the letters are quite pixelated, even when they are larger in size. I'm sure I just did something wrong, but I haven't figured out what.

So, two questions (I can post code if it will help):

1. I noticed that, when I try to render BOTH Bitmap AND Outline fonts, the whole rendering process slows down to the speed of a slideshow. Is there any way to speed this up?

2. Optionally, if the outline fonts didn't look like crap, I could just use them exclusively. Why, even with an anti-aliased font with GL_POLYGON_SMOOTH and GL_LINE_SMOOTH enabled, why do my outline fonts look like pixelated crap and not like the ones in the example on NeHe...is there any way to make them look nice when they're small or am I out of luck there?


thanks for any advice,
-langecrew-

-NiCo-
01-22-2008, 09:14 AM
I think you'll be better off using a font rendering engine such as QuesoGLC (http://quesoglc.sourceforge.net/)

N.