Sign in to follow this  

Bitmap fonts

Recommended Posts

I'm having some trouble with this bitmap font code I copied from NeHe:
void PutText(int x, int y, const char* text, ColourData* colour)
	glListBase(BaseFont - 32);
	glCallLists(strlen(text), GL_UNSIGNED_BYTE, text);
It renders text, but for some reason, when I call it as: PutText(10,10,"Test",&NormalColour); It starts from the bottom left hand corner (It's inside a glEnable2D which reverses the axes, so that's wrong), and then flies horizontally across the screen. I'm not incrementing anything... any idea why it's not working?

Share this post

Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

Sign in to follow this