GLB import error - only on Quest or phone


I cant reproduce this on a PG yet but I starting to investigate WebXR and I have a weird problem affecting one of my models. I am using the helpers to generate an XR environment and everything works fine on a PC browser but when running on a Quest or a Samsung Galaxy S7 I get an error in the ImportMesh function that says “unable to import… invalid index into function table”. This is before I switch to XR mode so it is probably nothing to do with XR but something with the model itself. Another model works fine in XR and the problematic model works fine on PC. Perhaps this is more to do with whether it is running Pollyfill or not???
Any ideas on how I can troubleshoot this? The model is Draco compressed so I could try without (but the other model that works is also Draco compressed).

Pinging @RaananW


as you say - this is probably not XR related, especially if it happens prior to actually using XR. You say you can’t reproduce this on the playground - does loading the model on the playground using android/quest works well?

Sorry for the tardiness in my reply. The inability to reproduce it in PG was because I didn’t know how to reproduce it (rather than it not being reproducable).

Anyway, I do now. I have setup a site with CORS enabled so I can load the model from there as I beleive it is to do with the model - perhaps it is too big (too many verts) for a mobile version? The PG below works fine on a desktop but not on a mobile device (Samsun Galaxy S7). If you comment out the model and enable another one instead it works. The problem model was originally created in SolidWorks and then via STL into Blender (simplified as much as possible) then exported to GLB with Draco. The other models were FBX->Blender->GLB+Draco.

Am I hiting a size problem or has the original file got some combination of left over mess that is causing a problem?

(I have tested this from multiple servers so confident it is not caused by server environment)

PG: Babylon.js Playground

I can reproduce this, thanks a lot for the playground.

@bghgary - this is the error shown when trying to load on mobile:

Any idea why this would happen?

I can’t repro this on my Android phone (OnePlus 6). From the callstack, it looks like something deep within Draco that is failing. It might be good to ask the Draco team? Issues · google/draco (

1 Like