TheProgrammer
TheProgrammer

Reputation: 1509

Error when loading gltf file with GLTFLoader: RangeError: Invalid typed array length: 4

I am able to load close to 100 GLTF files without issue with my code. But one file in particular causes this error:

"RangeError: Invalid typed array length: 4"

Would you know where it comes from and how to fix it ?

enter image description here

Upvotes: 3

Views: 9251

Answers (2)

Babylonjs sandbox is also quite useful.

https://sandbox.babylonjs.com/

Here you can upload your models to see if there are errors or stuff. For example, the link above from Khronos won't tell you when the URLs on your file are not correctly formatted, as is the case when you rename the .bin file.

Upvotes: 2

Don McCurdy
Don McCurdy

Reputation: 11980

This error most likely means the file is invalid; you can test that by opening the file on http://github.khronos.org/glTF-Validator/. If so, I would recommend reporting a bug on the tool used to create the file.

Upvotes: 4

Related Questions