Retroarch Tutorial

I’m hoping some of you godlike individuals can clarify how some of Retroarch’s finest features work and how to properly use them for the sake of education. I’ve been using Retroarch a while now and while I simply find it to be the greatest thing since sliced bread, there plenty who do not due to the daunting amount of options, adjustments, and customization adjustments that are available in the front end that scare many people away because they don’t know where to start. I’ve told people what program I use after they see me playing old games like a boss on my phone with an XBOX One controller attached to it. I find myself not being able to simply tell them a three step process to get them going because I know how complex Retroarch is.

There are a lot of “tutorials” on You Tube that stop way too short after initially installing the program. They never go into explaining the latency adjustments and how to properly use run ahead, how to properly remap controls per core or per game, how to save overrides for cores or games or explain the benefits of a game options folder…you know…just some of the things that make Retroarch the definitive platform. My aim is to make a video tutorial unlike any other which can guide a beginner on not just downloading a core and scanning playlists, but how to operate the fundamental adjustments and options so they can know what to do if they experience less than stellar performance which easily happens across the massive array of hardware that is available to use with Retroarch.

So with all that being said I am really wanting to make sure that I actually understand how few adjustments actually work so I’m not talking out of my ass when explaining things. These adjustments are hard GPU sync frames, frame delay, and threaded video. I used to stack frame delay frames on top of the hard GPU sync option until I saw a response to someone else’s question by the legendary Hunterk who said that there is no point on stacking these two adjustments since they pretty much do the exact same thing. I’ve seen it explained that latency is reduced with frame delay by delaying the rendering of the frame until it is absolutely time to display the frame. So what I take away from that this is not a “higher the better” adjustment but rather finding the right amount of frames until the game starts to stutter which is the point of where you’re no longer giving the system enough time to render the frame before output. GPU hard sync from what I understand is the GPU figuring this out and doing all of this automatically so stacking frame delay on top of GPU hard sync would be pointless. The “GPU hard sync frames” adjustment is one that mystifies me a bit. The closest relation I have to this adjustment is the buffered frames adjustment in Far Cry 3 where the higher you set it, the smoother the game will run but the more input latency you will have. I usually have this set to 0, but on cores like Mupen64Plus and Beetle Saturn I have to have it set to 1 or the games will stutter badly. So my understanding is that this is the same or similar to the buffered frames adjustment on Far Cry 3 that allows a number a frames to be drawn by the CPU ahead of time to switch out to always make sure that there is one ready at the expense of the frames displaying a little late. Last is threaded video. I’ve never had to use this until it came to Beetle Saturn because my Core i5 2500 is just under fast enough to play all games at a constant 60 frames especially games like Thunderforce V and Powerslave where the frames can dip below 60 to around 56 often. From what I’ve read, threaded video to my understanding is pretty much an automatic frame skip where instead of the games speed slowing down it simply drops the frames that it doesn’t have time to render at the expense of the audio stuttering because it drops out along with it but the game plays at full speed. I’ve played Thunderforce V with threaded video on and it has always remained very playable and the frame dips went largely unnoticed since the game usually doesn’t go lower than 56 frames which seems to be high enough not to produce any issues with the audio and missing only 3 to 4 frames out of 60 isn’t really noticeable when playing a fast game like Thunderforce V. With threaded video off it is very noticeable when the game slows down and is unplayable by my standards. When it comes to Powerslave which has moments where the frames can dip down into the low 50s, threaded video can assist in making the drop not as bad, but will not bring the game back up to 60, but seems to add up to 4 frames so it doesn’t appear to me to be a “drop as many frames as it takes to stay at 60” adjustment like many autoframe skips do and only seems to help if your system is just barely not rendering 60 frames.

So that is my understanding. If my understanding is somewhat correct or not correct at all I would love to actually know for the sake of not looking like a complete idiot in the video that I plan to do. If you’ve made it this far, thank you for taking the time to read all of this. I really want to help beginners understand this amazing frontend.

I may have been mistaken on the frame delay / hard GPU sync thing, actually. I’ve heard people use both of them at the same time and I can’t say for sure that it doesn’t stack, so :man_shrugging:

Regardless, Hard GPU Sync is using glFenceSync to know exactly when it needs to create a new frame. The number of frames is like the allowance. So, 0 means get it in that same frame no matter what, while 1 means get it within the next frame. This option increases the CPU load quite a bit, so a lot of people use 0 for most cores and then drop back to 1 frame for very heavy cores like beetle-saturn.

You’re exactly right about frame delay. It just holds off on emulating a frame by X milliseconds, so you want it to be set as high as possible without causing problems.

Threaded video runs the audio and video in separate threads, so they’re not as tightly coupled. This leads to stuttery video but, as you found, is more tolerant of uneven frame times and frame drops. If you run shaders that are too heavy for your GPU with it, it has the interesting effect of being exactly like frameskip, where the game keeps emulating at the normal speed but it only shows as many frames as it can generate.

1 Like

Also, if you use Vulkan, it’s supposed to be similar to gl with hard sync frames 0 by default. But you can reduce lag further in Vulkan by setting Max Swapchain Images to 2. That’s similar in CPU load to gl with hard sync frames 0, since I have to set it back to 3 for cores like Beetle Saturn to avoid crackling. I haven’t seen any objective tests yet to really know how much of a difference there is between these drivers and settings though.

1 Like

Thank you very much hunterk and Awakened for your quick responses. It would seem logical that frame delay wouldn’t stack on top of hard GPU sync especially after you’ve explained glFenceSync and since I have great difficulty trying to feel a difference when I have them stacked vs. not stacked. Either way I’m glad I know how it works so I can explain it. Just one more question on the swapchain images adjustment. Is that the built glFenceSync like option for Vulkan? I don’t use Vulkan because my hardware really seems to like OpenGL so I don’t have much experience with it other than it seems have less graphical glitches when using the Beetle Playstation HW core. Thanks again guys.