mirror of
https://github.com/ajisaacs/OpenNest.git
synced 2026-10-25 15:11:06 -04:00
fix(clamps): judge tiny keep-outs tolerance-free in interactive fill
InteractiveClamps.MaterialInKeepOut flattened a sub-tolerance keep-out with the 0.001 polygon tolerance and called a part covering a 1e-5 clamp clear, so the fill safety net could pass it. Keep-outs below the tolerance now use KeepOutOverlap. Adds the 1e-5 zone sweep through every fill strategy and a push (characterization; both already stay clear). PM b0062c73-40ef-440e-8efb-b94908f7c2d1
This commit is contained in:
1 parent
8f0c0692fd
commit
9b5885e5a2
2 files changed
+60
No files matched your search
@@ -97,6 +97,11 @@ internal static class InteractiveClamps
|
||||
var partProfile = new ShapeProfile(PartGeometry.GetPartEntities(part));
|
||||
if (partProfile.Perimeter == null)
|
||||
return true;
|
||||
// A keep-out below the polygon tolerance collapses in the tolerant test and would
|
||||
// read as clear (PM b0062c73); judge it tolerance-free instead.
|
||||
if (KeepOutOverlap.NeedsToleranceFreeTest(keepOut))
|
||||
return KeepOutOverlap.MaterialEnters(partProfile.Perimeter.ToPolygonWithTolerance(0.001),
|
||||
HolePolygons(partProfile), keepOut);
|
||||
var zoneProfile = new ShapeProfile(RectangleEntities(keepOut));
|
||||
if (zoneProfile.Perimeter == null)
|
||||
return true;
|
||||
|
||||
Reference in new issue
Block a user