Unable To Load GLB Models On iOS Safari 16.2

Experiencing a strange and inconsistent issue with Safari on various iOS devices. Specifically, this started with iOS 16.2 and worked prior to updating. Oddly enough, this issue is NOT present in Chrome on iOS, and we’ve isolated it specifically to Safari.

iPhone XR - 15.6.1 - No issue
iPad Pro 3rd gen - 15.6.1 - No issue
iPad Pro 3rd gen - 16.2 - Blank canvas w/ lag
iPhone 13 Pro Max - 16.2 - Blank canvas w/ lag
iPad Pro 5th gen - 16.2 - Blank canvas w/ lag

On these various devices that are having issues, I’m getting a blank white canvas that can’t be interacted with and intense browser lag with no other apps running in the background. Occasionally, getting a report of 0 fps in the playground.

Model seems to load as expected on any other device and browser, just affects iOS 16.2. I’m not able to get any logs at this time due to device limitations.

If anyone has any ideas about what’s going on, please help.

my pc is the same.
Is your glb file corrupted?

Works fine on my PC and with iOS 15.5 on my iphone 11. I’m downloading ios 16.2 now…

@Cedric Any updates on if it’s still working after the iOS update?

Yes, it works for me after 16.2 update.

@Cedric Well that makes this even more strange…

I wonder if it’s device specific…

So, here’s more tests with more devices on different iOS versions.
It’s getting really weird and I’m a loss on how to move forward on this since I can’t properly debug myself.

iPhone XR - 15.6.1 - Works without issue
iPhone 11 - 15.5 - Works without issue
iPhone 11 - 16.2 - Works without issue
iPad Pro 3rd gen - 15.6.1 - Does not load model
iPhone 13 Pro Max - 16.2 - Does not load model
iPad Pro 5th gen - 16.2 - Does not load model

Are you able to force and test in WebGL1?

It could be a workaround if it works in WebGL1 on all devices.

Quick update: It seems that most of this issue is based around Safari 16.2. Chrome seems to load fine.

Tested by loading on an iPhone and iPad on 15.*, worked fine. Then updated to 16.2, which then broke.

To be more descriptive about the issue, the canvas seems to load just white.

Can you try disabling webgl via metal in your safari exp features options ?

If that works please file a bug on Safari :frowning:

1 Like

Good callout, that resolved the issue! Will look into filing a Safari bug.

Thank you @sebavan .

For the time being until Apple (eventually) fixes this, do you know of any other solution that we can implement to avoid this?

not really as I have no idea what is broken in the Safari code unfortunately but forcing webgl1 as mentioned by @Evgeni_Popov might work ?

Unfortunately, forcing WebGL1 does not work unless I keep “WebGL Via Metal” off.

Tested using disableWebGL2Support in code and explicitly disabling WebGL2 in Safari experimental settings.

Super unfortunate.

yup hoping they ll fix it soon ish :frowning:

Why are other visually similar renderers such as SketchFab and Three.js seemingly unaffected by this?
It seems like Babylon has been the only renderer affected by a number of Apple’s updates. I’m not implying that this is Babylon’s fault, but why is it uniquely affected while others with similar material features remain unaffected?

We might be the only one relying on the exact broken feature :frowning: which would be great to determine.

Issue seems to have been resolved over the weekend somehow. No major iOS updates done, no BabylonJS updates done.

Confirmed working on all devices previously tested w/ WebGL via Metal enabled.

How weird…

Confirmed this is no longer happening. Also confirmed it was happening at the time of posting. Stealth app update maybe?

I tested on 2020 iPad (right before M1 release) v15.6 was working and when I updated my OS to 16.2 it was broken immediately after updating.

Now it’s working suddenly.

maybe it was a security issue of some sort and they auto update ??? I wonder if it is even possible LOL

Strike that, issue is back, except on iPhone 13 Pro Max. All devices using 16.2.

Newest playground (Just a different model):

iPhone 13 Pro Max:

  • Safari loads fine
  • Chrome loads fine

iPad Pro 5th gen

  • Safari doesn’t show model unless WebGL via Metal is disabled
  • Chrome doesn’t show model

iPad Pro 6th gen

  • Safari doesn’t show model unless WebGL via Metal is disabled
  • Chrome doesn’t show model

I’ve got access to a MacBook for debugging now. Unfortunately, I’m not seeing any errors in console, will continue looking into it to see if I find anything…