text

Started by
3 comments, last by dan parker 21 years, 1 month ago
Hi, can anyone tell me how to add text to a 3d environment in c++ OpenGL cheers Dan
Advertisement
Nehe has a tutorial on using text in opengl with some WGL functions (windows only tutorial, i believe).. http://nehe.gamedev.net/
Disclaimer: "I am in no way qualified to present advice on any topic concerning anything and can not be held responsible for any damages that my advice may incurr (due to neither my negligence nor yours)"
You go to the 2D mode (in fact, the Ortho mode), and then write each letter, froma texture, as a quad.
Go to nehe.gamedev.net for some tutorials.

Height Map Editor | Eternal Lands | Fast User Directory
I always like to say the best way to do it is load up a character set into a texture and render each character as a quad.

You would have to go through the trouble of generating the font texture, either manually or automatically, and assigning where each character starts and ends in the texture.

But, maybe there are better ways.
It's not what you're taught, it's what you learn.
Yes, i also like that method.
That''s what I also use in my game, and it is very fast. Once, I stole some display lists based text display routine, from a demo, but it took away like 10%(????????) of my framerate.
My own text routine takes no framerate at all


Height Map Editor | Eternal Lands | Fast User Directory

This topic is closed to new replies.

Advertisement