-
-
Notifications
You must be signed in to change notification settings - Fork 21.5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Vulkan Driver doesn't work on drivers that lack cubemap array support, such as iOS simulator and 1st-gen iPad Pro #74227
Comments
I got this same exact error today. I wonder if it is a Godot 4 thing or Xcode or M1 |
@ra669180 your computer is M1? My computer is a Intel chip |
@gumaciel yes, m1 and m1 pro getting the same error. The game loads on the simulator but gets stuck on the Godot Splash page and errors out. |
I'm not sure if MoltenVK is compiled for x86, so the Vulkan renderer may not work at all on the iOS simulator running on an Intel Mac. It should be possible to get it working on Apple Silicon though. |
@Calinou How do you get it running? I am on Apple Silicon and getting the same error. |
@ra669180 to be able to run on my Intel, i needed to change to |
@gumaciel you got it to run? Did you change the Compatibility render option in Xcode or Godot? |
I'm getting the exact same error on an Intel Mac and the iPhone 14 Pro simulator. |
Same here, this was done with the Godot Engine v4.1.dev1 Here is the debug log:
|
@cchipont Please surround large blocks of text with triple backticks like this: ``` This prevents them from taking too much space and also makes sure issue references aren't accidentally created. I edited your comment, but remember to do this next time 🙂 First-gen iPad Pro lacks full MoltenVK support, like the iOS simulator. Use the Compatibility rendering method when targeting old hardware in general. We could disable the check for 2D projects, but lacking support for cubemap arrays will break any shaded 3D rendering (as cubemap arrays are used to store the radiance maps for PBR). If you want to try this on your own, remove the check in the source code then compile an iOS export template. |
We discussed this on chat a bit. It seems like we can improve the situation somewhat by only failing when cubemap arrays are actually used. This should not be too difficult but it will require a few changes:
Additionally, we need to add documentation about this requirement somewhere as it will likely catch devs by surprise when they ship their game |
Thanks for considering this guys, it would be highly appreciated. |
Ran into this today as I was testing out the new 4.2dev1 build, hoping to get support for the mobile renderer on some older iOS devices (iPad Air 2 and older iPhones) with #70013 marked as fixed with the new replacement for sampler arrays #77740 . However, even with this improvement it now fails due to the image cube arrays instead.
I'm not sure when these are used, but if it would be possible to support these devices by avoiding to use cubemaps it would be great. It would make it much easier to distribute games on iOS via the app store as it would not only allow for broader compatibility, but currently you can't really guarantee that people who can buy your game on the app store can actually run it on their devices. |
@lostminds Please see my comment above explaining the steps needed to resolve this issue #74227 (comment) |
While waiting for a more substantial fix to this issue, perhaps removing the need for cubemap support to broaden iOS device support as detailed above by @clayjohn . Would it be possible to just add the UIRequiredDeviceCapabilities key iphone-ipad-minimum-performance-a12 to exported iOS projects using Vulkan renderers? As I understand it this will make sure that only devices that we are sure will be able to run the game can buy and download the apps on the app store by requiring an A12 or later GPU (all post 2018 iOS devices). Even if it will also block some A11 GPU devices (iPhone X and iPhone 8) that might (?) be able to run the mobile renderer it will ensure that people with unsupported A9 and A10 devices cannot buy the games in the app store and then just get a black screen when they try to start it. This could just be added as another capabilities property in the iOS export configuration, along with the existing wifi access and push notifications toggles, for example Previously I believed setting the required iOS version to iOS 16 would have this effect, but I've since learned there are several older iOS devices that can run iOS 16, but cannot run Godot mobile renderer: the rare first gen iPad pro as mentioned, but also the more common 7th gen iPad and iPhone 7 with the A10 GPU. |
You can manually add the key for iphone-ipad-minimum-performance-a12 in your info.plist. But it's a shame that Apple doesn't have a similar key for A11 or A10. The mobile renderer works fine on my iPhone 8 with A11, with 4.1.1-stable. According to Apple, the iPhone 7 only supports iOS 15. But it looks like there are still devices left, that you can't filter out by arm64 or iOS 16 as min-target. 7th gen iPad is A10, the iPad Pro is A9X. If I understood correctly, if the cubemap check is implemented, those devices would work with the vulkan mobile renderer? Having the simulator work would be fantastic as well. |
Just removing the check in vulkan_context.cpp will let godot run on most mentioned iOS devices (simulator for example), as long as cubemaps are really not used (I think its basically means reflections and some other advanced features). I do not recommend just removing the check, but maybe adding code to the project to detect the missing cubemaps support and "disable" these features can be possible. |
Btw in OgreNext we deal with this issue by converting all cubemap arrays into a 2D array of dual-paraboloid textures. |
Here's a pixel shader fullscreen pass that converts a cubemap into a 2D DP map. |
@darksylinc You prefer DP over Octahedral in this case? |
Octahedral is also good. I just forgot about it because I'm more familiar with DP. |
Use OpenGL3 with Godot 4.1.2 / Project settings / Renderer (all x3 to gl_compatibility) Then Export for iOS. |
I tried the above configuration on a M2 and does not work on the simulator. I keep getting:
Followed by this about once a second, and a blank display:
|
You right. Simulator won't display : |
I did some testing with v4.2.dev.custom_build.691634969 and compiled debug libs for iOS and the Simulator.
Unsurprisingly the particles do not work, with the shader not correctly setup. |
Yes, I am here because I discovered after migrating from Godot 3.5 to Godot 4.1.3 my app no longer works on a bunch of older iPad's and they are this "7th Generation" iPad running iOS 16. They are what, 4 years old I think? I think people upgrade their iPad's much less frequently than their phones, so it's kind of a "must support" thing.
Ummm.... Yes :) I appreciate all the improvements y'all are working on, but this one was a little frustrating to run into. It's been one long chain of "oh that doesn't work" , "oh that doesn't work", etc..... If there is a way to smooth this one over it would be helpful. I don't think my app is even that complicated, it's a bunch of control nodes with some tweens and audio. There are no 3D graphics or shaders or effects or anything that I am aware of. Perhaps the documentation or help popups could mention a few devices that need "compatibility" mode to make the impact of choosing "mobile" clear to developers? Perhaps even the error log message in Xcode could hint towards "compatibility" mode in some way?
Can we get this in 4.1 without much extra work? It feels to me that Godot 4 should a iPad that was purchased 4 or 5 years ago. People really don't upgrade their iPad's that often? Although just making it clear that compatibility mode is probably needed for a simple project to be backwards compatible might be enough? On a related side note, The dropdown menu on the top right where you change from "Mobile" to "Compatibility" didn't update the "Rendering" -> "Rendering Method.mobile" setting in 4.1.3. So when I tested "Compatibility" mode it still failed in iOS/iPad. But then I went into the project settings panel and saw that "Rendering Method.mobile" was still set to mobile. I don't know if that is intended, but it definitely confused me for a bit until I discovered it. |
You can make the same change in the 4.1.3 source code and recompile the iOS export template in the same way. As per the release policy, a proper fix won't be backported to 4.1.x as it implies feature development (adding a fallback for devices that don't support the required Vulkan/MoltenVK features at a hardware level).
See #72461. |
This comment is for those bumping into this thread. For this error (A9 CPU not supported because cubemaps), getting Godot 4.2.1 to run on iPhone 6S (A9 CPU, ~10 years old) was possible by setting the mobile renderer to gl_compatibility. I don't have other details, I'm just evaluating Godot. On an Android 4-5yo CPU low end device I'm also getting under 20 fps using mobile renderer (is it vulkan?) for a simple test with 400 simple distinct (no gpu instancing) objects. No iPhone issues on performance (comparably old devices) using either renderer. Also, on mobile renderer, on an Android low end device there's touch latency as FPS drops (why would the CPU be affected?), and some buffer for touch move fills slowly until it releases the events (touch start had no issues) - didn't get this with the gl_compatibility renderer. |
That's pretty obvious as this bypasses the entire problem by using OpenGL instead of Vulkan |
Any progress on this, by chance? We are not able to add the iphone-ipad-minimum-performance-a12 requirement since our game shipped without it, and Apple does not let you add requirements in updates :/ |
I guess the solution for this should be to have support for falling back to OpenGL (Compatibility) when using Forward+/Mobile? godotengine/godot-proposals#8006 |
This will help, but only if we make sure the fallback executes when the missing requirement is detected (it might be too far along in Vulkan initialization when this is detected right now). |
Godot version
4.0 stable
System information
Mac OS Monterey (12.6), Vulkan API 1.2.231, iOS 16.2 Simulator (iPhone 14 Pro), Intel chip CPU
Issue description
When trying to export an empty game to run in the Xcode simulator, it gives an error:
Should that be normal? Since on my Desktop running the application it works normally
full log:
Steps to reproduce
Just create a Empty project as "Mobile" Render option and try to export
Minimal reproduction project
EmptyProject40stableMobile.zip
The text was updated successfully, but these errors were encountered: