PDA

View Full Version : Only 100 FPS



Jan
04-20-2003, 07:28 AM
I just discovered, that my app runs only at 100 FPS (v-sync off).

The thing is, that when i discovered this i had the highest settings (32 Bit, anistropic filtering, and such stuff).
Now i have disabled nearly everything (except texturing) and it still runs at excactely 100 FPS.

For me this seems to be v-sync, but i checked under windows, it is set to "always off", and my app doesnīt change this.
Also if it was v-sync it would run at 60 Hz (because of my monitor).

My app uses 200 polys, VAR2 and nothing except texturing. On my Geforce 4200 this should be no problem.

So my question: Could it be a driver bug. I heard that Win2000 or WinXP had such an issue once (i use WinXP). I recently downloaded the 43.45 drivers. Could this be the problem?

Thanks.
Jan.

pkaler
04-20-2003, 07:45 AM
Draw nothing. Toggle SwapBuffers on and off. Maybe there's a bug in your FPS code.

jwatte
04-20-2003, 07:50 AM
FSP counter bug sounds possible.

It could also be that you are fill rate bound. Try culling out all triangles: glCullFace(GL_FRONT_AND_BACK).

Log a timestamp to disk (or memory buffer) everytime you SwapBuffers() and go back and analyze these after the fact.

Jan
04-20-2003, 09:32 AM
Ah, sorry.

I found my bug. In my main loop i had a "Sleep (1)", which on WinXP seems to be the same as a "Sleep (10)". I really didnīt notice this.

Sorry for bothering you.

Jan.

[This message has been edited by Jan2000 (edited 04-20-2003).]

JD
04-20-2003, 11:11 PM
When I set vsync to 'off by default' it reverted back to always on for some strange reason. I had to set it to 'always off' then it remained off. Strange. Using 41.09 drv.

[This message has been edited by JD (edited 04-21-2003).]

Ysaneya
04-21-2003, 03:19 AM
In my main loop i had a "Sleep (1)", which on WinXP seems to be the same as a "Sleep (10)".


Sleep is not accurate to the millisecond, whatever the OS. It's a well-known thing :) Thank you Windows :)

Y.

jwatte
04-21-2003, 11:31 AM
On BeOS, sleep() would be accurate to 40 microseconds or so, on Pentium-II hardware, assuming you are the highest-priority thread. We tried to get it better than that, but certain parts of the keyboard driver and other legacy hardware sort-of requires disabling interrupts for that long.

On systems with traditional, old-skool schedulers, such as Windows and Linux, sleep may be very jittery, so that's still something to look out for.