Noobie DirectDraw question
Hello, i am a relatively new programmer, and i've just recently been tapping into DirectDraw and it's world of possibilities ;P
I'm a total newbie when it comes to this stuff, so i read some toutorials and stuff, and then began to make my first app.
I am using VB.NET in VS.NET and i managed to make some kind of enumeration and a simple fullscreen app with flashy lines bouncing around and stuff. DirectDraw is easy and will work very good for me.
However, i have a small problem.
My program, even though i have a tick test to limit the fps to around 32, takes up 100% cpu constantly.
My main loop has only a call to a kind of showNextFrame function that won't execute if there hasn't been a set nuber of ticks since the last call, and a doEvents call.
Any help would be appreciated, i probably just forgot something very crucial in my noobish attempt :)
Thank you!
I suspect you're always calling PeekMessage() in you main loop.
Try to put your PeekMessage() together with the showNextFrame() function.
Try to put your PeekMessage() together with the showNextFrame() function.
This topic is closed to new replies.
Advertisement
Popular Topics
Advertisement