Hi, Tatsuya! Thanks for taking the time to participate in this thread.
I have tried removing this condition, also this swap 4 limit, but at that point I realized something:
I think what some of us are seeing here is an effect of emulators having variable frame times.
That’s why, having working VRR setups, we only see this subtle effect in RetroArch and not in native games: as I said, even OpenTyrian, Taradino or Chocolate Doom, which are 35 FPS games, have good frame pacing. In Ship of Harkinian, I can set framerate to 54 FPS or some other crazy exotic value and it looks perfectly smooth.
But on emulation, it’s different once we leave the classic “activate vsync and synchronize emulation to that” paradigm: you let the emulator impose the framerate, the frame times won’t be steady and the monitor won’t be able to keep up with these variable frame times.
I have found more information this old thead on the BlurBusters forum. It’s administrator is the most knowledgeable person in the world for this kind of problems, and has contributed with libretro in the past.
From there:
For proper fluidity on VRR displays, your refresh cycles is controlled by the exact timing of the pageflip.
So…when you’re in VSYNC OFF mode or VRR mode please use microsecond clocks for timing your framebuffer flips in your emulator source code!.
This will reduce microstutter issues for software-triggered display refresh cycles (which is what GSYNC and FreeSync essentially is) especially for strongly fixed-Hz content such as videos and emulators.
Basically, when programming for a VRR display, you’re now doing the equivalent of software-based VSYNC ON that’s lower lag than waiting for a monitor’s next fixed refresh cycle (for a non-VRR display).
To successfully display fixed-Hz material (emulators, videos, etc) in a way that is as microstutter-free as true VSYNC ON, but without lag of VSYNC ON, you have to have really pristine framepacing accuracy.
Do not use uncompensated millisecond-accurate timers, you may have to intentionally do a micro-busywait loop (a few tens or hundreds microseconds) within your timer event, to intentionally re-align your next frame buffer pageflip to a more exact interval since the last framebuffer flip […]
@GemaH The effect we’re talking about (essentially “movement is not as smooth with Sync to Exact ON as it is with classic VSYNC only”) is very, very subtle, and I dare to say most people won’t even notice it unless purposely looking at it, and even so, I bet it depends on how each person perceives movement “continuity”.
I am glad you don’t see it, but I think the problem is there on any monitor because apparently it has do do with how emulation itself works (unless somehow compensated for, as apparently standalone MAME does).