Advertisement

Bitmap fonts slowing the framerate

Started by April 06, 2001 06:13 PM
3 comments, last by Chandrill 23 years, 7 months ago
This could be just me making stupid mistakes, as I am a newbie at openGL, but whenever I try to do bitmap fonts in fullscreen mode everything slows down, until I get about 1 frame every 5 to 10 seconds. This happens even if there is nothing else being done, other than drawing the font. Everything works fine in windowed mode, I only get this in fullscreen mode. I''ve tried downloading the bitmap text tutorial and running it without any changes, and the same thing occurs. Anyone know what could cause this? I''m running a PIII,450Mhz, 128mb, with a voodoo3 if it makes a difference.
you''re obviously getting software unacceleration. what is causing it? do any other opengl programs with source run accelerated?

http://members.xoom.com/myBollux
Advertisement
Give up the source so we can look at it.
quote: Original post by Anonymous Poster

Give up the source so we can look at it.


Get in on nehe.gamedev.net



"And that''s the bottom line cause I said so!"

Cyberdrek
Headhunter Soft
A division of DLC Multimedia

Resist Windows XP''s Invasive Product Activation Technology!
[Cyberdrek | ]
For the code I''m using see Nehe''s tutorial #13 (nehe.gamedev.net).
What has me stumped is that the text displays fine in windowed mode(changes colors and moves up and down), but in fullscreen mode I get a black screen, and have to hold the escape key down for approximatly 10secs before it exits. To test if it simply was not displaying the text for some reason I borrowed from Nehe''s latest base code and added spinning triangles.
First 3 global variables:
float angle;int rot1, rot2;
then in the drawGLScene method I add
glRotatef (angle, 0.0f, 1.0f, 0.0f);
for (rot1=0; rot1<2; rot1++){
glRotatef(90.0f,0.0f,1.0f,0.0f);
glRotatef(180.0f,1.0f,0.0f,0.0f);
for (rot2=0; rot2<2; rot2++) {
glRotatef(180.0f,0.0f,1.0f,0.0f); glBegin (GL_TRIANGLES); glColor3f (1.f, 0.f, 0.f);
glVertex3f( 0.0f, 1.0f, 0.0f);
glColor3f (0.f, 1.f, 0.f);
glVertex3f(-1.0f,-1.0f, 1.0f);
glColor3f (0.f, 0.f, 1.f);
glVertex3f( 1.0f,-1.0f, 1.0f);
glEnd ();
}
}
angle += 0.5;

this creates a nice pair of spinning pyramids. if I comment out the line
glCallLists(strlen(text), GL_UNSIGNED_BYTE, text);
in the glPrint method, then everything works fine in fullscreen mode, if I leave it in, I again get the blackscreen and must hold down escape for about 10secs.

I''ve tried downloading and running other openGL programs and any without bitmap text run just fine. It''s only with bitmap text that I get this.

I hope i''ve adequetly explained whats going on here, and not competly confused everyone. Any help would be much appreciated.

This topic is closed to new replies.

Advertisement