libretro / RetroArch

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

Retroarch crashes when using certain cores #13942

Open thatgirlsarah opened 2 years ago

thatgirlsarah commented 2 years ago

First and foremost consider this:

Description

When I use certain cores٫ the app crashes.(video is linked below)

https://user-images.githubusercontent.com/68525892/169051631-425a604d-6a11-46aa-bf8f-be7bb910fab1.MOV

Expected behavior

For the game to play normally.

Actual behavior

The game is unplayable٫ causing the app to crash

Steps to reproduce the bug

  1. Open a game
  2. Choose a core
  3. App will crash afterwards

Bisect Results

This happened when I downloaded it for the first time around March.

Version/Commit

You can find this information under Information/System Information

Environment information

hizzlekizzle commented 2 years ago

Unfortunately, we don't have any dedicated iOS developers, so it's hard for us to keep abreast of these sorts of issues. I know N64 is a problem due to iOS/macOS/tvOS' poor OpenGL drivers, and I tried to make ParaLLEl-N64 fall back to software rendering on these platforms to avoid the issue, but this doesn't seem to help much on iOS, though it works great on macOS.

thatgirlsarah commented 2 years ago

I could contribute but I'm just learning how to code. And I don't know if you guys can hire minors(I'm 16 btw).

hizzlekizzle commented 2 years ago

We don't hire. We're all volunteers and we're always happy to see new contributors. If you spot a problem and can come up with a solution, drop us a pull-request and we'll take a look :)

ghost commented 2 years ago

Should keep this issue open if it's not fixed.

stevenjamescox commented 2 years ago

@thatgirlsarah I've had the same problem with ParaLLEl-64 on iOS but have found success with the Mupen64 Plus Next core for iOS: download link.

I'm not familiar enough with the RetroArch buildbot systems & practices to know why this core isn't built there for iOS (nor tvOs or macOS). @hizzlekizzle do you what the process is for getting cores added to the nightly build system for particular platforms?

hizzlekizzle commented 2 years ago

It's typically just a matter of adding the platform to the gitlab-ci.yaml. I haven't had luck building mupen64plus-next for macOS, though, using github's "actions" CI, which is roughly similar to the gitlab CI we use internally.

Did you build that core yourself? if so, did you need to do anything special to get it working?

stevenjamescox commented 2 years ago

Very interesting.

I did not build that core myself. I found it inside of a sideloadable RetroArch iOS app. I don't remember which. I took its mupen64plus_next_libretro_ios.dylib and included it the modules folder for iOS within my Xcode project files.

I previously attempted to build mupenplus-next for iOS (& tvOS) using the shell scripts at libretro-super but get the error libretro_build_core:Unknown OpenGL setting for mupen64plus-libretro-nx: "-libretro-nx_build_opengl". I don't yet know the syntax to configure the OpenGL setting for the script.

I bet that @MDOBreno knows how to do it. He posted some tvOS cores he compiled in this issue thread.

I'm not sure what the exact status of OpenGL is on Apple operating systems. I read here that up to OpenGL 4.1 will still work. But that post is a year old.

RetroArch does have a Metal (Apple's proprietary graphics API) driver. I don't know whether Metal stuff has to be baked in at the core level. I suspect that it does not (or at least not always), because I've successfully used various cores created for iOS 7 on my iOS 15 device, and Metal didn't debut until iOS 8.

hizzlekizzle commented 2 years ago

Software-rendered cores don't need it at the core level, but hardware-rendered cores, such as mupen64plus-next, do.

thatgirlsarah commented 2 years ago

I don't remember seeing that core in retroarch. How do you download codes that are not already in there?

stevenjamescox commented 2 years ago

@thatgirlsarah I thought it would be possible to download the core via the link I posted and then install it by going to "Load Core" then "Install or Restore a Core" and then select the downloaded core, but this does NOT appear to work. Either the core installer function isn't working right or something special has to happen with this core at the time of compilation. Might just be codesigning.

You might need to go the Xcode route and compile the app yourself. Full instructions here. You'd still download need to download the core via the link I've posted and then place it in the appropriate folder as noted in the instructions before compiling because this particular core won't be in the cores .zip file mentioned in the instructions.

stevenjamescox commented 2 years ago

@hizzlekizzle Fascinating. I had no idea this core did hardware decoding. No wonder it has to be built differently.

I’ll try to track down whomever built this core and find out how they included Metal support. Then maybe down the road this core and others can get added to added to the buildbot for macOS/iOS/tvOS.

thatgirlsarah commented 2 years ago

@stevenjamescox I'm not able to run Xcode 13 because my Mac only supports macOS Big Sur. Am I able to use Xcode 12 without upgrading?

stevenjamescox commented 2 years ago

@thatgirlsarah What version of iOS are you running on your phone? While the RetroArch Xcode project files will work just fine in Xcode 12, Xcode 12 doesn't officially support devices running iOS 15 (There are ways around this--you can manually add iOS 15 Device Support files to Xcode 12. This post has discusses ways to do that.)

rbreaves commented 1 year ago

Any progress on fixing the build bot for iOS or adding the mupen core to this project?

chinarut commented 1 year ago

I have a RetroArch iOS .ipa from Dec 2020 that contains the Mupen-64 core baked in. I upgraded the other day and notice due to this issue, I might as well roll back.

Where does Retroarch officially archive previous builds? I can’t find it anywhere. I could just attach the .ipa here but hey, i know this is not the best of practices :)

hizzlekizzle commented 1 year ago

You can find old stable releases here: http://buildbot.libretro.com/stable/