The delay experienced between entering commands and seeing them on the screen is one of the main problems in the world of emulation when it comes to transferring the gaming experience from old consoles to modern devices. Seriously, a slight lag between when the button is pressed and the action you see can basically ruin the whole game experience. The multi-platform emulator RetroArch, which serves as frontend for the API Libreto, just released a new version capable of reducing the latency to the point of even improving the reply speed of the original consoles it emulates.
Consoles constantly redraw the onscreen image with a refresh rate depending on the machine in question. On a Mega Drive for example, there’s a difference of two frames between the push of a button and the image. Two, almost imperceptible, frames is what it takes Sonic to start jumping from the moment we give the command. This small delay is what RetroArch uses to distort the input lag.
Continuing with the Sonic example, RetroArch shows us the information on the screen with a two-frame delay, even though the previous frames have been processed. This way, the emulator can skip upcoming frames when we press a button, which makes up for the delay produced with the input lag with the permanent advancement shown. RetroArch will always be two frames ahead, so if the input lag of the original console is less, the end result will improve the original latency. This is exactly what we can see in the following video of Super Mario Bros from NES, a console that only refreshes the frame after the button is pressed.
This feature is available from RetroArch 1.7.2 in most versions, including Android, which is the one we care about. To activate it, we have to go to Settings > Latency, and activate Run-Ahead to Reduce Latency.
This isn’t the only new change, though. The Windows version includes tons of new features like the possibility to get native resolutions to connect low-frequency CRT monitors (hello, arcade cabinets), as well as improve the drivers for Direct3D and Vulkan, and make it easier to map the controls for each platform.