TheGameCreators / GameGuruRepo

The GameGuru Repository For Community Collaboration
http://www.game-guru.com
137 stars 56 forks source link

Support for OS double VSYNC Setting (common on gaming laptops) #4478

Open Kravenwolf opened 1 year ago

Kravenwolf commented 1 year ago

VSYNC appears to be causing a MASSIVE performance drop on my system (and I don't mean because it's lowering my frame rate to my monitor's refresh rate). (My refresh rate is 60.)

With VSYNC enabled, I get a choppy 29-30 FPS in the snowy mountain stroll demo. My GPU is clearly struggling.

Disabling VSYNC in the very same scene with the same stuff going on not only almost immediately raises my frame rate to over 50 FPS (a 60% increase!), but it also stops the stuttering and makes the gameplay much more smooth, meaning VSYNC appears to be secretly killing performance:

Video here (keep your eye on the frame rate as VSYNC is toggled on/off): https://www.youtube.com/watch?v=xg3ic5k-aII

VSYNC shouldn't be doing this...right? Causing a 60% frame drop when the game is ALREADY running UNDER my monitor's refresh rate?

Some quick sleuthing on Google found some unfortunate information, if this is true: https://www.reddit.com/r/DeathStranding/comments/jk9rbt/vsync_causes_performance_problems/

--"That usually means you're just missing 60 FPS on some frames, and the next vsync boundary down is 30 which is kind of harsh. "

davetgc commented 1 year ago

Hi, could you post your system specs please.

MonkeyFrogStudio commented 1 year ago

Interesting. Running Snowy Mountain Stroll with vsync on, my frame rates range from about 69 - 81fps. When I turn off vysnc, my frame rates jump to 79 - 90+. It's not a huge increase, but an increase none-the-less. My refresh rate is 100Mhz, so I would be locked at 100, not 60, etc.

System specs: Intel i9-10900k 3.7GHz (overclocked to reach up to 5GHz) 64GB RAM Nvidia 3090 ti (24GB VRAM) Windows 11 (all updates)

Side note - this showcases another issue, though - the fact that I am only getting 80 or less FPS with vsync on and 90 or less with it off. In other words, I should easily be getting 100FPS with vsync on with my system and well over that with it turned off.

Kravenwolf commented 1 year ago

@davetgc GTX 1060 (3GB VRAM) Intel 7600K 16GB RAM

With Vsync off, the same demo with the same going-ons runs consistently around 50 FPS on my card (bit lower on that video because of my screen recorder running), so I'm pretty sure my GPU is not the problem, especially since the same performance drop is being applied to @MonkeyFrogStudio and his 3090 ti!

However, after checking several links on Google, a lot of gamers bring up this very same issue, and it unfortunately just looks to be the way that VSYNC works. If your GPU can't run the game at 120FPS without constantly dropping frames, then it drops it down to 60FPS and caps it there. If it can't keep it running smoothly at 60FPS, then it drops it down to 30 and caps it there:

VSYNC appears to be a bottleneck :/

https://www.reddit.com/r/DestinyTechSupport/comments/7deehm/dropping_to_30_fps_when_vsync_is_set_to_60/ https://www.reddit.com/r/computergraphics/comments/7sfu46/why_does_vsync_allow_fps_drop_below_60_if_without/ https://www.reddit.com/r/RocketLeague/comments/7wvsnn/fps_drops_when_vsync_enabled/ https://www.overclockers.com/forums/threads/is-it-normal-to-get-fps-drops-with-vsync-on-if-you-can-handle-it.787593/ https://forums.tomshardware.com/threads/fps-drops-below-60-with-v-sync.3682032/ https://forums.tomshardware.com/threads/vsync-fps-drops-problem.2554657/

I suppose if this is what VSYNC is SUPPOSED to be doing, then it's not a really a bug. But maybe Lee think of something? A 60% drop in performance on lower spec cards, and a ~10% drop on a 3090 ti. Wow!

davetgc commented 1 year ago

There's no doubt that performance can be improved, and there are a number of ways that we could look at after V1, including completing the move to DX1, improved Occlusion, a LOD system, etc.

However, game designers need to also take some responsibility, and look at ways that their levels can be improved and optimised. Professional gaming studios have whole teams dedicated to ensuring that every detail, not just engine optimisation is being used to squeeze an extra FPS or 2 out of a scene.

For example, using trigger zones to only spawn entities, especially characters when needed.

Keeping a focus on the important elements of a game rather than putting down 200 scenic objects in one area will also help. In many cases, a few well placed and chosen objects can add more to a scene than 100 small, unnoticed objects.

Avoid using multi texture objects, if possible will also help by reducing draw calls.

I'm sure others have suggestions as well.

MonkeyFrogStudio commented 1 year ago

@SampeyFS Your comment here is not helping. Unless you are specifically helping to solve or identify the issue, simply stating, "X is bad" is not helpful in the least.

MonkeyFrogStudio commented 1 year ago

@SampeyFS No, sorry. I will not comment more after this. What I was saying is there's no need to comment unless you are specifically HELPING with the issue. There's no need to say what you think or feel. There is only a need to report things that help identify the issue so the developers can fix the issue. Saying that performance is bad does not help the developers narrow down on what the actual issue is nor does it help them to identify and solve it. So, keep these threads clean and clear by not cluttering them up with useless comments.