[gs-bugs] [Bug 691455] Stroking of sloppily authored paths goes wrong.

bugzilla-daemon at ghostscript.com bugzilla-daemon at ghostscript.com
Wed Jul 14 11:02:17 UTC 2010


http://bugs.ghostscript.com/show_bug.cgi?id=691455

--- Comment #19 from Øyvind Kolås <pippin at gimp.org> 2010-07-14 11:02:13 UTC ---
Created an attachment (id=6480)
 --> (http://bugs.ghostscript.com/attachment.cgi?id=6480)
test-case2.ps

I think the comparison with SVG is valid, unless PostScript has a different
defintion for defining beziers and how beziers are stroked. In my
interpretation of such stroking the end-line of butt and square endcaps should
be tangential to the line defined by the last two coordinates in the curveto
coordinate triplet.

Of course strokepath fill and stroke should produce the same results, I am
arguing that the ghostscript output is just as inprecise in both cases.

Added a postscript file that illustrates another permutation of this corner
case (swapping the last coordinates of the curve). The upper end point still
has a vertical tangent, while the bottom end of the strokes no longer should
have a horizontal tangent.

The same numerical precision issues of using the slope of an insufficiently
precise piece-wise linear approximation causes the exact slope used for the
caps to be wrong.

(An interesting variation of the bug can be seen by using 0 setlinecap instead
of 2 setlinecap)

-- 
Configure bugmail: http://bugs.ghostscript.com/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the QA contact for the bug.


More information about the gs-bugs mailing list