Libretro2joy

[h]libretro2joy[/h]

How to compile the library


git clone https://github.com/lifning/libretro2joy.git
cd libretro2joy
make

Simple USB gamepad emulator, might be useful in some very specific circumstances. It started as an idea to use RetroArch’s netplay feature for certain PC games, though it’s not useful for that in its current state.* Currently Linux-only, as it is implemented with uinput. Perhaps it would at least be useful for “use your Pandora/RaspberryPi/Android/etc. as a WiFi PC gamepad” type hacks, for now.

  • At the very least, Dustforce de-synced when I tested across LAN. It would probably need to capture certain SDL and/or OpenGL calls to attempt to control the target game’s framerate, which would obviously limit compatibility. And if it comes down to capturing SDL calls, it may as well just emulate SDL’s Joystick API directly too… So that would probably be a separate project.

Pretty cool hack :smiley: To actually synchronize stuff over netplay though you’d need to make sure that: Game runs exactly as fast as the other computer (per-frame), all “randomness” (RNG, uninitialized memory, etc) are exactly the same. Might not really be doable without crazy, crazy hacks :wink:

Interesting! Thanks for sharing it. I’ll try to do some testing :smiley:

Thanks. It might be plausible to just run the game on one machine and stream the A/V to player two’s, assuming low enough latency for it to be playable.

Maybe hook into the video recording stuff, and let the user choose ZMBV, FFV1, or h.264 codec. They all have various latency, bandwidth and CPU requirements.

h.264 with zerolatency profile might be best for that. ZMBV is too slow and FFV1 is too big.

And I suppose opus would need to be used for audio…