Open HugoAdams opened 1 month ago
May I know the LOVE version you're using on?
This was on 11.4, but it seems to effect 11.5 too.
If you run this code, logcat will show multiple errors.
What are the errors (when running with 11.5)?
This is a logcat of the crash (github doesn't let me upload it directly). This is tested on a physical device (Samsung Galaxy Z Flip 3), the code I posted earlier seems to work ok on some virtual devices in Android Studio.
I think this is because devices in Android Studio do not simulate the safe area unless you use the developer option to Draw Cutout (it draws various notches and is off by default). I just tried on a virtual device (Pixel 8 API 35) with that setting on and it crashed with what looks like the same errors.
Thanks for the log. I think I found the cause.
If fullscreen is set to true, either through love.conf(), love.window.setFullscreen() or love.setMode() and then love.window.getSafeArea() is called then the application will crash.
If you run this code, logcat will show multiple errors.
The application will run fine if setFullscreen is called without calling getSafeArea and vice versa. It just means you cannot access the safe area while in fullscreen mode.
However, getSafeArea() can be called before setting fullscreen, but this does not work as the safe area returned has x and y set to 0, 0. If these were accurate numbers this method might be usable.