Fix issue with tool size

This commit is contained in:
Marc-Antoine Lafreniere
2019-02-26 20:54:19 -05:00
parent 46a3a02b2a
commit 921e04f88c

View File

@@ -24,7 +24,11 @@ if __name__ == "__main__":
else: else:
pxHeight, pxWidth = FileUtils.getPixelSize(height, width, args.he, args.wi) pxHeight, pxWidth = FileUtils.getPixelSize(height, width, args.he, args.wi)
rTool = int(math.ceil(args.t * pxHeight if pxHeight > pxWidth else pxWidth)) if pxHeight > pxWidth:
rTool = int(math.ceil(args.t * pxHeight))
else:
rTool = int(math.ceil(args.t * pxWidth))
matrixUpdated = path(matrix, rTool) matrixUpdated = path(matrix, rTool)
listIndexes = createSequence(matrixUpdated) listIndexes = createSequence(matrixUpdated)
gcode = listToGCode(listIndexes, pxHeight, pxWidth) gcode = listToGCode(listIndexes, pxHeight, pxWidth)