libretro / RetroArch

Cross-platform, sophisticated frontend for the libretro API. Licensed GPLv3.
http://www.libretro.com
GNU General Public License v3.0
10.09k stars 1.81k forks source link

[Question] Pepper Plugin for Electron / NW.js #4947

Open LukasBombach opened 7 years ago

LukasBombach commented 7 years ago

Hey, there is a (super small) custom pepper plugin that uses mpv C API + mpv to enable access to OpenGL in electron (so mpv can draw on it). MPV is a video player and this enables video support in electron. I wonder if it is possible to do the same with RetroArch and if this would be difficult. Someone also used that plugin and made a standalone version out of this.

RobLoach commented 4 years ago

Are you asking about a mpv core? RetroArch itself isn't built on Electron. There is the ffmpeg core though.

LukasBombach commented 4 years ago

No I am asking if it is possible to display RetroArch inside an Electron application using a pepper plugin (PPAPI). Because I would like to write a retro frontend with Electron (because writing elaborate and fancy UIs with web technologies is so easy) and run emulators in that Electron app.

What the linked MPV plugin does, is run an instance of the MPV player and tunnel its graphical output into electron using PPAPI

RobLoach commented 4 years ago

There was some investigation of getting a web/desktop frontend over at https://github.com/maddox/kart , but that's VERY old. Certainly possible, performance could be an issue.

LukasBombach commented 4 years ago

That is why I would be aiming for PPAPI (Performance) although I just learned that WebAssembly may have up to 95% of the "native" performance and I have seen you already have that as a compile target. So it might be worth investigating the performance of that, it may already solve the problem.