broaden edge type checking to include BoardCircle
This commit is contained in:
parent
6a639f2c7f
commit
e5c2c90cb2
1 changed files with 3 additions and 1 deletions
|
|
@ -4,6 +4,7 @@ import FreeCAD as App
|
|||
from . import settings
|
||||
import Part
|
||||
|
||||
from kipy import board_types as BoardTypes
|
||||
from kipy.board_types import Footprint3DModel, BoardArc, BoardPolygon, BoardSegment, PadStackShape
|
||||
from kipy.geometry import PolygonWithHoles, PolyLine, PolyLineNode, Vector2
|
||||
from kipy.proto.common.types import KiCadObjectType
|
||||
|
|
@ -197,7 +198,8 @@ def makeBoard(parent, kicad_board, polygon):
|
|||
def extract_polygons(board):
|
||||
# find polygons of Edge Cuts
|
||||
edge_cuts = [ edge for edge in board.get_shapes() if edge.layer == BoardLayer.BL_Edge_Cuts ]
|
||||
polygons = [ edge for edge in edge_cuts if (isinstance(edge, BoardPolygon) or isinstance(edge, BoardArc)) ]
|
||||
|
||||
polygons = [ edge for edge in edge_cuts if (isinstance(edge, BoardPolygon) or isinstance(edge, BoardArc) or isinstance(edge, BoardTypes.BoardCircle)) ]
|
||||
|
||||
return polygons
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue