Chromium Code Reviews| Index: third_party/WebKit/Source/modules/webgl/WebGLRenderingContext.cpp |
| diff --git a/third_party/WebKit/Source/modules/webgl/WebGLRenderingContext.cpp b/third_party/WebKit/Source/modules/webgl/WebGLRenderingContext.cpp |
| index cc46e806bbfa070435ca4cde303a74fd5a772a27..8d079724ee0ac5f9944b921479e903fc89799608 100644 |
| --- a/third_party/WebKit/Source/modules/webgl/WebGLRenderingContext.cpp |
| +++ b/third_party/WebKit/Source/modules/webgl/WebGLRenderingContext.cpp |
| @@ -85,6 +85,9 @@ static bool shouldCreateContext(WebGraphicsContext3DProvider* contextProvider) |
| CanvasRenderingContext* WebGLRenderingContext::Factory::create(ScriptState* scriptState, OffscreenCanvas* offscreenCanvas, const CanvasContextCreationAttributes& attrs) |
| { |
| WebGLContextAttributes attributes = toWebGLContextAttributes(attrs); |
| + // transferToImageBitmap calls paintRenderingResultsToImageData, which |
| + // requires this bit to be false; |
| + attributes.setPremultipliedAlpha(false); |
|
Ken Russell (switch to Gerrit)
2016/05/10 23:11:42
I don't think it's legal to just set this all the
xidachen
2016/05/11 00:17:52
I did hesitate when I added this statement. The on
Ken Russell (switch to Gerrit)
2016/05/11 01:00:41
It's likely that that code path has never been tes
xidachen
2016/05/11 01:07:08
Yeah, it makes more sense to implement this using
|
| OwnPtr<WebGraphicsContext3DProvider> contextProvider(createWebGraphicsContext3DProvider(scriptState, attributes, 1)); |
| if (!shouldCreateContext(contextProvider.get())) |
| return nullptr; |
| @@ -147,8 +150,7 @@ void WebGLRenderingContext::setOffscreenCanvasGetContextResult(OffscreenRenderin |
| ImageBitmap* WebGLRenderingContext::transferToImageBitmap(ExceptionState& exceptionState) |
| { |
| - NOTIMPLEMENTED(); |
| - return nullptr; |
| + return transferToImageBitmapBase(); |
| } |
| void WebGLRenderingContext::registerContextExtensions() |