GLTFLoader progress is not working correctly?

I am using the GLTFLoader to load a model, the progress callback is showing that the model is completely loaded but the textures are still loading, why is this happening…

I also recorded a video to show exactly what I mean and here is the test page https://webdesign-flash.ro/ht/emv/

Thank you!

Hi man,
handling the onProgress callback directly in the load, I think is wrong, try using the onProgress callback in your shared loadingManager.

1 Like

Yes, this is the answer to the LoaderManager but only if it is .gltf, for .glb the GLTFLoader progress works correctly, what a mess…

The glb format contains the textures so in that case the gltfloader will be used to load the textures

with the gltf format the texures are separate and you should load them with a TextureLoader

so if you have more than one loader : texture loader + gltfloader , you have to use the LoadingManager which will merge the two in loading

if you use three.js vanilla you might find this library useful which simplifies the loading of assets: https://agargaro.github.io/three.ez/docs/tutorial/asset-management

Yes, I get it now… I am sure this will help others as well.

Thank you.

1 Like