| 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 6e850c814c8eb3101c3cacd0d1d1dbc8734377fa..fe89c7728eacc30693628e20943977752a7b474f 100644
|
| --- a/third_party/WebKit/Source/modules/webgl/WebGLRenderingContextBase.cpp
|
| +++ b/third_party/WebKit/Source/modules/webgl/WebGLRenderingContextBase.cpp
|
| @@ -3003,9 +3003,10 @@ ScriptValue WebGLRenderingContextBase::getParameter(ScriptState* scriptState,
|
| case GL_COLOR_WRITEMASK:
|
| return getBooleanArrayParameter(scriptState, pname);
|
| case GL_COMPRESSED_TEXTURE_FORMATS:
|
| - return WebGLAny(scriptState, DOMUint32Array::create(
|
| - m_compressedTextureFormats.data(),
|
| - m_compressedTextureFormats.size()));
|
| + return WebGLAny(
|
| + scriptState,
|
| + DOMUint32Array::create(m_compressedTextureFormats.data(),
|
| + m_compressedTextureFormats.size()));
|
| case GL_CULL_FACE:
|
| return getBooleanParameter(scriptState, pname);
|
| case GL_CULL_FACE_MODE:
|
| @@ -5158,14 +5159,15 @@ void WebGLRenderingContextBase::texImageHelperHTMLCanvasElement(
|
| // TODO(zmo): Implement GPU-to-GPU copy path (crbug.com/612542).
|
| // Note that code will also be needed to copy to layers of 3D
|
| // textures, and elements of 2D texture arrays.
|
| - texImageImpl(
|
| - functionID, target, level, internalformat, xoffset, yoffset, zoffset,
|
| - format, type, canvas
|
| - ->copiedImage(FrontBuffer, PreferAcceleration,
|
| - functionIDToSnapshotReason(functionID))
|
| - .get(),
|
| - WebGLImageConversion::HtmlDomCanvas, m_unpackFlipY,
|
| - m_unpackPremultiplyAlpha, sourceSubRectangle, depth, unpackImageHeight);
|
| + texImageImpl(functionID, target, level, internalformat, xoffset, yoffset,
|
| + zoffset, format, type,
|
| + canvas
|
| + ->copiedImage(FrontBuffer, PreferAcceleration,
|
| + functionIDToSnapshotReason(functionID))
|
| + .get(),
|
| + WebGLImageConversion::HtmlDomCanvas, m_unpackFlipY,
|
| + m_unpackPremultiplyAlpha, sourceSubRectangle, depth,
|
| + unpackImageHeight);
|
| }
|
| }
|
|
|
| @@ -5233,8 +5235,9 @@ void WebGLRenderingContextBase::texImageHelperHTMLVideoElement(
|
| sourceImageRect ==
|
| IntRect(0, 0, video->videoWidth(), video->videoHeight());
|
| if (functionID == TexImage2D && sourceImageRectIsDefault && depth == 1 &&
|
| - GL_TEXTURE_2D == target && Extensions3DUtil::canUseCopyTextureCHROMIUM(
|
| - target, internalformat, type, level)) {
|
| + GL_TEXTURE_2D == target &&
|
| + Extensions3DUtil::canUseCopyTextureCHROMIUM(target, internalformat, type,
|
| + level)) {
|
| DCHECK_EQ(xoffset, 0);
|
| DCHECK_EQ(yoffset, 0);
|
| DCHECK_EQ(zoffset, 0);
|
| @@ -6987,8 +6990,9 @@ bool WebGLRenderingContextBase::validateTexFuncData(
|
| break;
|
| case GL_HALF_FLOAT:
|
| case GL_HALF_FLOAT_OES: // OES_texture_half_float
|
| - // As per the specification, ArrayBufferView should be null or a
|
| - // Uint16Array when OES_texture_half_float is enabled.
|
| + // As per the specification, ArrayBufferView should
|
| + // be null or a Uint16Array when
|
| + // OES_texture_half_float is enabled.
|
| if (pixels->type() != DOMArrayBufferView::TypeUint16) {
|
| synthesizeGLError(GL_INVALID_OPERATION, functionName,
|
| "type HALF_FLOAT_OES but ArrayBufferView is not NULL "
|
| @@ -7529,7 +7533,7 @@ String WebGLRenderingContextBase::ensureNotNull(const String& text) const {
|
|
|
| WebGLRenderingContextBase::LRUImageBufferCache::LRUImageBufferCache(
|
| int capacity)
|
| - : m_buffers(wrapArrayUnique(new std::unique_ptr<ImageBuffer>[ capacity ])),
|
| + : m_buffers(wrapArrayUnique(new std::unique_ptr<ImageBuffer>[capacity])),
|
| m_capacity(capacity) {}
|
|
|
| ImageBuffer* WebGLRenderingContextBase::LRUImageBufferCache::imageBuffer(
|
|
|