Why does TextureAssetTask ignore WebRequest?

I need to turn on .withCredentials() for requests from texture tasks. If I use MeshAssetTask and WebRequest.CustomRequestModifiers[request => request.withCredentials = true], everything is ok and cookie with tokens are included. But the same above code doesn’t affect on TextureAssetTask.

It seems that this is happening in all texture loads, not just with asset manager. I’ll take a deeper look asap.

1 Like

Hello, we have a PR up to fix this now :smiley: Use LoadFile when loading images so that WebRequest custom headers ar… by carolhmj · Pull Request #12891 · BabylonJS/Babylon.js (github.com)

1 Like