Index: src/gpu/gl/GrGLTexture.cpp |
diff --git a/src/gpu/gl/GrGLTexture.cpp b/src/gpu/gl/GrGLTexture.cpp |
index 8777d1b75559765f7117d9359d32911b71ca9c96..ce892ddbb19e1a9076463a86a99eab8ffd27d85a 100644 |
--- a/src/gpu/gl/GrGLTexture.cpp |
+++ b/src/gpu/gl/GrGLTexture.cpp |
@@ -30,20 +30,23 @@ void GrGLTexture::init(const GrSurfaceDesc& desc, const IDDesc& idDesc) { |
fTexParams.invalidate(); |
fTexParamsTimestamp = GrGpu::kExpiredTimestamp; |
fTextureID = idDesc.fTextureID; |
+ fIsWrapped = idDesc.fIsWrapped; |
} |
void GrGLTexture::onRelease() { |
if (fTextureID) { |
- if (!this->isWrapped()) { |
+ if (!fIsWrapped) { |
GL_CALL(DeleteTextures(1, &fTextureID)); |
} |
fTextureID = 0; |
+ fIsWrapped = false; |
} |
INHERITED::onRelease(); |
} |
void GrGLTexture::onAbandon() { |
fTextureID = 0; |
+ fIsWrapped = false; |
INHERITED::onAbandon(); |
} |