fix memleak, make sure gl textures are deleted by render thread, thanks to popcornmix
Merge pull request #3331 from FernetMenta/texture

make sure gl textures are deleted by render thread