Title: [122619] trunk/Source/WebCore
Revision
122619
Author
[email protected]
Date
2012-07-13 12:40:30 -0700 (Fri, 13 Jul 2012)

Log Message

[chromium] Remove incorrect debug assertion in LayerRendererChromium.cpp
https://bugs.webkit.org/show_bug.cgi?id=91260

Reviewed by Adrienne Walker.

ASSERT(!clipped) was being triggered after skinny almost-degenerate
quads went through anti-aliasing inflation, and then were being
transformed back from device space to local space. It turns out
this assertion is too aggressive, and we don't yet have an obvious
need to change the behavior on the clipped==true case.

No new tests needed, this patch fixes only comments and debug code.

* platform/graphics/chromium/LayerRendererChromium.cpp:
(WebCore::LayerRendererChromium::drawRenderPassQuad):
   fixed a comment.

(WebCore::LayerRendererChromium::drawTileQuad):
   fixed a similar comment, removed unnecessary assertion.

Modified Paths

Diff

Modified: trunk/Source/WebCore/ChangeLog (122618 => 122619)


--- trunk/Source/WebCore/ChangeLog	2012-07-13 19:11:12 UTC (rev 122618)
+++ trunk/Source/WebCore/ChangeLog	2012-07-13 19:40:30 UTC (rev 122619)
@@ -1,3 +1,25 @@
+2012-07-13  Shawn Singh  <[email protected]>
+
+        [chromium] Remove incorrect debug assertion in LayerRendererChromium.cpp
+        https://bugs.webkit.org/show_bug.cgi?id=91260
+
+        Reviewed by Adrienne Walker.
+
+        ASSERT(!clipped) was being triggered after skinny almost-degenerate
+        quads went through anti-aliasing inflation, and then were being
+        transformed back from device space to local space. It turns out
+        this assertion is too aggressive, and we don't yet have an obvious
+        need to change the behavior on the clipped==true case.
+
+        No new tests needed, this patch fixes only comments and debug code.
+
+        * platform/graphics/chromium/LayerRendererChromium.cpp:
+        (WebCore::LayerRendererChromium::drawRenderPassQuad):
+           fixed a comment.
+
+        (WebCore::LayerRendererChromium::drawTileQuad):
+           fixed a similar comment, removed unnecessary assertion.
+
 2012-07-13  Philip Rogers  <[email protected]>
 
         Remove assert in localCoordinateSpaceTransform()

Modified: trunk/Source/WebCore/platform/graphics/chromium/LayerRendererChromium.cpp (122618 => 122619)


--- trunk/Source/WebCore/platform/graphics/chromium/LayerRendererChromium.cpp	2012-07-13 19:11:12 UTC (rev 122618)
+++ trunk/Source/WebCore/platform/graphics/chromium/LayerRendererChromium.cpp	2012-07-13 19:40:30 UTC (rev 122619)
@@ -699,7 +699,7 @@
         GLC(context(), context()->uniform3fv(shaderEdgeLocation, 8, edge));
     }
 
-    // Map device space quad to surface space. contentsDeviceTransform has no perspective since it was generated with to2dTransform() so we don't need to project.
+    // Map device space quad to surface space. contentsDeviceTransform has no 3d component since it was generated with to2dTransform() so we don't need to project.
     FloatQuad surfaceQuad = CCMathUtil::mapQuad(contentsDeviceTransform.inverse(), deviceLayerEdges.floatQuad(), clipped);
     ASSERT(!clipped);
 
@@ -879,10 +879,12 @@
         // Create device space quad.
         CCLayerQuad deviceQuad(leftEdge, topEdge, rightEdge, bottomEdge);
 
-        // Map quad to layer space.
+        // Map device space quad to local space. contentsDeviceTransform has no 3d component since it was generated with to2dTransform() so we don't need to project.
         WebTransformationMatrix inverseDeviceTransform = deviceTransform.inverse();
         localQuad = CCMathUtil::mapQuad(inverseDeviceTransform, deviceQuad.floatQuad(), clipped);
-        ASSERT(!clipped);
+
+        // We should not ASSERT(!clipped) here, because anti-aliasing inflation may cause deviceQuad to become
+        // clipped.  To our knowledge this scenario does not need to be handled differently than the unclipped case.
     } else {
         // Move fragment shader transform to vertex shader. We can do this while
         // still producing correct results as fragmentTexTransformLocation
_______________________________________________
webkit-changes mailing list
[email protected]
http://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to