View Full Version : Drawing text not horizontally with GLUT.

11-20-2003, 05:21 AM
Hey there,

I would like to draw some text accoring to a given direction.
So far, what I have been doing is this:

/* position the center */
glTranslatef(x, y, 0.0);
/* give the orientation */
glRotatef(my_angle, 0.0, 0.0, 1.0);

glRasterPos3f(0.0, 0.0, 0.0);
glutBitmapCharacter(my_font, my_char);

Ok so basically, I thought that this would give me some text drawn in the direction my_angle since I applied a rotation to GL_MODELVIEW... but it does not.
The text still appears horizontally.

Is there anyway to have the text appear diagonally then please?

11-20-2003, 05:42 AM
Matrix functions have no effect on the bitmap text.

You need to use a textured map font, vector font or a real 3D font made with vertex.

nehe.gamedev.net has examples of these diffrent fonts.

11-20-2003, 06:08 AM
Thanks. Exactly what I needed.