libretro / dolphin

Dolphin is a GameCube / Wii emulator, allowing you to play games for these two platforms on PC with improvements.
https://dolphin-emu.org/
GNU General Public License v2.0
86 stars 68 forks source link

Sys folder not recognized Dolphin retroarch 64 [Android] #316

Open OlliSagi opened 1 year ago

OlliSagi commented 1 year ago

Hello everyone,

I'm facing an issue with the Dolphin 'Sys' folder detection in Retroarch. Here's a rundown of my situation:

Downloaded the core from Retroarch 64. Used the "online downloader" for the dolphin-data.zip and unpacked it in the correct folder. Checked the core settings which indicate:

Firmware: (blank)
(!) Present, Necesarry: Dolphin Sys folder
(!) You need the Dolphin 'Sys' folder in 'system/dolphin-emu'
(!) Check https://docs.libretro.com/...
[Libretro Docs Reference](https://docs.libretro.com/)

Suspecting a version mismatch:

I downloaded the Sys folder directly from GitHub and placed it in the 'system/dolphin-emu/' folder. But the issue persists. I verified the retroarch.cfg in 'Android/data/com.retroarch.aarch64/files' and confirmed the correct path:

system_directory = "/storage/emulated/0/RetroArch/system".

This path matches what I see in Retroarch's folder browser.

When attempting to run a game, it crashes post a brief display of discolored blocks.

I've exhausted my troubleshooting methods. If anyone has faced this before or has any suggestions, I'd greatly appreciate the help.

Btw I'm trying to load .rvz gamecube roms.

i30817 commented 11 months ago

If you're trying this in android, I should mention that the only way I got android dolphin to work was to use the buildbot version of RetroArch with the .aarch64 substring in the filename that can be installed independently of the one you auto get on the website.

That doesn't mean that version of RetroArch is newer. In fact, it's the exact opposite, I think. This core is just so outdated, it only runs on a older video driver code (I believe it has a single video driver called 'android' iirc) that is kept on a buildbot single utility 'run dolphin libretro'. As opposite to the one you probably have, that has vulkan and gl drivers (although that's slightly misleading, there are android parts involved in those too, it just detects the os at runtime).

Edit: from testing bellow I can't even tell how it worked anymore so don't try the above.

Resuming, you should just use the actual dolphin in the playstore, at least until a new porter comes up to update this core, like it's currently happening with citra, and will probably not happen with PS2 (because it was done and ignored, too bad).

zorn-v commented 11 months ago

I believe it has a single video driver called 'android' iirc

There is no such driver there :smile: For android used same drivers - OpenGL (GLES actually) and vulkan.

BTW, I tried to update this core also but seems there some significant changes (removed bEMUThread option which is "false" in libretro core but "considered true" in current master) and we stuck in RunGpuLoop I've left it for now

Anyway, I'll open draft PR so anyone can use my fixes and go on

i30817 commented 11 months ago

I think I was confused with the android input driver.

But I really really think I previously \ installed (and uninstalled) a version of RetroArch that loaded the dolphin core in android. I tried the buildbot but couldn't actually find one that works right now (tried 1.9.0, 1.13.0, 1.15.0 and 1.16.0).

The actual reason dolphin crashes is ("Requesting OpenGL context, but RetroArch is compiled against OpenGLES. Cannot use HW context.")

Anyway... Use upstream playstore dolphin.

i30817 commented 11 months ago

BTW, I tried to update this core also but seems there some significant changes (removed bEMUThread option which is "false" in libretro core but "considered true" in current master) and we stuck in RunGpuLoop I've left it for now

There is no way dolphin can be accurate without controlling its own threading\event loop, that was the original sin of the first port that caused all the crashes. Including on changing settings. Or individual games that require bEMUThread to true (like that Castlevania game in the game store).

zorn-v commented 11 months ago

The actual reason dolphin crashes is ("Requesting OpenGL context, but RetroArch is compiled against OpenGLES. Cannot use HW context.")

Seems like you use VERY OLD version. Current libretro detect OpenGL/GLES properly I think https://github.com/libretro/dolphin/blob/2f4b0f7902257d40a054f60b2c670d6e314f2a04/Source/Core/DolphinLibretro/Video.cpp#L370

i30817 commented 11 months ago

It's actually 1.16.0 🤷

Well the actual last lines are:

[Environ]: GET_VARIABLE: dolphin_renderer = "Hardware"
[Environ]: SET_HW_RENDER, context type: gl.
Requesting OpenGL context, but RetroArch is compiled against OpenGLES. Cannot use HW context.
[Environ]: SET_HW_RENDER - Dynamic request HW context failed.
[Environ]: SET_HW_RENDER, context type: gl.
Requesting OpenGL context, but RetroArch is compiled against OpenGLES. Cannot use HW context.
[Environ]: SET_HW_RENDER - Dynamic request HW context failed.
[Environ]: SET_HW_RENDER, context type: gl.
Requesting OpenGLES3 context.
Reached end of SET_HW_RENDER.
[Environ]: SET_HW_SHARED_CONTEXT.
24:37:276 DolphinLibretro/Boot.cpp:121 N[Video]: Using GFX backend: OGL
24:37:277 DolphinLibretro/Boot.cpp:125 E[BOOT]: Could not boot /storage/emulated/0/RetroArch/downloads/Nintendo - Wii/Resident Evil Archives - Resident Evil (USA).rvz

[Content]: Failed to load content
[Core]: Content ran for a total of: 00 hours, 00 minutes, 00 seconds.