Restrict removal of g0 to clearance height to the engraving of the last base model.

This commit is contained in:
Markus Lampert
2019-02-04 11:44:03 -08:00
committed by Yorik van Havre
parent f07f996c48
commit 2e692dff2d
3 changed files with 7 additions and 2 deletions

View File

@@ -119,6 +119,10 @@ class ObjectDeburr(PathEngraveBase.ObjectOp):
self.wires = wires
self.buildpathocc(obj, wires, zValues, True)
# the last command is a move to clearance, which is automatically added by PathOp
if self.commandlist:
self.commandlist.pop()
def opRejectAddBase(self, obj, base, sub):
'''The chamfer op can only deal with features of the base model, all others are rejected.'''
return not base in self.model

View File

@@ -146,6 +146,9 @@ class ObjectEngrave(PathEngraveBase.ObjectOp):
self.buildpathocc(obj, shapeWires, zValues)
wires.extend(shapeWires)
self.wires = wires
# the last command is a move to clearance, which is automatically added by PathOp
if self.commandlist:
self.commandlist.pop()
except Exception as e:
PathLog.error(e)

View File

@@ -113,8 +113,6 @@ class ObjectOp(PathOp.ObjectOp):
self.appendCommand(cmd, z, rel)
last = edge.Vertexes[0].Point
self.commandlist.append(Path.Command('G0', {'Z': obj.ClearanceHeight.Value, 'F': self.vertRapid}))
if self.commandlist:
self.commandlist.pop()
def appendCommand(self, cmd, z, rel):
params = cmd.Parameters