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

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

Issue 2547813002: Remove WebGLObject maps from WebGLRenderingContextBase and WebGLContextGroup. (Closed)
Patch Set: Fixed WebGLContextObject::validate. Made WebGLExtension non-finalized. Created 4 years 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 /* 1 /*
2 * Copyright (C) 2013 Google Inc. All rights reserved. 2 * Copyright (C) 2013 Google Inc. All rights reserved.
3 * 3 *
4 * Redistribution and use in source and binary forms, with or without 4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions 5 * modification, are permitted provided that the following conditions
6 * are met: 6 * are met:
7 * 7 *
8 * 1. Redistributions of source code must retain the above copyright 8 * 1. Redistributions of source code must retain the above copyright
9 * notice, this list of conditions and the following disclaimer. 9 * notice, this list of conditions and the following disclaimer.
10 * 2. Redistributions in binary form must reproduce the above copyright 10 * 2. Redistributions in binary form must reproduce the above copyright
(...skipping 17 matching lines...) Expand all
28 #include "gpu/command_buffer/client/gles2_interface.h" 28 #include "gpu/command_buffer/client/gles2_interface.h"
29 #include "modules/webgl/WebGLFramebuffer.h" 29 #include "modules/webgl/WebGLFramebuffer.h"
30 30
31 namespace blink { 31 namespace blink {
32 32
33 WebGLDrawBuffers::WebGLDrawBuffers(WebGLRenderingContextBase* context) 33 WebGLDrawBuffers::WebGLDrawBuffers(WebGLRenderingContextBase* context)
34 : WebGLExtension(context) { 34 : WebGLExtension(context) {
35 context->extensionsUtil()->ensureExtensionEnabled("GL_EXT_draw_buffers"); 35 context->extensionsUtil()->ensureExtensionEnabled("GL_EXT_draw_buffers");
36 } 36 }
37 37
38 WebGLDrawBuffers::~WebGLDrawBuffers() {}
39
40 WebGLExtensionName WebGLDrawBuffers::name() const { 38 WebGLExtensionName WebGLDrawBuffers::name() const {
41 return WebGLDrawBuffersName; 39 return WebGLDrawBuffersName;
42 } 40 }
43 41
44 WebGLDrawBuffers* WebGLDrawBuffers::create(WebGLRenderingContextBase* context) { 42 WebGLDrawBuffers* WebGLDrawBuffers::create(WebGLRenderingContextBase* context) {
45 return new WebGLDrawBuffers(context); 43 return new WebGLDrawBuffers(context);
46 } 44 }
47 45
48 // static 46 // static
49 bool WebGLDrawBuffers::supported(WebGLRenderingContextBase* context) { 47 bool WebGLDrawBuffers::supported(WebGLRenderingContextBase* context) {
(...skipping 139 matching lines...) Expand 10 before | Expand all | Expand 10 after
189 if (supportsDepth) 187 if (supportsDepth)
190 gl->DeleteTextures(1, &depth); 188 gl->DeleteTextures(1, &depth);
191 if (supportsDepthStencil) 189 if (supportsDepthStencil)
192 gl->DeleteTextures(1, &depthStencil); 190 gl->DeleteTextures(1, &depthStencil);
193 gl->DeleteTextures(colors.size(), colors.data()); 191 gl->DeleteTextures(colors.size(), colors.data());
194 192
195 return ok; 193 return ok;
196 } 194 }
197 195
198 } // namespace blink 196 } // namespace blink
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698