Title: [145159] trunk/Source/WebCore
Revision
145159
Author
[email protected]
Date
2013-03-07 17:06:47 -0800 (Thu, 07 Mar 2013)

Log Message

Compute WebGL context attributes from DrawingBuffer when it is used
https://bugs.webkit.org/show_bug.cgi?id=111666

Reviewed by James Robinson.

Fixed computation of antialias flag when DrawingBuffer is used.

No new tests; covered by existing tests. Ran WebGL conformance
tests on desktop Linux and Android to test.

* html/canvas/WebGLRenderingContext.cpp:
(WebCore):
(WebCore::WebGLRenderingContext::getContextAttributes):
    Query DrawingBuffer, when used, for antialias flag.

Modified Paths

Diff

Modified: trunk/Source/WebCore/ChangeLog (145158 => 145159)


--- trunk/Source/WebCore/ChangeLog	2013-03-08 00:59:21 UTC (rev 145158)
+++ trunk/Source/WebCore/ChangeLog	2013-03-08 01:06:47 UTC (rev 145159)
@@ -1,3 +1,20 @@
+2013-03-07  Kenneth Russell  <[email protected]>
+
+        Compute WebGL context attributes from DrawingBuffer when it is used
+        https://bugs.webkit.org/show_bug.cgi?id=111666
+
+        Reviewed by James Robinson.
+
+        Fixed computation of antialias flag when DrawingBuffer is used.
+
+        No new tests; covered by existing tests. Ran WebGL conformance
+        tests on desktop Linux and Android to test.
+
+        * html/canvas/WebGLRenderingContext.cpp:
+        (WebCore):
+        (WebCore::WebGLRenderingContext::getContextAttributes):
+            Query DrawingBuffer, when used, for antialias flag.
+
 2013-03-07  Beth Dakin  <[email protected]>
 
         Need API to draw custom overhang area

Modified: trunk/Source/WebCore/html/canvas/WebGLRenderingContext.cpp (145158 => 145159)


--- trunk/Source/WebCore/html/canvas/WebGLRenderingContext.cpp	2013-03-08 00:59:21 UTC (rev 145158)
+++ trunk/Source/WebCore/html/canvas/WebGLRenderingContext.cpp	2013-03-08 01:06:47 UTC (rev 145159)
@@ -2342,12 +2342,17 @@
 
     // Also, we need to enforce requested values of "false" for depth
     // and stencil, regardless of the properties of the underlying
-    // GraphicsContext3D.
+    // GraphicsContext3D or DrawingBuffer.
     RefPtr<WebGLContextAttributes> attributes = WebGLContextAttributes::create(m_context->getContextAttributes());
     if (!m_attributes.depth)
         attributes->setDepth(false);
     if (!m_attributes.stencil)
         attributes->setStencil(false);
+    if (m_drawingBuffer) {
+        // The DrawingBuffer obtains its parameters from GraphicsContext3D::getContextAttributes(),
+        // but it makes its own determination of whether multisampling is supported.
+        attributes->setAntialias(m_drawingBuffer->multisample());
+    }
     return attributes.release();
 }
 
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to