PDA

View Full Version : Fonts???



Dan
03-11-2000, 09:37 AM
Is there any way that I can blit bitmaps onto the screen, while using the perspective project mode, or does anybody know of any sites that have tutorials of how to load a TrueType font and display it? (while in perspective project mode)

dmy
03-12-2000, 11:18 PM
as a rule of thumb, don't blit anything!
put textures on a quad instead.
blitting wit glCopyPixels() is very slow, where texturing is much faster.

this way your text will behave just like another opengl object, underlying to glTranslate(), glRotate() and the other matrix functions.

to render text with perspective on, just set the modelview matrix to the identity, then draw textured quads with some ascii on them.

Dolo/\/\ightY

galenb
01-20-2004, 05:58 PM
Hi,

I'm having the same issues as you it sounds. The first part I can answer for you the second (about the true type fonts) is a loss in my opinion.

So, in order to draw 2D graphics on top of a 3D view, think of it like layers in photo shop, render the scene with:

gluPerspective(FOV, aspect, nearClip, farClip);
Render3DView();
then switch to:
gluOrtho2D(left, right, top, bottom);
Render2DData();

Render3DView(); and Render2D(); are just theoretical functions supplied by you but I think you understand. Don't forget to glEnable all the blending and stuff like that.

-=GB=-