[Webkit-unassigned] [Bug 28820] Chromium: do anti-aliased path clipping

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Fri Sep 4 03:06:14 PDT 2009


https://bugs.webkit.org/show_bug.cgi?id=28820





--- Comment #10 from Dean McNamee <deanm at chromium.org>  2009-09-04 03:06:13 PDT ---
(In reply to comment #9)
> I think you're taking the word 'bodge' as too pejorative. The correct
> application of sensible bodges is called 'engineering'. Doing anti-aliased
> clipping as you draw is a bodge: you get the wrong answer. But in this case
> it's a sensible bodge. I rather wish Skia would support it as this point.
> 
> <canvas> not having anti-aliased clipping is unfortunate for some, and a
> requirement for others. I think it's just a manifestation of anything complex
> in early stages.

Looks like I don't have permission to review the patch.  Anyway, some small
feedback.

> +
> +        // This clip function is used only by <canvas> code. It allows
> +        // implementations to handle clipping on the canvas differently since
> +        // the disipline is different.

discipline ?

> +    // If we are currently tracking any anti-alias clip paths, then we already
> +    // have a layer in place and don't need to add another.
> +    bool haveLayerOutstanding = m_state->m_antiAliasClipPaths.size();

How about !isEmpty() ?  Actually, you could flip the logic to
noOustandingLayers, and invert the if() also.  You could also just do the
append 
and check if size == 1.


> +    for (size_t i = paths.size() - 1; i < paths.size(); --i) {
> +        paths[i].setFillType(SkPath::kInverseWinding_FillType);

Cool man...

-- 
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