The flickering problem ;-)

Started by
4 comments, last by Nitromouse 21 years, 8 months ago
Hi together I have done some examples from the page. And at first i have to say that they are really great. But I have a problem: The screen is flickering when I set the Video Mode with SDL_HWSURFACE (on the video memory). does it flickering because of my video card, or what is the problem. Would be nice if someone helps me. I''m just a Noob ;-) Thanx Sorry about my English -> I''''m German
Sorry about my English -> I''m German
Advertisement
I'm not an expert in this but what i understand from the sdl mailinglist is that there is an issue about SDL_Flip in win2k and winxp. It seems that the horizontal syncs on the screen image are handled differently by these win versions. SDL_Flip will do the hardware blitting if you request a HW surface. If you don't or are in window mode SDL_Flip is replaced by SDL_Rect, which does not have the flikkering....
So the three possible solutions are: do software blitting, run it on win98 or winme, or hope that they fix this bug in the next version of sdl....

The weird thing is that i never noticed the flikkering untill recently (i usually do stuff in windowed mode). I cannot remember that i saw the flikkering the first time i tried one of these cone lessons. So it can also be an other problem. When i updated to DX8 i did not update my driver of my graphic card. Since then i sometimes have problems with other apps as well. So it can also be a problem like this. I'll try updating the cards driver soon....

[edited by - smilydon on July 29, 2002 9:08:16 PM]
It could be the video card, it''s is an really old one(ATI Rage Pro)
I use Win98.
And I intitalised tu Fullscreen

Sorry about my English -> I''''m German
Sorry about my English -> I''m German
You are right, i also see flickering in win98 (i have dual boot). Also my driver under win98 was up to date.

However i could stop it by changing the 32 in SDL_SetVideoMode to 24. It is possible that the older cards (mine is also very old (1998)) have trouble with the alpha channel. I can remember that i once ran a program that checked the sdl features i could do. It told me that i do not have hardware accelerated alpha blitting. That's basically what you have when you ask for a 32 bit dept (one byte for RGBA).

I still think it should not create a 32 bit video mode when it cannot handle this in hardware. So this might be a bug....

However, i have not checked whether i got a hardware surface, maybe sdl gave me a software buffer because it didn't like the 24 bit depth. This i have to check.....

[edited by - smilydon on July 30, 2002 5:25:14 PM]
Someone please correct me if i''m wrong but i''m pretty sure 2d hardware accelerated alpha blending doesn''t exhist, in directdraw there''s a flag for alpha but it went unsupported due to lack of hardware support,.....that''s just what i got from directdraw which sdl uses with windows so i don''t think that would be it, the alpha blending is all done in software or uses mmx i doubt it would use direct3d. and i don''t know enough to talk about 32bit color depth.
Free Game Textures!!!http://www.vb3d.com/Textures.html
Now i have done it with the flag SDL_DOUBLEBUF und there is no flickering anymore.

Could someone explain me the flag SDL_HPALLETE (or a little bit different) ??

Sorry about my English -> I''''m German
Sorry about my English -> I''m German

This topic is closed to new replies.

Advertisement