Lights does not render on iOS

Hi.

Maybe related to this problem:

Lights are not rendered inside Safari and Chrome browser on iOS 13.7 if the radius is higher 255
Tried this preview:
https://game-previews.gdevelop-app.com/1600002594041-924982/index.html

Thanks.

Might be related to this: https://github.com/4ian/GDevelop/pull/1979

Although I do know that WebGL is a hard requirement, and iOS has always had issues with WebGL dating back to 2014. No clue if thatā€™s still a problem.

Not sure, it seems he is working on a way to detect ahead of time if WebGL is supported or not and if not then return null and donā€™t render the lights to avoid the project to crash.

The browser does support WebGL, pass all the tests I throw at it except the GDevelop test.
Not sure if it a compatibility problem on iOS/Safari side or is it something on GD side with the implementation but I do know that so far it did pass all the WebGL tests I tried except this but only when tha radius is higher than 255 :thinking:

Weird, I had heard of iOS and webgl compatibility issues before, but Iā€™d trust your testing way over my memory :smiley:

Unfortunately, Iā€™m not sure what would cause that specifically. Iā€™d wait for someone with more knowledge around the light system to chime in.

Oh, I donā€™t doubt that iOS/Safari could have compatibility issues but so far I did not noticed any, even the lights in GD was ok as long I did not go above 255 radius, so there is plenty of things remain to be broken, I was just lucky to find one I guess :grin:

There is an error in the console ?
CTRL+SHIFT+i

The only error I get is:

[blocked] The page at ā€¦/index.html was not allowed to run insecure content

Failed to load resources 403 Runtime/pixi-renderers/pixi-legacy.min.js.map

I get this error also if the radius is below 255 and light is rendered and everything is working, not sure what sort of content being blocked there and if it related at all.

If you want, you can post a quick message and resume this topic on the current github issues for Light.

The dev work on another fix for light.
When you are sure you have a bug related to GDevelop if you can itā€™s easier on github because all developers are on it.
Contrary to the forum where there is a lot of notification in all directions we get lost.

unfortunately I am not 100% sure if this is a bug related to GDevelop or compatibility problem on iOS since the compiled code doesnā€™t throw any errors related to lights specifically, someone should debug the engine to be certain but I am not setup for that and i donā€™t feel comfortable take this to GutHub without being certain what is it.

Anyway, I just leave this here, hopefully someone able to debug this one day and decide if it a bug or not.

Thanks.

1 Like

4ian is the only one to have a iOS :wink:
And if itā€™s reported on github the author of the light extension will read your post and take a look on the radius parameters if this one is buggy he will found the bug.
He just needs to know the possible issue.

Hi, I have the same issue but on Android, the lights arenā€™t rendering, I have no error they just dissappear, while they donā€™t when I preview the game in gdevelop. How do you think I can fix this?

Reported on GitHub:

Letā€™s see if someone can figure this out :+1:

1 Like

I think the tests are perfectly reasonable, someone canā€™t randomly come up with a number like 256 (a power of 2). I canā€™t really test myself since I donā€™t have iOS/Safari, but I believe thereā€™s definitely some limitation that doesnā€™t let lights being greater than 255 :thinking:. As far as I can see, webgl-2 is still an experimental feature in safari and in development, and 256 being a power of two seems like there are some limitations regarding shaders/buffers and textures.

Itā€™d be really helpful if 4ian would be able to confirm this, then maybe we can find a solution to this :grimacing:.

2 Likes