joncampbell123 / dosbox-x

DOSBox-X fork of the DOSBox project
GNU General Public License v2.0
2.82k stars 383 forks source link

Libretro core #893

Open Margen67 opened 6 years ago

Margen67 commented 6 years ago

I noticed there's a RetroArch core for the original DOSBox, but not DOSBox-X. I found a request on reddit but nothing on the issue tracker. Much like the creator of the reddit post, I would also like to see DOSBox-X core as it's better than the original DOSBox.

joncampbell123 commented 6 years ago

Sounds good to me, but I personally don't have any interest in implementing it at this time.

What does it take to add DOSBox-X to the libretro project?

Margen67 commented 6 years ago

I'm not sure, but perhaps these might help: https://github.com/libretro/dosbox-libretro https://www.libretro.com/index.php/develop/

andres-asm commented 6 years ago

Well.. I don't think DOSBox iterates per-frame so it can be a bit complicated. For original DOSBox that fork was quite stripped so it's hard to backport.

I have a new fork up-to-date with the latest DOSBox SVN that should be easier to adapt.

The biggest issue is the buildsystem, for libretro we prefer static makefiles. https://github.com/fr500/dosbox-svn/tree/libretro

From what I've seen with DOSBox-X it's more compatible but has no dynamic core right?

sikthehedgehog commented 6 years ago

Probably a good start would be to make a list of what had been stripped in that DOSBox fork (I imagine that it's just about everything UI, since that'd be RetroArch's job?). Even if nothing comes out of it, at least it could give a good clue as to what could use with more decoupling if needed (to help untie the core from the interface).

andres-asm commented 6 years ago

no the stripped core strips SDL basically because they don't like dependencies. It wasn't a good reason and in the long run it hurt the core (no auto cycles, no cdrom, stubbed timers, stubbed threads)

The SDL mapper can go, the rest can be kept, no reason to remove things.

As far as I can see the general architecture seems to be mostly the same, so the same skeleton could be used (from the SVN core)

yksoft1 commented 6 years ago

@fr500 It has dynamic core but only for x86-32, not for x86-64 or arm platforms.

andres-asm commented 6 years ago

Ah, so dynamic_x86, not dynrec I thought the new dynrec was less hacky, more accurate, even though it's slower.

DYNREC is by far slower but it's quite nice in that it can accomodate a bunch of different backends. I have my core running with dynrec in AARCH64

I'll take a stab at making a simple libretro port this weekend if I can figure out building under msys2

andres-asm commented 6 years ago

Seems a number of internal things have changed, so the architecture is not.. identical I tried a port but ran into issues, control->Init(), etc stuff is different now. mixer has some new members in some functions, etc.

Furthermore the current dosbox libretro is a gigantic hack on top of the surface renderer. Does dosbox iterate per-frame? (my guess is not)

I think a completely new port would be better than trying to use the new one. The libretro API is rather simple, getting to know an emulator from within is not though.

evbo commented 3 years ago

@fr500 have you looked at dosbox-svn libretro core? It is the state of the art for libretro from what I understand and might offer more insight:

https://git.libretro.com/libretro/dosbox-svn

Having dosbox-x as a libretro core would be amazing. You could run win95 on Lakka! I already do this with win3.1 and it works great.

toddfraser88 commented 3 years ago

Is there anyone else interested in having dosbox-X as a retroarch core? or there's just not enough interest in it?

ghost commented 3 years ago

Dosbox-x on retroarch would be great

coppermine733 commented 3 years ago

I would like to see this as well

Ric-82 commented 2 years ago

I'd like to see dosbox-x as retroarch core, especially if it will run on Android too.

RaouleMenard commented 2 years ago

I'm also looking forward for Dosbox-X as a RetroArch core.

For Android support with gamepad - as I plan to use it on a Retroid Pocket 2+.

Mostly for playing Windows 95/98 games and Nec PC98 support - RetroArch already have the Dosbox Pure core which is perfect for normal Dos, but not for Windows nor PC98.

evbo commented 2 years ago

Update: the dosbox-core Feb 2022 release installs windows 95/98 easy (no major graphics emulation issues like with other cores listed above that comment):

https://github.com/schellingb/dosbox-pure/issues/105#issuecomment-1046069386

Unfortunately even with a 3.4 GHz processor I cannot run any games at reasonable speed, so hopefully this may inspire dosbox-x to release a core too :)

evbo commented 2 years ago

This is not a panacea by any means, but if you're willing to let go of some conveniences libretro cores provide, I just found this core that will run arbitrary bash commands: https://github.com/SwedishGojira/libretro-bash-launcher

What this means is you can run it just like any other core and then start dosbox-x as a standalone Linux process rather than libretro core. Not perfect, but dang near close!