When working on a project, I came across an issue with loading large textures onto spheres. While most textures load within an acceptable time frame, some larger ones take up to ten seconds to fully download, causing the app to freeze during this process. To address this issue, I am looking for a way to preload all textures in the background and only apply them to the spheres once they have finished downloading.
I have experimented with using callback functions, promises, and even the built-in .loadAsync feature of the texture loader, but none of these solutions have reduced the freezing duration.
If anyone has suggestions on how to resolve this loading problem, it would greatly benefit my project. The project can be accessed here.