• Advertisement
Sign in to follow this  

2d screen

This topic is 4753 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

i am using directX7 with c++. i have found that if you write all sprites and static background to backbuffer before display the screen flickers badly, what is the norm for 2D game display? you dont need to erase any sprites like this as the whole screen is re-drawn is it more of a standard to display a background once then display a sprite move and erase in a loop....?

Share this post


Link to post
Share on other sites
Advertisement
Quote:
Original post by jagguy
i have found that if you write all sprites and static background to backbuffer before display the screen flickers badly, what is the norm for 2D game display?
Are you sure that you're rendering to a back(!)buffer? The hole point of using one is to eliminate flickering, compared to writing directly to the front buffer, so at worst you'll experience tearing. If the problem is tearing then I suggest that you enable vsync manually since many "advanced" players like to tweak such settings themselves.

Quote:
Original post by jagguy
is it more of a standard to display a background once then display a sprite move and erase in a loop....?
It used to be but nowadays it's rarely worth the effort. Some effects, such as paralax scrolling, are close to impossible to optimize with such a scheme anyway.
There's still some exceptional cases around though. So if you're doing software rendering in a high resolution with mostly static backgrounds and you expect the user to be running other programs in the background it might be a good idea (think Tetris).

Share this post


Link to post
Share on other sites
i believe i am using a backbuffer correctly ( i will check again). if i display the background once and move a sprite i dont get a flicker but an image trail that hasnt been erased.

its only when i display a background each frame that this happens

Share this post


Link to post
Share on other sites
Would it be possible for you to be a more specific? Does your monitor flicker or does the Window flicker?
It might be that you have a vSync problem...
Please be a bit more specific.

Share this post


Link to post
Share on other sites
Original post by Armadon

the window flickers but it doesnt flicker if i display the background image once and just draw and erase on the background image in a loop for animation.

nothing to do with vsync

[Edited by - jagguy on February 16, 2005 3:22:12 AM]

Share this post


Link to post
Share on other sites
Sign in to follow this  

  • Advertisement