GLTextures store the source for easier debugging

This commit is contained in:
Brad Davis 2016-09-20 19:45:50 -07:00
parent d382305174
commit ee476a6048
2 changed files with 2 additions and 0 deletions

View file

@ -135,6 +135,7 @@ float GLTexture::getMemoryPressure() {
// Create the texture and allocate storage
GLTexture::GLTexture(const std::weak_ptr<GLBackend>& backend, const Texture& texture, GLuint id, bool transferrable) :
GLObject(backend, texture, id),
_source(texture.source()),
_storageStamp(texture.getStamp()),
_target(getGLTextureType(texture)),
_internalFormat(gl::GLTexelFormat::evalGLTexelFormatInternal(texture.getTexelFormat())),

View file

@ -111,6 +111,7 @@ public:
~GLTexture();
const GLuint& _texture { _id };
const std::string _source;
const Stamp _storageStamp;
const GLenum _target;
const GLenum _internalFormat;