Recommended Posts

My game's FPS average counter showed a steady 75 (or 100 depends on the screen) FPS.
However, from time to time I noticed some hazard in the smooth animation.
So I made a graph of the exact FPS and noticed that my suspicion was true.
Why do you think this FPS glitch happen? most of the time the FPS is steady and high, but the glitch can happen only once or twice and then be steady or even several times in a few seconds.
The second wierd thing is that I use Direct3D and in the Present I set it to not return from the present until the image was actually done. So the FPS shouldnt go above the screen refresh rate more then one frame at a time.
(I hope you can notice on the bottom left of the image the drop and then rise of the FPS)
Have a look in the screen shot and tell me what you think.
Thanks in advance, I appreaciate your help.

Share this post

Link to post

Share on other sites

Original post by speediewhats happening or what are you animating in your game at the time the Frames drop? Maybe you could show some code thats being executed at that point.

What you just see on the screenshots.These are just sprite animations.However, I can make the character walk back and forth and it wont have any FPS drop, but then suddenly it will happen. So an image can be drawen once and it wont have any FPS drop, but later the same image drawen will cause an FPS drop.Maybe it is something related to the OS work in the background?In other words I dont understand what you want me to show you? the code of what?The code being executed at that point is the whole loop cycle, which includes all the input, logic, drawing the peremitive and then doing present. So its too much code to post it all here.

Share this post

Link to post

Share on other sites

i mean.. it's maybe dumb to suggest that.. but have you set up windows performance monitor to monitor your system while you're experiencing those glitches in your app? maybe something weird is happening underneath.. at least you could see whether you have a processor peak or io or... well.. something different :)

0

Share this post

Link to post

Share on other sites

Original post by thesimoni mean.. it's maybe dumb to suggest that.. but have you set up windows performance monitor to monitor your system while you're experiencing those glitches in your app? maybe something weird is happening underneath.. at least you could see whether you have a processor peak or io or... well.. something different :)

The CPU monitor showes usage of 50% of the CPU.A strange thing is that the CPU usage is split to two graphes, so I dont know what the two mean. I dont have a duel core CPU.

0

Share this post

Link to post

Share on other sites

Guest Anonymous Poster

Guest Anonymous Poster

it's a hyper-threading cpu then. try adding a few other metrics to the graph (right click) like disk io, memory usage, etc ... try to find out if there's something spiking when your app freaks out. however, this was just a guess. just something i would check before investigating further in my code.

- simon

0

Share this post

Link to post

Share on other sites

Guest Anonymous Poster

Guest Anonymous Poster

ah i just realized you only had a look at the task manager's graphs. they don't tell you a whole lot. use Run > Perfmon.exe for this. There you can dig a bit deeper into what 's consuming resources on your system. - simon

0

Share this post

Link to post

Share on other sites

I have checked with perfmon, and it showed 50% usage of CPU and low usage of memory.However, I was unable to recreate the glitch for now, so I will check it again late.I just wanted to put a screenshot of my game with some little imporvement on the look of it.Please tell me what you think.