Don't apply electrical clearance to shapes on Edge.Cuts.

Also don't apply them to NPTH holes.
This commit is contained in:
Jeff Young 2022-04-13 17:51:42 +01:00
parent c64ea07d0b
commit 604a148f40
1 changed files with 8 additions and 6 deletions

View File

@ -769,18 +769,20 @@ void ZONE_FILLER::buildCopperItemClearances( const ZONE* aZone, PCB_LAYER_ID aLa
if( aItem->GetBoundingBox().Intersects( zone_boundingbox ) )
{
bool ignoreLineWidths = false;
int gap = evalRulesForItems( CLEARANCE_CONSTRAINT, aZone, aItem, aLayer );
int gap = bds.GetDRCEpsilon();
if( aItem->IsOnLayer( Edge_Cuts ) )
if( aItem->IsOnLayer( aLayer ) )
{
gap = std::max( gap, evalRulesForItems( CLEARANCE_CONSTRAINT,
aZone, aItem, aLayer ) );
}
else if( aItem->IsOnLayer( Edge_Cuts ) )
{
gap = std::max( gap, evalRulesForItems( EDGE_CLEARANCE_CONSTRAINT,
aZone, aItem, Edge_Cuts ) );
ignoreLineWidths = true;
gap = std::max( gap, bds.GetDRCEpsilon() );
}
if( aItem->IsOnLayer( Margin ) )
else if( aItem->IsOnLayer( Margin ) )
{
gap = std::max( gap, evalRulesForItems( EDGE_CLEARANCE_CONSTRAINT,
aZone, aItem, Margin ) );