Loading a texture from a react app shows checkerboard

Im trying to load a texture using new Texture(URL,scene)

assets/screenshots/SetUpScreen_English.jpg

but im getting a checkerboard pattern, in the inspector i load it in manually via the button and it works fine.

using TextureTask shows the same problem and i also get a message saying :

Error while trying to load image: assets/screenshots/Set... - Fallback texture was used

this is a react app by the way

Should i load textures another way? using img?

It should work, as long as your texture url is available on your website. Usually the checkerboard pattern would be a 404 of some sorts. You can easily check by trying to access your image url manually.

Ok you are right, when i go to the url it reloads the react page and doesnt go to the asset…

1 Like