Polygon to line separation DRC wrong
Bug #746178 reported by
Stephen Ecob
This bug affects 1 person
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
pcb |
Fix Released
|
High
|
Luis de Arquer |
Bug Description
DRC incorrectly complains about the clearance between polygon and line in the attached PCB.
With minclear set to 3.98mil DRC complains, even though the separation is about 4.5mil.
PCB version is GIT head fetched on 20110329, patched with Peter Clifton's patch for bug 746093
Changed in geda-project: | |
importance: | Undecided → Medium |
tags: | added: drc polygons |
Changed in pcb: | |
milestone: | none → pcb-4.2.0 |
status: | New → In Progress |
Changed in pcb: | |
milestone: | pcb-4.2.0 → pcb-4.1.3 |
status: | In Progress → Fix Committed |
Changed in geda-project: | |
status: | New → Fix Committed |
Changed in pcb: | |
status: | Fix Committed → Fix Released |
Changed in geda-project: | |
status: | Fix Committed → Fix Released |
To post a comment you must log in.
I have been stumbling with DRC issues which could be reduced to the same problem, even with latest master as of 07/2018 (commit 475c79598)
The reason why this happens is that, when the track is considered to plow through the polygon, only the clearance of the line is taken into account, not the real distance to the polygon.
if (line->Clearance < 2 * PCB->Bloat) agUndoList (type, ptr1, ptr2, ptr2);
{
AddObjectToFl
SET_FLAG (i->flag, line);
message = _("Line with insufficient clearance inside polygon\n");
goto doIsBad;
}
But PlowsPolygon() uses the bounding box of the line, which is not very accurate, rendering some false positives. The function IsLineInPolygon(), though, performs an accurate, though more expensive, test.
If we use IsLineInPolygon() with the "candidates" detected by PlowsPolygon(), the bug is fixed. Also, it fixed other related bugs (for example, when the plowing line has low clearance, but still is far from the polygon because other elements of higher clearance plow the polygon at the same place too).