Original Post
Hello everyone!
I'm working on a game in C++ using Direct3D and I'm having a problem with vertical sync.
When I have my presentation interval set to default (Vsync on) I'm getting input lag, that is, the controls get all sloppy and slow. However if i change the presentation interval to immediate i get no lag whatsoever.
What I think is going on is that IDirect3DDevice9::Present is stalling the application because it's waiting for vertical sync. I'm looking for a way of getting around this problem.
I've found out that the IDirect3DDevice9Ex device (which only works on vista and later systems) has a Present method which can be set to not wait for vertical sync and instead return an error message if the hardware is not ready. So the question is, how do I achieve this using the normal IDirect3DDevice9 device?
I'm working on a game in C++ using Direct3D and I'm having a problem with vertical sync.
When I have my presentation interval set to default (Vsync on) I'm getting input lag, that is, the controls get all sloppy and slow. However if i change the presentation interval to immediate i get no lag whatsoever.
What I think is going on is that IDirect3DDevice9::Present is stalling the application because it's waiting for vertical sync. I'm looking for a way of getting around this problem.
I've found out that the IDirect3DDevice9Ex device (which only works on vista and later systems) has a Present method which can be set to not wait for vertical sync and instead return an error message if the hardware is not ready. So the question is, how do I achieve this using the normal IDirect3DDevice9 device?