[Webkit-unassigned] [Bug 61560] Canvas performance regression with `clip`

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Sat Jun 4 06:24:55 PDT 2011


--- Comment #4 from Jarred Nicholls <jarred at sencha.com>  2011-06-04 06:24:55 PST ---
The clipping path intersection is not being detected by CGContextClip nor CGContextEOClip it would seem.  Surrounding the CG clip w/ save/restore graphics state certainly does fix the issue.  Bug in CG?

@@ -1095,13 +1095,15 @@ void GraphicsContext::clip(const Path& path)

     // CGContextClip does nothing if the path is empty, so in this case, we
     // instead clip against a zero rect to reduce the clipping region to
     // nothing - which is the intended behavior of clip() if the path is empty.
     if (path.isEmpty())
         CGContextClipToRect(context, CGRectZero);
     else {
+        CGContextSaveGState(context);
         CGContextAddPath(context, path.platformPath());
+        CGContextRestoreGState(context);

Configure bugmail: https://bugs.webkit.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.

More information about the webkit-unassigned mailing list