[whatwg] Canvas line styles comments
Philip Taylor
excors+whatwg at gmail.com
Sat Feb 2 14:20:45 PST 2008
On 02/02/2008, Kristof Zelechovski <giecrilj at stegny.2a.pl> wrote:
> You considered the convex hull of the original lines to get that paradox;
> I had the stroke path segments in mind.
> (Stroke path segments are the path equivalent of the stroked curve
> when the stroke operator is not allowed and must be replaced by the fill
> operator).
> Each line corresponds to two parallel stroke path segments;
> two of them intersect and the other two get joint with an arc.
> One of the possible arcs is in the convex hull of those stroke path
> segments.
If the two lines are very short, their stroke paths will (if I
understand correctly) look like
.-.
| |
| |
| |
.-----|-*-------.
'-----|-|-------'
| |
| |
'-'
where the * is the join point and the short lines are the two parallel
stroke path segments of each line. Then the convex hull is nearly a
square rotated by 45 degrees, like
.-.
/| |'-
/ | | '-
/ | | '-.
.-----|-*-------.
'-----|-|-------'
'. | | .-'
'-.| |_.-'
'-'
and so an arc with radius lineWidth/2 from the rightmost point going
clockwise to the upmost point will not be contained entirely within
that nearly-square. So neither arc is within the convex hull.
--
Philip Taylor
excors at gmail.com
More information about the whatwg
mailing list