- work in Gerber Export: finished the body export but have some errors with clear geometry (LPC)
This commit is contained in:
parent
bdd13a3800
commit
5b663c5f20
@ -1330,11 +1330,12 @@ class FlatCAMGerber(FlatCAMObj, Gerber):
|
||||
gerber_code += 'D02*\n'
|
||||
gerber_code += 'G37*\n'
|
||||
|
||||
if 'clear_geometry' in self.apertures['0']:
|
||||
clear_list = list(geo.interiors)
|
||||
if clear_list:
|
||||
gerber_code += '%LPC*%\n'
|
||||
for geo in self.apertures['0']['clear_geometry']:
|
||||
for clear_geo in clear_list:
|
||||
gerber_code += 'G36*\n'
|
||||
geo_coords = list(geo.exterior.coords)
|
||||
geo_coords = list(clear_geo.coords)
|
||||
|
||||
# first command is a move with pen-up D02 at the beginning of the geo
|
||||
if g_zeros == 'T':
|
||||
|
@ -15,6 +15,7 @@ CAD program, and create G-Code for Isolation routing.
|
||||
- work in Gerber Export: finished the header export
|
||||
- fixed the Gerber Object and Gerber Editor Apertures Table to not show extra rows when there are aperture macros in the object
|
||||
- work in Gerber Export: finished the body export but have some errors with clear geometry (LPC)
|
||||
- Gerber Export - finished
|
||||
|
||||
6.05.2019
|
||||
|
||||
|
@ -3219,7 +3219,7 @@ class Gerber (Geometry):
|
||||
if 'clear_geometry' in self.apertures[apid]:
|
||||
for pol in self.apertures[apid]['clear_geometry']:
|
||||
global_clear_geo.append(pol)
|
||||
# self.apertures[apid].pop('clear_geometry', None)
|
||||
self.apertures[apid].pop('clear_geometry', None)
|
||||
log.warning("Found %d clear polygons." % len(global_clear_geo))
|
||||
|
||||
temp_geo = []
|
||||
@ -3497,11 +3497,14 @@ class Gerber (Geometry):
|
||||
# we need to scale the geometry stored in the Gerber apertures, too
|
||||
try:
|
||||
for apid in self.apertures:
|
||||
if 'solid_geometry' in self.apertures[apid]:
|
||||
self.apertures[apid]['solid_geometry'] = scale_geom(self.apertures[apid]['solid_geometry'])
|
||||
if 'follow_geometry' in self.apertures[apid]:
|
||||
self.apertures[apid]['follow_geometry'] = scale_geom(self.apertures[apid]['follow_geometry'])
|
||||
if 'clear_geometry' in self.apertures[apid]:
|
||||
self.apertures[apid]['clear_geometry'] = scale_geom(self.apertures[apid]['clear_geometry'])
|
||||
|
||||
except Exception as e:
|
||||
log.debug('FlatCAMGeometry.scale() --> %s' % str(e))
|
||||
log.debug('camlib.Gerber.scale() Exception --> %s' % str(e))
|
||||
|
||||
self.app.inform.emit(_("[success] Gerber Scale done."))
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user