On Tue, 2009-02-17 at 13:29 -0800, Ben Jackson wrote: > On Tue, Feb 17, 2009 at 09:08:33PM +0000, Peter Clifton wrote: > > > > > > I think the only straightforward way to fix the self-intersecting arc is > > > to build it internally from two parts and union them. Might be slow on > > > teardrop'd boards. > > > > Probably just need some simple geometry to work out if it would > > self-intersect or not fn(radius, width, angle), and do something > > different with those cases which do. Unfortunately, there is (of > > course), a whole family of potential intersections, so its not quite as > > simple as just specifying an outer circle poly, with a circular hole. > > You just build it as two halves and use the polygon code to union it. > The math to make the self-intersecting arc "by hand" is going to end up > being a special case of exactly what the polygon code will do. Your fn() > shouldn't be too bad, I think it's just "find the coordinates of the arc > endpoints and see if they're <thickness apart".
Plus some tolerance I'd guess, to account for potential errors in whatever \_/ approximation gets used for the caps. I agree we ought to use the polygon code rather than trying to special case it directly, I just hoped we could avoid the cost of bisecting each arc we cleared. -- Peter Clifton Electrical Engineering Division, Engineering Department, University of Cambridge, 9, JJ Thomson Avenue, Cambridge CB3 0FA Tel: +44 (0)7729 980173 - (No signal in the lab!) _______________________________________________ geda-user mailing list [email protected] http://www.seul.org/cgi-bin/mailman/listinfo/geda-user

