When loaded images go out of scope we should be deleting them from the GPU
https://www.khronos.org/registry/OpenGL-Refpages/es2.0/xhtml/glDeleteTextures.xml
This didn't use to be much of an issue if you just load images inside of setup, but now we rerun setup whenever we hotreload, which ends up being a lot and causes performance issues.
Ideally we somehow improve our bindings to use custom blocks with a finalize that frees the images on the gpu https://caml.inria.fr/pub/docs/manual-ocaml/intfc.html#sec461
failing that:
Exposing this might help: bsansouci/reasongl#4 and let us write this in Reprocessing by using a Gc.finalize on the returned imageT objects.
@bsansouci
When loaded images go out of scope we should be deleting them from the GPU
https://www.khronos.org/registry/OpenGL-Refpages/es2.0/xhtml/glDeleteTextures.xml
This didn't use to be much of an issue if you just load images inside of setup, but now we rerun setup whenever we hotreload, which ends up being a lot and causes performance issues.
Ideally we somehow improve our bindings to use custom blocks with a finalize that frees the images on the gpu https://caml.inria.fr/pub/docs/manual-ocaml/intfc.html#sec461
failing that:
Exposing this might help: bsansouci/reasongl#4 and let us write this in Reprocessing by using a Gc.finalize on the returned imageT objects.
@bsansouci