odd flicker with nehe (SOLVED!)
I have made a couple of programs from the nehe base code, and I get an odd flicker every so often, where the app window flashes white for just an instant, and also the mouse cursor flashes to an hour glass.
At first I thought it was my code, so I just compiled an empty nehe project and and I got the same flicker.
So I thought I might need to reboot, that didnt help, then I thought it was just my computer perhaps, so I ran it on my wife's computer, and it had the same flicker.
So then I dloaded the nehe simplest code, and the other nehe codes, glut, dialog, oop, latest, etc...
And to my surprise the only ones with no flicker, were the simplest, and the glut versions of the nehe base code.
So has anyone else came across this bug? If you have, can it be fixed in the Latest realease base code? (Which is what my apps are based off of)
Thanks for any info on this :)
[Edited by - SelethD on December 19, 2005 1:59:55 PM]
Hmm, a tricky one. My initial guess would be something is grabbing a lot of resources or opening a socket and this is causing the program to stall temporarily. I take it you've investigated the usual suspects such as rougue processes, virii and spyware? Also have a look to see if any antivirus, firewall or task scheduling programs might be updating at these times as well.
A few questions for you, not that these will help much but should reduce the guesses:
Sorry I can't be more specific but it's a pretty random sounding bug, if indeed it is a bug.
A few questions for you, not that these will help much but should reduce the guesses:
- Does it happen in fullscreen and windowed modes?
- Is the flicker intermittent or regularly timed?
- How long does the flash last for, i.e. is an instant thing or is there a noticible length to it?
Sorry I can't be more specific but it's a pretty random sounding bug, if indeed it is a bug.
Well, it only happens in windowed mode, not fullscreen. And it doesnt always happen on a regular time. The app can be just sitting there, and for no reason, it will 'blink'. Then sometimes, it wont do it until the mouse is clicked. (even if there is no mouse support in the app)
BTW, im not running my apps and getting this error. I downloaded the ones from the NEHE site, and ran the .exe's in their zips. So it cant be anything im doing.
Right now im looking at the source code and trying to find a difference in the 'simple' version of the code (which has no 'blink')
http://nehe.gamedev.net/counter.asp?file=files/basecode/nehegl_simple.zip
And the 'latest' version of the code (which does 'blink')
http://nehe.gamedev.net/counter.asp?file=files/basecode/nehegl.zip
Just if anyone knows about the code, can they tell me what might be different in these two versions that would cause this?
Thanks again :)
BTW, im not running my apps and getting this error. I downloaded the ones from the NEHE site, and ran the .exe's in their zips. So it cant be anything im doing.
Right now im looking at the source code and trying to find a difference in the 'simple' version of the code (which has no 'blink')
http://nehe.gamedev.net/counter.asp?file=files/basecode/nehegl_simple.zip
And the 'latest' version of the code (which does 'blink')
http://nehe.gamedev.net/counter.asp?file=files/basecode/nehegl.zip
Just if anyone knows about the code, can they tell me what might be different in these two versions that would cause this?
Thanks again :)
I figured it out
in the main game loop, it was calling CreateWindow, over and over again.
I fixed that, but still the flicker remained.
Then I noticed there was a missing 'TranslateMessage()' before the DispatchMessage() command.
So after adding that, it works fine, no flicker.
I tried just adding the TranslateMessage, without fixing the constant CreateWindow thing, and it still didnt work, so you need to fix BOTH of these problems to get rid of the flicker.
Thanks to all who replied :)
in the main game loop, it was calling CreateWindow, over and over again.
I fixed that, but still the flicker remained.
Then I noticed there was a missing 'TranslateMessage()' before the DispatchMessage() command.
So after adding that, it works fine, no flicker.
I tried just adding the TranslateMessage, without fixing the constant CreateWindow thing, and it still didnt work, so you need to fix BOTH of these problems to get rid of the flicker.
Thanks to all who replied :)
This topic is closed to new replies.
Advertisement
Popular Topics
Advertisement