Written in C++, using:
OpenGL - v3.3.8 with glad - v0.1.34
stb_image - v2.27
dear imgui - v1.80
1 thread per Resource. Threadpool manages threads. ResourceManager owns said Threadpool.
-
Launch threads to read resources.
-
Create all the resources (empty).
-
Assign all threads to pool.
-
When a resource is read, free the pool slot for another.
-
If a resource is not loaded:
1. Check if the resource finished the reading. 2. If this is the case, launch OpenGL resource setup. -
Option for reload Scene multithread <=> monothread.
Reload is locked if any resource is not loaded -
On Scene destruction : Delete all resources and join all threads.
Le Class Diagram
Threadpool for file reading
20 (arbitrary) threads in the pool.
Indissociable from OpenGL thread.
Checks periodically the state of resource: when read, create openGL resource.




