Altium PCB import: Polygon Cutout only cuts copper fill.

Fixes https://gitlab.com/kicad/code/kicad/-/issues/15587
This commit is contained in:
Alex Shvartzkop 2023-09-06 08:43:01 +03:00
parent ee2f954bbe
commit 4f303a8dc2
1 changed files with 24 additions and 2 deletions

View File

@ -1930,7 +1930,18 @@ void ALTIUM_PCB::ConvertShapeBasedRegions6ToBoardItem( const AREGION6& aElem )
zone->SetIsRuleArea( true );
HelperSetZoneKeepoutRestrictions( zone, aElem.keepoutrestrictions );
if( aElem.is_keepout )
{
HelperSetZoneKeepoutRestrictions( zone, aElem.keepoutrestrictions );
}
else if( aElem.kind == ALTIUM_REGION_KIND::POLYGON_CUTOUT )
{
zone->SetDoNotAllowCopperPour( true );
zone->SetDoNotAllowVias( false );
zone->SetDoNotAllowTracks( false );
zone->SetDoNotAllowPads( false );
zone->SetDoNotAllowFootprints( false );
}
zone->SetPosition( aElem.outline.at( 0 ).position );
zone->Outline()->AddOutline( linechain );
@ -2014,7 +2025,18 @@ void ALTIUM_PCB::ConvertShapeBasedRegions6ToFootprintItem( FOOTPRINT* aFoot
zone->SetIsRuleArea( true );
HelperSetZoneKeepoutRestrictions( zone, aElem.keepoutrestrictions );
if( aElem.is_keepout )
{
HelperSetZoneKeepoutRestrictions( zone, aElem.keepoutrestrictions );
}
else if( aElem.kind == ALTIUM_REGION_KIND::POLYGON_CUTOUT )
{
zone->SetDoNotAllowCopperPour( true );
zone->SetDoNotAllowVias( false );
zone->SetDoNotAllowTracks( false );
zone->SetDoNotAllowPads( false );
zone->SetDoNotAllowFootprints( false );
}
zone->SetPosition( aElem.outline.at( 0 ).position );
zone->Outline()->AddOutline( linechain );