[metapost] Re: all intersections between two paths

Boguslaw Jackowski B_Jackowski at GUST.org.pl
Tue Jan 11 10:27:25 CET 2005

I wrote:
> The crucial assumptions for the algorithm to work are: (1) B\'ezier
> segments have no selfintersections and (2) two B\'ezier segments do not
> intersect at more than two points.

After thinking the matter over, I'm inclined to improve the algorithm,
i.e., to implement the algorithm with less rigid restrictions.

Obviously, not all cases can be handled robustly using MF/MP.
The most notable example is the case of infinitely many common
points, i.e., (partially) overlapping B\'ezier curves. As you
could seen from one of the examples, also the problem of tangency
cannot be handled robustly.

On the other hand, since the finding of the points of
selfintersections using MF/MP is fairly straightforward,
I'd rather uphold the assumption (1). But I'm not sure...

My question is: which constraints imposed on single B\'ezier segments
you would consider reasonable?

Thanks -- Jacko

 Bogus\l{}aw Jackowski: B_Jackowski at GUST.ORG.PL
 Hofstadter's Law: It always takes longer than you expect, even
                   when you take into account Hofstadter's Law.

More information about the metapost mailing list