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

Unified Diff: third_party/WebKit/Source/modules/webgl/WebGLBuffer.cpp

Issue 1817323003: Revert of Remove create/delete methods from WebGraphicsContext3D. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@complex-casts
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 side-by-side diff with in-line comments
Download patch
Index: third_party/WebKit/Source/modules/webgl/WebGLBuffer.cpp
diff --git a/third_party/WebKit/Source/modules/webgl/WebGLBuffer.cpp b/third_party/WebKit/Source/modules/webgl/WebGLBuffer.cpp
index 4f8e50efe8033553316d6befadc619d30203f166..a3144eef04e46b0887324fd6df119b8c47b3f7e9 100644
--- a/third_party/WebKit/Source/modules/webgl/WebGLBuffer.cpp
+++ b/third_party/WebKit/Source/modules/webgl/WebGLBuffer.cpp
@@ -25,7 +25,6 @@
#include "modules/webgl/WebGLBuffer.h"
-#include "gpu/command_buffer/client/gles2_interface.h"
#include "modules/webgl/WebGLRenderingContextBase.h"
namespace blink {
@@ -40,9 +39,7 @@
, m_initialTarget(0)
, m_size(0)
{
- GLuint buffer;
- ctx->contextGL()->GenBuffers(1, &buffer);
- setObject(buffer);
+ setObject(ctx->webContext()->createBuffer());
}
WebGLBuffer::~WebGLBuffer()
@@ -53,7 +50,7 @@
void WebGLBuffer::deleteObjectImpl(WebGraphicsContext3D* context3d, gpu::gles2::GLES2Interface* gl)
{
- gl->DeleteBuffers(1, &m_object);
+ context3d->deleteBuffer(m_object);
m_object = 0;
}

Powered by Google App Engine
This is Rietveld 408576698