libretro / libretro-uae

PUAE libretro
GNU General Public License v2.0
112 stars 60 forks source link

No keyboard events passed in "game focus mode" when run-ahead is globally enabled #468

Closed bidinou closed 2 years ago

bidinou commented 2 years ago

Hi !

Using the latest RA (snap packages) and puae core, I noticed that the keyboards events are not passed when enabling both "game focus mode" (general settings) and "keyboard pass-through".

HOWEVER, they are passed when using the pass-through without the focus-mode - which is not optimal because one has to unbind all RA events. <-- this bit is actually wrong, see below

Thanks a lot for your commitment in improving the puae core, that is SO much appreciated :-) cheers

(configuration : Linux, KDE-Neon (based on Ubuntu 20.04 + up to date KDE stack), snap packages of retroarch, Vulkan)

sonninnos commented 2 years ago

That core option is pretty much a relic from the time when RetroArch did not block keyboard events when they are used in hotkeys etc, but then again the core did not use frontend key events then either, so there is no wonder it does not work anymore as intended.

Without it for example default keyboard settings would send joystick directions and keyboard arrow keys at the same time when using the keyboard. And currently the frontend blocks it from happening, so the core option can not do anything. And it only applied to keys that are used as RetroPad buttons.

Frontend "game focus" simply allows keyboard events to go to the core uninterrupted. What is it that you are trying to do exactly that you need the core option? How old are the snap packages..?

With "game focus" I can type no problems and the core option does nothing.

bidinou commented 2 years ago

Hi ! Thanks a lot for taking the time to reply. I'm actually using the latest snap packages. What happens is, when using "game focus" & "keyboard pass-through", I cannot use my keyboard for Amiga apps using the keyboard. For instance, interactive fictions. If I don't use the "game focus" mode but still use "keyboard pass-through", the problem is obviously that some keys trigger RetroArch events (but the other keys are passed to the Amiga program).

bidinou commented 2 years ago

Hmm. Actually, I tried again, and the "pass-through" option doesn't actually seem to make a difference. So with or without game focus, I actually cannot send characters to the Amiga app.

Maybe I'm overlooking something.

bidinou commented 2 years ago

OK ! So, the culprit setting is... Enabling run-ahead !! Even though it's not supported, it does prevent the keyboard from working for some reason. Now I need to find a way to enable it for other cores without preventing the Amiga core from working properly :)

bidinou commented 2 years ago

Okay, so, it turned out... It's a general RetroArch issue as it also affects the DOSBOX core ! So I filed a bug accordingly here : https://github.com/libretro/RetroArch/issues/13261

sonninnos commented 2 years ago

The core actually successfully disables run-ahead at startup, but apparently not when second instance is also enabled.. Same thing applies to changing disks. As in it can't recover to normal state if second instance is enabled at startup, and stays forever broken.

So yep, these (keyboard events + disc control) are frontend related and can't be fixed here, meaning these can be closed.