Jump to content
  • Advertisement

Archived

This topic is now archived and is closed to further replies.

Chocoboko

A little problem with the screen flickering when it scrolls

This topic is 5574 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

Hi, I am writing a 2D console-style RPG in SDL. I have a little problem. The character can walk around the screen just fine, but when the screen scrolls, it gives a bit of a nasty flicker effect in windowed mode. It''s not as noticeable in full screen mode though. The game is using a resolution of 640x480. It runs at 100 FPS in windowed mode and 60 FPS in full screen mode. Can a too high FPS cause flickering or something similar? Thank you.

Share this post


Link to post
Share on other sites
Advertisement
Well, the most likely options are not waiting for the v-sync, single-buffering, or a combination of the two.



Best viewed with irony.

Hail Eris! All fnord hail Discordia!

Share this post


Link to post
Share on other sites
You need to use the SDL_DOUBLEBUF with SDL_SetVideoMode to use double buffering. I don''t think there''s anything for controlling v-sync, although your driver may allow you to turn v-sync on and off (in Windows, you can get to from the Advanced... button on Settings tab of the display properties dialog. I don''t know where it might be in Linux or any other OS.).

Share this post


Link to post
Share on other sites

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

We are the game development community.

Whether you are an indie, hobbyist, AAA developer, or just trying to learn, GameDev.net is the place for you to learn, share, and connect with the games industry. Learn more About Us or sign up!

Sign me up!