| Index: third_party/WebKit/Source/modules/webgl/WebGLRenderingContextBase.cpp
|
| diff --git a/third_party/WebKit/Source/modules/webgl/WebGLRenderingContextBase.cpp b/third_party/WebKit/Source/modules/webgl/WebGLRenderingContextBase.cpp
|
| index b92a8c47b00e37c940cdf74130811439a815872b..6f716e5a5808b7fbdc2b4f2ca54ebceefeffb1d4 100644
|
| --- a/third_party/WebKit/Source/modules/webgl/WebGLRenderingContextBase.cpp
|
| +++ b/third_party/WebKit/Source/modules/webgl/WebGLRenderingContextBase.cpp
|
| @@ -4065,7 +4065,7 @@ void WebGLRenderingContextBase::texImageCanvasByGPU(TexImageByGPUType functionTy
|
| targetLevel = 0;
|
| targetInternalformat = GL_RGBA;
|
| targetType = GL_UNSIGNED_BYTE;
|
| - targetTexture = webContext()->createTexture();
|
| + contextGL()->GenTextures(1, &targetTexture);
|
| contextGL()->BindTexture(GL_TEXTURE_2D, targetTexture);
|
| contextGL()->TexParameteri(GL_TEXTURE_2D, GL_TEXTURE_MAG_FILTER, GL_NEAREST);
|
| contextGL()->TexParameteri(GL_TEXTURE_2D, GL_TEXTURE_MIN_FILTER, GL_NEAREST);
|
| @@ -4091,7 +4091,8 @@ void WebGLRenderingContextBase::texImageCanvasByGPU(TexImageByGPUType functionTy
|
| }
|
|
|
| if (!possibleDirectCopy) {
|
| - WebGLId tmpFBO = webContext()->createFramebuffer();
|
| + uint32_t tmpFBO;
|
| + contextGL()->GenFramebuffers(1, &tmpFBO);
|
| contextGL()->BindFramebuffer(GL_FRAMEBUFFER, tmpFBO);
|
| contextGL()->FramebufferTexture2D(GL_FRAMEBUFFER, GL_COLOR_ATTACHMENT0, GL_TEXTURE_2D, targetTexture, 0);
|
| contextGL()->BindTexture(texture->getTarget(), texture->object());
|
| @@ -4104,8 +4105,8 @@ void WebGLRenderingContextBase::texImageCanvasByGPU(TexImageByGPUType functionTy
|
| }
|
| contextGL()->FramebufferTexture2D(GL_FRAMEBUFFER, GL_COLOR_ATTACHMENT0, GL_TEXTURE_2D, 0, 0);
|
| restoreCurrentFramebuffer();
|
| - webContext()->deleteFramebuffer(tmpFBO);
|
| - webContext()->deleteTexture(targetTexture);
|
| + contextGL()->DeleteFramebuffers(1, &tmpFBO);
|
| + contextGL()->DeleteTextures(1, &targetTexture);
|
| }
|
| }
|
|
|
|
|