Page 23 of 65

Re: Blur Buster's G-SYNC 101 Series Discussion

Posted: 04 Sep 2017, 15:09
by jorimt
Durante wrote: Took a while, but here I am :P

Now seriously, I was just reading this thread (since a friend asked me about the exact differences between G-sync with V-sync on/off in specific frame ranges, and jorimt's set of articles is the best resource I know on the subject), and I found the discussion of frame limiting latency impact that came up around the post I quoted (in June) very interesting.

I had some ideas about "predictive" external FPS capping a few years back: http://blog.metaclassofnil.com/?p=715
It never actually really worked out in my implementation, probably primarily since I didn't have any way to track the true V-sync timing at that point, and also because my implementation methodology was off. I do still think that the overall idea is viable, however. Of course, with most modern games you might well be halting the wrong thread this way.
RealNC wrote:Welcome back :P

What we haven't seen yet from anyone out there, is a "throttling" limiter. Meaning, do frame limiting even when not needed by always applying a few ms of wait time. In theory this should be easy to add to an existing limiter:

Code: Select all

if (frame_time < target_frame_time) {
    // Apply limit just like we always did.
} else {
    // Apply a small limit here, sacrificing 1-2FPS, while previously this was a no-op.
}
This should (I'm 99.99% certain) reduce input lag to the lowest possible value that any external, non-predictive limiter can possibly achieve.

No one has done this yet, even though it does look like it's a dead-simple modification to any frame limiter :-/
masterotaku wrote:What about SpecialK for fps limiting?: https://github.com/Kaldaien/SpecialK/releases

It has an optional busy-wait limiter, framerate variance tolerance, and lots of features. And it has a GUI where you can change the settings in real time.

I tried it in Trails of Cold Steel and it's very smooth, but hammers one of my cores so much that it reaches >90 degrees, lol. Si I have that disabled, but keep the mod for custom textures.
Sparky wrote:I had some ideas about this. Obviously there's backpressure, but how hard would it be to modify the IO library to block the main game thread or render thread when it tries to gather mouse input, and use that block for rate limiting? Obviously this won't work for all games, as multiple threads might be reading input, but for at least a few games it should give you the lowest possible latency.
RealNC's idea seems like the most straightforward way of ensuring lowest latency at all times with existing external framerate limiters, such as RTSS.

@RealNC, I assume you mean setting a framerate target once for the given game, but instead of applying as a static number (e.g. 142 FPS at 144Hz), it would apply as an offset (e.g. -1 FPS, -2 FPS, etc) to the current framerate. This means if the output framerate is 110 frames, it would limit to 108, 39 to 37 limit, and so forth.

While this wouldn't be as low latency as an in-game limiter, it would prevent pre-rendered frames from kicking in and reduce latency at all framerates (instead of just at a single set limit), since the limiter would become the framerate's limiting factor in all instances.

@masterotaku, I've never used SpecialK. Are you saying it does something similar to the above, but is too hard on the CPU as a result?

Re: Blur Buster's G-SYNC 101 Series Discussion

Posted: 04 Sep 2017, 16:35
by RealNC
jorimt wrote:@RealNC, I assume you mean setting a framerate target once for the given game, but instead of applying as a static number (e.g. 142 FPS at 144Hz), it would apply as an offset (e.g. -1 FPS, -2 FPS, etc) to the current framerate. This means if the output framerate is 110 frames, it would limit to 108, 39 to 37 limit, and so forth.
Yeah. As your quick latency tests showed in the past, this would get us between 1 and 2 frames less latency at all times.

One of the reasons to cap FPS to the average FPS of the game when using g-sync, is to minimize latency variation. It's quite annoying when the game goes from 100FPS to 70FPS when you look in a different direction, because the mouse then feels more floaty. However, if you cap the game to 69FPS, that floaty mouse feel goes away.

If a limiter would always apply a slight throttle, this would become much less of an issue and input lag would be more consistent.

According to my experience, making sure the frame rate cap is reached provides even less latency than MPRF 1. Such a frame limiter would reduce latency across the board under all circumstances. You could even rename it from "fps_limiter.exe" to "reduce_input_lag.exe" ;-)

Re: Blur Buster's G-SYNC 101 Series Discussion

Posted: 05 Sep 2017, 02:23
by masterotaku
jorimt wrote: @masterotaku, I've never used SpecialK. Are you saying it does something similar to the above, but is too hard on the CPU as a result?
I think it does exactly what you want, applying the necessary wait time to cap the game at the fps you need (with a lot of decimals of precision) and you don't have to think about how many miliseconds you have to spare. As a result, one of the CPU cores appears with 99-100% usage. I don't know a lot about its details and I haven't used it much, so it's better if you ask him here: https://steamcommunity.com/groups/Speci ... 590954694/

Re: Blur Buster's G-SYNC 101 Series Discussion

Posted: 05 Sep 2017, 04:42
by daninthemix
I'm new to G-sync but am already noticing problems that may be covered in this thread. I have a 4K 60hz monitor, and I noticed in most games a minor stutter (as in the occasional hitch), but in some games it's very easy to reproduce. For instance Bioshock 2, I can load a particular save and simply move the camera left or right. Either there's stutter or there isn't. These are my findings:

G-sync ON + V-sync ON - STUTTER
G-sync OFF + V-sync ON - SMOOTH
G-sync ON + V-sync ON + NV Inspector 58fps frame-limit - SMOOTH

(note: doesn't matter whether the in-game V-sync option is on or off).

This is really annoying, because while just setting a global 58fps frame cap is easy enough, I also like to stream games to my big screen TV, either via Steam Link or Nvidia Shield, and that will obviously cause stutter on a 60hz TV! I'm damned if I do and damned if I don't. :(

(I also tried overclocking my screen, thinking that a 60fps cap at something like 64hz would work fine - but the monitor will not overclock at all, not even 1hz).

Re: Blur Buster's G-SYNC 101 Series Discussion

Posted: 05 Sep 2017, 05:46
by RealNC
masterotaku wrote:
jorimt wrote: @masterotaku, I've never used SpecialK. Are you saying it does something similar to the above, but is too hard on the CPU as a result?
I think it does exactly what you want, applying the necessary wait time to cap the game at the fps you need
That's not what we're talking about here. The issue is that we don't know what FPS we need. SpecialK will not cap the frame rate if the game does not render enough FPS.

Unless I'm missing something in the settings...

Re: Blur Buster's G-SYNC 101 Series Discussion

Posted: 05 Sep 2017, 08:43
by jorimt
daninthemix wrote:I'm new to G-sync but am already noticing problems that may be covered in this thread. I have a 4K 60hz monitor, and I noticed in most games a minor stutter (as in the occasional hitch), but in some games it's very easy to reproduce. For instance Bioshock 2, I can load a particular save and simply move the camera left or right. Either there's stutter or there isn't. These are my findings:

G-sync ON + V-sync ON - STUTTER
G-sync OFF + V-sync ON - SMOOTH
G-sync ON + V-sync ON + NV Inspector 58fps frame-limit - SMOOTH

(note: doesn't matter whether the in-game V-sync option is on or off).

This is really annoying, because while just setting a global 58fps frame cap is easy enough, I also like to stream games to my big screen TV, either via Steam Link or Nvidia Shield, and that will obviously cause stutter on a 60hz TV! I'm damned if I do and damned if I don't. :(

(I also tried overclocking my screen, thinking that a 60fps cap at something like 64hz would work fine - but the monitor will not overclock at all, not even 1hz).
All the answers are in my G-SYNC 101 article:
http://www.blurbusters.com/gsync/gsync101/

If you don't want to drudge through the whole article, however, to sum up, if the framerate hits or exceeds the refresh rate, G-SYNC can no longer adjust the framerate to the refresh rate, and thus reverts to a V-SYNC state (G-SYNC + V-SYNC "On"), or V-SYNC OFF (G-SYNC + V-SYNC "Off"), which is why you need an FPS limit to keep it within its range.

And yes, I've noticed at lower refresh rates that G-SYNC can begin to stutter with G-SYNC + V-SYNC "On" once the framerate hits or exceeds the refresh rate. This is because while G-SYNC reverts to V-SYNC behavior here, there are still some differences between it and actual V-SYNC:

Image

In this scenario, G-SYNC keeps bouncing in and out of its range (above the refresh rate rate it reverts to V-SYNC behavior and delays frame appearance, but in the next delivery cycle, the framerate may drop just below the refresh rate into the G-SYNC range and show the next frame without delay, repeat, causing the appearance of stutter; delayed frame, instant frame, instant frame, delayed frame, instant frame, etc), and at lower refresh rates, this process may simply be more apparent than at higher refresh rates.

A also recommended the in-game or RTSS limiter. Nvidia Inspector adds a lot of latency with G-SYNC in particular:

Image

TLDR; It's normal behavior, use an FPS limit in game's that the framerate can exceed 60 FPS at 4k when possible to keep G-SYNC within its working range.

Re: Blur Buster's G-SYNC 101 Series Discussion

Posted: 05 Sep 2017, 08:46
by daninthemix
jorimt wrote:
daninthemix wrote:I'm new to G-sync but am already noticing problems that may be covered in this thread. I have a 4K 60hz monitor, and I noticed in most games a minor stutter (as in the occasional hitch), but in some games it's very easy to reproduce. For instance Bioshock 2, I can load a particular save and simply move the camera left or right. Either there's stutter or there isn't. These are my findings:

G-sync ON + V-sync ON - STUTTER
G-sync OFF + V-sync ON - SMOOTH
G-sync ON + V-sync ON + NV Inspector 58fps frame-limit - SMOOTH

(note: doesn't matter whether the in-game V-sync option is on or off).

This is really annoying, because while just setting a global 58fps frame cap is easy enough, I also like to stream games to my big screen TV, either via Steam Link or Nvidia Shield, and that will obviously cause stutter on a 60hz TV! I'm damned if I do and damned if I don't. :(

(I also tried overclocking my screen, thinking that a 60fps cap at something like 64hz would work fine - but the monitor will not overclock at all, not even 1hz).
All the answers are in my G-SYNC 101 article:
http://www.blurbusters.com/gsync/gsync101/

If you don't want to drudge through the whole article, however, to sum up, if the framerate hits or exceeds the refresh rate, G-SYNC can no longer adjust the framerate to the refresh rate, and thus reverts to a V-SYNC state (G-SYNC + V-SYNC "On"), or V-SYNC OFF (G-SYNC + V-SYNC "Off"), which is why you need an FPS limit to keep it within its range.

And yes, I've noticed at lower refresh rates that G-SYNC can begin to stutter with G-SYNC + V-SYNC "On" once the framerate hits or exceeds the refresh rate. This is because while G-SYNC reverts to V-SYNC behavior here, there are still some differences between it and actual V-SYNC:

Image

In this scenario, G-SYNC keeps bouncing in and out of its range (above the refresh rate rate it reverts to V-SYNC behavior and delays frame appearance, but in the next delivery cycle, the framerate may drop just below the refresh rate into the G-SYNC range and show the next frame without delay, repeat, causing the appearance of stutter; delayed frame, instant frame, instant frame, delayed frame, instant frame, etc), and at lower refresh rates, this process may simply be more apparent than at higher refresh rates.

A also recommended the in-game or RTSS limiter. Nvidia Inspector adds a lot of latency with G-SYNC in particular:

Image

TLDR; It's normal behavior, use an FPS limit in game's that the framerate can exceed 60 FPS at 4k when possible.
Thanks for clarifying. Actually RTSS would be better as I can simply run it when I play at the desk, and NOT run it when playing in the living room. Thing is I run with a non-admin account, so I'll have to see whether it's possible or not.

What confused me the most was how 'normal' (non G-sync) v-sync was butter smooth - so long as you stay at 60fps! I really do think Nvidia should do something about this.

Re: Blur Buster's G-SYNC 101 Series Discussion

Posted: 05 Sep 2017, 09:09
by jorimt
daninthemix wrote:What confused me the most was how 'normal' (non G-sync) v-sync was butter smooth - so long as you stay at 60fps! I really do think Nvidia should do something about this.
V-SYNC may be "butter smooth" when sustained above 60 FPS at 60Hz, but it introduces anywhere from 2-6 frames of input lag in that scenario as well. G-SYNC fixes this within it's range, so stutter or no when hitting its ceiling, you don't want G-SYNC to revert to V-SYNC behavior, as it will also revert to these latency levels and you'll lose all benefits of the method anyway.

And there's nothing Nvidia can do to fix this issue; if G-SYNC can't adjust the refresh rate to the framerate, it can't work the way it is intended to, period. Only real solution is ever increasing refresh rate ceilings (240Hz, 480Hz, etc) paired with systems and games that can't exceed said refresh rates. In the meantime, a -2 or -3 FPS limit takes care of the "issue" quite easily.

If the game has a framerate limiter, use it (lowest latency), if not, use RTSS when possible.

Re: Blur Buster's G-SYNC 101 Series Discussion

Posted: 05 Sep 2017, 09:41
by daninthemix
jorimt wrote: V-SYNC may be "butter smooth" when sustained above 60 FPS at 60Hz, but it introduces anywhere from 2-6 frames of input lag in that scenario as well.
Understood, but I think my confusion has arisen from the fact that "cap frame rate below refresh, otherwise input lag" has been widely published now (I noted it from somewhere, even before I bought the screen), whereas the true headline appears to be "cap frame rate below refresh, otherwise input lag and / or stutter".

Since that information is not widely published, new G-sync owners (particularly those running at 60hz) will be in for a nasty shock.

Re: Blur Buster's G-SYNC 101 Series Discussion

Posted: 05 Sep 2017, 10:05
by jorimt
Agreed.

The lack of detailed information directly from Nvidia on these points and others with G-SYNC is what drove me to do the research and write the article myself.

To be fair though, Nvidia has explained a lot of this, albeit in vague (difficult to find) PR form. But then again, if they had tried to break it down like I did, the average user probably wouldn't have the patience to fully absorb and comprehend the limitations of G-SYNC anyway.

Darned if they do, darned if they don't situation really.