dimitrikarpov / retroarch-js

1 stars 1 forks source link

More platforms #2

Open Impre-visible opened 11 months ago

Impre-visible commented 11 months ago

Hi, I was wondering, would you add more supported platforms ? Like PS1, N64, more Sega platforms. Thanks

dimitrikarpov commented 11 months ago

Hi! Yes, I plan to add more compiled cores. Not sure about PS1, not all retroarch cores can be compiled for web. List of all web compiled cores can found in official retroarch build web.libretro.com. And You can try to compile core yourself with this manual

Impre-visible commented 11 months ago

EmulatorJS support the PS1 emulator, but it's not made for react, so maybe it's possible to emulate PS1 on web

dimitrikarpov commented 11 months ago

Did not know that. Thanks for sharing. So, now we can build cores for PSX. Only one thing left, I have to figured out how to load bioses. My package cannot use third-party bioses for now.

dimitrikarpov commented 9 months ago

EmulatorJS support the PS1 emulator, but it's not made for react, so maybe it's possible to emulate PS1 on web

EmulatorJS is awesome! So, I tried to make react wrapper around it. And it works. Soon I will deploy this wrapper to use instead of my library. With typescript support. It is too hard to support many cores. EmulatorJS team did good job at this. Also EmulatorJS has good UI and tons of settings.

Screenshot from 2023-12-03 09-24-33 Screenshot from 2023-12-03 09-28-12

And component API will looks like this image

dimitrikarpov commented 8 months ago

react emulatorjs wrapper has been released https://www.npmjs.com/package/react-emulatorjs?activeTab=readme Now You can use emulatorjs in react projects

also check online react-emulatorjs playground https://dimitrikarpov.github.io/react-emulatorjs/

predadorBR commented 6 months ago

I've already used emulatorjs a lot, I liked your project because it's an alternative, I'm wanting to work on netplay, and I really appreciate your examples, I'm taking the logic of the codes from both and trying to put them together and it's working, I'll be looking at more of your examples. zero, congratulations on the examples and documentation.

dimitrikarpov commented 6 months ago

Thanks for feedback.

But now I am focused more on react-emulatorjs than retroarch-js. When I started retroarch-js I just want a easy solution to embed retroarch in to my react projects. All solutions was not single page apps friendly. This behaviour was designed by original retroarch. This is how original retroarch manages with wasm binaries. But it was not a huge problem. Using some tweaks we can recompile retroarch cores to incapsulate their environment variables in esmodule closure, instead of using global variables. The problem is to find wich versions of cores would work properly after recompiling, because to recompile we have to use git sources of cores and not all of them are quite stable at time of recompile. And with full-time job I don't have enough time to keep cores up to date with retroarch project and finding ways to compile new cores. And some stange bugs with gamepads. But I still have some ideas of evolving this approach, such compile only core without gluing retroarch native frontend and using web api for gamepads support.

Then I try incapsulate in browser's iframe instead of es modules and this works. Also it works well with emulator-js. So I created a react wrapper. And it is fits my initial goal: easy implementation in to react projects. Also it gaves huge amount of supported core, cool UI and powerfull features. I just add typescript support that reflects emulator-js options for better developer experience.

Also emulator-js team created CDN and now no need to download cores on own server. Just install react-emulatorjs wrapper and this is it.

Also netplay in roadmap of emulator-js team. So sooner or later it would be implemented.

So, You can check react-emulatorjs wrapper with updated docs, quick start and onlne playground. https://www.npmjs.com/package/react-emulatorjs?activeTab=readme

P.S. Also I thinking about creating just js iframe wrapper as Web Component to use this single page approach in any js app or js framework, like svelte or angular.