Title: [136917] trunk/Source/Platform
Revision
136917
Author
commit-qu...@webkit.org
Date
2012-12-06 18:57:21 -0800 (Thu, 06 Dec 2012)

Log Message

[chromium] Rename non-standard discard/ensureFramebufferCHROMIUM extensions so we can use real GL_EXT_discard_framebuffer
https://bugs.webkit.org/show_bug.cgi?id=104316

Patch by James Robinson <jam...@chromium.org> on 2012-12-06
Reviewed by Kenneth Russell.

GL_EXT_discard_framebuffer is a GL extension that enables optimizations for GPUs that aggressively defer
operations. We've 'borrowed' the extension namespace to enable backbuffer management, but this makes it
impossible to use the actual extension.  This adds new entry points for backbuffer management. After callers
(which aren't in the WebKit repo) are updated, we can remove the overlapping entry points.

* chromium/public/WebGraphicsContext3D.h:
(WebGraphicsContext3D):
(WebKit::WebGraphicsContext3D::discardFramebufferCHROMIUM):
(WebKit::WebGraphicsContext3D::discardBackbufferCHROMIUM):
(WebKit::WebGraphicsContext3D::ensureBackbufferCHROMIUM):

Modified Paths

Diff

Modified: trunk/Source/Platform/ChangeLog (136916 => 136917)


--- trunk/Source/Platform/ChangeLog	2012-12-07 02:30:17 UTC (rev 136916)
+++ trunk/Source/Platform/ChangeLog	2012-12-07 02:57:21 UTC (rev 136917)
@@ -1,3 +1,21 @@
+2012-12-06  James Robinson  <jam...@chromium.org>
+
+        [chromium] Rename non-standard discard/ensureFramebufferCHROMIUM extensions so we can use real GL_EXT_discard_framebuffer
+        https://bugs.webkit.org/show_bug.cgi?id=104316
+
+        Reviewed by Kenneth Russell.
+
+        GL_EXT_discard_framebuffer is a GL extension that enables optimizations for GPUs that aggressively defer
+        operations. We've 'borrowed' the extension namespace to enable backbuffer management, but this makes it
+        impossible to use the actual extension.  This adds new entry points for backbuffer management. After callers
+        (which aren't in the WebKit repo) are updated, we can remove the overlapping entry points.
+
+        * chromium/public/WebGraphicsContext3D.h:
+        (WebGraphicsContext3D):
+        (WebKit::WebGraphicsContext3D::discardFramebufferCHROMIUM):
+        (WebKit::WebGraphicsContext3D::discardBackbufferCHROMIUM):
+        (WebKit::WebGraphicsContext3D::ensureBackbufferCHROMIUM):
+
 2012-12-06  Kenneth Russell  <k...@google.com>
 
         Associate URLs with GraphicsContext3D instances created for WebGL

Modified: trunk/Source/Platform/chromium/public/WebGraphicsContext3D.h (136916 => 136917)


--- trunk/Source/Platform/chromium/public/WebGraphicsContext3D.h	2012-12-07 02:30:17 UTC (rev 136916)
+++ trunk/Source/Platform/chromium/public/WebGraphicsContext3D.h	2012-12-07 02:57:21 UTC (rev 136917)
@@ -169,10 +169,16 @@
     virtual void setMemoryAllocationChangedCallbackCHROMIUM(WebGraphicsMemoryAllocationChangedCallbackCHROMIUM* callback) { }
     virtual void sendManagedMemoryStatsCHROMIUM(const WebGraphicsManagedMemoryStats* stats) { }
 
-    // GL_EXT_discard_framebuffer - discard/ensure existance of surface backbuffer.
-    // FIXME: make these pure virtual once they are implemented by clients.
+    // GL_EXT_discard_framebuffer - makes specified attachments of currently bound framebuffer undefined.
     virtual void discardFramebufferEXT(WGC3Denum target, WGC3Dsizei numAttachments, const WGC3Denum* attachments) { }
+
+    // GL_CHROMIUM_discard_backbuffer - controls allocation/deallocation of the back buffer.
+    // FIXME: Parameters to discardFramebufferCHROMIUM aren't used, remove when calling code is gone.
+    // FIXME: Remove xxxFramebufferCHROMIUM versions when callers switch to xxxBackbufferCHROMIUM()
+    virtual void discardFramebufferCHROMIUM(WGC3Denum, WGC3Dsizei, const WGC3Denum*) { }
     virtual void ensureFramebufferCHROMIUM() { }
+    virtual void discardBackbufferCHROMIUM() { }
+    virtual void ensureBackbufferCHROMIUM() { }
 
     // Query whether it is built on top of compliant GLES2 implementation.
     virtual bool isGLES2Compliant() = 0;
_______________________________________________
webkit-changes mailing list
webkit-changes@lists.webkit.org
http://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to