Fix incorrect aperture macro outline primitive point count

This commit is contained in:
jaseg 2023-04-29 12:15:55 +02:00
parent 8d5403260b
commit fdb07ea26e

View file

@ -290,7 +290,7 @@ class Outline(Primitive):
rotation = ConstantExpression(0)
coords = ','.join(coord.to_gerber(unit) for coord in coords)
return f'{self.code},{self.exposure.to_gerber()},{len(self.coords)-1},{coords},{rotation.to_gerber()}'
return f'{self.code},{self.exposure.to_gerber()},{len(self.coords)//2-1},{coords},{rotation.to_gerber()}'
def to_graphic_primitives(self, offset, rotation, variable_binding={}, unit=None, polarity_dark=True):
with self.Calculator(self, variable_binding, unit) as calc: