1) Also reorders parameters to make sure the compiler helps out.
2) This also makes it harder to mess up the discrepency between
BOX2I/wxRECT/etc::Inflate() and SHAPE_POLY_SET::Inflate.
3) Also fixes a couple of bugs where the corner strategy was passed
in as a segCount.
4) Also fixes a couple of bugs where the error wasn't forced to the
outside to match the ERROR_LOCATION.
5) Also fixes a couple of bugs where the seg count was specified
without regard to an already passed-in max deviation
Don't open-code knockout text shape generation in several different
places.
Make sure triangulated knockout text gets clearance added when
specified.
Collapse duplicated footprint text item plot routine (they're no
longer any different from plotting pcb text items).
Adds QA checks to copper sliver tests. Adds the following checks:
- Dot product between two arms (quickly avoids checks for >90°)
- Checks the sliver is convex (area test)
- Eliminates minor slivers with angles that are approximately 0 and ones
with the opposite side width beneath a configurable level
- Updates Clipper2 to fix a couple of jagged edges on inflate
- Adds simplify during zone fill inflation to limit jaggies
Fixes https://gitlab.com/kicad/code/kicad/issues/14549
When filling the zone for the NPTH, the hole should not be considered as
a copper element in terms of clearance. This prevents close but
different knockout elements from being formed
Rounded line ends when deflating leads to microscopic jags in the
outline that are not visible but add substantial computation time and
minor error when computing polygon offsets.
Instead, the chamfer deflate method prevents these jagged lines by
clipping angles < 90° by the error level. This does not impact deflate
calls where we explicitly require the angles to be maintained
When two zones with the same net and same priority overlap, they should
both be filled, matching the behavior of v6. If you would like an
explicit override of one or the other, you need to set the zone priority
higher. Relying on the UUID as a tie breaker is good for zones with
different nets but creates unexpected changes from v6 when applying it
to zones of the same net
This makes it clearer that the overrides are not inverses of each
other -- one overrides the flashing state and the other overrides
the connection state (to other zones, not to everything).
Also fixes a bug where we were failing to check the force-no-connect
for pads.
If removing unused via annular ring option is enabled on a layer, then the via will have the ring if both:
- Via center is not inside a rule area with "Keep out copper fill" flag set
- Highest-priority zone the via hole intersects with has the same net
Pads will be flashed if:
- Pad center is not inside a rule area with "Keep out copper fill" flag set
- Highest-priority zone at the pad center has the same net
Fixes https://gitlab.com/kicad/code/kicad/issues/12964
Just testing a single point to find copper that is outside the board works
until the arc->segment conversion moves the board outline just enough to
have the filled copper slightly (few IU) outside of the converted outline.
Instead, we do an expensive check of comparing the size of the
intersection between the island and the island's intersection with the
board. If the intersection is at least half as large as the original
island, we can say with certainty that the island is inside. The margin
could be much smaller than half but this preserves the intent without
picking an arbitrary number that might be violated
Fixes https://gitlab.com/kicad/code/kicad/issues/13717
Also ensure that calculated areas for island removal are absolute.
The on-outline zone can happen when the clearance to the edge is
particularly small.
Fixes https://gitlab.com/kicad/code/kicad/issues/13717
It is hard for a user to tell what is going on when their zone
just doesn't fill at all. We catch isolated areas in the DRC so
we can just leave them alone here until the zone has at least one
non-isolated filled area.
Also change default back to always remove islands to reduce confusion
Fixes https://gitlab.com/kicad/code/kicad/-/issues/13271
We can't fill lower-priority zones until the higher-priority ones
have been tesselated, and as the tesselation step always gets pushed
to the back of the queue after the fill finishes having them sorted
by priority accomplishes little. (We're also going to push all other
layers of the high-priority zone to the back as the first layer will
have the lock, further degrading the usefulness of sorting.)
If the pad hasn't already been owned by another zone, and the zone we're
currently filling can connect to it, then we want to try to flash it even
if it's not connected to anything else.
Fixes https://gitlab.com/kicad/code/kicad/issues/13415
Handles cancellation in main fill loop. Allows loops to finish without
restarting new ones. Further enhancement might allow breaking threads
cleanly but this gets 90% of the cases
Fixes https://gitlab.com/kicad/code/kicad/issues/12693
1) The highest priority zone that a via/pad collides with "owns" its
connectivity state. Once set, lower priority zones cannot change it --
and in fact, if they would have connected to it are forced not to.
2) The connectivity state goes with the zone fill state, and therefore
must be saved in the file.
3) Display of remove-unconnected's pads is no longer done in GetViewLOD()
(which isn't called for selected items), and is instead done in PCB_PAINTER.
This allows us to draw the full pad in outline mode when a via/pad is
selected which would otherwise only show the hole.
4) Note that in some cases this will still generate DRC errors -- in
particular when a via nearly collides with a higher priority zone it
won't get "owned" by that zone and may therefore have insufficient
clearance if said zone concludes it's unconnected and a subsequent
(lower priority) zone connects to it (causing it to now become flashed).
Fixes https://gitlab.com/kicad/code/kicad/issues/11299
pad of a given number.
Also improves other DRC logic to tighten up the net-tie rules now that
we know which pads are allowed to short with which other pads.
Also removes the "Overlapping pads" DRC violation now that we know
whether or not overlapping pads in a net-tie footprint constitute a
short.
Fixes https://gitlab.com/kicad/code/kicad/issues/12506
Don't wait until all zones are filled before tesselating fills.
Tesselation happens on a layer-by-layer basis, so once the zones' layers
are filled, we can tesselate them in parallel with the remaining fill
work
When multiple zones overlap each other, we need to synchronize the
filling. This should not wait for all zones to try to fill before
restarting. Instead, zones that cannot be filled because the depend on
another zone finishing are immediately re-inserted into the fill queue.
The outline collision is relatively cheap (especially after filtering
bbox collisions) so check if a zone REALLY depends on another zone
before making it wait. Waiting for zones can really increase the total
fill time