- Home /
Downloading images and keeping them after loading a scene (WebGL)
Hi, guys. I'm making a "virtual expo" in WebGl where users can navigate through stands and see images of all the products. To make it a lot faster to load, my build does not include the images, they are downloaded from a server after the game starts. It also enables me to change them on the server and automatically update the next time the user refreshes its browser. It works alright.
The problem is the game has 7 areas that separate the different stand categories, and every time you come back to a previous one, all images have to download again, making it tedious for the user and bandwith heavy for the server. I dont want to store them all in memory with "dont destroy on load" or similar methods because they're quite a bunch and the memory requirements for the users would rise significantly.
How could I store them at runtime in a folder (in the user's end) once they are downloaded, so the next time the user loads a previous area they dont have to download them again but instead load them from the folder in case they exist already?
Something like "resources load" but from webgl. Thanks a lot in advance.