Correction: it's not monotonicity that matters, but having the two
control points on different sides of the straight line.
Graham Asher wrote:
The aim is to draw a straight line between the start end end of a
cubic spline, instead of rendering the curve correctly, if the curve
deviates by less than a certain value from the straight line. The code
in gray_render_cubic in ftgrays.c checks only the midpoint of the
curve. However, this is not necessarily the furthest point from the
straight line. If the sequence start, control1, control2, end is not
monotonic in one of the dimensions x, y, an s-shaped curve is produced
with points further from the line than the midpoint, which may even
lie on the line. This situation occurs in 's' for the sample font.
With this information I can easily produce a fix, simply by testing
for non-monotonicity and disabling the optimisation in such
circumstances, but I shall see if I can up with something slightly
better.
Graham
_______________________________________________
Freetype-devel mailing list
Freetype-devel@nongnu.org
http://lists.nongnu.org/mailman/listinfo/freetype-devel