Weird framerate issue: Disable VSync => Enable VSync => Solid 60 fps

Hi everyone,

I ran into a weird framerate issue while setting up RetroArch on my new Windows 10 PC and would really appreciate your help.

PC system:

  • Intel i3-7320 4,1 Ghz / Intel HD Graphics 630 / 8 GB DDR4 Ram
  • Windows 10 with latest updates and drivers
  • Connected via HDMI to Sony Full HD LCD TV

RetroArch Settings:

  • Default settings, i.e. no GPU hard sync, no frame delay
  • fullscreen mode
  • gl video driver
  • Windows 10 screen refresh rate set to 60p (it was 59p by default after installing)

What causes the issue:

  • Load SNES Core Higan, BSNES Accuracy or Balanced (nothing else tested so far)
  • Load Content (SNES rom, no matter which one)
  • Games run 100% fine at 60 Hz
  • Load shader preset (i.e. CRT-geom), CG or GLSL
  • RetroArch menu drops instantly to locked 30 Hz, game stutters, sound is cracking (Saved shader as core setting at this point for further testing)

Workaround:

  • Disable VSync and everything runs INSTANTLY perfect at 60 frames (however with tearing)
  • You can watch the “Estimated screen refesh rate” (Video settings) rising up from 30 to 59,999 Hz again
  • Now it gets interesting: Enable VSync again and it STAYS PERFECTLY FINE with no framerate issues whatsoever (!!!)
  • Loading another game content without changing the core causes no issues, still smooth 60 frames

Problem with this workaround: When you restart RetroArch and load up the core again and start up a game you have locked 30 frames again :frowning: The same happens when selecting the game via the Playlist. You need to disable and enable VSync everytime to have solid 60 frames again!

What I have tried so far without luck:

  • Set Intel HD graphics to High Performance
  • Setting Windows 10 back to 59p :wink:
  • Enable GPU hard sync
  • Selecting other CRT shaders like Lottes or Royal
  • Re-installing RetroArch

Can someone please tell me what is going on here?! And hopefully what I can do to solve this issue?

Toggling VSync Off and On again shows that my PC should have no problems with Higan in combination with the CRT-geom shader.

Best regards Yamato

Do other cores act the same or are they okay?

Yes, it is exactly the same with…

  • Nestopia UE
  • Beetle PCE Fast
  • Snes9x
  • Genesis Plus GX

(tested so far)

As soon as I load up CRT-geom shader via the Quick Menu the RetroArch Front End as well as loaded games begin to stutter while the Estimated Screen Framerate sinks down to 30 Hz.

Disabeling VSync, waiting for the Estimated Screen Framerate to go back to 60 Hz again and re-enabling VSync solves this issue as described in my 1st post. Then every games runs smoothly at 60 frames per second.

1st new observation:

I noticed that this “trick” only works when a game is loaded. If you just load a core and select the CRT-geom shader via the Quick Menu then disabling VSync changes nothing. The Estimated Screen Framerate stays at solid 30 Hz then when no game content is loaded.

2nd new observation:

The issue occurs in fullscreen mode only!

And you said it’s the same regardless of which shader you use? Can you try one that we know is very fast, like crt-pi?

With CRT-Pi the framerate stays stable.

Please note that I edited my last post: The issue occurs in fullscreen mode only.

Ok, that sounds like it’s just not able to hit full speed with those shaders. From my experience, even the older HD4000 can run crt-geom full speed at 1080p, so I’m guessing you have a 1440p or 4K display…?

I’m afraid no. The PC is connected to a Full HD 1920 x 1080 Sony LCD TV via HDMI. Windows resolution is set to 1080p.

The weird thing is that my system CAN run all listed cores (even Higan) with CRT-geom shader at 60 frames per second with absolutely no frame drops. But FIRST you need to disable Vsync and enable it back again as described above (see “Workaround”). All this is happening in full screen mode only.

So what’s wrong with my setup / settings / with RetroArch? Why does the refresh rate go down to 30 Hz and stay there when booting up crt-geom shader (or crt-royal, lotte etc.) in fullscreen mode? :frowning:

Can you try opening your retroarch.cfg in a text editor and see what is in the video_refresh_rate line? Try changing it to video_refresh_rate = “59.950001” or “60.0”

Sorry, changing to these values didn’t work :slightly_frowning_face:

I found a solution! :smile:

  1. Open the Control Panel for Intel graphics (right click on Windows 10 desktop => Intel Graphics Settings)

  2. Go to 3D Settings

  3. Chose RetroArch.exe and set Vertical Sync to “on” (standard setting was to use application settings, so this has to be turned off). RetroArch’s own VSync setting gets bypassed now.

  4. Restart RetroArch. Now everything runs at 60 fps right from the start. Vertical Sync is still active, so no tearing :grin:

Maybe this issue can be solved within RetroArch in the future?

Many thanks to hunterk for trying to help me solving this!

1 Like

Oh this issue used to drive me nuts back in the day. Happened when running intense cores, capturing screenshots, changing settings or shaders on the fly, using reshade, setting hard sync frames to 0, saving/loading states, and a long etc…

One of the best features of RA is its wonderful vsync implementation. You don’t want to bypass it, Windows vsync lags quite a bit. I think the problem here is that in a double buffer vsync scenario (which is a standard I believe), when for whatever reason the computer can’t run the program at the desired frame rate, it (the frame rate) gets halved. And it often stays like that until the video system is refreshed/reset. Which can be done manually by fast forwarding, disabling and re-enabling vsync like you were doing and so on. But that’s not convenient.

The way I fixed it (nvidia card): force a triple buffer. I’m pretty confident that it will help you too. You might get an extra frame of input lag by doing so though. One frame is easy to compensate with hard sync or run-ahead anyway. In my particular case, I got my frame back by being able to run practically every core with 0 hard sync frames (which I couldn’t always do without randomly running into the problem you described until I forced triple buffering). And even if it wasn’t, a frame of input lag would still be a small price to pay for 60 constant fps neatly sync’d by good old RA : )

And by the way, this is not exclusive to RA. Triple buffering has also fixed the same issue with many other emulators, particularly stuff that I need to run with reshade, like Dolphin, ppsspp, NullDC, Demul, SSF, PCSX2, Supermodel…

Squalo, thank you very, very much for your detailed explanation and assistance!

Unfortunately my Intel Graphics control panel does not give me any option to active triple buffering. I’m using the built-in Intel HD Graphics 630 as I’m emulating 8 to 32 bit systems and Mame so I did not invest in a separate gpu card.

You are welcome, Yamato. That intel chip seems recent enough. Maybe you could try to update the drivers and/or find this menu.

I’m still confident that if you manage to force triple buffering, you will fix the issue.