Sign in to follow this  

A few vsync questions

Recommended Posts

Geronimo2000    270
I haven't ever gotten this issue straight, and was hoping some of you might be able to help me out. 1. When or why should I choose to specify more than one back buffer when I initialize a device? How does the vsync issue come into play. 2. Do some input devices lag or run faster when you choose to vsync or immediate? I have noticed my application runs slower on some systems when I vsync it, and some run slower when I don't, but in one case it has to do with keyboard response and the other has to do with mouse response. 4. Can someone outline some general guidelines or pros and cons regarding whether you should choose vsync vs. immediate rendering. Thanks a lot for any help, links, or input you can provide.

Share this post

Link to post
Share on other sites
turnpast    1011
Ok, I'm ont nearly 100% on this issue, but I will help as I can. There have been some good posts on this forum abot this in the past, but sadly I was unable to find them with a quick search.

When vsync is enabled (PresentationInterval != Immediate) the back buffer flips to the front when the monitor refreshes. This can cause a slow down if it takes longer to render than the interval between monitor refreshes. Without multiple back buffers you just have to wait for the next monitor refresh before you can start rendering the next frame, with multiple back buffers you can continue to render even if you are waiting for the vsync (with some limitations).

If you use immediate mode you can get tearing where the screen is half the new frame and half the old. I think that you can also (usslessly) render more than once per screen refresh.

It seems to me (and I am no expert) that you would want to use back buffering if tearing is a problem and you would want to use multiple back buffers if your card supports it (mine does not) and you are seeing a slowdown from using one back buffer.

Read about the 'SwapChain' in the docs, it will probably give you a better explaination than I have.

Share this post

Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

Sign in to follow this