Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(247)

Side by Side Diff: third_party/WebKit/Source/modules/webgl/WebGL2RenderingContextBase.cpp

Issue 1824433002: Remove getError() and synthesizeGLError() from WebGraphicsContext3D. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@simples-tplus
Patch Set: Created 4 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 // Copyright 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "modules/webgl/WebGL2RenderingContextBase.h" 5 #include "modules/webgl/WebGL2RenderingContextBase.h"
6 6
7 #include "bindings/modules/v8/WebGLAny.h" 7 #include "bindings/modules/v8/WebGLAny.h"
8 #include "core/frame/ImageBitmap.h" 8 #include "core/frame/ImageBitmap.h"
9 #include "core/html/HTMLCanvasElement.h" 9 #include "core/html/HTMLCanvasElement.h"
10 #include "core/html/HTMLImageElement.h" 10 #include "core/html/HTMLImageElement.h"
(...skipping 2673 matching lines...) Expand 10 before | Expand all | Expand 10 after
2684 2684
2685 return contextGL()->IsVertexArrayOES(vertexArray->object()); 2685 return contextGL()->IsVertexArrayOES(vertexArray->object());
2686 } 2686 }
2687 2687
2688 void WebGL2RenderingContextBase::bindVertexArray(ScriptState* scriptState, WebGL VertexArrayObject* vertexArray) 2688 void WebGL2RenderingContextBase::bindVertexArray(ScriptState* scriptState, WebGL VertexArrayObject* vertexArray)
2689 { 2689 {
2690 if (isContextLost()) 2690 if (isContextLost())
2691 return; 2691 return;
2692 2692
2693 if (vertexArray && (vertexArray->isDeleted() || !vertexArray->validate(0, th is))) { 2693 if (vertexArray && (vertexArray->isDeleted() || !vertexArray->validate(0, th is))) {
2694 webContext()->synthesizeGLError(GL_INVALID_OPERATION); 2694 synthesizeGLError(GL_INVALID_OPERATION, "bindVertexArray", "invalid vert exArray");
2695 return; 2695 return;
2696 } 2696 }
2697 2697
2698 if (vertexArray && !vertexArray->isDefaultObject() && vertexArray->object()) { 2698 if (vertexArray && !vertexArray->isDefaultObject() && vertexArray->object()) {
2699 contextGL()->BindVertexArrayOES(objectOrZero(vertexArray)); 2699 contextGL()->BindVertexArrayOES(objectOrZero(vertexArray));
2700 2700
2701 vertexArray->setHasEverBeenBound(); 2701 vertexArray->setHasEverBeenBound();
2702 setBoundVertexArrayObject(scriptState, vertexArray); 2702 setBoundVertexArrayObject(scriptState, vertexArray);
2703 } else { 2703 } else {
2704 contextGL()->BindVertexArrayOES(0); 2704 contextGL()->BindVertexArrayOES(0);
(...skipping 887 matching lines...) Expand 10 before | Expand all | Expand 10 after
3592 params.skipPixels = m_unpackSkipPixels; 3592 params.skipPixels = m_unpackSkipPixels;
3593 params.skipRows = m_unpackSkipRows; 3593 params.skipRows = m_unpackSkipRows;
3594 if (dimension == Tex3D) { 3594 if (dimension == Tex3D) {
3595 params.imageHeight = m_unpackImageHeight; 3595 params.imageHeight = m_unpackImageHeight;
3596 params.skipImages = m_unpackSkipImages; 3596 params.skipImages = m_unpackSkipImages;
3597 } 3597 }
3598 return params; 3598 return params;
3599 } 3599 }
3600 3600
3601 } // namespace blink 3601 } // namespace blink
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698