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

Unified Diff: Source/core/html/canvas/WebGLFramebuffer.cpp

Issue 223223003: Re-land "WebGL: Transfer ownership of WebGraphicsContext3D to DrawingBuffer" (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: fix errata on comment Created 6 years, 8 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
« no previous file with comments | « Source/core/html/canvas/WebGLDrawBuffers.cpp ('k') | Source/core/html/canvas/WebGLProgram.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/html/canvas/WebGLFramebuffer.cpp
diff --git a/Source/core/html/canvas/WebGLFramebuffer.cpp b/Source/core/html/canvas/WebGLFramebuffer.cpp
index 8dff43cbf19d8fa2e8788c07f7138552554834e2..dbef20712f3ae5a3e5f3e3b093b09257aa4effef 100644
--- a/Source/core/html/canvas/WebGLFramebuffer.cpp
+++ b/Source/core/html/canvas/WebGLFramebuffer.cpp
@@ -263,7 +263,7 @@ WebGLFramebuffer::WebGLFramebuffer(WebGLRenderingContextBase* ctx)
, m_hasEverBeenBound(false)
{
ScriptWrappable::init(this);
- setObject(ctx->webGraphicsContext3D()->createFramebuffer());
+ setObject(ctx->webContext()->createFramebuffer());
}
WebGLFramebuffer::~WebGLFramebuffer()
@@ -302,7 +302,7 @@ void WebGLFramebuffer::attach(GLenum attachment, GLenum attachmentPoint)
ASSERT(isBound());
WebGLAttachment* attachmentObject = getAttachment(attachment);
if (attachmentObject)
- attachmentObject->attach(context()->webGraphicsContext3D(), attachmentPoint);
+ attachmentObject->attach(context()->webContext(), attachmentPoint);
}
WebGLSharedObject* WebGLFramebuffer::getAttachmentObject(GLenum attachment) const
@@ -413,7 +413,7 @@ void WebGLFramebuffer::removeAttachmentFromBoundFramebuffer(GLenum attachment)
WebGLAttachment* attachmentObject = getAttachment(attachment);
if (attachmentObject) {
- attachmentObject->onDetached(context()->webGraphicsContext3D());
+ attachmentObject->onDetached(context()->webContext());
m_attachments.remove(attachment);
drawBuffersIfNecessary(false);
switch (attachment) {
@@ -446,7 +446,7 @@ void WebGLFramebuffer::removeAttachmentFromBoundFramebuffer(WebGLSharedObject* a
WebGLAttachment* attachmentObject = it->value.get();
if (attachmentObject->isSharedObject(attachment)) {
GLenum attachmentType = it->key;
- attachmentObject->unattach(context()->webGraphicsContext3D(), attachmentType);
+ attachmentObject->unattach(context()->webContext(), attachmentType);
removeAttachmentFromBoundFramebuffer(attachmentType);
checkMore = true;
break;
@@ -601,7 +601,7 @@ void WebGLFramebuffer::drawBuffersIfNecessary(bool force)
}
}
if (reset) {
- context()->webGraphicsContext3D()->drawBuffersEXT(
+ context()->webContext()->drawBuffersEXT(
m_filteredDrawBuffers.size(), m_filteredDrawBuffers.data());
}
}
« no previous file with comments | « Source/core/html/canvas/WebGLDrawBuffers.cpp ('k') | Source/core/html/canvas/WebGLProgram.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698