class TextureResourceHandler

This class is a workaround to crashes and memory leaks caused by not reserving and freeing opengl textures from the same thread.

class TextureResourceHandler
{
public:
    //
methods

    static TextureResourceHandler& Instance();
    texture_name_t generateTextureID();
    void releaseTextureID(unsigned int texName);
};

Methods

texture_name_t generateTextureID()

Return [textureName, textureUnit].